Opened 9 years ago

Closed 9 years ago

Last modified 9 years ago

#25336 closed Bug (wontfix)

activate current language when clicking view_on_site button in Django Post admin page

Reported by: Zoe Owned by: Zoe
Component: contrib.admin Version: 1.7
Severity: Normal Keywords: multiple languages, post admin, view on site
Cc: Triage Stage: Unreviewed
Has patch: no Needs documentation: no
Needs tests: no Patch needs improvement: no
Easy pickings: no UI/UX: no

Description

The issue is in single post admin page, when the post has multi-language, the view_on_site button always navigate to the default language no matter what language the obj is using. The solution is simple to activate the current language and create a url with current language code instead of default language always.

Attachments (1)

options.py (79.5 KB ) - added by Zoe 9 years ago.
the solution is between line 273-278

Download all attachments as: .zip

Change History (5)

by Zoe, 9 years ago

Attachment: options.py added

the solution is between line 273-278

comment:2 by Zoe, 9 years ago

Owner: changed from nobody to Zoe
Status: newassigned

comment:3 by Zoe, 9 years ago

Resolution: fixed
Status: assignedclosed

comment:4 by Tim Graham, 9 years ago

Resolution: fixedwontfix

As discussed on the pull request. It's not clear to me that this can't be solved in a custom get_absolute_url() method. Assuming that the model instance has a language_code doesn't seem like a good idea. Please reopen with more details if you find that it can't be solved without making a change to Django. Thanks!

Note: See TracTickets for help on using tickets.
Back to Top