Commit 92275f51 authored by Alexandre Boeglin's avatar Alexandre Boeglin

in SupplyLine_asPredicate and SupplyLine_asPredicate, deal with both source and destination.

git-svn-id: https://svn.erp5.org/repos/public/erp5/trunk@19279 20353a03-c40f-0410-a6d1-a30d3c3de9de
parent 59869e6e
......@@ -65,11 +65,14 @@
</item>
<item>
<key> <string>_body</string> </key>
<value> <string>if context.getDestinationValue() is None:\n
return context.generatePredicate(membership_criterion_base_category_list = (\'resource\',),\n
criterion_property_list = (\'start_date\',))\n
<value> <string>base_category_tuple = (\'resource\',)\n
\n
return context.generatePredicate(membership_criterion_base_category_list = (\'destination\', \'resource\'),\n
if context.getSource():\n
base_category_tuple += (\'source\',)\n
if context.getDestination():\n
base_category_tuple += (\'destination\',)\n
\n
return context.generatePredicate(membership_criterion_base_category_list = base_category_tuple,\n
criterion_property_list = (\'start_date\',))\n
</string> </value>
</item>
......@@ -121,9 +124,10 @@ return context.generatePredicate(membership_criterion_base_category_list = (\'de
<tuple>
<string>args</string>
<string>kw</string>
<string>base_category_tuple</string>
<string>_getattr_</string>
<string>context</string>
<string>None</string>
<string>_inplacevar_</string>
</tuple>
</value>
</item>
......
......@@ -65,11 +65,14 @@
</item>
<item>
<key> <string>_body</string> </key>
<value> <string>if context.getDestinationValue() is None:\n
return context.generatePredicate(membership_criterion_base_category_list = (\'resource\',),\n
criterion_property_list = (\'start_date\',))\n
<value> <string>base_category_tuple = (\'resource\',)\n
\n
return context.generatePredicate(membership_criterion_base_category_list = (\'destination\', \'resource\'),\n
if context.getSource():\n
base_category_tuple += (\'source\',)\n
if context.getDestination():\n
base_category_tuple += (\'destination\',)\n
\n
return context.generatePredicate(membership_criterion_base_category_list = base_category_tuple,\n
criterion_property_list = (\'start_date\',))\n
</string> </value>
</item>
......@@ -115,9 +118,10 @@ return context.generatePredicate(membership_criterion_base_category_list = (\'de
<tuple>
<string>args</string>
<string>kw</string>
<string>base_category_tuple</string>
<string>_getattr_</string>
<string>context</string>
<string>None</string>
<string>_inplacevar_</string>
</tuple>
</value>
</item>
......
177
\ No newline at end of file
181
\ 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