Thanks. That worked for enabling translations for poll names - i had to insert 'from django.contrib.contenttypes import generic', right? It worked, but it raised few more questions. When creating poll i get lines for name translations now and in front of each of them there is language drop down menu, where i can choose to which language this translation belongs to. How can i replace that with just language name. Do i have to create some kind of loop for that view (/poll/poll/ add), so i just get correct amount of name translations and nothing else?
in any case it worked, but when i tried to save that poll i got this error : Request URL: http://127.0.0.1:8000/admin/poll/poll/add/ Exception Type: TypeError Exception Value: coercing to Unicode: need string or buffer, GenericRelatedObjectManager found Runnin search on that error i found : http://mail.python.org/pipermail/python-list/2006-July/566947.html Does that mean, that connection between translation and poll name failed or something else at all? Alan. On Apr 9, 6:36 pm, matehat <mathieu.damo...@gmail.com> wrote: > First of all, the ModelAdmin needs to know about how to handle the > generic relations and whether you even need them to appear. You need > to subclass "generic.GenericTabularInline" (in the same way you > subclassed "admin.ModelAdmin") and specify fields you want to be able > to edit on that Trans object (probably only the "name" field if I > understood right) and the actual model (here Trans). Then, you'd need > to add the 'inlines' attribute to your PollAdmin and add the > GenericTabularInline subclass. So your code should look something > like : > > http://dpaste.com/30763/ --~--~---------~--~----~------------~-------~--~----~ You received this message because you are subscribed to the Google Groups "Django users" group. To post to this group, send email to django-users@googlegroups.com To unsubscribe from this group, send email to django-users+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/django-users?hl=en -~----------~----~----~----~------~----~------~--~---