5

i have installed photologue - A customizable plug-in photo management application for the Django web framework here into my project without problem...

now i want to change app name in admin page which is photologue. for this i have used ugettext_lazy but i got an error when i define this to all Meta:

from django.utils.translation import ugettext_lazy as _

class Meta:
    app_label = _('newappname')

Error:

ValueError at /admin/

Cannot create form field for 'effect' yet, because its related model 
'PhotoEffect' has not been loaded yet

Is there any easy way for changing app name, i have looked a lot but didnt find...

urcm
  • 2,274
  • 1
  • 19
  • 45

1 Answers1

2

Django does not support app renaming in the admin right now, but ticket #3591 was raised to add that functionality, so hopefully it will be added.

There are several ways of acomplishing that. The simplest and preferred would be changing the main admin template and using whatever name you want as the app name there.

Other solutions:

Community
  • 1
  • 1
Mariusz Jamro
  • 30,615
  • 24
  • 120
  • 162
  • @thanks for replying... how can i install this ticket, i have never installed any ticket before... and changing template i didnt find my app name in change_list.html ... – urcm Jul 10 '12 at 13:31
  • Look for lines like `{% blocktrans with name=app.name %}{{ name }}{% endblocktrans %}`. E.g the admin index template: https://github.com/django/django/blob/master/django/contrib/admin/templates/admin/index.html#L21 – Mariusz Jamro Jul 10 '12 at 13:35
  • this method is not fit to me bacause of using grappelli ui in django... can u help me about installing this ticket.. – urcm Jul 10 '12 at 13:45