create a new Major Incident from SOW through tab (+) / UI Action

Fariya Muskhan
Tera Contributor

Hi,

I’m attempting to add a new workspace tab option that allows users to create a Major Incident by updating the Chrome Tab JSON property. However, I’m unable to set the Major Incident state to “Accepted” through the JSON configuration.

I also tried invoking the MIM Major Incident Template via the same JSON configuration, but that approach is not working either.

Could you please confirm whether this is possible through the Chrome Tab JSON object? If it isn’t supported, what is the recommended approach—such as using a UI Action—to create a Major Incident and automatically apply the required state/template?

Thanks in Advance!!

6 REPLIES 6

TharaS657398130
Giga Guru

This isn’t going to work through the Chrome Tab JSON — that configuration is only meant for navigation and opening pages, not for setting field values or triggering backend logic like setting the state to Accepted or applying a Major Incident template. That’s why both approaches you tried are failing.

The correct way to handle this is to use a UI Action (or Workspace Action). You can create a button like “Create Major Incident” which, when clicked, runs server-side logic to either update the current record or create a new one, set the state to Accepted, and apply the Major Incident template (via script or by calling the template API). This approach gives you full control and works reliably in Workspace.

So in short: Chrome Tab JSON can’t do this, and the recommended solution is to use a UI Action/Action with server-side script to handle the state change and template application properly.

lauri457
Tera Sage

You need to add a params property into routeInfo which has the key query and then an encoded query as a value which works exactly like a sysparm_query does in classic ui. 

 

        {
            "label": {
                "translatable": true,
                "message": "New major inc"
            },
            "routeInfo": {
                "route": "record",
                "fields": {
                    "table": "incident",
                    "sysId": "-1"
                },
                "params": {
                    "query": "major_incident_state=accepted"
                },
                "multiInstField": "sysId"
            },
            "condition": {
                "tableDescription": {
                    "table": "incident",
                    "canCreate": true
                },
                "roles": [
                    "sn_incident_write",
                    "itil"
                ]
            }
        },

 Not sure if there is a way to call templates like sysparm_template