Commit 163715a0 authored by Julien Muchembled's avatar Julien Muchembled

Initial implementation of ERP5Git

git-svn-id: https://svn.erp5.org/repos/public/erp5/trunk@43620 20353a03-c40f-0410-a6d1-a30d3c3de9de
parent 5726aee5
......@@ -70,7 +70,7 @@ def setPermissionsOnEGovModule(self, portal_type_object):
'Add ERP5 Publications','Add ERP5 Reports',
'Add ERP5 Sites','Add ERP5 Subscriptions',
'Add ERP5 Tools','Add ERP5Catalog Tools',
'Add ERP5Form Tools','Add ERP5Subversion Tools',
'Add ERP5Form Tools',
'Add ERP5SyncML Tools','Add ERP5Type Tools',
'Add ExtFiles','Add ExtImages',
'Add External Methods','Add Filesystem Directory Views',
......
748
749
\ No newline at end of file
......@@ -30,7 +30,9 @@
</item>
<item>
<key> <string>description</string> </key>
<value> <string></string> </value>
<value>
<none/>
</value>
</item>
<item>
<key> <string>icon</string> </key>
......@@ -38,7 +40,7 @@
</item>
<item>
<key> <string>id</string> </key>
<value> <string>svn_conflicted_files</string> </value>
<value> <string>conflicted_files</string> </value>
</item>
<item>
<key> <string>permissions</string> </key>
......@@ -54,7 +56,7 @@
</item>
<item>
<key> <string>title</string> </key>
<value> <string>Resolve SVN Conflicted Files</string> </value>
<value> <string>Resolve VCS Conflicted Files</string> </value>
</item>
<item>
<key> <string>visible</string> </key>
......
......@@ -26,11 +26,15 @@
</item>
<item>
<key> <string>condition</string> </key>
<value> <string></string> </value>
<value>
<persistent> <string encoding="base64">AAAAAAAAAAM=</string> </persistent>
</value>
</item>
<item>
<key> <string>description</string> </key>
<value> <string></string> </value>
<value>
<none/>
</value>
</item>
<item>
<key> <string>icon</string> </key>
......@@ -38,7 +42,7 @@
</item>
<item>
<key> <string>id</string> </key>
<value> <string>svn_unversioned_files</string> </value>
<value> <string>create_working_copy</string> </value>
</item>
<item>
<key> <string>permissions</string> </key>
......@@ -50,11 +54,11 @@
</item>
<item>
<key> <string>priority</string> </key>
<value> <float>15.0</float> </value>
<value> <float>17.0</float> </value>
</item>
<item>
<key> <string>title</string> </key>
<value> <string>Clean SVN Unversioned Files</string> </value>
<value> <string>Create Working Copy</string> </value>
</item>
<item>
<key> <string>visible</string> </key>
......@@ -71,7 +75,20 @@
<dictionary>
<item>
<key> <string>text</string> </key>
<value> <string>string:${object_url}/BusinessTemplate_viewUnversioned</string> </value>
<value> <string>string:${object_url}/BusinessTemplate_viewCreateWorkingCopy</string> </value>
</item>
</dictionary>
</pickle>
</record>
<record id="3" aka="AAAAAAAAAAM=">
<pickle>
<global name="Expression" module="Products.CMFCore.Expression"/>
</pickle>
<pickle>
<dictionary>
<item>
<key> <string>text</string> </key>
<value> <string>python: here.isVcsType(None)</string> </value>
</item>
</dictionary>
</pickle>
......
<?xml version="1.0"?>
<ZopeData>
<record id="1" aka="AAAAAAAAAAE=">
<pickle>
<global name="ActionInformation" module="Products.CMFCore.ActionInformation"/>
</pickle>
<pickle>
<dictionary>
<item>
<key> <string>action</string> </key>
<value>
<persistent> <string encoding="base64">AAAAAAAAAAI=</string> </persistent>
</value>
</item>
<item>
<key> <string>categories</string> </key>
<value>
<tuple>
<string>action_type/object_view</string>
</tuple>
</value>
</item>
<item>
<key> <string>category</string> </key>
<value> <string>object_view</string> </value>
</item>
<item>
<key> <string>condition</string> </key>
<value>
<persistent> <string encoding="base64">AAAAAAAAAAM=</string> </persistent>
</value>
</item>
<item>
<key> <string>description</string> </key>
<value>
<none/>
</value>
</item>
<item>
<key> <string>icon</string> </key>
<value> <string></string> </value>
</item>
<item>
<key> <string>id</string> </key>
<value> <string>git_commit</string> </value>
</item>
<item>
<key> <string>permissions</string> </key>
<value>
<tuple>
<string>Manage portal</string>
</tuple>
</value>
</item>
<item>
<key> <string>priority</string> </key>
<value> <float>4.5</float> </value>
</item>
<item>
<key> <string>title</string> </key>
<value> <string>Git</string> </value>
</item>
<item>
<key> <string>visible</string> </key>
<value> <int>1</int> </value>
</item>
</dictionary>
</pickle>
</record>
<record id="2" aka="AAAAAAAAAAI=">
<pickle>
<global name="Expression" module="Products.CMFCore.Expression"/>
</pickle>
<pickle>
<dictionary>
<item>
<key> <string>text</string> </key>
<value> <string>string:${object_url}/BusinessTemplate_viewVcsStatus</string> </value>
</item>
</dictionary>
</pickle>
</record>
<record id="3" aka="AAAAAAAAAAM=">
<pickle>
<global name="Expression" module="Products.CMFCore.Expression"/>
</pickle>
<pickle>
<dictionary>
<item>
<key> <string>text</string> </key>
<value> <string>python: here.getInstallationState() not in (\'installed\', \'replaced\') and here.isVcsType(\'git\')</string> </value>
</item>
</dictionary>
</pickle>
</record>
</ZopeData>
......@@ -26,11 +26,15 @@
</item>
<item>
<key> <string>condition</string> </key>
<value> <string></string> </value>
<value>
<persistent> <string encoding="base64">AAAAAAAAAAM=</string> </persistent>
</value>
</item>
<item>
<key> <string>description</string> </key>
<value> <string></string> </value>
<value>
<none/>
</value>
</item>
<item>
<key> <string>icon</string> </key>
......@@ -76,4 +80,17 @@
</dictionary>
</pickle>
</record>
<record id="3" aka="AAAAAAAAAAM=">
<pickle>
<global name="Expression" module="Products.CMFCore.Expression"/>
</pickle>
<pickle>
<dictionary>
<item>
<key> <string>text</string> </key>
<value> <string>python: here.isVcsType(\'svn\')</string> </value>
</item>
</dictionary>
</pickle>
</record>
</ZopeData>
......@@ -32,7 +32,9 @@
</item>
<item>
<key> <string>description</string> </key>
<value> <string></string> </value>
<value>
<none/>
</value>
</item>
<item>
<key> <string>icon</string> </key>
......@@ -40,7 +42,7 @@
</item>
<item>
<key> <string>id</string> </key>
<value> <string>commit</string> </value>
<value> <string>svn_commit</string> </value>
</item>
<item>
<key> <string>permissions</string> </key>
......@@ -73,7 +75,7 @@
<dictionary>
<item>
<key> <string>text</string> </key>
<value> <string>string:${object_url}/BusinessTemplate_viewSvnStatus</string> </value>
<value> <string>string:${object_url}/BusinessTemplate_viewVcsStatus</string> </value>
</item>
</dictionary>
</pickle>
......@@ -86,7 +88,7 @@
<dictionary>
<item>
<key> <string>text</string> </key>
<value> <string>python: here.getInstallationState() != \'installed\' and here.getInstallationState() != \'replaced\'</string> </value>
<value> <string>python: here.getInstallationState() not in (\'installed\', \'replaced\') and here.isVcsType(\'svn\')</string> </value>
</item>
</dictionary>
</pickle>
......
......@@ -30,7 +30,9 @@
</item>
<item>
<key> <string>description</string> </key>
<value> <string></string> </value>
<value>
<none/>
</value>
</item>
<item>
<key> <string>icon</string> </key>
......@@ -71,7 +73,7 @@
<dictionary>
<item>
<key> <string>text</string> </key>
<value> <string>string:${object_url}/BusinessTemplate_doSvnUpdateKeep</string> </value>
<value> <string>string:${object_url}/BusinessTemplate_doSvnUpdate?keep:int=1</string> </value>
</item>
</dictionary>
</pickle>
......
......@@ -26,11 +26,15 @@
</item>
<item>
<key> <string>condition</string> </key>
<value> <string></string> </value>
<value>
<persistent> <string encoding="base64">AAAAAAAAAAM=</string> </persistent>
</value>
</item>
<item>
<key> <string>description</string> </key>
<value> <string></string> </value>
<value>
<none/>
</value>
</item>
<item>
<key> <string>icon</string> </key>
......@@ -38,7 +42,7 @@
</item>
<item>
<key> <string>id</string> </key>
<value> <string>view_svn_repos_infos</string> </value>
<value> <string>view_svn_repos_info</string> </value>
</item>
<item>
<key> <string>permissions</string> </key>
......@@ -71,7 +75,20 @@
<dictionary>
<item>
<key> <string>text</string> </key>
<value> <string>string:${object_url}/BusinessTemplate_doSvnInfo</string> </value>
<value> <string>string:${object_url}/BusinessTemplate_viewSvnInfo</string> </value>
</item>
</dictionary>
</pickle>
</record>
<record id="3" aka="AAAAAAAAAAM=">
<pickle>
<global name="Expression" module="Products.CMFCore.Expression"/>
</pickle>
<pickle>
<dictionary>
<item>
<key> <string>text</string> </key>
<value> <string>python: here.isVcsType(\'svn\')</string> </value>
</item>
</dictionary>
</pickle>
......
......@@ -38,13 +38,13 @@
</item>
<item>
<key> <string>id</string> </key>
<value> <string>subversion</string> </value>
<value> <string>vcs</string> </value>
</item>
<item>
<key> <string>permissions</string> </key>
<value>
<tuple>
<string></string>
<string>View</string>
</tuple>
</value>
</item>
......@@ -54,7 +54,7 @@
</item>
<item>
<key> <string>title</string> </key>
<value> <string>Subversion</string> </value>
<value> <string>VCS</string> </value>
</item>
<item>
<key> <string>visible</string> </key>
......@@ -71,7 +71,7 @@
<dictionary>
<item>
<key> <string>text</string> </key>
<value> <string>string:${object_url}/Preference_viewSubversion</string> </value>
<value> <string>string:${object_url}/Preference_viewVcs</string> </value>
</item>
</dictionary>
</pickle>
......
......@@ -30,7 +30,9 @@
</item>
<item>
<key> <string>description</string> </key>
<value> <string></string> </value>
<value>
<none/>
</value>
</item>
<item>
<key> <string>icon</string> </key>
......@@ -38,13 +40,13 @@
</item>
<item>
<key> <string>id</string> </key>
<value> <string>bt_svn_history</string> </value>
<value> <string>bt_vcs_history</string> </value>
</item>
<item>
<key> <string>permissions</string> </key>
<value>
<tuple>
<string></string>
<string>View</string>
</tuple>
</value>
</item>
......@@ -54,7 +56,7 @@
</item>
<item>
<key> <string>title</string> </key>
<value> <string>View SVN History</string> </value>
<value> <string>View VCS History</string> </value>
</item>
<item>
<key> <string>visible</string> </key>
......@@ -71,7 +73,7 @@
<dictionary>
<item>
<key> <string>text</string> </key>
<value> <string>string:${object_url}/BusinessTemplate_doSvnLogGlobal</string> </value>
<value> <string>string:${object_url}/BusinessTemplate_doVcsLogGlobal</string> </value>
</item>
</dictionary>
</pickle>
......
......@@ -64,7 +64,7 @@ def findMessageListFromPythonInProduct(function_name_list):
product_dir = os.path.dirname(Products.ERP5.__path__[0])
erp5_product_list = ('CMFActivity', 'CMFCategory',
'ERP5', 'ERP5Banking', 'ERP5Catalog', 'ERP5Configurator',
'ERP5Form', 'ERP5OOo', 'ERP5Security', 'ERP5Subversion',
'ERP5Form', 'ERP5OOo', 'ERP5Security', 'ERP5Vcs',
'ERP5SyncML', 'ERP5Type', 'ERP5Wizard', 'ERP5Workflow',
'HBTreeFolder2', 'MailTemplates', 'TimerService',
'ZMySQLDA', 'ZMySQLDDA', 'ZSQLCatalog',
......
......@@ -2,7 +2,7 @@
<ZopeData>
<record id="1" aka="AAAAAAAAAAE=">
<pickle>
<global name="ERP5TypeInformation" module="Products.ERP5Type.ERP5Type"/>
<global name="Base Type" module="erp5.portal_type"/>
</pickle>
<pickle>
<dictionary>
......
......@@ -2,7 +2,7 @@
<ZopeData>
<record id="1" aka="AAAAAAAAAAE=">
<pickle>
<global name="ERP5TypeInformation" module="Products.ERP5Type.ERP5Type"/>
<global name="Base Type" module="erp5.portal_type"/>
</pickle>
<pickle>
<dictionary>
......
......@@ -2,7 +2,7 @@
<ZopeData>
<record id="1" aka="AAAAAAAAAAE=">
<pickle>
<global name="ERP5TypeInformation" module="Products.ERP5Type.ERP5Type"/>
<global name="Base Type" module="erp5.portal_type"/>
</pickle>
<pickle>
<dictionary>
......
......@@ -2,7 +2,7 @@
<ZopeData>
<record id="1" aka="AAAAAAAAAAE=">
<pickle>
<global name="ERP5TypeInformation" module="Products.ERP5Type.ERP5Type"/>
<global name="Base Type" module="erp5.portal_type"/>
</pickle>
<pickle>
<dictionary>
......
......@@ -2,7 +2,7 @@
<ZopeData>
<record id="1" aka="AAAAAAAAAAE=">
<pickle>
<global name="ERP5TypeInformation" module="Products.ERP5Type.ERP5Type"/>
<global name="Base Type" module="erp5.portal_type"/>
</pickle>
<pickle>
<dictionary>
......
......@@ -63,7 +63,7 @@ from Products.ERP5Type.Document import newTempBase\n
#- \'portal_catalog/erp5_mysql\' & \'portal_catalog/cps3_mysql\' & \'portal_types/Business Template\'\n
##\n
\n
portals_scanned = [\'portal_actions\', \'portal_memberdata\', \'portal_skins\', \'portal_types\', \'portal_undo\', \'portal_url\', \'portal_workflow\', \'portal_discussion\', \'portal_membership\', \'portal_registration\', \'portal_properties\', \'portal_metadata\', \'portal_syndication\', \'portal_uidannotation\', \'portal_uidgenerator\', \'portal_uidhandler\', \'portal_report\', \'portal_rules\', \'portal_ids\', \'portal_simulation\', \'portal_alarms\', \'portal_domains\', \'portal_deliveries\', \'portal_orders\', \'portal_classes\', \'portal_catalog\', \'portal_selections\', \'portal_synchronizations\', \'portal_activities\', \'portal_subversion\']\n
portals_scanned = [\'portal_actions\', \'portal_memberdata\', \'portal_skins\', \'portal_types\', \'portal_undo\', \'portal_url\', \'portal_workflow\', \'portal_discussion\', \'portal_membership\', \'portal_registration\', \'portal_properties\', \'portal_metadata\', \'portal_syndication\', \'portal_uidannotation\', \'portal_uidgenerator\', \'portal_uidhandler\', \'portal_report\', \'portal_rules\', \'portal_ids\', \'portal_simulation\', \'portal_alarms\', \'portal_domains\', \'portal_deliveries\', \'portal_orders\', \'portal_classes\', \'portal_catalog\', \'portal_selections\', \'portal_synchronizations\', \'portal_activities\']\n
orphans_list = []\n
if object is None:\n
object = context\n
......
......@@ -52,11 +52,10 @@
<key> <string>_body</string> </key>
<value> <string encoding="cdata"><![CDATA[
from Products.ERP5Subversion.SubversionClient import SubversionSSLTrustError\n
from Products.ERP5Vcs.SubversionClient import SubversionSSLTrustError\n
from Products.ERP5Type.Document import newTempBase\n
\n
portal = context.getPortalObject()\n
portal_subversion = portal.portal_subversion\n
\n
# For now we will work only under portal_skins\n
folder_id = context.getParentValue().getId() # replace aq_parent by getParentValue\n
......@@ -75,7 +74,8 @@ if business_template is not None:\n
repository_path = \'%s/SkinTemplateItem/portal_skins/%s/%s.xml\' % (\n
business_template.getTitle(), folder_id, context.getId())\n
\n
log_list = portal_subversion.log(repository_path, business_template)\n
vcs_tool = business_template.getVcsTool()\n
log_list = vcs_tool.log(repository_path, business_template)\n
for log_dict in log_list:\n
log_dict[\'message\'] = log_dict[\'message\'].replace(\'\\n\', \'<br/>\')\n
temp_object = newTempBase(folder=context, id=\'1\', **log_dict)\n
......
<?xml version="1.0"?>
<ZopeData>
<record id="1" aka="AAAAAAAAAAE=">
<pickle>
<global name="PythonScript" module="Products.PythonScripts.PythonScript"/>
</pickle>
<pickle>
<dictionary>
<item>
<key> <string>Script_magic</string> </key>
<value> <int>3</int> </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\n
from Products.ERP5Subversion.SubversionClient import SubversionLoginError\n
from Products.ERP5Type.Message import translateString\n
from ZTUtils import make_query\n
request = container.REQUEST\n
\n
# XXX: To be compatible with commit from diff view\n
if same_type(added, []):\n
added = \',\'.join(added)\n
if same_type(modified, []):\n
modified = \',\'.join(modified)\n
if same_type(removed, []):\n
removed = \',\'.join(removed)\n
\n
def getRevisionNumber(revision):\n
"""get the revision number from a revision, with backward compatibility support.\n
"""\n
try:\n
return revision.getNumber()\n
except AttributeError:\n
return revision\n
\n
if changelog is None or not changelog.strip():\n
error_msg = "Please set a ChangeLog message."\n
error_kw = {}\n
method = \'BusinessTemplate_viewSvnChangelog\'\n
else:\n
portal_subversion = context.getPortalObject().portal_subversion\n
exclude_list = added.split(\',\') + modified.split(\',\') + removed.split(\',\')\n
portal_subversion.revert(\'.\', business_template=context, recurse=True,\n
exclude_list=filter(None, exclude_list))\n
try:\n
revision = portal_subversion.checkin(\'.\', business_template=context,\n
log_message=changelog)\n
except SubversionSSLTrustError, e:\n
error_msg = "SSL Certificate was not recognized"\n
error_kw = dict(caller=\'commit\', trust_dict=e.getTrustDict())\n
method = \'BusinessTemplate_viewSvnSSLTrust\'\n
except SubversionLoginError, e:\n
error_msg = "Server needs authentication, no cookie found"\n
error_kw = dict(caller=\'commit\', realm=e.getRealm(),\n
username=portal_subversion.getPreferredUsername())\n
method = \'BusinessTemplate_viewSvnLogin\'\n
else:\n
return request.RESPONSE.redirect(\'%s/view?%s\' % (\n
context.absolute_url(),\n
make_query(portal_status_message=translateString(\n
\'Files committed successfully in revision ${revision}.\',\n
mapping=dict(revision=getRevisionNumber(revision))))))\n
\n
request.set(\'portal_status_message\', translateString(error_msg))\n
request.set(\'cancel_url\', context.absolute_url() +\n
\'/BusinessTemplate_viewSvnStatus?do_extract=False\'\n
\'&portal_status_message=Commit%20cancelled.\')\n
context = context.asContext(added=added, modified=modified, removed=removed,\n
**error_kw)\n
return getattr(context, method)()\n
]]></string> </value>
</item>
<item>
<key> <string>_params</string> </key>
<value> <string>added=\'\',modified=\'\',removed=\'\', changelog=None, **kw</string> </value>
</item>
<item>
<key> <string>id</string> </key>
<value> <string>BusinessTemplate_doSvnCommit</string> </value>
</item>
</dictionary>
</pickle>
</record>
</ZopeData>
<?xml version="1.0"?>
<ZopeData>
<record id="1" aka="AAAAAAAAAAE=">
<pickle>
<global name="PythonScript" module="Products.PythonScripts.PythonScript"/>
</pickle>
<pickle>
<dictionary>
<item>
<key> <string>Script_magic</string> </key>
<value> <int>3</int> </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 ZTUtils import make_query\n
\n
modified=context.REQUEST["modified"]\n
added=context.REQUEST["added"]\n
removed=context.REQUEST["removed"]\n
\n
subversion_tool = context.getPortalObject()["portal_subversion"]\n
template_tool = context.getPortalObject()["portal_templates"]\n
\n
print \'<div style="color: black">\'\n
tab_Modified=modified.split(\',\')\n
tab_Added=added.split(\',\')\n
tab_Removed=removed.split(\',\')\n
\n
if modified != \'none\':\n
for f in tab_Modified:\n
diff = subversion_tool.diff(f, context)\n
final_diff = template_tool.getFilteredDiffAsHTML(diff)\n
if len(final_diff):\n
print \'<input name="modified" value="%s" type="checkbox" checked="checked" />\'%f\n
f = context.getPortalObject()["portal_subversion"].relativeToAbsolute(f, context)\n
print "<span style=\'font-weight: bold; color: black;\'>Index: "\\\n
"<a href=\'BusinessTemplate_viewSvnShowFile?%s\'>%s</a></span>" %(\n
make_query(file=f), f)\n
edit_path = subversion_tool.editPath(context, f)\n
if(edit_path != \'#\'):\n
print "<a href=\'"+edit_path+"\'><img src=\'ERP5Subversion_imgs/edit.png\' alt=\'Edit\' style=\'border: 0\' /></a>"\n
print final_diff\n
print \'</span><br/>\'\n
print \'<hr/><br/>\'\n
\n
if added != \'none\':\n
for f in tab_Added:\n
print \'<input name="added" value="%s" type="checkbox" checked="checked" />\'%f\n
f = subversion_tool.relativeToAbsolute(f, context)\n
print "<span style=\'font-weight: bold; color: black;\'>Index: "\\\n
"<a href=\'BusinessTemplate_viewSvnShowFile?%s\'>%s</a></span>" %(\n
make_query(file=f), f)\n
edit_path = subversion_tool.editPath(context, f)\n
if(edit_path != \'#\'):\n
print "<a href=\'"+edit_path+"\'><img src=\'ERP5Subversion_imgs/edit.png\' alt=\'Edit\' style=\'border: 0\' /></a>"\n
print \'</span><br/>\'\n
print "<span style=\'color: green;\'>File Added</span><br/><br/><hr/><br/>"\n
\n
if removed != \'none\':\n
for f in tab_Removed:\n
print \'<input name="removed" value="%s" type="checkbox" checked="checked" />\'%f\n
f = subversion_tool.relativeToAbsolute(f, context)\n
print "<span style=\'font-weight: bold; color: black;\'>Index: "\\\n
"<a href=\'BusinessTemplate_viewSvnShowFile?%s\'>%s</a></span>" %(\n
make_query(file=f), f)\n
edit_path = subversion_tool.editPath(context, f)\n
if(edit_path != \'#\'):\n
print "<a href=\'"+edit_path+"\'><img src=\'ERP5Subversion_imgs/edit.png\' alt=\'Edit\' style=\'border: 0\' /></a>"\n
print \'</span><br/>\'\n
print "<span style=\'color: red;\'>File Removed</span><br/><br/><hr/><br/>"\n
\n
print \'</div>\'\n
return printed\n
]]></string> </value>
</item>
<item>
<key> <string>_params</string> </key>
<value> <string></string> </value>
</item>
<item>
<key> <string>id</string> </key>
<value> <string>BusinessTemplate_doSvnDiff</string> </value>
</item>
</dictionary>
</pickle>
</record>
</ZopeData>
<?xml version="1.0"?>
<ZopeData>
<record id="1" aka="AAAAAAAAAAE=">
<pickle>
<global name="PythonScript" module="Products.PythonScripts.PythonScript"/>
</pickle>
<pickle>
<dictionary>
<item>
<key> <string>Script_magic</string> </key>
<value> <int>3</int> </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>from Products.ERP5Subversion.SubversionClient import SubversionSSLTrustError, SubversionLoginError\n
from Products.ERP5Type.Document import newTempBase\n
working_copy = context.getPortalObject()["portal_subversion"].getSubversionPath(context)\n
\n
try:\n
conflicted_list = context.getPortalObject()["portal_subversion"].conflictedFiles(working_copy)\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=\'log\').BusinessTemplate_viewSvnSSLTrust()\n
except SubversionLoginError, error1 :\n
context.REQUEST.set(\'portal_status_message\', \'Server needs authentication, no cookie found\')\n
return context.asContext(caller=\'log\', realm = error1.getRealm(), username = context.getPortalObject()["portal_subversion"].getPreferredUsername()).BusinessTemplate_viewSvnLogin()\n
\n
if not conflicted_list:\n
return []\n
\n
object_list = []\n
for my_dict in conflicted_list:\n
temp_object = newTempBase(folder=context.getPortalObject(), id=\'1234\')\n
temp_object.edit(**my_dict)\n
object_list.append(temp_object)\n
\n
return object_list\n
</string> </value>
</item>
<item>
<key> <string>_params</string> </key>
<value> <string>**kw</string> </value>
</item>
<item>
<key> <string>id</string> </key>
<value> <string>BusinessTemplate_doSvnListConflicted</string> </value>
</item>
</dictionary>
</pickle>
</record>
</ZopeData>
<?xml version="1.0"?>
<ZopeData>
<record id="1" aka="AAAAAAAAAAE=">
<pickle>
<global name="PythonScript" module="Products.PythonScripts.PythonScript"/>
</pickle>
<pickle>
<dictionary>
<item>
<key> <string>Script_magic</string> </key>
<value> <int>3</int> </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>from Products.ERP5Subversion.SubversionClient import SubversionSSLTrustError, SubversionLoginError\n
from Products.ERP5Type.Document import newTempBase\n
working_copy = context.getPortalObject()["portal_subversion"].getSubversionPath(context)\n
\n
try:\n
unversioned_list = context.getPortalObject()["portal_subversion"].unversionedFiles(working_copy)\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=\'log\').BusinessTemplate_viewSvnSSLTrust()\n
except SubversionLoginError, error1 :\n
context.REQUEST.set(\'portal_status_message\', \'Server needs authentication, no cookie found\')\n
return context.asContext(caller=\'log\', realm = error1.getRealm(), username = context.getPortalObject()["portal_subversion"].getPreferredUsername()).BusinessTemplate_viewSvnLogin()\n
\n
if not unversioned_list:\n
return []\n
\n
object_list = []\n
for my_dict in unversioned_list:\n
temp_object = newTempBase(folder=context.getPortalObject(), id=\'1234\')\n
temp_object.edit(**my_dict)\n
object_list.append(temp_object)\n
\n
return object_list\n
</string> </value>
</item>
<item>
<key> <string>_params</string> </key>
<value> <string>**kw</string> </value>
</item>
<item>
<key> <string>id</string> </key>
<value> <string>BusinessTemplate_doSvnListUnversioned</string> </value>
</item>
</dictionary>
</pickle>
</record>
</ZopeData>
<?xml version="1.0"?>
<ZopeData>
<record id="1" aka="AAAAAAAAAAE=">
<pickle>
<global name="PythonScript" module="Products.PythonScripts.PythonScript"/>
</pickle>
<pickle>
<dictionary>
<item>
<key> <string>Script_magic</string> </key>
<value> <int>3</int> </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\n
from Products.ERP5Type.Document import newTempBase\n
\n
portal = context.getPortalObject()\n
portal_subversion = portal.portal_subversion\n
\n
try:\n
log_list = portal_subversion.log(added, context)\n
except SubversionSSLTrustError, error:\n
context.REQUEST.set(\'portal_status_message\', \n
\'SSL Certificate was not recognized\')\n
return context.asContext(trust_dict = error.getTrustDict(), \n
caller=\'log\', \n
added=added).BusinessTemplate_viewSvnSSLTrust()\n
\n
if not log_list:\n
return []\n
\n
object_list = []\n
for my_dict in log_list:\n
my_dict[\'message\'] = \'<br/>\'.join(my_dict[\'message\'].split(\'\\n\'))\n
my_dict[\'uid\'] = my_dict[\'revision\']\n
temp_object = newTempBase(folder=context.getPortalObject(), \n
id=\'1234\', **my_dict)\n
object_list.append(temp_object)\n
\n
context.REQUEST.set(\'object_list\', object_list)\n
return context.BusinessTemplate_viewSvnLog()\n
]]></string> </value>
</item>
<item>
<key> <string>_params</string> </key>
<value> <string>added,**kw</string> </value>
</item>
<item>
<key> <string>id</string> </key>
<value> <string>BusinessTemplate_doSvnLog</string> </value>
</item>
</dictionary>
</pickle>
</record>
</ZopeData>
<?xml version="1.0"?>
<ZopeData>
<record id="1" aka="AAAAAAAAAAE=">
<pickle>
<global name="PythonScript" module="Products.PythonScripts.PythonScript"/>
</pickle>
<pickle>
<dictionary>
<item>
<key> <string>Script_magic</string> </key>
<value> <int>3</int> </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
from Products.ERP5Type.Document import newTempBase\n
\n
# get selected business templates\n
p = context.getPortalObject()\n
portal_selections = p.portal_selections\n
selection_name = \'business_template_selection\' # harcoded because we can also get delete_selection\n
uids = portal_selections.getSelectionCheckedUidsFor(selection_name)\n
\n
if len(uids) != 1:\n
raise \'TemplateConditionError\', \'You can select only one Business Template\'\n
\n
file = context.portal_catalog.getObject(uids[0]).getTitle()\n
\n
try:\n
log_list = context.getPortalObject()["portal_subversion"].log(file, context.portal_catalog.getObject(uids[0]))\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=\'log\', file=file).BusinessTemplate_viewSvnSSLTrust()\n
except SubversionLoginError, error1 :\n
context.REQUEST.set(\'portal_status_message\', \'Server needs authentication, no cookie found\')\n
return context.asContext(caller=\'log\', file=file, realm = error1.getRealm(), username = context.getPortalObject()["portal_subversion"].getPreferredUsername()).BusinessTemplate_viewSvnLogin()\n
\n
if not log_list:\n
return []\n
\n
object_list = []\n
for my_dict in log_list:\n
my_dict[\'message\']=\'<br/>\'.join(my_dict[\'message\'].split(\'\\n\'))\n
my_dict[\'uid\']=my_dict[\'revision\']\n
temp_object = newTempBase(folder=context.getPortalObject(), id=\'1234\')\n
temp_object.edit(**my_dict)\n
object_list.append(temp_object)\n
\n
context.REQUEST.set(\'object_list\', object_list)\n
context.REQUEST.set(\'file\', file)\n
return context.asContext(context=context.portal_catalog.getObject(uids[0])).BusinessTemplate_viewSvnLog()\n
]]></string> </value>
</item>
<item>
<key> <string>_params</string> </key>
<value> <string>**kw</string> </value>
</item>
<item>
<key> <string>id</string> </key>
<value> <string>BusinessTemplate_doSvnLogGlobal</string> </value>
</item>
</dictionary>
</pickle>
</record>
</ZopeData>
<?xml version="1.0"?>
<ZopeData>
<record id="1" aka="AAAAAAAAAAE=">
<pickle>
<global name="PythonScript" module="Products.PythonScripts.PythonScript"/>
</pickle>
<pickle>
<dictionary>
<item>
<key> <string>Script_magic</string> </key>
<value> <int>3</int> </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>context.getPortalObject()["portal_subversion"].setLogin(auth, user, password)\n
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 == \'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
return context.REQUEST.RESPONSE.redirect(context.absolute_url() + \'/BusinessTemplate_doSvnInfo\')\n
if caller == \'switch\':\n
return context.REQUEST.RESPONSE.redirect(context.absolute_url() + \'/BusinessTemplate_doSvnSwitch(repos_url)\')\n
return \'Error: Caller \'+caller+\' is unknown\'\n
</string> </value>
</item>
<item>
<key> <string>_params</string> </key>
<value> <string>user,password,auth,added,modified,removed,caller,changelog,**kw</string> </value>
</item>
<item>
<key> <string>id</string> </key>
<value> <string>BusinessTemplate_doSvnLogin</string> </value>
</item>
</dictionary>
</pickle>
</record>
</ZopeData>
<?xml version="1.0"?>
<ZopeData>
<record id="1" aka="AAAAAAAAAAE=">
<pickle>
<global name="PythonScript" module="Products.PythonScripts.PythonScript"/>
</pickle>
<pickle>
<dictionary>
<item>
<key> <string>Script_magic</string> </key>
<value> <int>3</int> </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>from Products.ERP5Subversion.SubversionClient import SubversionSSLTrustError\n
try:\n
infos_list = context.getPortalObject()["portal_subversion"].ls(added, 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(), added=added, caller=\'ls\').BusinessTemplate_viewSvnSSLTrust()\n
if infos_list:\n
return context.asContext(infos_dict=infos_list[0], file=added, edit_path=context.getPortalObject()["portal_subversion"].editPath(context, added)).BusinessTemplate_viewSvnInfosFile()\n
else:\n
return context.asContext(infos_dict=False, file=added, edit_path=context.getPortalObject()["portal_subversion"].editPath(context, added)).BusinessTemplate_viewSvnInfosFile()\n
</string> </value>
</item>
<item>
<key> <string>_params</string> </key>
<value> <string>added</string> </value>
</item>
<item>
<key> <string>id</string> </key>
<value> <string>BusinessTemplate_doSvnLs</string> </value>
</item>
</dictionary>
</pickle>
</record>
</ZopeData>
<?xml version="1.0"?>
<ZopeData>
<record id="1" aka="AAAAAAAAAAE=">
<pickle>
<global name="PythonScript" module="Products.PythonScripts.PythonScript"/>
</pickle>
<pickle>
<dictionary>
<item>
<key> <string>Script_magic</string> </key>
<value> <int>3</int> </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[
file = context.REQUEST[\'file\']\n
\n
if \'uids\' not in context.REQUEST.keys(): \n
context.REQUEST.set(\'portal_status_message\', \'You must select TWO revisions.\')\n
return context.asContext(file=file).BusinessTemplate_viewSvnLog()\n
\n
revisions_list = context.REQUEST[\'uids\']\n
\n
if len(revisions_list) != 2:\n
context.REQUEST.set(\'portal_status_message\', \'You must select exactly TWO revisions.\')\n
return context.asContext(file=file).BusinessTemplate_viewSvnLog()\n
\n
revisions_list.sort()\n
\n
diff = "<b><font color=\'black\'>Index: <a href=\'BusinessTemplate_viewSvnShowFile?file="+context.getPortalObject()["portal_subversion"].relativeToAbsolute(file, context)+"\'>"+context.getPortalObject()["portal_subversion"].relativeToAbsolute(file, context)+"</a> <a href=\'"+context.getPortalObject()["portal_subversion"].editPath(context, file)+"\'><img src=\'ERP5Subversion_imgs/edit.png\' border=\'0\'></a><br/>"\n
diff += \'<hr/></b>\'\n
diff += context.getPortalObject()["portal_subversion"].diffHTML(file, context, revision1=revisions_list[0], revision2=revisions_list[1])\n
diff += \'</font>\'\n
return context.asContext(diff=diff).BusinessTemplate_viewSvnMultiDiff()\n
]]></string> </value>
</item>
<item>
<key> <string>_params</string> </key>
<value> <string>**kw</string> </value>
</item>
<item>
<key> <string>id</string> </key>
<value> <string>BusinessTemplate_doSvnMultiDiff</string> </value>
</item>
</dictionary>
</pickle>
</record>
</ZopeData>
<?xml version="1.0"?>
<ZopeData>
<record id="1" aka="AAAAAAAAAAE=">
<pickle>
<global name="PythonScript" module="Products.PythonScripts.PythonScript"/>
</pickle>
<pickle>
<dictionary>
<item>
<key> <string>Script_magic</string> </key>
<value> <int>3</int> </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>dict_keys=(\'valid_until\', \'hostname\', \'realm\', \'finger_print\', \'valid_from\', \'issuer_dname\', \'failures\',)\n
trust_dict={}\n
for key in dict_keys:\n
trust_dict[key]=context.REQUEST[key]\n
\n
context.getPortalObject()["portal_subversion"].acceptSSLServer(trust_dict, True)\n
\n
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 == \'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
return context.REQUEST.RESPONSE.redirect(context.absolute_url() + \'/BusinessTemplate_doSvnLs?added=\'+added.replace(\'%20\',\'%2520\').replace(\' \',\'%20\'))\n
if caller == \'log\':\n
return context.REQUEST.RESPONSE.redirect(context.absolute_url() + \'/BusinessTemplate_doSvnLog?added=\'+added.replace(\'%20\',\'%2520\').replace(\' \',\'%20\'))\n
if caller == \'info\':\n
return context.REQUEST.RESPONSE.redirect(context.absolute_url() + \'/BusinessTemplate_doSvnInfo\')\n
if caller == \'switch\':\n
return context.REQUEST.RESPONSE.redirect(context.absolute_url() + \'/BusinessTemplate_doSvnSwitch(repos_url)\')\n
return \'Error: Caller \'+ caller + \'is unknown\'\n
</string> </value>
</item>
<item>
<key> <string>_params</string> </key>
<value> <string>added, modified, removed, caller, changelog, **kw</string> </value>
</item>
<item>
<key> <string>id</string> </key>
<value> <string>BusinessTemplate_doSvnSslTrust</string> </value>
</item>
</dictionary>
</pickle>
</record>
</ZopeData>
<?xml version="1.0"?>
<ZopeData>
<record id="1" aka="AAAAAAAAAAE=">
<pickle>
<global name="PythonScript" module="Products.PythonScripts.PythonScript"/>
</pickle>
<pickle>
<dictionary>
<item>
<key> <string>Script_magic</string> </key>
<value> <int>3</int> </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>_params</string> </key>
<value> <string></string> </value>
</item>
<item>
<key> <string>id</string> </key>
<value> <string>BusinessTemplate_doSvnUpdateKeep</string> </value>
</item>
</dictionary>
</pickle>
</record>
</ZopeData>
<?xml version="1.0"?>
<ZopeData>
<record id="1" aka="AAAAAAAAAAE=">
<pickle>
<global name="ZopePageTemplate" module="Products.PageTemplates.ZopePageTemplate"/>
</pickle>
<pickle>
<dictionary>
<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_subpath</string> </key>
<value> <string>traverse_subpath</string> </value>
</item>
</dictionary>
</value>
</item>
</dictionary>
</state>
</object>
</value>
</item>
<item>
<key> <string>_text</string> </key>
<value> <unicode encoding="cdata"><![CDATA[
<tal:block tal:replace="nothing"\n
xmlns:tal="http://xml.zope.org/namespaces/tal"\n
xmlns:metal="http://xml.zope.org/namespaces/metal"\n
xmlns:i18n="http://xml.zope.org/namespaces/i18n">\n
<!--\n
Copyright (c) 2006 Nexedi SARL and Contributors. All Rights Reserved.\n
Christophe Dumez <christophe@nexedi.com>\n
\n
This program is Free Software; you can redistribute it and/or\n
modify it under the terms of the GNU General Public License\n
as published by the Free Software Foundation; either version 2\n
of the License, or (at your option) any later version.\n
\n
This program is distributed in the hope that it will be useful,\n
but WITHOUT ANY WARRANTY; without even the implied warranty of\n
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the\n
GNU General Public License for more details.\n
\n
You should have received a copy of the GNU General Public License\n
along with this program; if not, write to the Free Software\n
Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.\n
-->\n
</tal:block>\n
<tal:block metal:use-macro="here/view_main/macros/master">\n
<tal:block metal:fill-slot="main">\n
\n
<tal:block tal:define="path context/file; infos_dict context/infos_dict">\n
\n
<br/><a tal:attributes="href python:\'BusinessTemplate_viewSvnShowFile?file=\'+str(path)"><b tal:content="python:context.getPortalObject()[\'portal_subversion\'].relativeToAbsolute(path,context)"></b></a>\n
<span tal:condition="python:context.edit_path!=\'#\'"><a tal:attributes="href context/edit_path"><img src=\'ERP5Subversion_imgs/edit.png\' style=\'border: 0\' alt="edit"/></a></span>\n
<hr/><br/>\n
<div tal:condition="infos_dict" style="text-align: center">\n
<table style="width: 60%; border-style: solid; border-width: 1px; text-align: left; margin-left:auto; margin-right:auto; color: black;" cellspacing="0">\n
<tr><td style=\'background-color: rgb(204, 204, 255); font-weight: bold;\'>Name</td><td style=\'background-color: white;\' tal:content="python:path.split(\'/\')[-1]">filename</td></tr>\n
<tr><td style=\'background-color: rgb(204, 204, 255); font-weight: bold;\'>Size</td><td style=\'background-color: white;\' tal:content="python:\'%.2f kb\'%(infos_dict[\'size\']/1024.0)">filesize</td></tr>\n
<tr><td style=\'background-color: rgb(204, 204, 255); font-weight: bold;\'>Last Change Revision</td><td style=\'background-color: white;\' tal:content="python:infos_dict[\'created_rev\']">last revision</td></tr>\n
<tr><td style=\'background-color: rgb(204, 204, 255); font-weight: bold;\'>Last Change Author</td><td style=\'background-color: white;\' tal:content="python:infos_dict[\'last_author\']">last author</td></tr>\n
<tr><td style=\'background-color: rgb(204, 204, 255); font-weight: bold;\'>Last Change Date</td><td style=\'background-color: white;\' tal:content="python:infos_dict[\'time\']">last date</td></tr>\n
</table>\n
</div>\n
<span tal:condition="not:infos_dict">\n
No informations for this file since it\'s not yet committed to the repository !\n
</span>\n
<br/>\n
<div style="text-align: center"><button onclick="history.back()" value="back" name="back" type="button">Back</button>\n
</div>\n
</tal:block>\n
</tal:block>\n
</tal:block>
]]></unicode> </value>
</item>
<item>
<key> <string>content_type</string> </key>
<value> <string>text/html</string> </value>
</item>
<item>
<key> <string>expand</string> </key>
<value> <int>0</int> </value>
</item>
<item>
<key> <string>id</string> </key>
<value> <string>BusinessTemplate_viewSvnInfosFile</string> </value>
</item>
<item>
<key> <string>output_encoding</string> </key>
<value> <string>utf-8</string> </value>
</item>
<item>
<key> <string>title</string> </key>
<value> <unicode></unicode> </value>
</item>
</dictionary>
</pickle>
</record>
</ZopeData>
<?xml version="1.0"?>
<ZopeData>
<record id="1" aka="AAAAAAAAAAE=">
<pickle>
<global name="ERP5Form" module="Products.ERP5Form.Form"/>
</pickle>
<pickle>
<dictionary>
<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/>
</value>
</item>
</dictionary>
</state>
</object>
</value>
</item>
<item>
<key> <string>_objects</string> </key>
<value>
<tuple/>
</value>
</item>
<item>
<key> <string>action</string> </key>
<value> <string>BusinessTemplate_doSvnRemoveFiles</string> </value>
</item>
<item>
<key> <string>encoding</string> </key>
<value> <string>UTF-8</string> </value>
</item>
<item>
<key> <string>enctype</string> </key>
<value> <string></string> </value>
</item>
<item>
<key> <string>group_list</string> </key>
<value>
<list>
<string>bottom</string>
</list>
</value>
</item>
<item>
<key> <string>groups</string> </key>
<value>
<dictionary>
<item>
<key> <string>bottom</string> </key>
<value>
<list>
<string>listbox</string>
</list>
</value>
</item>
</dictionary>
</value>
</item>
<item>
<key> <string>id</string> </key>
<value> <string>BusinessTemplate_viewUnversioned</string> </value>
</item>
<item>
<key> <string>method</string> </key>
<value> <string>POST</string> </value>
</item>
<item>
<key> <string>name</string> </key>
<value> <string>BusinessTemplate_viewUnversioned</string> </value>
</item>
<item>
<key> <string>pt</string> </key>
<value> <string>form_dialog</string> </value>
</item>
<item>
<key> <string>row_length</string> </key>
<value> <int>4</int> </value>
</item>
<item>
<key> <string>stored_encoding</string> </key>
<value> <string>UTF-8</string> </value>
</item>
<item>
<key> <string>title</string> </key>
<value> <string>Delete</string> </value>
</item>
<item>
<key> <string>unicode_mode</string> </key>
<value> <int>0</int> </value>
</item>
<item>
<key> <string>update_action</string> </key>
<value> <string></string> </value>
</item>
</dictionary>
</pickle>
</record>
</ZopeData>
......@@ -14,7 +14,7 @@
</item>
<item>
<key> <string>id</string> </key>
<value> <string>erp5_svn</string> </value>
<value> <string>erp5_vcs</string> </value>
</item>
<item>
<key> <string>title</string> </key>
......
......@@ -51,13 +51,13 @@
<item>
<key> <string>_body</string> </key>
<value> <string>from ZTUtils import make_query\n
form_results = context.BusinessTemplate_viewSvnCreateWorkingCopy.validate_all(REQUEST)\n
form_results = context.BusinessTemplate_viewCreateWorkingCopy.validate_all(REQUEST)\n
working_copy = form_results[\'your_repository\']\n
context.getPortalObject().portal_subversion.createSubversionPath(working_copy, context)\n
context.getVcsTool(path=working_copy).createBusinessTemplateWorkingCopy()\n
\n
query_string = make_query(portal_status_message=\'Business Template Working Copy created\')\n
REQUEST.response.redirect(\'%s/BusinessTemplate_viewSvnStatus?%s\' % \n
(context.absolute_url(), query_string))\n
REQUEST.response.redirect(\'%s/BusinessTemplate_viewVcsStatus?%s\' % \n
(context.absolute_url_path(), query_string))\n
</string> </value>
</item>
<item>
......@@ -66,7 +66,7 @@ REQUEST.response.redirect(\'%s/BusinessTemplate_viewSvnStatus?%s\' % \n
</item>
<item>
<key> <string>id</string> </key>
<value> <string>BusinessTemplate_doSvnCreateWorkingCopy</string> </value>
<value> <string>BusinessTemplate_doCreateWorkingCopy</string> </value>
</item>
</dictionary>
</pickle>
......
......@@ -50,7 +50,7 @@
</item>
<item>
<key> <string>_body</string> </key>
<value> <string>context.getPortalObject()["portal_subversion"].cleanup(context)\n
<value> <string>context.getVcsTool().cleanup(context)\n
\n
context.REQUEST.set(\'portal_status_message\', \'Subversion locks removed successfully.\')\n
return context.BusinessTemplate_viewSvnStatus()\n
......
......@@ -257,7 +257,7 @@
<dictionary>
<item>
<key> <string>_text</string> </key>
<value> <string>python:context.getPortalObject().portal_preferences.getPreferredSubversionWorkingCopyList()</string> </value>
<value> <string>python: context.getVcsTool().getWorkingCopyList()</string> </value>
</item>
</dictionary>
</pickle>
......
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
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