mirror of
https://github.com/ae-utbm/sith.git
synced 2024-11-22 14:13:21 +00:00
Reindent stock app
This commit is contained in:
parent
20deda8a8e
commit
df20bf6dde
@ -373,7 +373,7 @@ class StockTakeItemsBaseFormView(CounterTabsMixin, CanEditMixin, DetailView, Bas
|
|||||||
for i in self.stock.items.filter(type=t).order_by('name').all():
|
for i in self.stock.items.filter(type=t).order_by('name').all():
|
||||||
field_name = "item-%s" % (str(i.id))
|
field_name = "item-%s" % (str(i.id))
|
||||||
fields[field_name] = forms.IntegerField(required=False, label=str(i), initial=0, min_value=0, max_value=i.effective_quantity,
|
fields[field_name] = forms.IntegerField(required=False, label=str(i), initial=0, min_value=0, max_value=i.effective_quantity,
|
||||||
help_text=_("("+ str(i.effective_quantity) + " left)"))
|
help_text=_("(%(effective_quantity)s left" % {"effective_quantity": str(i.effective_quantity)}))
|
||||||
kwargs[field_name] = i.effective_quantity
|
kwargs[field_name] = i.effective_quantity
|
||||||
kwargs['stock_id'] = self.stock.id
|
kwargs['stock_id'] = self.stock.id
|
||||||
kwargs['counter_id'] = self.stock.counter.id
|
kwargs['counter_id'] = self.stock.counter.id
|
||||||
|
Loading…
Reference in New Issue
Block a user