sartography / cr-connect

0 stars 0 forks source link

Workflow ID Script #589

Closed calexh-sar closed 2 years ago

calexh-sar commented 2 years ago

Logging automatically adds the Workflow # where the log event occurred: image.png

Once that data is downloaded, I need a script that would return the Workflow ID and Name based on the Workflow #. image.png

cullerton commented 2 years ago

@calexh-sar Follow-up question. We have the workflow id. You're looking for the workflow spec name and id, right?

calexh-sar commented 2 years ago

@cullerton, from one test of this script it appears it is not returning the Workflow Spec Display Name. Is it possible to return that as well? If so, would you please update the script.

  "test": {
    "category_id": 1,
    "id": "personnel",
    "category": {
      "admin": null,
      "id": 1,
      "display_order": 0,
      "display_name": "Core Information"
    },

image.png

cullerton commented 2 years ago

@calexh-sar Is this still an issue for you? I just tried on Testing and got a good result.

{'is_master_spec': False, 'description': 'Test', 'display_name': 'Mike Test', 'id': 'mike_test', 'display_order': 2, 'standalone': False, 'is_review': False, 'libraries': [], 'primary_process_id': 'Process_8207916', 'primary_file_name': 'get_spec_from_workflow_id.bpmn', 'library': False, 'category_id': 'admin_sandbox'}

calexh-sar commented 2 years ago

@cullerton looks like things are working now: "test": { "is_master_spec": false, "description": "Upload the study Protocol, Application & Coversheet", "display_name": "Protocol, Application & Cover Sheet", "id": "protocol_application_and_coversheet", "display_order": 0, "standalone": false, "is_review": false, "libraries": [ "approvals", "email_variables", "emails", "covid_check", "associates", "orgs", "metrics", "documents", "shared", "text" ], "primary_process_id": "Process_Protocol_Application_Coversheet", "primary_file_name": "protocol.bpmn", "library": false, "category_id": "documents_for_irb" }