Commit 498238bc authored by Christophe Dumez's avatar Christophe Dumez

2006-05-23 chris

* do not extract business template anymore when going back from diff

git-svn-id: https://svn.erp5.org/repos/public/erp5/trunk@7423 20353a03-c40f-0410-a6d1-a30d3c3de9de
parent e34d3e71
......@@ -73,13 +73,13 @@
return \'\'\'<script>\n
\n
function doCommit(form){\n
submitAction(form,\'%s/BusinessTemplate_doSvnCommit\');\n
submitAction(form,\'%(absURL)s/BusinessTemplate_doSvnCommit\');\n
}\n
\n
function goBack(){\n
open(\'%s/BusinessTemplate_viewSvnStatus\', \'_self\');\n
open(\'%(absURL)s/BusinessTemplate_viewSvnStatus?do_extract=False\', \'_self\');\n
} \n
</script>\'\'\'% (context.absolute_url(), context.absolute_url())\n
</script>\'\'\'% {\'absURL\' : context.absolute_url(), }\n
]]></string> </value>
......
......@@ -70,6 +70,11 @@
<key> <string>_body</string> </key>
<value> <string encoding="cdata"><![CDATA[
if \'do_extract\' not in context.REQUEST.keys():\n
do_extract = \'True\'\n
else:\n
do_extract = context.REQUEST[\'do_extract\']\n
\n
if "files" in context.REQUEST.keys():\n
files = context.REQUEST["files"]\n
else:\n
......@@ -114,7 +119,7 @@ print \'\'\'\n
tree.enableCheckBoxes(true)\n
tree.enableThreeStateCheckboxes(true);\n
tree.enableDragAndDrop(false)\n
tree.loadXML(\'tree.xml?bt_id=%s\', hideObject)\n
tree.loadXML(\'tree.xml?bt_id=%(btId)s&do_extract=%(extract)s\', hideObject)\n
tree.setOnClickHandler(showMenu)\n
}\n
\n
......@@ -132,10 +137,10 @@ print \'\'\'\n
showObject();\n
is_expanded = false;\n
if(!is_showing_unmodified){\n
tree.loadXML(\'tree.xml?bt_id=%s&show_unmodified=True&do_extract=False\', hideObject);\n
tree.loadXML(\'tree.xml?bt_id=%(btId)s&show_unmodified=True&do_extract=False\', hideObject);\n
is_showing_unmodified = true;\n
}else{\n
tree.loadXML(\'tree.xml?bt_id=%s&do_extract=False\', hideObject);\n
tree.loadXML(\'tree.xml?bt_id=%(btId)s&do_extract=False\', hideObject);\n
is_showing_unmodified = false;\n
}\n
tree.refreshItem(0);\n
......@@ -204,7 +209,7 @@ print \'\'\'\n
if (nbRemoved==0 && nbAdded==0 && nbModified==0) {\n
alert(\'Nothing to commit !\');\n
} else {\n
submitAction(form,\'%s/BusinessTemplate_doSvnCommit\');\n
submitAction(form,\'%(absURL)s/BusinessTemplate_doSvnCommit\');\n
}\n
}\n
\n
......@@ -258,7 +263,7 @@ print \'\'\'\n
alert("Nothing to revert !");\n
} else {\n
if(confirm(\'Are you sure you want to revert changes?\')){\n
submitAction(form,\'%s/BusinessTemplate_doSvnRevert\');\n
submitAction(form,\'%(absURL)s/BusinessTemplate_doSvnRevert\');\n
}\n
}\n
}\n
......@@ -311,7 +316,7 @@ print \'\'\'\n
if (nbRemoved==0 && nbAdded==0 && nbModified==0) {\n
alert(\'Nothing to diff !\');\n
} else {\n
submitAction(form,\'%s/BusinessTemplate_viewSvnDiff\');\n
submitAction(form,\'%(absURL)s/BusinessTemplate_viewSvnDiff\');\n
}\n
}\n
\n
......@@ -363,30 +368,30 @@ print \'\'\'\n
document.onmousemove = getMouse;\n
\n
function update(){\n
open(\'%s/BusinessTemplate_doSvnUpdate\', \'_self\');\n
open(\'%(absURL)s/BusinessTemplate_doSvnUpdate\', \'_self\');\n
}\n
\n
function infos(){\n
open(\'%s/BusinessTemplate_doSvnInfo\', \'_self\');\n
open(\'%(absURL)s/BusinessTemplate_doSvnInfo\', \'_self\');\n
}\n
\n
function cleanup(){\n
open(\'%s/BusinessTemplate_doSvnCleanup\', \'_self\');\n
open(\'%(absURL)s/BusinessTemplate_doSvnCleanup\', \'_self\');\n
}\n
\n
function log(){\n
//hide popup\n
document.getElementById(\'menudiv\').style.display = "none";\n
open(\'%s/BusinessTemplate_doSvnLog?added=\'+tree.getSelectedItemId(), \'_self\');\n
open(\'%(absURL)s/BusinessTemplate_doSvnLog?added=\'+tree.getSelectedItemId(), \'_self\');\n
}\n
\n
function ls(){\n
//hide popup\n
document.getElementById(\'menudiv\').style.display = "none";\n
open(\'%s/BusinessTemplate_doSvnLs?added=\'+tree.getSelectedItemId(), \'_self\');\n
open(\'%(absURL)s/BusinessTemplate_doSvnLs?added=\'+tree.getSelectedItemId(), \'_self\');\n
}\n
</script>\n
\'\'\'% (context.getId(), context.getId(), context.getId(), context.absolute_url(), context.absolute_url(), context.absolute_url(), context.absolute_url(), context.absolute_url(), context.absolute_url(), context.absolute_url(), context.absolute_url())\n
\'\'\'% {\'btId\' : context.getId(), \'absURL\' : context.absolute_url(), \'extract\' : do_extract}\n
\n
return printed\n
......@@ -435,6 +440,7 @@ return printed\n
<string>_print</string>
<string>_getattr_</string>
<string>context</string>
<string>do_extract</string>
<string>_getitem_</string>
<string>files</string>
<string>None</string>
......
......@@ -100,9 +100,9 @@ if not changelog :\n
\n
try:\n
if commit_non_recurs != \'none\' and commit_non_recurs != \'\':\n
context.getPortalObject()["portal_subversion"].checkin(path=commit_non_recurs, bt=context, recurse=False, log_message=changelog)\n
context.getPortalObject()["portal_subversion"].checkin(path=commit_non_recurs, business_template=context, recurse=False, log_message=changelog)\n
if commit_recurs != \'none\' and commit_recurs != \'\':\n
context.getPortalObject()["portal_subversion"].checkin(path=commit_recurs, bt=context, recurse=True, log_message=changelog)\n
context.getPortalObject()["portal_subversion"].checkin(path=commit_recurs, business_template=context, recurse=True, log_message=changelog)\n
except SubversionSSLTrustError, error:\n
context.REQUEST.set(\'portal_status_message\', \'SSL Certificate was not recognized\')\n
return context.asContext(added=added, modified=modified, removed=removed, trust_dict = error.getTrustDict(), caller=\'commit\', changelog=changelog).BusinessTemplate_viewSvnSSLTrust()\n
......
......@@ -87,7 +87,7 @@ if not added_files and not other_files:\n
context.REQUEST.set(\'portal_status_message\', \'Nothing to revert.\')\n
return context.BusinessTemplate_viewSvnStatus()\n
\n
context.getPortalObject()["portal_subversion"].revertZODB(bt=context, added_files=added_files, other_files=other_files)\n
context.getPortalObject()["portal_subversion"].revertZODB(business_template=context, added_files=added_files, other_files=other_files)\n
\n
context.REQUEST.set(\'portal_status_message\', \'Changes reverted successfully.\')\n
return context.BusinessTemplate_viewSvnStatus()\n
......
......@@ -84,7 +84,7 @@ if not repos_url :\n
return context.BusinessTemplate_viewSvnNewRepos()\n
\n
try:\n
context.getPortalObject()["portal_subversion"].switch(bt=context, url=repos_url)\n
context.getPortalObject()["portal_subversion"].switch(business_template=context, url=repos_url)\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=\'switch\',repos_url=repos_url).BusinessTemplate_viewSvnSSLTrust()\n
......
......@@ -63,7 +63,7 @@
here/BusinessTemplate_doCreateJavaScriptDiff">JavaScript here</tal:js>\n
<tal:py replace="structure \n
here/BusinessTemplate_doSvnDiff">diff here</tal:py>\n
<center><button onclick="history.back()" value="Back" name="Back" type="button">Back</button>\n
<center><button onclick="goBack()" value="Back" name="Back" type="button">Back</button>\n
<button onclick="doCommit(this.form)" value="commit" name="commit Changes" type="button">Commit Changes</button></center>\n
</tal:block>\n
</tal:block>\n
......
......@@ -70,7 +70,7 @@
<key> <string>_body</string> </key>
<value> <string encoding="cdata"><![CDATA[
if do_extract==True:\n
if do_extract == \'True\':\n
context.getPortalObject().portal_subversion.extractBT(context)\n
\n
context.REQUEST.RESPONSE.setHeader(\'Content-Type\', \'text/xml;; charset=utf-8\')\n
......@@ -97,7 +97,7 @@ return context.getPortalObject().portal_subversion.treeToXML(root, context).stri
</item>
<item>
<key> <string>_params</string> </key>
<value> <string>show_unmodified=False, do_extract=True</string> </value>
<value> <string>show_unmodified=False, do_extract=\'True\'</string> </value>
</item>
<item>
<key> <string>errors</string> </key>
......@@ -125,7 +125,6 @@ return context.getPortalObject().portal_subversion.treeToXML(root, context).stri
<tuple>
<string>show_unmodified</string>
<string>do_extract</string>
<string>True</string>
<string>_getattr_</string>
<string>context</string>
<string>root</string>
......@@ -142,7 +141,7 @@ return context.getPortalObject().portal_subversion.treeToXML(root, context).stri
<value>
<tuple>
<int>0</int>
<int>1</int>
<string>True</string>
</tuple>
</value>
</item>
......
2006-05-23 chris
* do not extract business template anymore when going back from diff
2006-05-22 chris
* display reminder when committing
......
0.7.5
\ No newline at end of file
0.7.6
\ 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