Commit 7c4c9c1a authored by Romain Courteaud's avatar Romain Courteaud

Fix incompatibility with proxyfield.

git-svn-id: https://svn.erp5.org/repos/public/erp5/trunk@16459 20353a03-c40f-0410-a6d1-a30d3c3de9de
parent ed1a6146
......@@ -75,9 +75,11 @@
\n
# movement list should not be empty, as Item should always be created\n
# from movement\n
last_movement = movement_list[0]\n
resource_uid = last_movement.resource_uid\n
return context.portal_catalog(uid=resource_uid)[0].title\n
# But, if it raises an error, ProxyField may be broken\n
if len(movement_list) == 1:\n
last_movement = movement_list[0]\n
resource_uid = last_movement.resource_uid\n
return context.portal_catalog(uid=resource_uid)[0].title\n
</string> </value>
</item>
<item>
......@@ -124,6 +126,7 @@ return context.portal_catalog(uid=resource_uid)[0].title\n
<string>context</string>
<string>DateTime</string>
<string>movement_list</string>
<string>len</string>
<string>_getitem_</string>
<string>last_movement</string>
<string>resource_uid</string>
......
......@@ -17,9 +17,9 @@
<value>
<list>
<string>title</string>
<string>editable</string>
<string>display_width</string>
<string>default</string>
<string>display_width</string>
<string>editable</string>
</list>
</value>
</item>
......@@ -67,6 +67,14 @@
<persistent> <string encoding="base64">AAAAAAAAAAI=</string> </persistent>
</value>
</item>
<item>
<key> <string>display_width</string> </key>
<value> <string></string> </value>
</item>
<item>
<key> <string>editable</string> </key>
<value> <string></string> </value>
</item>
<item>
<key> <string>field_id</string> </key>
<value> <string></string> </value>
......@@ -79,6 +87,10 @@
<key> <string>target</string> </key>
<value> <string></string> </value>
</item>
<item>
<key> <string>title</string> </key>
<value> <string></string> </value>
</item>
</dictionary>
</value>
</item>
......@@ -86,6 +98,10 @@
<key> <string>values</string> </key>
<value>
<dictionary>
<item>
<key> <string>default</string> </key>
<value> <string></string> </value>
</item>
<item>
<key> <string>display_width</string> </key>
<value> <int>20</int> </value>
......
22
\ No newline at end of file
23
\ 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