On Dec 12, 8:45 am, Dennis Schmidt wrote:
> Hi,
>
> actually that is how I do it. I'm subclassing from admin.ModelAdmin
> and then set the form-field to the custom form I made. But maybe this
> really only works for forms in applications.
No, it does work in the admin too. Setting the form att
Hi,
actually that is how I do it. I'm subclassing from admin.ModelAdmin
and then set the form-field to the custom form I made. But maybe this
really only works for forms in applications. I'll try that out. Thx
On 12 Dez., 14:31, Matias wrote:
> Hi,
>
> How do you register the model in the admin
Hi,
How do you register the model in the admin site?
You should register your model using a ModelAdmin subclass.
Here is some docs that may help you
http://docs.djangoproject.com/en/dev/ref/contrib/admin/
The ModelForms are ment to be used in your applications rather than the
admin site.
Hope t
Hello,
I have a problem with ModelForms in the django admin site. I want to
exclude some fields so they won't be displayed when I edit the model
in the admin site. This is my code:
class CommonInvoiceForm(forms.ModelForm):
price_factor = forms.ChoiceField(choices=COST_FACTOR_CHOICES)
4 matches
Mail list logo