Open window in Same tab for the Service Operations workspace

smacleod
Tera Guru

Like many groups we have had to rebuild our Edit buttons for the workspace views. I have managed to get the declarative action to work properly in the Project workspace, however I am unable to get the open(url,'_self') script to work in the Service Operations Workspace.

 

I have tried:

open(url,'_self')

top.window.open(url,'_self')

g_navigation.open(url,'_self')

 

How do I get this to work in the Service Operations Workspace?

5 REPLIES 5

It is difficult to offer guidance when you don't show what you have tried so far.

 

The DA is visible because they are global to the table and component and you need to restrict them to a view or experience when that is not wanted.  

 

 

If your add button does nothing when you click it then make sure your action name matches the key in the payload definition. Also make sure you are using the correct configuration in your event mapping. 

Screenshot 2026-04-17 115511.png

Screenshot 2026-04-17 115556.png

The component in PWS is labeled list - related. In my opinion you can check these easiest from the composition field on your sys_ux_macroponent record of the page your related list is on. To surface the correct target event you can set controller as Form or UI Controller Record Page

Screenshot 2026-04-17 120017.png

This should get the modal working, if it does not open the mra page correctly then you can check the payloads match the definition.

[
    {
        "name": "route",
        "fieldType": "string",
        "label": "Viewport modal - route",
        "interfaceApiName": "",
        "typeMetadata": null,
        "mandatory": false,
        "readOnly": false
    },
    {
        "name": "fields",
        "fieldType": "json",
        "label": "Viewport modal - fields",
        "interfaceApiName": "",
        "typeMetadata": {
            "schema": {
                "type": "object"
            }
              
        },
        "mandatory": false,
        "readOnly": false
    },
    {
        "name": "params",
        "fieldType": "json",
        "label": "Viewport modal - params (Optional)",
        "interfaceApiName": "",
         "typeMetadata": {
            "schema": {
                "type": "object"
            }
              
        },
        "mandatory": false,
        "readOnly": false
    },
    {
        "name": "size",
        "fieldType": "choice",
        "label": "Modal size",
        "typeMetadata": {
            "choices": [
                {
                    "label": "Small",
                    "value": "sm"
                },
                {
                    "label": "Medium",
                    "value": "md"
                },
                {
                    "label": "Large",
                    "value": "lg"
                },
                {
                    "label": "Fullscreen",
                    "value": "fullscreen"
                }
            ]
        },
        "valueType": "string",
        "mandatory": false,
        "readOnly": false
    },
    {
        "name": "ariaLabel",
        "fieldType": "string",
        "label": "Arial label",
        "interfaceApiName": "",
        "typeMetadata": null,
        "mandatory": false,
        "readOnly": false
    }
]