From b7ccc6ea0705ac863081c758fb93930f7ad7b8ad Mon Sep 17 00:00:00 2001 From: Lance Edgar Date: Sun, 1 Oct 2023 17:31:33 -0500 Subject: [PATCH] Use enum to display `POS_ROW_TYPE` --- tailbone/views/batch/pos.py | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/tailbone/views/batch/pos.py b/tailbone/views/batch/pos.py index e4c787f9..c8ceede5 100644 --- a/tailbone/views/batch/pos.py +++ b/tailbone/views/batch/pos.py @@ -158,6 +158,8 @@ class POSBatchView(BatchMasterView): def configure_row_grid(self, g): super().configure_row_grid(g) + g.set_enum('row_type', self.enum.POS_ROW_TYPE) + g.set_type('quantity', 'quantity') g.set_type('reg_price', 'currency') g.set_type('txn_price', 'currency') @@ -174,6 +176,8 @@ class POSBatchView(BatchMasterView): def configure_row_form(self, f): super().configure_row_form(f) + g.set_enum('row_type', self.enum.POS_ROW_TYPE) + f.set_renderer('product', self.render_product) f.set_type('quantity', 'quantity')