Commit a409a7e6 authored by Jérome Perrin's avatar Jérome Perrin

Fix jump action by using Base_jumpToRelatedObject to jump and...

Fix jump action by using Base_jumpToRelatedObject to jump and Base_checkPermission to check that the destination module is visible

git-svn-id: https://svn.erp5.org/repos/public/erp5/trunk@24760 20353a03-c40f-0410-a6d1-a30d3c3de9de
parent 937c1d70
...@@ -73,7 +73,7 @@ ...@@ -73,7 +73,7 @@
<key> <string>text</string> </key> <key> <string>text</string> </key>
<value> <string encoding="cdata"><![CDATA[ <value> <string encoding="cdata"><![CDATA[
string:${portal_url}/purchase_order_module/view?reset:int=1&default_source_title=${object/getTitle} string:${object_url}/Base_jumpToRelatedObject?base_category=source&portal_type=Purchase+Order
]]></string> </value> ]]></string> </value>
</item> </item>
...@@ -91,7 +91,7 @@ string:${portal_url}/purchase_order_module/view?reset:int=1&default_source_title ...@@ -91,7 +91,7 @@ string:${portal_url}/purchase_order_module/view?reset:int=1&default_source_title
<dictionary> <dictionary>
<item> <item>
<key> <string>text</string> </key> <key> <string>text</string> </key>
<value> <string>python:portal.restrictedTraverse(\'purchase_order_module\', None) is not None</string> </value> <value> <string>python: portal.Base_checkPermission(\'purchase_order_module\', \'View\')</string> </value>
</item> </item>
</dictionary> </dictionary>
</pickle> </pickle>
......
...@@ -11,9 +11,7 @@ ...@@ -11,9 +11,7 @@
<dictionary> <dictionary>
<item> <item>
<key> <string>action</string> </key> <key> <string>action</string> </key>
<value> <value> <string></string> </value>
<persistent> <string encoding="base64">AAAAAAAAAAI=</string> </persistent>
</value>
</item> </item>
<item> <item>
<key> <string>category</string> </key> <key> <string>category</string> </key>
...@@ -22,12 +20,16 @@ ...@@ -22,12 +20,16 @@
<item> <item>
<key> <string>condition</string> </key> <key> <string>condition</string> </key>
<value> <value>
<persistent> <string encoding="base64">AAAAAAAAAAM=</string> </persistent> <persistent> <string encoding="base64">AAAAAAAAAAI=</string> </persistent>
</value> </value>
</item> </item>
<item> <item>
<key> <string>description</string> </key> <key> <string>description</string> </key>
<value> <string></string> </value> <value> <string encoding="cdata"><![CDATA[
string:${object_url}/Base_jumpToRelatedObject?base_category=source&portal_type=Purchase+Packing+List
]]></string> </value>
</item> </item>
<item> <item>
<key> <string>icon</string> </key> <key> <string>icon</string> </key>
...@@ -71,27 +73,7 @@ ...@@ -71,27 +73,7 @@
<dictionary> <dictionary>
<item> <item>
<key> <string>text</string> </key> <key> <string>text</string> </key>
<value> <string encoding="cdata"><![CDATA[ <value> <string>python: portal.Base_checkPermission(\'purchase_packing_list_module\', \'View\')</string> </value>
string:${portal_url}/purchase_packing_list_module/view?reset:int=1&default_source_title=${object/getTitle}
]]></string> </value>
</item>
</dictionary>
</pickle>
</record>
<record id="3" aka="AAAAAAAAAAM=">
<pickle>
<tuple>
<global name="Expression" module="Products.CMFCore.Expression"/>
<tuple/>
</tuple>
</pickle>
<pickle>
<dictionary>
<item>
<key> <string>text</string> </key>
<value> <string>python:portal.restrictedTraverse(\'purchase_packing_list_module\', None) is not None</string> </value>
</item> </item>
</dictionary> </dictionary>
</pickle> </pickle>
......
...@@ -73,7 +73,7 @@ ...@@ -73,7 +73,7 @@
<key> <string>text</string> </key> <key> <string>text</string> </key>
<value> <string encoding="cdata"><![CDATA[ <value> <string encoding="cdata"><![CDATA[
string:${portal_url}/sale_order_module/view?reset:int=1&default_destination_title=${object/getTitle} string:${object_url}/Base_jumpToRelatedObject?base_category=destination&portal_type=Sale+Order
]]></string> </value> ]]></string> </value>
</item> </item>
...@@ -91,7 +91,7 @@ string:${portal_url}/sale_order_module/view?reset:int=1&default_destination_titl ...@@ -91,7 +91,7 @@ string:${portal_url}/sale_order_module/view?reset:int=1&default_destination_titl
<dictionary> <dictionary>
<item> <item>
<key> <string>text</string> </key> <key> <string>text</string> </key>
<value> <string>python:portal.restrictedTraverse(\'sale_order_module\', None) is not None</string> </value> <value> <string>python: portal.Base_checkPermission(\'sale_order_module\', \'View\')</string> </value>
</item> </item>
</dictionary> </dictionary>
</pickle> </pickle>
......
...@@ -73,7 +73,7 @@ ...@@ -73,7 +73,7 @@
<key> <string>text</string> </key> <key> <string>text</string> </key>
<value> <string encoding="cdata"><![CDATA[ <value> <string encoding="cdata"><![CDATA[
string:${portal_url}/sale_packing_list_module/view?reset:int=1&default_destination_title=${object/getTitle} string:${object_url}/Base_jumpToRelatedObject?base_category=destination&portal_type=Sale+Packing+List
]]></string> </value> ]]></string> </value>
</item> </item>
...@@ -91,7 +91,7 @@ string:${portal_url}/sale_packing_list_module/view?reset:int=1&default_destinati ...@@ -91,7 +91,7 @@ string:${portal_url}/sale_packing_list_module/view?reset:int=1&default_destinati
<dictionary> <dictionary>
<item> <item>
<key> <string>text</string> </key> <key> <string>text</string> </key>
<value> <string>python:portal.restrictedTraverse(\'sale_packing_list_module\', None) is not None</string> </value> <value> <string>python: portal.Base_checkPermission(\'sale_packing_list_module\', \'View\')</string> </value>
</item> </item>
</dictionary> </dictionary>
</pickle> </pickle>
......
...@@ -21,7 +21,9 @@ ...@@ -21,7 +21,9 @@
</item> </item>
<item> <item>
<key> <string>condition</string> </key> <key> <string>condition</string> </key>
<value> <string></string> </value> <value>
<persistent> <string encoding="base64">AAAAAAAAAAM=</string> </persistent>
</value>
</item> </item>
<item> <item>
<key> <string>description</string> </key> <key> <string>description</string> </key>
...@@ -69,7 +71,27 @@ ...@@ -69,7 +71,27 @@
<dictionary> <dictionary>
<item> <item>
<key> <string>text</string> </key> <key> <string>text</string> </key>
<value> <string>string:${portal_url}/purchase_order_module/view</string> </value> <value> <string encoding="cdata"><![CDATA[
string:${object_url}/Base_jumpToRelatedObject?base_category=source&portal_type=Purchase+Order
]]></string> </value>
</item>
</dictionary>
</pickle>
</record>
<record id="3" aka="AAAAAAAAAAM=">
<pickle>
<tuple>
<global name="Expression" module="Products.CMFCore.Expression"/>
<tuple/>
</tuple>
</pickle>
<pickle>
<dictionary>
<item>
<key> <string>text</string> </key>
<value> <string>python: portal.Base_checkPermission(\'purchase_order_module\', \'View\')</string> </value>
</item> </item>
</dictionary> </dictionary>
</pickle> </pickle>
......
...@@ -21,7 +21,9 @@ ...@@ -21,7 +21,9 @@
</item> </item>
<item> <item>
<key> <string>condition</string> </key> <key> <string>condition</string> </key>
<value> <string></string> </value> <value>
<persistent> <string encoding="base64">AAAAAAAAAAM=</string> </persistent>
</value>
</item> </item>
<item> <item>
<key> <string>description</string> </key> <key> <string>description</string> </key>
...@@ -69,7 +71,27 @@ ...@@ -69,7 +71,27 @@
<dictionary> <dictionary>
<item> <item>
<key> <string>text</string> </key> <key> <string>text</string> </key>
<value> <string>string:${portal_url}/purchase_packing_list_module/view</string> </value> <value> <string encoding="cdata"><![CDATA[
string:${object_url}/Base_jumpToRelatedObject?base_category=source&portal_type=Purchase+Packing+List
]]></string> </value>
</item>
</dictionary>
</pickle>
</record>
<record id="3" aka="AAAAAAAAAAM=">
<pickle>
<tuple>
<global name="Expression" module="Products.CMFCore.Expression"/>
<tuple/>
</tuple>
</pickle>
<pickle>
<dictionary>
<item>
<key> <string>text</string> </key>
<value> <string>python: portal.Base_checkPermission(\'purchase_packing_list_module\', \'View\')</string> </value>
</item> </item>
</dictionary> </dictionary>
</pickle> </pickle>
......
...@@ -21,7 +21,9 @@ ...@@ -21,7 +21,9 @@
</item> </item>
<item> <item>
<key> <string>condition</string> </key> <key> <string>condition</string> </key>
<value> <string></string> </value> <value>
<persistent> <string encoding="base64">AAAAAAAAAAM=</string> </persistent>
</value>
</item> </item>
<item> <item>
<key> <string>description</string> </key> <key> <string>description</string> </key>
...@@ -69,7 +71,27 @@ ...@@ -69,7 +71,27 @@
<dictionary> <dictionary>
<item> <item>
<key> <string>text</string> </key> <key> <string>text</string> </key>
<value> <string>string:${portal_url}/sale_order_module/view</string> </value> <value> <string encoding="cdata"><![CDATA[
string:${object_url}/Base_jumpToRelatedObject?base_category=destination&portal_type=Sale+Order
]]></string> </value>
</item>
</dictionary>
</pickle>
</record>
<record id="3" aka="AAAAAAAAAAM=">
<pickle>
<tuple>
<global name="Expression" module="Products.CMFCore.Expression"/>
<tuple/>
</tuple>
</pickle>
<pickle>
<dictionary>
<item>
<key> <string>text</string> </key>
<value> <string>python: portal.Base_checkPermission(\'sale_order_module\', \'View\')</string> </value>
</item> </item>
</dictionary> </dictionary>
</pickle> </pickle>
......
...@@ -21,7 +21,9 @@ ...@@ -21,7 +21,9 @@
</item> </item>
<item> <item>
<key> <string>condition</string> </key> <key> <string>condition</string> </key>
<value> <string></string> </value> <value>
<persistent> <string encoding="base64">AAAAAAAAAAM=</string> </persistent>
</value>
</item> </item>
<item> <item>
<key> <string>description</string> </key> <key> <string>description</string> </key>
...@@ -69,7 +71,27 @@ ...@@ -69,7 +71,27 @@
<dictionary> <dictionary>
<item> <item>
<key> <string>text</string> </key> <key> <string>text</string> </key>
<value> <string>string:${portal_url}/sale_packing_list_module/view</string> </value> <value> <string encoding="cdata"><![CDATA[
string:${object_url}/Base_jumpToRelatedObject?base_category=destination&portal_type=Sale+Packing+List
]]></string> </value>
</item>
</dictionary>
</pickle>
</record>
<record id="3" aka="AAAAAAAAAAM=">
<pickle>
<tuple>
<global name="Expression" module="Products.CMFCore.Expression"/>
<tuple/>
</tuple>
</pickle>
<pickle>
<dictionary>
<item>
<key> <string>text</string> </key>
<value> <string>python: portal.Base_checkPermission(\'sale_packing_list_module\', \'View\')</string> </value>
</item> </item>
</dictionary> </dictionary>
</pickle> </pickle>
......
534 535
\ No newline at end of file \ 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