Re: Proposal: make Model __unicode__() default to self.name

2017-12-12 Thread Alex Corcoles
Hi Collin, On Tuesday, December 12, 2017 at 3:48:38 PM UTC+1, Collin Anderson wrote: > Yes, having a good __str__ is important, and thats why i think defaulting > it to the pk is good, because it's better than nothing. Yes, you'll still > want to override __str__ with something better (that lik

Re: Proposal: make Model __unicode__() default to self.name

2017-12-11 Thread Alex Corcoles
Sorry to resurrect this, but I commented on the bug tracker ( https://code.djangoproject.com/ticket/28839#comment:4 ) and was told to take the discussion here. I want to point out that __str__ is used for "GUI" purposes (such as dropdown texts in ModelForm/ModelAdmin) and putting a default __st