Commit 1530e154 authored by Łukasz Nowak's avatar Łukasz Nowak

Check specialise better.

Sale Order and Sale Packing Lists can have uncommon, migration related specialise.

Invoice shall have only correct specialise.
parent d508b504
<?xml version="1.0"?>
<ZopeData>
<record id="1" aka="AAAAAAAAAAE=">
<pickle>
<global name="TALES Constraint" module="erp5.portal_type"/>
</pickle>
<pickle>
<dictionary>
<item>
<key> <string>_identity_criterion</string> </key>
<value>
<persistent> <string encoding="base64">AAAAAAAAAAI=</string> </persistent>
</value>
</item>
<item>
<key> <string>_range_criterion</string> </key>
<value>
<persistent> <string encoding="base64">AAAAAAAAAAM=</string> </persistent>
</value>
</item>
<item>
<key> <string>description</string> </key>
<value>
<none/>
</value>
</item>
<item>
<key> <string>expression</string> </key>
<value> <string>python: object.getSpecialise() == "sale_trade_condition_module/vifib_trade_condition"</string> </value>
</item>
<item>
<key> <string>id</string> </key>
<value> <string>specialise_value_constraint</string> </value>
</item>
<item>
<key> <string>message_expression_false</string> </key>
<value> <string>Only Vifib trade condition is allowed</string> </value>
</item>
<item>
<key> <string>portal_type</string> </key>
<value> <string>TALES Constraint</string> </value>
</item>
</dictionary>
</pickle>
</record>
<record id="2" aka="AAAAAAAAAAI=">
<pickle>
<global name="PersistentMapping" module="Persistence.mapping"/>
</pickle>
<pickle>
<dictionary>
<item>
<key> <string>data</string> </key>
<value>
<dictionary/>
</value>
</item>
</dictionary>
</pickle>
</record>
<record id="3" aka="AAAAAAAAAAM=">
<pickle>
<global name="PersistentMapping" module="Persistence.mapping"/>
</pickle>
<pickle>
<dictionary>
<item>
<key> <string>data</string> </key>
<value>
<dictionary/>
</value>
</item>
</dictionary>
</pickle>
</record>
</ZopeData>
......@@ -26,12 +26,24 @@
</item>
<item>
<key> <string>expression</string> </key>
<value> <string>python: object.getSpecialise() == "sale_trade_condition_module/vifib_trade_condition"</string> </value>
<value> <string>python: object.getSpecialise() in ["sale_trade_condition_module/vifib_trade_condition", "sale_trade_condition_module/vifib_simple_trade_condition"]</string> </value>
</item>
<item>
<key> <string>id</string> </key>
<value> <string>specialise_value_constraint</string> </value>
</item>
<item>
<key> <string>int_index</string> </key>
<value>
<none/>
</value>
</item>
<item>
<key> <string>membership_criterion_category</string> </key>
<value>
<tuple/>
</value>
</item>
<item>
<key> <string>message_expression_false</string> </key>
<value> <string>Only Vifib trade condition is allowed</string> </value>
......@@ -40,6 +52,22 @@
<key> <string>portal_type</string> </key>
<value> <string>TALES Constraint</string> </value>
</item>
<item>
<key> <string>string_index</string> </key>
<value>
<none/>
</value>
</item>
<item>
<key> <string>test_method_id</string> </key>
<value>
<tuple/>
</value>
</item>
<item>
<key> <string>test_tales_expression</string> </key>
<value> <string>python: context.getSpecialise() is not None</string> </value>
</item>
</dictionary>
</pickle>
</record>
......
......@@ -26,12 +26,24 @@
</item>
<item>
<key> <string>expression</string> </key>
<value> <string>python: object.getSpecialise() == "sale_trade_condition_module/vifib_trade_condition"</string> </value>
<value> <string>python: object.getSpecialise() in ["sale_trade_condition_module/vifib_trade_condition", "sale_trade_condition_module/vifib_simple_trade_condition"]</string> </value>
</item>
<item>
<key> <string>id</string> </key>
<value> <string>specialise_value_constraint</string> </value>
</item>
<item>
<key> <string>int_index</string> </key>
<value>
<none/>
</value>
</item>
<item>
<key> <string>membership_criterion_category</string> </key>
<value>
<tuple/>
</value>
</item>
<item>
<key> <string>message_expression_false</string> </key>
<value> <string>Only Vifib trade condition is allowed</string> </value>
......@@ -40,6 +52,22 @@
<key> <string>portal_type</string> </key>
<value> <string>TALES Constraint</string> </value>
</item>
<item>
<key> <string>string_index</string> </key>
<value>
<none/>
</value>
</item>
<item>
<key> <string>test_method_id</string> </key>
<value>
<tuple/>
</value>
</item>
<item>
<key> <string>test_tales_expression</string> </key>
<value> <string>python: context.getSpecialise() is not None</string> </value>
</item>
</dictionary>
</pickle>
</record>
......
383
\ No newline at end of file
384
\ 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