You called this URL via POST, but the URL doesn't end in a slash and you have APPEND_SLASH set. Django can't redirect to the slash URL while maintaining POST data. Change your form to point to localhost:8000/admin/substance/substance/1442/change/payment/ (note the trailing slash), or set APPEND_SLASH=False in your Django settings.
invalid literal for int() with base 10: '1442/change/payment'
It looks like your second URL is different than the first.
/admin/substance/substance/1442/change/payment
/admin/substance/substance/1442/change/payment/change/
If you just want to add a slash, then add it.
/admin/substance/substance/1442/change/payment/
I’m guessing that Django is interpreting the second URL like so:
/admin/substance/substance/(pk=1442/change/payment)/change/
--
You received this message because you are subscribed to the Google Groups "Django users" group.
To unsubscribe from this group and stop receiving emails from it, send an email to
django-users...@googlegroups.com.
To post to this group, send email to
django...@googlegroups.com.
Visit this group at https://groups.google.com/group/django-users.
To view this discussion on the web visit
https://groups.google.com/d/msgid/django-users/f8061a7d-27b5-c929-c364-d8870829ad3e%40dewhirst.com.au.
For more options, visit https://groups.google.com/d/optout.
To unsubscribe from this group and stop receiving emails from it, send an email to django-users...@googlegroups.com.
To post to this group, send email to django...@googlegroups.com.
Visit this group at https://groups.google.com/group/django-users.
To view this discussion on the web visit https://groups.google.com/d/msgid/django-users/07926202-7c6b-4486-878c-aacdb9f556e6%40dewhirst.com.au.
For more options, visit https://groups.google.com/d/optout.
Hi Mike, I'm not really seeing why this is throwing errors at you. It seems like you've done everything right. Could you provide the code (or the relevant parts) for the Substance Admin form? Thanks!
Based on the error message, it looks like you’re trying to call reverse(‘admin’) somewhere, but that’s not in the code you shared. Actually, you probably want to use a reverse call when populating content[‘link’].
From: django...@googlegroups.com [mailto:django...@googlegroups.com]
On Behalf Of Mike Dewhirst
Sent: Friday, January 25, 2019 3:35 AM
To: django...@googlegroups.com
Subject: Re: Admin form_url breakout problem
On 25/01/2019 2:40 am, Matthew Pava wrote:
--
You received this message because you are subscribed to the Google Groups "Django users" group.
To unsubscribe from this group and stop receiving emails from it, send an email to
django-users...@googlegroups.com.
To post to this group, send email to
django...@googlegroups.com.
Visit this group at https://groups.google.com/group/django-users.
To view this discussion on the web visit https://groups.google.com/d/msgid/django-users/c70b8afa-6c7b-07b8-3f5d-ec2da8047951%40dewhirst.com.au.