Commit 2001a488 authored by Fabien Morin's avatar Fabien Morin

forget to commit this file in r29325, sorry

git-svn-id: https://svn.erp5.org/repos/public/erp5/trunk@29327 20353a03-c40f-0410-a6d1-a30d3c3de9de
parent ac8c1150
...@@ -55,6 +55,7 @@ ...@@ -55,6 +55,7 @@
<key> <string>_body</string> </key> <key> <string>_body</string> </key>
<value> <string>from Products.ERP5Type.Document import newTempBase\n <value> <string>from Products.ERP5Type.Document import newTempBase\n
from Products.ERP5Type.Cache import CachingMethod\n from Products.ERP5Type.Cache import CachingMethod\n
Base_translateString = context.Base_translateString\n
\n \n
def getModifiedObjectList(context):\n def getModifiedObjectList(context):\n
result = context.preinstall()\n result = context.preinstall()\n
...@@ -79,23 +80,29 @@ no_backup_dict = {}\n ...@@ -79,23 +80,29 @@ no_backup_dict = {}\n
for k in no_backup_list:\n for k in no_backup_list:\n
no_backup_dict[k] = 1\n no_backup_dict[k] = 1\n
\n \n
install_title = Base_translateString(\'Install\')\n
upgrade_title = Base_translateString(\'Upgrade\')\n
backup_title = Base_translateString(\'Backup And Upgrade\')\n
remove_title = Base_translateString(\'Remove\')\n
save_and_remove_title = Base_translateString(\'Backup And Remove\')\n
\n
i = 0\n i = 0\n
object_list = []\n object_list = []\n
for object_id in keys:\n for object_id in keys:\n
object_state, object_class = modified_object_list[object_id]\n object_state, object_class = modified_object_list[object_id]\n
line = newTempBase(context, \'tmp_install_%s\' %(str(i)))\n line = newTempBase(context, \'tmp_install_%s\' %(str(i)))\n
if object_state == \'New\':\n if object_state == \'New\':\n
choice_item_list=[[\'Install\', \'install\']]\n choice_item_list=[[install_title, \'install\']]\n
elif object_state == \'Modified\':\n elif object_state == \'Modified\':\n
if object_class in no_backup_dict:\n if object_class in no_backup_dict:\n
choice_item_list=[[\'Upgrade\', \'install\']]\n choice_item_list=[[upgrade_title, \'install\']]\n
else:\n else:\n
choice_item_list=[[\'Backup And Upgrade\', \'backup\']]\n choice_item_list=[[backup_title, \'backup\']]\n
elif object_state == \'Removed\':\n elif object_state == \'Removed\':\n
if object_class in no_backup_dict:\n if object_class in no_backup_dict:\n
choice_item_list=[[\'Remove\', \'remove\']]\n choice_item_list=[[remove_title, \'remove\']]\n
else:\n else:\n
choice_item_list=[[\'Backup And Remove\', \'save_and_remove\']]\n choice_item_list=[[save_and_remove_title, \'save_and_remove\']]\n
\n \n
line.edit(object_id=object_id,\n line.edit(object_id=object_id,\n
object_state=object_state,\n object_state=object_state,\n
...@@ -148,16 +155,22 @@ return object_list\n ...@@ -148,16 +155,22 @@ return object_list\n
<string>newTempBase</string> <string>newTempBase</string>
<string>Products.ERP5Type.Cache</string> <string>Products.ERP5Type.Cache</string>
<string>CachingMethod</string> <string>CachingMethod</string>
<string>getModifiedObjectList</string> <string>_getattr_</string>
<string>context</string> <string>context</string>
<string>Base_translateString</string>
<string>getModifiedObjectList</string>
<string>modified_object_list</string> <string>modified_object_list</string>
<string>_getattr_</string>
<string>keys</string> <string>keys</string>
<string>no_backup_list</string> <string>no_backup_list</string>
<string>no_backup_dict</string> <string>no_backup_dict</string>
<string>_getiter_</string> <string>_getiter_</string>
<string>k</string> <string>k</string>
<string>_write_</string> <string>_write_</string>
<string>install_title</string>
<string>upgrade_title</string>
<string>backup_title</string>
<string>remove_title</string>
<string>save_and_remove_title</string>
<string>i</string> <string>i</string>
<string>object_list</string> <string>object_list</string>
<string>object_id</string> <string>object_id</string>
......
1316 1317
\ No newline at end of file \ 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