Various tweaks for support of native inventory

certaianly some other things made it in here too..
This commit is contained in:
Lance Edgar 2017-07-19 01:42:18 -05:00
parent eb68eec520
commit 61d504afb8
11 changed files with 129 additions and 16 deletions

View file

@ -291,6 +291,10 @@ class ProductsView(MasterView):
fs.last_sold.set(readonly=True)
fs.append(fa.Field('current_price_ends', type=fa.types.DateTime, readonly=True,
value=lambda p: p.current_price.ends if p.current_price else None))
fs.append(fa.Field('inventory_on_hand', readonly=True, label="On Hand",
value=lambda p: p.inventory.on_hand if p.inventory else None))
fs.append(fa.Field('inventory_on_order', readonly=True, label="On Order",
value=lambda p: p.inventory.on_order if p.inventory else None))
def configure_fieldset(self, fs):
fs.configure(