Don't negate credit line quantity when is empty
issue6508 review40371002
This commit is contained in:
1 parent
294ab17541
commit
0923543707
1 file changed
+4
-1
+4
-1
@@ -2033,7 +2033,10 @@ class InvoiceLine(sequence_ordered(), ModelSQL, ModelView, TaxableMixin):
|
||||
'''
|
||||
line = self.__class__()
|
||||
line.origin = self
|
||||
line.quantity = -self.quantity
|
||||
if self.quantity:
|
||||
line.quantity = -self.quantity
|
||||
else:
|
||||
line.quantity = self.quantity
|
||||
|
||||
for field in ('sequence', 'type', 'invoice_type', 'unit_price',
|
||||
'description', 'unit', 'product', 'account'):
|
||||
|
||||
Reference in new issue
Block a user