minor fix
This commit is contained in:
parent
f120d60605
commit
019ecd4ce2
|
@ -2445,7 +2445,6 @@ class AppWindow(FrontWindow):
|
|||
self.add_sale_line(res)
|
||||
self._sale_line['product'] = record
|
||||
self.product_id = product_id
|
||||
print(self._sale_line, self.product_id, 'valida add pro')
|
||||
self.message_bar.set('system_ready')
|
||||
self.set_amounts()
|
||||
self.set_state('add')
|
||||
|
@ -2796,7 +2795,11 @@ class AppWindow(FrontWindow):
|
|||
self.label_input.setFocus()
|
||||
self.dialog_product_edit.close()
|
||||
if self.enviroment == 'restaurant':
|
||||
if self._config['tip_product']['code'] == removed_item['product']['code']:
|
||||
prd_code = removed_item.get('product.code', None)
|
||||
if isinstance(removed_item['product'], dict):
|
||||
prd_code = removed_item['product']['code']
|
||||
|
||||
if prd_code and self._config['tip_product']['code'] == prd_code:
|
||||
self.Sale.write([self._sale['id']], {'tip': None})
|
||||
|
||||
def set_discount(self, eval_value, lines_ids=[], type_=None):
|
||||
|
|
Loading…
Reference in New Issue