Commit 8733a4fc authored by Łukasz Nowak's avatar Łukasz Nowak

Fix condition.

parent c0654bc7
......@@ -51,11 +51,13 @@
<item>
<key> <string>_body</string> </key>
<value> <string>portal = context.getPortalObject()\n
if context.getPortalType() != \'Sale Packing List\' \\\n
and context.getSpecialise() != portal.portal_preferences.getPreferredAggregatedSaleTradeCondition():\n
if context.getPortalType() != \'Sale Packing List\':\n
raise TypeError(\'Incorrect delivery.\')\n
isTransitionPossible = portal.portal_workflow.isTransitionPossible\n
if context.getSimulationState() == \'confirmed\' and len(context.checkConsistency()) == 0 and context.getCausalityState() == \'solved\':\n
if context.getSimulationState() == \'confirmed\' \\\n
and len(context.checkConsistency()) == 0 \\\n
and context.getCausalityState() == \'solved\' \\\n
and context.getSpecialise() == portal.portal_preferences.getPreferredAggregatedSaleTradeCondition():\n
comment = \'Delivered by alarm as all actions in confirmed state are ready.\'\n
if isTransitionPossible(context, \'start\'):\n
context.start(comment=comment)\n
......
......@@ -51,11 +51,13 @@
<item>
<key> <string>_body</string> </key>
<value> <string>portal = context.getPortalObject()\n
if context.getPortalType() != \'Sale Invoice Transaction\' \\\n
and context.getSpecialise() != portal.portal_preferences.getPreferredAggregatedSaleTradeCondition():\n
if context.getPortalType() != \'Sale Invoice Transaction\':\n
raise TypeError(\'Incorrect delivery.\')\n
isTransitionPossible = portal.portal_workflow.isTransitionPossible\n
if context.getSimulationState() == \'confirmed\' and len(context.checkConsistency()) == 0 and context.getCausalityState() == \'solved\':\n
if context.getSimulationState() == \'confirmed\'\\\n
and len(context.checkConsistency()) == 0\\\n
and context.getCausalityState() == \'solved\'\\\n
and context.getSpecialise() == portal.portal_preferences.getPreferredAggregatedSaleTradeCondition():\n
comment = \'Stopped by alarm as all actions in confirmed state are ready.\'\n
if isTransitionPossible(context, \'start\'):\n
context.start(comment=comment)\n
......
176
\ No newline at end of file
177
\ No newline at end of file
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