Policy Workflow Step 21


Was this helpful?
Was this helpful?
// Block with the Approve/Reject buttons, embedded into the grid
{
"tag": "approve_documents_btn",
"blockType": "InterfaceActionBlock",
"permissions": [
"OWNER"
],
"type": "selector",
// For the selector type:
"uiMetaData": {
//"field" - field which is linked to the selector.
"field": "status",
//"options" - list of the possible options.
"options": [
//Button:
{
//Button text.
"name": "Approve",
//Value which will be stored in the "field".
//In this example document.status = "APPROVED"
"value": "APPROVED",
//Button style.
"uiClass": "btn-approve",
//Specify which block to pass control to.
//If the "Approve" button was clicked, the control would be passed to the update_approve_document_status block.
"bindBlock": "update_approve_document_status"
},
{
"name": "Reject",
"value": "REJECTED",
"uiClass": "btn-reject",
//If the "Reject" button was clicked pass control to the installer_rejected block.
"bindBlock": "installer_rejected"
}
]
}
}
]
}
]
},