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

smart_assistant: use relative URL for gadget URL

Using an absolute URL for gadgets cause the gadget to have a different URL
per language when the web site uses "Language in URL" feature.

Using absolute URL is not good for cache and also it seems to cause
incompatibilities with recent versions of ERP5JS. Using relative URL is
what we usually do, it does not have cache problem and works fine.
parent 5e2cf409
......@@ -142,9 +142,7 @@
</item>
<item>
<key> <string>gadget_url</string> </key>
<value>
<persistent> <string encoding="base64">AAAAAAAAAAQ=</string> </persistent>
</value>
<value> <string></string> </value>
</item>
<item>
<key> <string>hidden</string> </key>
......@@ -215,7 +213,7 @@
</item>
<item>
<key> <string>gadget_url</string> </key>
<value> <string></string> </value>
<value> <string>gadget_custom_player.html</string> </value>
</item>
<item>
<key> <string>hidden</string> </key>
......@@ -270,20 +268,7 @@
<dictionary>
<item>
<key> <string>_text</string> </key>
<value> <string>python:here.aq_parent.aq_parent.getPortalType() == \'Web Section\'</string> </value>
</item>
</dictionary>
</pickle>
</record>
<record id="4" aka="AAAAAAAAAAQ=">
<pickle>
<global name="TALESMethod" module="Products.Formulator.TALESField"/>
</pickle>
<pickle>
<dictionary>
<item>
<key> <string>_text</string> </key>
<value> <string>python:field.restrictedTraverse(\'gadget_custom_player.html\').absolute_url()</string> </value>
<value> <string>python: here.aq_parent.aq_parent.getPortalType() == \'Web Section\'</string> </value>
</item>
</dictionary>
</pickle>
......
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