mirror of
https://github.com/django/django.git
synced 2025-07-04 17:59:13 +00:00
magic-removal: Fixed #1557 -- Fixed typo in generic-views success message. Thanks, Matthew Flanagan
git-svn-id: http://code.djangoproject.com/svn/django/branches/magic-removal@2595 bcc190cf-cafb-0310-a4f2-bffc1f526a37
This commit is contained in:
parent
07131c390d
commit
344cc981f6
@ -39,7 +39,7 @@ def create_object(request, model, template_name=None,
|
|||||||
new_object = manipulator.save(new_data)
|
new_object = manipulator.save(new_data)
|
||||||
|
|
||||||
if not request.user.is_anonymous():
|
if not request.user.is_anonymous():
|
||||||
request.user.message_set.create(message="The %s was created sucessfully." % model._meta.verbose_name)
|
request.user.message_set.create(message="The %s was created successfully." % model._meta.verbose_name)
|
||||||
|
|
||||||
# Redirect to the new object: first by trying post_save_redirect,
|
# Redirect to the new object: first by trying post_save_redirect,
|
||||||
# then by obj.get_absolute_url; fail if neither works.
|
# then by obj.get_absolute_url; fail if neither works.
|
||||||
@ -111,7 +111,7 @@ def update_object(request, model, object_id=None, slug=None,
|
|||||||
manipulator.save(new_data)
|
manipulator.save(new_data)
|
||||||
|
|
||||||
if not request.user.is_anonymous():
|
if not request.user.is_anonymous():
|
||||||
request.user.message_set.create(message="The %s was updated sucessfully." % model._meta.verbose_name)
|
request.user.message_set.create(message="The %s was updated successfully." % model._meta.verbose_name)
|
||||||
|
|
||||||
# Do a post-after-redirect so that reload works, etc.
|
# Do a post-after-redirect so that reload works, etc.
|
||||||
if post_save_redirect:
|
if post_save_redirect:
|
||||||
|
Loading…
x
Reference in New Issue
Block a user