Commit c2a61d30 authored by Łukasz Nowak's avatar Łukasz Nowak

Fine tune predicate even more.

Separate discount and tax phases.
parent c3b5c3d3
...@@ -138,7 +138,7 @@ class TestTradeModelLineMixin(TestBPMMixin, UserDict): ...@@ -138,7 +138,7 @@ class TestTradeModelLineMixin(TestBPMMixin, UserDict):
successor='trade_state/accounted', successor='trade_state/accounted',
delivery_builder=['portal_deliveries/purchase_invoice_transaction_trade_model_builder', delivery_builder=['portal_deliveries/purchase_invoice_transaction_trade_model_builder',
'portal_deliveries/sale_invoice_transaction_trade_model_builder'], 'portal_deliveries/sale_invoice_transaction_trade_model_builder'],
test_tales_expression="python: context.BusinessLink_testDeliveryLink('Trade Model Simulation Rule')", test_tales_expression="python: context.BusinessLink_testDeliveryLink('Trade Model Simulation Rule') and context.getResourceValue() is not None and context.getResourceValue().getUse() == 'discount'",
), ),
dict(reference='tax', dict(reference='tax',
trade_phase='default/tax', trade_phase='default/tax',
...@@ -154,7 +154,7 @@ class TestTradeModelLineMixin(TestBPMMixin, UserDict): ...@@ -154,7 +154,7 @@ class TestTradeModelLineMixin(TestBPMMixin, UserDict):
successor='trade_state/accounted', successor='trade_state/accounted',
delivery_builder=['portal_deliveries/purchase_invoice_transaction_trade_model_builder', delivery_builder=['portal_deliveries/purchase_invoice_transaction_trade_model_builder',
'portal_deliveries/sale_invoice_transaction_trade_model_builder'], 'portal_deliveries/sale_invoice_transaction_trade_model_builder'],
test_tales_expression="python: context.BusinessLink_testDeliveryLink('Trade Model Simulation Rule')", test_tales_expression="python: context.BusinessLink_testDeliveryLink('Trade Model Simulation Rule') and context.getResourceValue() is not None and context.getResourceValue().getUse() == 'tax'",
), ),
] ]
for business_link in business_link_list: for business_link in business_link_list:
......
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