diff --git a/web_widget_sub_view/README.rst b/web_widget_sub_view/README.rst index 23efebb0189..23c350d2de7 100644 --- a/web_widget_sub_view/README.rst +++ b/web_widget_sub_view/README.rst @@ -64,8 +64,18 @@ Also, you can use: - view-type: To force an specific view kind. By default it uses list in desktop and kanban in mobile. -- create-action: To force an specific action for creation (it is a - xmlid) +- create-action: To force an specific action for creation. Depending on + create-action-type, it is either the name of a Python method on the + model, or the id/xmlid of an existing action. +- create-action-type: How create-action should be interpreted: + + - object (default): create-action is a method name on the model, + called server-side. Whatever action it returns (e.g. opening a + wizard) is executed. + - action: create-action is an existing action's id or xmlid (e.g. + ``%(module.action_xmlid)s``), which is loaded and executed directly, + without calling any method. + - open-action: The function to launch to open the record. By default, it uses get_formview_action. - filter: set 0 to hide the filters diff --git a/web_widget_sub_view/readme/USAGE.md b/web_widget_sub_view/readme/USAGE.md index 49b6cdc0f42..57fb0782d75 100644 --- a/web_widget_sub_view/readme/USAGE.md +++ b/web_widget_sub_view/readme/USAGE.md @@ -17,7 +17,13 @@ Context is recomended for setting default values and forcing specific views or d Also, you can use: - view-type: To force an specific view kind. By default it uses list in desktop and kanban in mobile. -- create-action: To force an specific action for creation (it is a xmlid) +- create-action: To force an specific action for creation. Depending on create-action-type, it is either + the name of a Python method on the model, or the id/xmlid of an existing action. +- create-action-type: How create-action should be interpreted: + - object (default): create-action is a method name on the model, called server-side. Whatever action + it returns (e.g. opening a wizard) is executed. + - action: create-action is an existing action's id or xmlid (e.g. `%(module.action_xmlid)s`), which is + loaded and executed directly, without calling any method. - open-action: The function to launch to open the record. By default, it uses get_formview_action. - filter: set 0 to hide the filters - group-by: set 0 to hide the group-by diff --git a/web_widget_sub_view/static/description/index.html b/web_widget_sub_view/static/description/index.html index 21d1cbc3081..ff3fddffe4d 100644 --- a/web_widget_sub_view/static/description/index.html +++ b/web_widget_sub_view/static/description/index.html @@ -3,7 +3,7 @@ -Web Widget Sub View +README.rst