Add initial support for mobile "quick row" feature, for ordering
at least for now, ordering only, but hopefully much more soon...
This commit is contained in:
parent
aa6e540abd
commit
68bd3047c4
10 changed files with 143 additions and 23 deletions
|
@ -579,13 +579,6 @@ class ReceivingBatchView(PurchasingBatchView):
|
|||
f.set_readonly('po_total')
|
||||
f.set_readonly('invoice_total')
|
||||
|
||||
def get_mobile_row_data(self, parent):
|
||||
query = self.get_row_data(parent)
|
||||
return self.sort_mobile_row_data(query)
|
||||
|
||||
def sort_mobile_row_data(self, query):
|
||||
return query.order_by(model.PurchaseBatchRow.modified.desc())
|
||||
|
||||
def render_mobile_row_listitem(self, row, i):
|
||||
description = row.product.full_description if row.product else row.description
|
||||
return "({}) {}".format(row.upc.pretty(), description)
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue