mirror of
https://github.com/OCA/pms.git
synced 2025-01-29 00:17:45 +02:00
[IMP] pms: allow partial invoicing (#61)
* [IMP] pms: allow partial invoicing * [FIX] pms: precommit fixes * [FIX] pms: uncomment init test file
This commit is contained in:
@@ -285,4 +285,12 @@ class FolioAdvancePaymentInv(models.TransientModel):
|
||||
)
|
||||
if not lines_to_invoice:
|
||||
raise UserError(_("Nothing to invoice"))
|
||||
return lines_to_invoice
|
||||
|
||||
lines_dict = dict()
|
||||
for line in lines_to_invoice:
|
||||
if not line.display_type:
|
||||
lines_dict[line.id] = line.qty_to_invoice
|
||||
else:
|
||||
lines_dict[line.id] = 0
|
||||
return lines_dict
|
||||
# return lines_to_invoice
|
||||
|
||||
Reference in New Issue
Block a user