minor fix
This commit is contained in:
parent
ff857fc5b3
commit
af6fe7b697
BIN
app/logo.png
BIN
app/logo.png
Binary file not shown.
Before Width: | Height: | Size: 48 KiB After Width: | Height: | Size: 21 KiB |
|
@ -118,9 +118,9 @@ class MainWindow(FrontWindow):
|
||||||
|
|
||||||
self.do_invoice = DoInvoice(self, self._context)
|
self.do_invoice = DoInvoice(self, self._context)
|
||||||
self.do_invoice.sigDoInvoice.connect(self.__do_invoice_thread)
|
self.do_invoice.sigDoInvoice.connect(self.__do_invoice_thread)
|
||||||
self.set_cache_company()
|
|
||||||
|
|
||||||
if self.cache_local:
|
if self.cache_local:
|
||||||
|
self.set_cache_company()
|
||||||
self.set_cache_products()
|
self.set_cache_products()
|
||||||
|
|
||||||
def set_domains(self):
|
def set_domains(self):
|
||||||
|
@ -831,6 +831,7 @@ class MainWindow(FrontWindow):
|
||||||
|
|
||||||
def button_plus_pressed(self):
|
def button_plus_pressed(self):
|
||||||
error = False
|
error = False
|
||||||
|
print(self._state)
|
||||||
if self._input_text == '' and self._amount_text == '0':
|
if self._input_text == '' and self._amount_text == '0':
|
||||||
return
|
return
|
||||||
if self._state in ('paid', 'disabled'):
|
if self._state in ('paid', 'disabled'):
|
||||||
|
@ -1053,7 +1054,7 @@ class MainWindow(FrontWindow):
|
||||||
self.ModSale.reconcile_invoice({
|
self.ModSale.reconcile_invoice({
|
||||||
'sale_id': self.sale_to_post['id']
|
'sale_id': self.sale_to_post['id']
|
||||||
})
|
})
|
||||||
self.set_state('finished')
|
# self.set_state('finished')
|
||||||
|
|
||||||
def _done_sale(self, is_credit=False):
|
def _done_sale(self, is_credit=False):
|
||||||
self._sale['is_credit'] = is_credit
|
self._sale['is_credit'] = is_credit
|
||||||
|
@ -1467,7 +1468,7 @@ class MainWindow(FrontWindow):
|
||||||
return True
|
return True
|
||||||
|
|
||||||
def action_cancel(self):
|
def action_cancel(self):
|
||||||
if self._state == 'finished':
|
if self._state == 'disabled':
|
||||||
return
|
return
|
||||||
if self.type_pos_user == 'cashier':
|
if self.type_pos_user == 'cashier':
|
||||||
self.dialog_cancel_invoice.exec_()
|
self.dialog_cancel_invoice.exec_()
|
||||||
|
@ -2478,7 +2479,6 @@ class MainWindow(FrontWindow):
|
||||||
key not in (Qt.Key_Enter, Qt.Key_End):
|
key not in (Qt.Key_Enter, Qt.Key_End):
|
||||||
# Clear ui context when keys function are pressed
|
# Clear ui context when keys function are pressed
|
||||||
self._clear_context()
|
self._clear_context()
|
||||||
|
|
||||||
if key in (Qt.Key_Return, Qt.Key_Plus):
|
if key in (Qt.Key_Return, Qt.Key_Plus):
|
||||||
self.button_plus_pressed()
|
self.button_plus_pressed()
|
||||||
elif key in self.show_keys:
|
elif key in self.show_keys:
|
||||||
|
|
Binary file not shown.
Before Width: | Height: | Size: 1.7 KiB After Width: | Height: | Size: 4.9 KiB |
Loading…
Reference in New Issue