From bff4fd3e9879e639bae274efddf3ffe118c1c473 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?J=C3=A9rome=20Perrin?= <jerome@nexedi.com> Date: Fri, 27 Jan 2006 10:50:17 +0000 Subject: [PATCH] (romain) modify Base_edit to call field_editor after saving the matrixbox. git-svn-id: https://svn.erp5.org/repos/public/erp5/trunk@5375 20353a03-c40f-0410-a6d1-a30d3c3de9de --- .../SkinTemplateItem/portal_skins/erp5_core/Base_edit.xml | 8 +++++++- 1 file changed, 7 insertions(+), 1 deletion(-) diff --git a/product/ERP5/bootstrap/erp5_core/SkinTemplateItem/portal_skins/erp5_core/Base_edit.xml b/product/ERP5/bootstrap/erp5_core/SkinTemplateItem/portal_skins/erp5_core/Base_edit.xml index 6424d95ccc..7f0d085c7e 100755 --- a/product/ERP5/bootstrap/erp5_core/SkinTemplateItem/portal_skins/erp5_core/Base_edit.xml +++ b/product/ERP5/bootstrap/erp5_core/SkinTemplateItem/portal_skins/erp5_core/Base_edit.xml @@ -91,6 +91,7 @@ try:\n form.validate_all_to_request(request)\n # Basic attributes\n kw = {}\n + encapsulated_editor_list = []\n # Parse attributes\n for f in form.get_fields():\n k = f.id\n @@ -98,7 +99,8 @@ try:\n if hasattr(v, \'edit\'):\n # This is an encapsulated editor\n # call it\n - v.edit(context)\n + encapsulated_editor_list.append(v)\n +# v.edit(context)\n pass\n elif v is not MARKER:\n if k[0:3] == \'my_\':\n @@ -245,6 +247,8 @@ try:\n \n # Maybe we should build a list of objects we need\n # Update basic attributes\n + for encapsulated_editor in encapsulated_editor_list:\n + encapsulated_editor.edit(context)\n context.edit(REQUEST=request,**kw)\n \n except FormValidationError, validation_errors:\n @@ -343,6 +347,7 @@ request[ \'RESPONSE\' ].redirect( redirect_url )\n <string>getattr</string> <string>form</string> <string>kw</string> + <string>encapsulated_editor_list</string> <string>_getiter_</string> <string>f</string> <string>k</string> @@ -383,6 +388,7 @@ request[ \'RESPONSE\' ].redirect( redirect_url )\n <string>url</string> <string>o</string> <string>planning_box_field</string> + <string>encapsulated_editor</string> <string>validation_errors</string> <string>field_errors</string> <string>field_id</string> -- 2.30.9