Commit 76eeeb0f authored by Jérome Perrin's avatar Jérome Perrin

simplify this script

git-svn-id: https://svn.erp5.org/repos/public/erp5/trunk@27294 20353a03-c40f-0410-a6d1-a30d3c3de9de
parent b810324f
...@@ -53,10 +53,11 @@ ...@@ -53,10 +53,11 @@
</item> </item>
<item> <item>
<key> <string>_body</string> </key> <key> <string>_body</string> </key>
<value> <string>if context.getPortalType() in [\'Purchase Packing List Line\',\'Inventory Line\'] and (context.getResource() and context.getResourceValue().getAggregatedPortalTypeList()) or (context.getAggregate()) or (context.getResource() is None and context.getPortalItemTypeList()):\n <value> <string>"""This scripts is used to know if quantity can be edited by user.\n
return 0\n If items are used, quantity is set by the item quantity.\n
else:\n """\n
return 1\n return not (context.getPortalType() in context.getPortalDeliveryMovementTypeList()\n
and (context.getResource() and context.getResourceValue().getAggregatedPortalTypeList()))\n
</string> </value> </string> </value>
</item> </item>
<item> <item>
...@@ -95,7 +96,6 @@ else:\n ...@@ -95,7 +96,6 @@ else:\n
<tuple> <tuple>
<string>_getattr_</string> <string>_getattr_</string>
<string>context</string> <string>context</string>
<string>None</string>
</tuple> </tuple>
</value> </value>
</item> </item>
......
664 665
\ 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