Add button (Custom) not working in Configurable HR Workspace.

Srinath9
Tera Guru

Hi Everyone,

 

Having the below article as reference, I configured one button "Add" in HR Configurable Workspace.

 

Introduction to Declarative Actions - ServiceNow Community

 

The above article has all the steps to have a Related list action in Workspace, but I am configuring this Add button for one of the related lists "Approvers"(HR Case) which is where I need that button. The below screenshots are configurations that I have developed for the Add button. 

Srinath9_0-1709279378402.png


Srinath9_1-1709279418044.png

 

Srinath9_2-1709279520451.png

 

In the above image, there will be Target Payload Mapping field, below is the one which I used in the Target Payload Mapping field,

{
  "type": "MAP_CONTAINER",
  "container": {
    "route": {
      "type": "JSON_LITERAL",
      "value": "mra"
    },
    "size": {
      "type": "JSON_LITERAL",
      "value": "lg"
    },
    "fields": {
      "type": "MAP_CONTAINER",
      "container": {
        "label": {
          "type": "EVENT_PAYLOAD_BINDING",
          "binding": {
            "address": ["label"]
          }
        },
        "userGivenTable": {
          "type": "EVENT_PAYLOAD_BINDING",
          "binding": {
            "address": ["userGivenTable"]
          }
        },
        "table": {
          "type": "EVENT_PAYLOAD_BINDING",
          "binding": {
            "address": ["table"]
          }
        },
        "parentRecordSysId": {
          "type": "EVENT_PAYLOAD_BINDING",
          "binding": {
            "address": ["parentRecordSysId"]
          }
        },
        "parentFieldName": {
          "type": "EVENT_PAYLOAD_BINDING",
          "binding": {
            "address": ["parentFieldName"]
          }
        },
        "referencedFieldName": {
          "type": "EVENT_PAYLOAD_BINDING",
          "binding": {
            "address": ["referencedFieldName"]
          }
        },
        "extensionPoint": {
          "type": "EVENT_PAYLOAD_BINDING",
          "binding": {
            "address": ["extensionPoint"]
          }
        },
        "view": {
          "type": "EVENT_PAYLOAD_BINDING",
          "binding": {
            "address": ["view"]
          }
        },
        "columns": {
          "type": "EVENT_PAYLOAD_BINDING",
          "binding": {
            "address": ["columns"]
          }
        },
        "type": {
          "type": "EVENT_PAYLOAD_BINDING",
          "binding": {
            "address": ["type"]
          }
        },
        "hideSelectAll": {
          "type": "EVENT_PAYLOAD_BINDING",
          "binding": {
            "address": ["hideSelectAll"]
          }
        },
        "relatedListName": {
          "type": "EVENT_PAYLOAD_BINDING",
          "binding": {
            "address": ["relatedListName"]
          }
        }
      }
    },
    "params": {
      "type": "JSON_LITERAL",
      "value": {}
    }
  }
}

 

Srinath9_3-1709280038176.png

 

After all set & ready, the button's appearing but it's not doing anything. Can someone please point out where I'm wrong?

 

Any help is much appreciated!

 

Thanks,

Srinath

 

2 REPLIES 2

heathers_
Kilo Sage

I'm facing the same issue. Was this resolved?

Andrew Bettcher
Kilo Sage

Did you get this sorted? 

I've got my button and when I click the MRA appears but when I select records and click "Add", it doesn't add them.....

But surely, this is the MRA component that is native right? Surely, as long as I call it OK and it works for other buttons on the page, it should do what it's designed to do??