Add "min % diff" option for pricing batch from products query
refactor the "batch from query" a bit also, to allow for multiple batch type options which represent the same underlying batch type. (thought i needed that, then realized i didn't, but seems safe to include.)
This commit is contained in:
parent
d9e5eff23d
commit
3b54ab3e0b
3 changed files with 56 additions and 35 deletions
tailbone/views/batch
|
@ -49,6 +49,11 @@ class PricingBatchView(BatchMasterView):
|
|||
rows_editable = True
|
||||
rows_bulk_deletable = True
|
||||
|
||||
labels = {
|
||||
'min_diff_threshold': "Min $ Diff",
|
||||
'min_diff_percent': "Min % Diff",
|
||||
}
|
||||
|
||||
grid_columns = [
|
||||
'id',
|
||||
'description',
|
||||
|
@ -65,6 +70,7 @@ class PricingBatchView(BatchMasterView):
|
|||
'id',
|
||||
'description',
|
||||
'min_diff_threshold',
|
||||
'min_diff_percent',
|
||||
'calculate_for_manual',
|
||||
'notes',
|
||||
'created',
|
||||
|
@ -124,6 +130,11 @@ class PricingBatchView(BatchMasterView):
|
|||
'status_text',
|
||||
]
|
||||
|
||||
def configure_form(self, f):
|
||||
super(PricingBatchView, self).configure_form(f)
|
||||
|
||||
f.set_type('min_diff_threshold', 'currency')
|
||||
|
||||
def configure_row_grid(self, g):
|
||||
super(PricingBatchView, self).configure_row_grid(g)
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue