Actions can be used in the following scenarios:
Table.operation.actions
Form.operation.actions
Actions are abstractions for some common behaviors, and the following Actions are built-in for processing logic:
Common.openModal
Common.historyPush
Common.historyBack
Table.save
Table.delete
Form.save
Form.delete
Service.*
Studio.*
title: Action name
icon: Action icon
action: the specified Action
style?: style ('danger' or 'success', optional)
disabled?: Disable ({bind:string;value: string | Array<string>}
, not required)
confirm?: Second confirmation pop-up window (not required)
pet.form.json
{"name": "::Pet Admin","action": {"bind": { "model": "pet", "option": { "withs": { "doctor": {} } } }},"layout": {"primary": "id","operation": {"preset": { "save": { "back": true }, "back": {} },"actions": [{"title": "Cure {{name}}","icon": "icon-check","action": {"Form.save": { "id": "{{id}}", "status": "cured" }},"style": "success","confirm": {"title": "Prompt","desc": "Confirm to change {{name}} to healing state?"}}]}}}
Open a popup.
width: the width of the popup window (px)
Form?: The content is specified as Form ({type: 'view' | 'edit';model:string}
, not required)
Page?: The content is specified as Page ({type: 'chart' | 'edit';model:string}
, not required)
Make routing jumps.
pathname: jump path
search?: routing query field (optional)
Return to the previous page.
Save Table data items, the parameter is the key-value interface, and must contain the primary key.
Delete the Table data item, the parameter is an empty object.
Save Form data, the parameter is the key-value interface, and must contain the primary key.
Delete Form data.
The following two attributes are mutually exclusive attributes, you can choose one of them.
back?: Whether to return to the previous page after performing the above delete action (not required)
pathname?: The path to jump to after performing the above delete action (not required)
Call the specified application cloud function.
The * after Service. is the cloud function file name
method: cloud function
args: cloud function parameters (Array<any>
, not required)
Call the specified Studio cloud function.
The * after Studio. is the file name of the Studio cloud function
method: cloud function
args: cloud function parameters (Array<any>
, not required)
Actions can be used in the following scenarios:
Table.operation.actions
Form.operation.actions
Actions are abstractions for some common behaviors, and the following Actions are built-in for processing logic:
Common.openModal
Common.historyPush
Common.historyBack
Table.save
Table.delete
Form.save
Form.delete
Service.*
Studio.*
title: Action name
icon: Action icon
action: the specified Action
style?: style ('danger' or 'success', optional)
disabled?: Disable ({bind:string;value: string | Array<string>}
, not required)
confirm?: Second confirmation pop-up window (not required)
pet.form.json
{"name": "::Pet Admin","action": {"bind": { "model": "pet", "option": { "withs": { "doctor": {} } } }},"layout": {"primary": "id","operation": {"preset": { "save": { "back": true }, "back": {} },"actions": [{"title": "Cure {{name}}","icon": "icon-check","action": {"Form.save": { "id": "{{id}}", "status": "cured" }},"style": "success","confirm": {"title": "Prompt","desc": "Confirm to change {{name}} to healing state?"}}]}}}
Open a popup.
width: the width of the popup window (px)
Form?: The content is specified as Form ({type: 'view' | 'edit';model:string}
, not required)
Page?: The content is specified as Page ({type: 'chart' | 'edit';model:string}
, not required)
Make routing jumps.
pathname: jump path
search?: routing query field (optional)
Return to the previous page.
Save Table data items, the parameter is the key-value interface, and must contain the primary key.
Delete the Table data item, the parameter is an empty object.
Save Form data, the parameter is the key-value interface, and must contain the primary key.
Delete Form data.
The following two attributes are mutually exclusive attributes, you can choose one of them.
back?: Whether to return to the previous page after performing the above delete action (not required)
pathname?: The path to jump to after performing the above delete action (not required)
Call the specified application cloud function.
The * after Service. is the cloud function file name
method: cloud function
args: cloud function parameters (Array<any>
, not required)
Call the specified Studio cloud function.
The * after Studio. is the file name of the Studio cloud function
method: cloud function
args: cloud function parameters (Array<any>
, not required)