1 Register User-define event
1 Register intercept event, specify action pre-execution trigger, and block/release follow-up actions
Support multiple registrations, execute in order of registration; support asynchronous ajax, avoid request jam Scenario 1: perform custom logic and block/release before submi, save, returnn, forward, withdraw, etc Scenario 2: execute custom logic and block/allow follow-up action before add/detele detail row
Type of action | Note | Minimum Version |
---|---|---|
WfForm.OPER_SAVE | Save | |
WfForm.OPER_SUBMIT | Submission/approval/submission feedback/no feedback | |
WfForm.OPER_SUBMITCONFIRM | Submit to the confirmation page, if it is the confirmation interface, the click confirmation triggers the SUBMIT | |
WfForm.OPER_REJECT | Return | |
WfForm.OPER_REMARK | Note submission | |
WfForm.OPER_INTERVENE | Intervention | |
WfForm.OPER_FORWARD | Forwarding | |
WfForm.OPER_TAKEBACK | Compulsory recovery | |
WfForm.OPER_DELETE | Delete | |
WfForm.OPER_ADDROW | Add a line of detail and spell the serial number of the list | |
WfForm.OPER_DELROW | Delete the line and spell the list number | |
WfForm.OPER_PRINTPREVIEW | Print Preview | KB900190501 |
WfForm.OPER_EDITDETAILROW | Mobile - Edit Details | KB900191101 |
WfForm.OPER_BEFOREVERIFY | Check pre-fill trigger event | KB900191201 |
Interface name and parameter description
registerCheckEvent:function (type, fun)
Parameters | Parameter type | Required | Remarks |
---|---|---|---|
type | String | Yes | Action type (see table above for details), separated by commas |
fun | Function | Yes | The custom function is entered into the body of the success function that performs callback, custom logic completion or asynchronous ajax, and the release needs to be called callback, does not call to block subsequent operations |
Example
2 Register hook event, trigger after specific action completed
Support multiple call registration and execute in order of registration
Type | Note | Minimum Version |
---|---|---|
WfForm.ACTION_ADDROW | Add a line of detail and spell the serial number of the list | KB900190407 |
WfForm.ACTION_DELROW | Delete the line and spell the list number | KB900190407 |
WfForm.ACTION_EDITDETAILROW | Mobile-edit line, list number | KB900190501 |
WfForm.ACTION_SWITCHDETAILPAGING | Switching detail pages | KB900191201 |
WfForm.ACTION_SWITCHTABLAYOUT | Switch template layout tab | KB900191201 |
Interface name and parameter description
registerAction:function(actionname, fn)
Parameters | type | Required | Remarks |
---|---|---|---|
actionname | String | Yes | Action type, see table above |
fn | Function | Yes | Trigger event |
Example |
Last updated