Commit 7859c6ce authored by Christophe Dumez's avatar Christophe Dumez

- added show unmodified files feature

git-svn-id: https://svn.erp5.org/repos/public/erp5/trunk@7245 20353a03-c40f-0410-a6d1-a30d3c3de9de
parent f857a88e
...@@ -78,6 +78,7 @@ print \'\'\'\n ...@@ -78,6 +78,7 @@ print \'\'\'\n
var tree = null;\n var tree = null;\n
var business_template;\n var business_template;\n
var is_expanded=false;\n var is_expanded=false;\n
var is_showing_unmodified=false;\n
var ie = document.all\n var ie = document.all\n
var ns6 = document.getElementById&&!document.all\n var ns6 = document.getElementById&&!document.all\n
var isMenu = false ;\n var isMenu = false ;\n
...@@ -124,6 +125,19 @@ print \'\'\'\n ...@@ -124,6 +125,19 @@ print \'\'\'\n
is_expanded=false;\n is_expanded=false;\n
}\n }\n
}\n }\n
\n
function showNormalFiles(){\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
is_showing_unmodified = true;\n
}else{\n
tree.loadXML(\'tree.xml?bt_id=%s&do_extract=False\', hideObject);\n
is_showing_unmodified = false;\n
}\n
tree.refreshItem(0);\n
}\n
\n \n
function commit(popup, form){\n function commit(popup, form){\n
nbModified=0;\n nbModified=0;\n
...@@ -371,7 +385,7 @@ print \'\'\'\n ...@@ -371,7 +385,7 @@ print \'\'\'\n
open(\'%s/BusinessTemplate_doSvnLs?file=\'+tree.getSelectedItemId(), \'_self\');\n open(\'%s/BusinessTemplate_doSvnLs?file=\'+tree.getSelectedItemId(), \'_self\');\n
}\n }\n
</script>\n </script>\n
\'\'\'% (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 \'\'\'% (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
\n \n
return printed\n return printed\n
......
...@@ -143,7 +143,8 @@ here/BusinessTemplate_doCreateJavaScriptStatus">javascript here</tal:js><br>\n ...@@ -143,7 +143,8 @@ here/BusinessTemplate_doCreateJavaScriptStatus">javascript here</tal:js><br>\n
<p><font color="green">Added files</font><br />\n <p><font color="green">Added files</font><br />\n
<font color="orange">Modified files</font><br />\n <font color="orange">Modified files</font><br />\n
<font color="red">Removed files</font><br />\n <font color="red">Removed files</font><br />\n
<font color="grey">conflicted files</font><br />\n <font color="grey">Conflicted files</font><br />\n
<font color=\'black\'>Unmodified files</font><br />\n
</p>\n </p>\n
</div>\n </div>\n
</div>\n </div>\n
...@@ -154,7 +155,9 @@ here/BusinessTemplate_doCreateJavaScriptStatus">javascript here</tal:js><br>\n ...@@ -154,7 +155,9 @@ here/BusinessTemplate_doCreateJavaScriptStatus">javascript here</tal:js><br>\n
winList[\'captionWindow\'].open();\n winList[\'captionWindow\'].open();\n
}\n }\n
</script>\n </script>\n
\n </center>\n
<input name="showUnmodified" value="showUnmodified" type="checkbox" onclick="showNormalFiles()"> <font color=\'black\'>Show unmodified files</font>\n
<center>\n
<script>\n <script>\n
// Menu Customization\n // Menu Customization\n
var MenuToolBar=new CreateToolBarMenu(\'#dae6e6\', \'#FFFFFF\', \'#B1BBBB\', \'#6699FF\', \'font-family:verdana;font-size:11px;color:black;font-weight:bold\', 16, 16)\n var MenuToolBar=new CreateToolBarMenu(\'#dae6e6\', \'#FFFFFF\', \'#B1BBBB\', \'#6699FF\', \'font-family:verdana;font-size:11px;color:black;font-weight:bold\', 16, 16)\n
...@@ -176,6 +179,15 @@ here/BusinessTemplate_doCreateJavaScriptStatus">javascript here</tal:js><br>\n ...@@ -176,6 +179,15 @@ here/BusinessTemplate_doCreateJavaScriptStatus">javascript here</tal:js><br>\n
} else if(ie4) {\n } else if(ie4) {\n
var splash = document.all.splashScreen;\n var splash = document.all.splashScreen;\n
}\n }\n
\n
function showObject() {\n
\t if (ns4) {\n
\t splash.visibility = "visible";\n
\t }\n
\t if (ie4 || upLevel) {\n
\t splash.style.visibility = "visible";\n
}\n
}\n
\n \n
function hideObject() {\n function hideObject() {\n
\t if (ns4) {\n \t if (ns4) {\n
......
...@@ -68,11 +68,12 @@ ...@@ -68,11 +68,12 @@
<key> <string>_body</string> </key> <key> <string>_body</string> </key>
<value> <string encoding="cdata"><![CDATA[ <value> <string encoding="cdata"><![CDATA[
context.getPortalObject().portal_subversion.extractBT(context)\n if do_extract==True:\n
context.getPortalObject().portal_subversion.extractBT(context)\n
\n \n
context.REQUEST.RESPONSE.setHeader(\'Content-Type\', \'text/xml;; charset=utf-8\')\n context.REQUEST.RESPONSE.setHeader(\'Content-Type\', \'text/xml;; charset=utf-8\')\n
\n \n
root = context.getPortalObject().portal_subversion.getModifiedTree(context)\n root = context.getPortalObject().portal_subversion.getModifiedTree(context, show_unmodified)\n
if not root:\n if not root:\n
return \'\'\'<?xml version=\'1.0\' encoding=\'iso-8859-1\'?>\n return \'\'\'<?xml version=\'1.0\' encoding=\'iso-8859-1\'?>\n
<tree id=\'0\'></tree>\'\'\'\n <tree id=\'0\'></tree>\'\'\'\n
...@@ -94,7 +95,7 @@ return context.getPortalObject().portal_subversion.treeToXML(root, context).stri ...@@ -94,7 +95,7 @@ return context.getPortalObject().portal_subversion.treeToXML(root, context).stri
</item> </item>
<item> <item>
<key> <string>_params</string> </key> <key> <string>_params</string> </key>
<value> <string></string> </value> <value> <string>show_unmodified=False, do_extract=True</string> </value>
</item> </item>
<item> <item>
<key> <string>errors</string> </key> <key> <string>errors</string> </key>
...@@ -114,12 +115,15 @@ return context.getPortalObject().portal_subversion.treeToXML(root, context).stri ...@@ -114,12 +115,15 @@ return context.getPortalObject().portal_subversion.treeToXML(root, context).stri
<dictionary> <dictionary>
<item> <item>
<key> <string>co_argcount</string> </key> <key> <string>co_argcount</string> </key>
<value> <int>0</int> </value> <value> <int>2</int> </value>
</item> </item>
<item> <item>
<key> <string>co_varnames</string> </key> <key> <string>co_varnames</string> </key>
<value> <value>
<tuple> <tuple>
<string>show_unmodified</string>
<string>do_extract</string>
<string>True</string>
<string>_getattr_</string> <string>_getattr_</string>
<string>context</string> <string>context</string>
<string>root</string> <string>root</string>
...@@ -134,7 +138,10 @@ return context.getPortalObject().portal_subversion.treeToXML(root, context).stri ...@@ -134,7 +138,10 @@ return context.getPortalObject().portal_subversion.treeToXML(root, context).stri
<item> <item>
<key> <string>func_defaults</string> </key> <key> <string>func_defaults</string> </key>
<value> <value>
<none/> <tuple>
<int>0</int>
<int>1</int>
</tuple>
</value> </value>
</item> </item>
<item> <item>
......
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