Commit 78270d0f authored by Ayush Tiwari's avatar Ayush Tiwari

erp5_catalog: Use the _setArgument from SQL Method class to update arguments_src property

parent 8adda966
......@@ -1767,7 +1767,6 @@ class ERP5Site(FolderMixIn, CMFSite, CacheCookieMixin):
# Update properties and attributes of erp5_sql_catalog with the info
# data of same attributes of sql_method
erp5_sql_method.title = sql_method.title
erp5_sql_method.setArgument(sql_method.arguments_src)
erp5_sql_method.setConnectionId(sql_method.connection_id)
erp5_sql_method.setSrc(sql_method.src)
......@@ -1781,6 +1780,10 @@ class ERP5Site(FolderMixIn, CMFSite, CacheCookieMixin):
erp5_sql_method.setClassFile(sql_method.class_file_)
erp5_sql_method.setClassName(sql_method.class_name_)
# Update argument at last cause this will update other attributes by
# calling manage_edit for SQLMethod in ZRDB.DA
erp5_sql_method._setArgument(sql_method.arguments_src)
# Delete sql_method object from erp5_catalog and update the Id of
# erp5_catalog_object with the Id of sql_method
#erp5_catalog._delOb(id=method_id)
......
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