Action

App Price

Posted by @nahumck, Last update over 6 years ago

Opens the “App Price” Workflow and returns the result.

Workflow:
https://workflow.is/workflows/cd97fa45ce17486bbe5774321e4d8216

Steps

  • script

    // [[selection]] tag workaround
    
    var sel = editor.getSelectedText();
    draft.setTemplateTag("selection", sel)
  • runWorkflow

    workflowName
    App Price
    waitForResponse
    true
  • script

    // check for last result from Workflow callback, insert if available
    var response = context.callbackResponses[0];
    if (response) {
      var result = response["result"];
      if (result) {
        var selRange = editor.getSelectedRange();
        editor.setSelectedText(result);
        editor.setSelectedRange([selRange[0] + result.length, 0]);
      }
    }

Options

  • After Success Default
    Notification Info
    Log Level Error
Items available in the Drafts Directory are uploaded by community members. Use appropriate caution reviewing downloaded items before use.