mirror of
https://github.com/NaN-tic/trytond-account_invoice_consecutive.git
synced 2023-12-13 20:50:10 +01:00
Merge invoice and credit note
This commit is contained in:
parent
532069914b
commit
cf9e3780f1
1 changed files with 2 additions and 2 deletions
|
@ -29,7 +29,7 @@ class Invoice:
|
||||||
def validate(cls, invoices):
|
def validate(cls, invoices):
|
||||||
super(Invoice, cls).validate(invoices)
|
super(Invoice, cls).validate(invoices)
|
||||||
for invoice in invoices:
|
for invoice in invoices:
|
||||||
if 'in_' not in invoice.type:
|
if invoice.type != 'in':
|
||||||
invoice.check_same_dates()
|
invoice.check_same_dates()
|
||||||
|
|
||||||
def check_same_dates(self):
|
def check_same_dates(self):
|
||||||
|
@ -63,7 +63,7 @@ class Invoice:
|
||||||
check = not bool(self.number)
|
check = not bool(self.number)
|
||||||
|
|
||||||
super(Invoice, self).set_number()
|
super(Invoice, self).set_number()
|
||||||
if check and self.type in ('out_invoice', 'out_credit_note'):
|
if check and self.type == 'out':
|
||||||
table = self.__table__()
|
table = self.__table__()
|
||||||
move = Move.__table__()
|
move = Move.__table__()
|
||||||
period = Period.__table__()
|
period = Period.__table__()
|
||||||
|
|
Loading…
Reference in a new issue