Andre, you're right.
But a subclass would probably save me one line:
model = OrderItem
The rest follows a pattern but is otherwise unique. I'm going to look into
dynamic forms as suggested by Derek
On Tue, Jun 21, 2011 at 5:42 PM, Andre Terra wrote:
> I'm reading
I'm reading this on my phone, so I apologize in advice if I missed
something crucial, but what's stopping you from subclassing and
overriding just the relevant parts?
Sincerely,
Andre Terra
On 6/17/11, Nikhil Somaru wrote:
> Hi,
>
> Is there a way to reduce the repetition in
Thanks derek.
On Sat, Jun 18, 2011 at 8:03 AM, Nikhil Somaru wrote:
> Hi,
>
> Is there a way to reduce the repetition in the following form classes:
>
> class ItemsStep2(ModelForm): #approval
> class Meta:
> model = OrderItem
> fields = ('item',
Hi,
Is there a way to reduce the repetition in the following form classes:
class ItemsStep2(ModelForm): #approval
class Meta:
model = OrderItem
fields = ('item', 'quantity_requested', 'quantity_approved')
widgets = {
'quantity_requested':
4 matches
Mail list logo