Commit db5b3011 authored by Nicolas Delaby's avatar Nicolas Delaby

Use Tales expression to guess which index should be use in Relation Field

git-svn-id: https://svn.erp5.org/repos/public/erp5/trunk@22409 20353a03-c40f-0410-a6d1-a30d3c3de9de
parent 4a5e7902
......@@ -66,17 +66,19 @@
<value>
<dictionary>
<item>
<key> <string>base_category</string> </key>
<key> <string>base_category</string> </key>
<value> <string></string> </value>
</item>
<item>
<key> <string>catalog_index</string> </key>
<value> <string></string> </value>
<key> <string>catalog_index</string> </key>
<value>
<persistent> <string encoding="base64">AAAAAAAAAAI=</string> </persistent>
</value>
</item>
<item>
<key> <string>enabled</string> </key>
<key> <string>enabled</string> </key>
<value>
<persistent> <string encoding="base64">AAAAAAAAAAI=</string> </persistent>
<persistent> <string encoding="base64">AAAAAAAAAAM=</string> </persistent>
</value>
</item>
<item>
......@@ -88,9 +90,9 @@
<value> <string></string> </value>
</item>
<item>
<key> <string>portal_type</string> </key>
<key> <string>portal_type</string> </key>
<value>
<persistent> <string encoding="base64">AAAAAAAAAAM=</string> </persistent>
<persistent> <string encoding="base64">AAAAAAAAAAQ=</string> </persistent>
</value>
</item>
<item>
......@@ -98,7 +100,7 @@
<value> <string></string> </value>
</item>
<item>
<key> <string>title</string> </key>
<key> <string>title</string> </key>
<value> <string></string> </value>
</item>
</dictionary>
......@@ -164,12 +166,28 @@
<dictionary>
<item>
<key> <string>_text</string> </key>
<value> <string>python: (here.getResource() and here.getResourceValue().getAggregatedPortalTypeList()) or (here.getAggregate()) or (here.getResource() is None and here.getPortalItemTypeList())</string> </value>
<value> <string>python: field.getId().replace(\'my_\', \'\').replace(\'_list\', \'\').replace(\'%s_\' % field.get_value(\'base_category\'), \'\')</string> </value>
</item>
</dictionary>
</pickle>
</record>
<record id="3" aka="AAAAAAAAAAM=">
<pickle>
<tuple>
<global name="TALESMethod" module="Products.Formulator.TALESField"/>
<tuple/>
</tuple>
</pickle>
<pickle>
<dictionary>
<item>
<key> <string>_text</string> </key>
<value> <string>python: (here.getResource() and here.getResourceValue().getAggregatedPortalTypeList()) or (here.getAggregate()) or (here.getResource() is None and here.getPortalItemTypeList())</string> </value>
</item>
</dictionary>
</pickle>
</record>
<record id="4" aka="AAAAAAAAAAQ=">
<pickle>
<tuple>
<global name="TALESMethod" module="Products.Formulator.TALESField"/>
......
418
\ No newline at end of file
421
\ 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