Commit dc3afa4f authored by Rafael Monnerat's avatar Rafael Monnerat

slapos_accounting: Do not stop Invoice w/o Sale Invoice Transaction Lines

    This forces to wait for builders before stop
parent bcc96031
......@@ -5,6 +5,7 @@ isTransitionPossible = portal.portal_workflow.isTransitionPossible
if context.getSimulationState() == 'confirmed'\
and len(context.checkConsistency()) == 0\
and context.getCausalityState() == 'solved'\
and len(context.objectValues(portal_type="Sale Invoice Transaction Line"))\
and context.getSpecialise() in [portal.portal_preferences.getPreferredAggregatedSaleTradeCondition(),
portal.portal_preferences.getPreferredAggregatedSubscriptionSaleTradeCondition()]:
comment = 'Stopped by alarm as all actions in confirmed state are ready.'
......
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