diff --git a/bt5/erp5_egov/SkinTemplateItem/portal_skins/erp5_egov/getPrintFormUrl.xml b/bt5/erp5_egov/SkinTemplateItem/portal_skins/erp5_egov/getPrintFormUrl.xml new file mode 100644 index 0000000000000000000000000000000000000000..705b7b0dbf8afd9f238c3287ba13fea5ed8c9279 --- /dev/null +++ b/bt5/erp5_egov/SkinTemplateItem/portal_skins/erp5_egov/getPrintFormUrl.xml @@ -0,0 +1,152 @@ +<?xml version="1.0"?> +<ZopeData> + <record id="1" aka="AAAAAAAAAAE="> + <pickle> + <tuple> + <global name="PythonScript" module="Products.PythonScripts.PythonScript"/> + <tuple/> + </tuple> + </pickle> + <pickle> + <dictionary> + <item> + <key> <string>Python_magic</string> </key> + <value> + <none/> + </value> + </item> + <item> + <key> <string>Script_magic</string> </key> + <value> <int>3</int> </value> + </item> + <item> + <key> <string>__ac_local_roles__</string> </key> + <value> + <none/> + </value> + </item> + <item> + <key> <string>_bind_names</string> </key> + <value> + <object> + <klass> + <global name="NameAssignments" module="Shared.DC.Scripts.Bindings"/> + </klass> + <tuple/> + <state> + <dictionary> + <item> + <key> <string>_asgns</string> </key> + <value> + <dictionary> + <item> + <key> <string>name_container</string> </key> + <value> <string>container</string> </value> + </item> + <item> + <key> <string>name_context</string> </key> + <value> <string>context</string> </value> + </item> + <item> + <key> <string>name_m_self</string> </key> + <value> <string>script</string> </value> + </item> + <item> + <key> <string>name_subpath</string> </key> + <value> <string>traverse_subpath</string> </value> + </item> + </dictionary> + </value> + </item> + </dictionary> + </state> + </object> + </value> + </item> + <item> + <key> <string>_body</string> </key> + <value> <string>if not context.portal_actions.listFilteredActionsFor(context).has_key(\'object_print\'):\n + return None\n +\n +new_print_action_list = context.Base_fixDialogActions(\n + context.Base_filterDuplicateActions(\n + context.portal_actions.listFilteredActionsFor(context)), \'object_print\')\n +if new_print_action_list:\n + return new_print_action_list[0][\'original_url\']\n +\n +return None\n +</string> </value> + </item> + <item> + <key> <string>_code</string> </key> + <value> + <none/> + </value> + </item> + <item> + <key> <string>_filepath</string> </key> + <value> + <none/> + </value> + </item> + <item> + <key> <string>_params</string> </key> + <value> <string></string> </value> + </item> + <item> + <key> <string>errors</string> </key> + <value> + <tuple/> + </value> + </item> + <item> + <key> <string>func_code</string> </key> + <value> + <object> + <klass> + <global name="FuncCode" module="Shared.DC.Scripts.Signature"/> + </klass> + <tuple/> + <state> + <dictionary> + <item> + <key> <string>co_argcount</string> </key> + <value> <int>0</int> </value> + </item> + <item> + <key> <string>co_varnames</string> </key> + <value> + <tuple> + <string>_getattr_</string> + <string>context</string> + <string>None</string> + <string>new_print_action_list</string> + <string>_getitem_</string> + </tuple> + </value> + </item> + </dictionary> + </state> + </object> + </value> + </item> + <item> + <key> <string>func_defaults</string> </key> + <value> + <none/> + </value> + </item> + <item> + <key> <string>id</string> </key> + <value> <string>getPrintFormUrl</string> </value> + </item> + <item> + <key> <string>warnings</string> </key> + <value> + <tuple/> + </value> + </item> + </dictionary> + </pickle> + </record> +</ZopeData> diff --git a/bt5/erp5_egov/SkinTemplateItem/portal_skins/erp5_egov_widget_library/WebSite_viewDGIDHeaderFormRenderer.xml b/bt5/erp5_egov/SkinTemplateItem/portal_skins/erp5_egov_widget_library/WebSite_viewDGIDHeaderFormRenderer.xml index 22e30ebdd3af8f32ac2cd071bb3a78e305580899..21f83a0727ec2a84db602a3e7a20184bb3241fd8 100644 --- a/bt5/erp5_egov/SkinTemplateItem/portal_skins/erp5_egov_widget_library/WebSite_viewDGIDHeaderFormRenderer.xml +++ b/bt5/erp5_egov/SkinTemplateItem/portal_skins/erp5_egov_widget_library/WebSite_viewDGIDHeaderFormRenderer.xml @@ -62,7 +62,10 @@ <span class="onright">\n <a class="home" tal:attributes="href python:context.getWebSiteValue().absolute_url()" href="./home" \n i18n:translate="" i18n:domain="ui">Home</a>\n - <a class="print" href="DeclarationTVA_viewDeclarationTVAAsPdf" i18n:translate="" i18n:domain="ui">Print</a>\n + <tal:block tal:condition="python: context.getPrintFormUrl() is not None">\n + <a class="print" href="DeclarationTVA_viewDeclarationTVAAsPdf"\n + tal:attributes="href python: context.getPrintFormUrl()" i18n:translate="" i18n:domain="ui">Print</a>\n + </tal:block> \n <a class="help" href="./help" i18n:translate="" i18n:domain="ui">Help</a>\n </span>\n <div class="clear">\n @@ -89,6 +92,12 @@ <key> <string>title</string> </key> <value> <string></string> </value> </item> + <item> + <key> <string>uid</string> </key> + <value> + <none/> + </value> + </item> </dictionary> </pickle> </record> diff --git a/bt5/erp5_egov/SkinTemplateItem/portal_skins/erp5_egov_widget_library/WebSite_viewHeaderFormRenderer.xml b/bt5/erp5_egov/SkinTemplateItem/portal_skins/erp5_egov_widget_library/WebSite_viewHeaderFormRenderer.xml index 340df905803e8a479c1638eb1dc32471e652c3b9..675dda975365a1e246e507e5dd337473efca6eb7 100644 --- a/bt5/erp5_egov/SkinTemplateItem/portal_skins/erp5_egov_widget_library/WebSite_viewHeaderFormRenderer.xml +++ b/bt5/erp5_egov/SkinTemplateItem/portal_skins/erp5_egov_widget_library/WebSite_viewHeaderFormRenderer.xml @@ -62,7 +62,10 @@ <span class="onright">\n <a class="home" tal:attributes="href python:context.getWebSiteValue().absolute_url()" href="./home" \n i18n:translate="" i18n:domain="ui">Home</a>\n - <a class="print" href="DeclarationTVA_viewDeclarationTVAAsPdf" i18n:translate="" i18n:domain="ui">Print</a>\n + <tal:block tal:condition="python: context.getPrintFormUrl() is not None">\n + <a class="print" href="DeclarationTVA_viewDeclarationTVAAsPdf"\n + tal:attributes="href python: context.getPrintFormUrl()" i18n:translate="" i18n:domain="ui">Print</a>\n + </tal:block>\n <!--<a class="help" href="EGov_helpWithContext" tal:attributes="href python:\'help/\' + here.EGov_helpWithContext()" i18n:translate="" i18n:domain="ui">Help</a>-->\n <a class="help" href="EGov_helpWithContext" tal:attributes="href python:\'help/\' + here.EGov_helpWithContext()" onclick="window.open(this.href, \'safi_help\',\'width=800,height=500,menubar=yes,toolbar=yes,scrollbars=yes,resizable=yes\'); return false;" i18n:translate="" i18n:domain="ui">Help</a>\n </span>\n @@ -90,6 +93,12 @@ <key> <string>title</string> </key> <value> <string></string> </value> </item> + <item> + <key> <string>uid</string> </key> + <value> + <none/> + </value> + </item> </dictionary> </pickle> </record> diff --git a/bt5/erp5_egov/bt/revision b/bt5/erp5_egov/bt/revision index 44dfb1d0bc37a983be2737660078a23f65f86190..4acc65d01203475b5fbfa75a08718733074050ca 100644 --- a/bt5/erp5_egov/bt/revision +++ b/bt5/erp5_egov/bt/revision @@ -1 +1 @@ -264 \ No newline at end of file +266 \ No newline at end of file