Commit 44004d41 authored by Romain Courteaud's avatar Romain Courteaud

slapos_accounting: do not loop other deliveries which will not be expanded

Only payable deliveries will generate invoices.
parent 0cbfd4b7
......@@ -5,6 +5,10 @@ select_dict = {'causality__related__uid': None}
kw.update(
portal_type='Sale Packing List',
ledger__uid=portal.portal_categories.ledger.automated.getUid(),
# Only payable deliveries are expanded
# (it prevents the alarm to always those non expandable deliveries)
source_section__uid='%',
destination_section__uid='%',
# This is an optimisation to help mariadb selecting a better index
simulation_state=['delivered'],
......
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