Fix bug when updating Order Form data, if row.po_total is None
not sure how/when that happens, but just fall back to $0
This commit is contained in:
parent
2d29174772
commit
cc41c38d68
|
@ -220,7 +220,7 @@ class OrderingBatchView(PurchasingBatchView):
|
||||||
return {
|
return {
|
||||||
'row_cases_ordered': '' if not row or row.removed else int(row.cases_ordered or 0),
|
'row_cases_ordered': '' if not row or row.removed else int(row.cases_ordered or 0),
|
||||||
'row_units_ordered': '' if not row or row.removed else int(row.units_ordered or 0),
|
'row_units_ordered': '' if not row or row.removed else int(row.units_ordered or 0),
|
||||||
'row_po_total': '' if not row or row.removed else '${:0,.2f}'.format(row.po_total),
|
'row_po_total': '' if not row or row.removed else '${:0,.2f}'.format(row.po_total or 0),
|
||||||
'batch_po_total': '${:0,.2f}'.format(batch.po_total or 0),
|
'batch_po_total': '${:0,.2f}'.format(batch.po_total or 0),
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue