Commit 847d236a authored by Christophe Dumez's avatar Christophe Dumez

2006-07-25 chris

* Added function to update business template, without reverting the changes
* Fixed SVN SSL Trust & Login errors when updating business template

git-svn-id: https://svn.erp5.org/repos/public/erp5/trunk@8746 20353a03-c40f-0410-a6d1-a30d3c3de9de
parent edab9c9d
......@@ -58,7 +58,11 @@
</item>
<item>
<key> <string>title</string> </key>
<value> <string>Update Business Template from SVN</string> </value>
<value> <string encoding="cdata"><![CDATA[
Revert & Update Business Template from SVN
]]></string> </value>
</item>
<item>
<key> <string>visible</string> </key>
......
<?xml version="1.0"?>
<ZopeData>
<record id="1" aka="AAAAAAAAAAE=">
<pickle>
<tuple>
<tuple>
<string>Products.CMFCore.ActionInformation</string>
<string>ActionInformation</string>
</tuple>
<none/>
</tuple>
</pickle>
<pickle>
<dictionary>
<item>
<key> <string>__ac_local_roles__</string> </key>
<value>
<none/>
</value>
</item>
<item>
<key> <string>action</string> </key>
<value>
<persistent> <string encoding="base64">AAAAAAAAAAI=</string> </persistent>
</value>
</item>
<item>
<key> <string>category</string> </key>
<value> <string>object_action</string> </value>
</item>
<item>
<key> <string>condition</string> </key>
<value> <string></string> </value>
</item>
<item>
<key> <string>description</string> </key>
<value> <string></string> </value>
</item>
<item>
<key> <string>icon</string> </key>
<value> <string></string> </value>
</item>
<item>
<key> <string>id</string> </key>
<value> <string>update_svn_bt_norevert</string> </value>
</item>
<item>
<key> <string>permissions</string> </key>
<value>
<tuple/>
</value>
</item>
<item>
<key> <string>priority</string> </key>
<value> <float>12.5</float> </value>
</item>
<item>
<key> <string>title</string> </key>
<value> <string>Update Business Template from SVN</string> </value>
</item>
<item>
<key> <string>visible</string> </key>
<value> <int>1</int> </value>
</item>
</dictionary>
</pickle>
</record>
<record id="2" aka="AAAAAAAAAAI=">
<pickle>
<tuple>
<tuple>
<string>Products.CMFCore.Expression</string>
<string>Expression</string>
</tuple>
<none/>
</tuple>
</pickle>
<pickle>
<dictionary>
<item>
<key> <string>text</string> </key>
<value> <string>string:${object_url}/BusinessTemplate_doSvnUpdateKeep</string> </value>
</item>
</dictionary>
</pickle>
</record>
</ZopeData>
......@@ -73,8 +73,10 @@ if caller == \'update\':\n
return context.REQUEST.RESPONSE.redirect(context.absolute_url() + \'/BusinessTemplate_doSvnUpdate\')\n
if caller == \'tree\':\n
return context.BusinessTemplate_viewSvnStatus(do_extract=\'False\')\n
if caller == \'updatewc\':\n
return context.REQUEST.RESPONSE.redirect(context.absolute_url() + \'/BusinessTemplate_doSvnUpdatewc\')\n
if caller == \'update\':\n
return context.REQUEST.RESPONSE.redirect(context.absolute_url() + \'/BusinessTemplate_doSvnUpdate\')\n
if caller == \'updateKeep\':\n
return context.REQUEST.RESPONSE.redirect(context.absolute_url() + \'/BusinessTemplate_doSvnUpdateKeep\')\n
if caller == \'commit\':\n
return context.BusinessTemplate_doSvnCommit(changelog=changelog,added=added,removed=removed,modified=modified)\n
if caller == \'info\':\n
......
......@@ -79,8 +79,10 @@ if caller == \'update\':\n
return context.REQUEST.RESPONSE.redirect(context.absolute_url() + \'/BusinessTemplate_doSvnUpdate\')\n
if caller == \'tree\':\n
return context.BusinessTemplate_viewSvnStatus(do_extract=\'False\')\n
if caller == \'updatewc\':\n
return context.REQUEST.RESPONSE.redirect(context.absolute_url() + \'/BusinessTemplate_doSvnUpdatewc\')\n
if caller == \'update\':\n
return context.REQUEST.RESPONSE.redirect(context.absolute_url() + \'/BusinessTemplate_doSvnUpdate\')\n
if caller == \'updateKeep\':\n
return context.REQUEST.RESPONSE.redirect(context.absolute_url() + \'/BusinessTemplate_doSvnUpdateKeep\')\n
if caller == \'commit\':\n
return context.BusinessTemplate_doSvnCommit(changelog=changelog,added=added,removed=removed,modified=modified)\n
if caller == \'ls\':\n
......
<?xml version="1.0"?>
<ZopeData>
<record id="1" aka="AAAAAAAAAAE=">
<pickle>
<tuple>
<tuple>
<string>Products.PythonScripts.PythonScript</string>
<string>PythonScript</string>
</tuple>
<none/>
</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 encoding="cdata"><![CDATA[
from Products.ERP5Subversion.SubversionClient import SubversionSSLTrustError, SubversionLoginError\n
\n
try:\n
new_bt = context.getPortalObject()["portal_subversion"].updateKeep(context)\n
except SubversionSSLTrustError, error:\n
context.REQUEST.set(\'portal_status_message\', \'SSL Certificate was not recognized\')\n
return context.asContext(trust_dict = error.getTrustDict(), caller=\'updateKeep\').BusinessTemplate_viewSvnSSLTrust()\n
except SubversionLoginError, error1 :\n
context.REQUEST.set(\'portal_status_message\', \'Server needs authentication, no cookie found\')\n
return context.asContext(caller=\'updateKeep\', realm = error1.getRealm(), username = context.getPortalObject()["portal_subversion"].getPreferredUsername()).BusinessTemplate_viewSvnLogin()\n
\n
context.REQUEST.set(\'portal_status_message\', \'Working Copy updated successfully.\')\n
return new_bt.REQUEST.RESPONSE.redirect(new_bt.REQUEST[\'BASE3\']+\'/\'+new_bt.getId()+\'/\'+\'BusinessTemplate_viewInstallationDialog?workflow_action=install_action&form_id=\'+new_bt.getId())\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>Products.ERP5Subversion.SubversionClient</string>
<string>SubversionSSLTrustError</string>
<string>SubversionLoginError</string>
<string>_getattr_</string>
<string>_getitem_</string>
<string>context</string>
<string>new_bt</string>
<string>error</string>
<string>error1</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>BusinessTemplate_doSvnUpdateKeep</string> </value>
</item>
<item>
<key> <string>warnings</string> </key>
<value>
<tuple/>
</value>
</item>
</dictionary>
</pickle>
</record>
</ZopeData>
2006-07-25 chris
* Added function to update business template, without reverting the changes
2006-07-19 chris
* Renamed or moved some files/folders to avoid conflicts with other business templates.
......
87
\ No newline at end of file
88
\ No newline at end of file
......@@ -10,6 +10,7 @@ Business Template | svn_cleanup_locks
Business Template | svn_conflicted_files
Business Template | svn_unversioned_files
Business Template | update_svn_bt
Business Template | update_svn_bt_norevert
Business Template | view_svn_repos_infos
External Folder | history
External Folder | metadata
......
0.8.6
\ No newline at end of file
0.8.7
\ 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