Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
Popup windows(text) with workflow
(12-06-2022, 12:22 PM)Joana Wrote: I would like to create a workflow that opens a popup window with text and two options.
For example: This sales quote is invoiced.
Make invoice: YES / NO


1. Create a Business Action, type: DETAILVIEWHTML which allows us to execute any script that we want.

Link URL:
function doWeInvoice() {
   if (confirm('This Sales Quote is invoiced')) {
       runBAWorkflow(workflowid, $RECORD$);

This script contains the function which is used to display the modal dialog with an optional message and two buttons.
In the runBAWorkflow function, as a first parameter, you have to put the id of the workflow which will create the Invoice. The workflow should be set to 'System. Mass Actions' and the workflow task type should be 'Convert Inventory Module Records', where you select the module for which you will create records(in this case 'Invoice').

2. Then to trigger this popup, you have to create another Business Action, type DETAILVIEWBUTTON or DETAILVIEWBASIC

Link URL:javascript:doWeInvoice()

3. In this Business Action, you can put a Business Rule to define if you want to show this button or not.

For example
Create a Business Map, type : Condition Expression
Content: <map><expression>if invoiced == '1' then 1 else 0 end</expression></map>

So, in this case when the status of the sales order is ‘Invoiced’, the button will show and you can call the popup otherwise it will be hidden.

Hope it helps! Let us know Smile

Messages In This Thread
Popup windows(text) with workflow - Joana - 12-06-2022, 12:22 PM
RE: Popup windows(text) with workflow - xh.shazivari - 12-14-2022, 05:35 PM

Forum Jump:

Users browsing this thread: 1 Guest(s)