Commit dee0106a authored by Arnaud Fontaine's avatar Arnaud Fontaine

erp5_real_time_inventory_accounting: Set AT reference to PL.getReference().

parent 91d4b705
......@@ -2,8 +2,11 @@
accounting_transaction = context
related_packing_list = accounting_transaction.getDefaultCausalityValue()
if not accounting_transaction.hasTitle() and related_packing_list is not None and related_packing_list.hasTitle():
accounting_transaction.setTitle(related_packing_list.getTitle())
if related_packing_list is not None:
if not accounting_transaction.hasTitle() and related_packing_list.hasTitle():
accounting_transaction.setTitle(related_packing_list.getTitle())
if not accounting_transaction.hasReference() and related_packing_list.hasReference():
accounting_transaction.setReference(related_packing_list.getReference())
resource = None
ledger = None
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment