I'm trying to execute an automation script from the different nodes of a service definition component in Dashboard but for some reason, the component is not recognizing the parameters (Booking ID and Node ID) of my script:
The component is linked to a booking and I can see the nodes and currently assigned resources. By clicking on each node's button, a popup message appears to collect the requested parameters. What I could be missing on this configuration?
Your action configuration seems correct. Be aware that the Booking ID needs to be script parameter ID 1 and Node ID needs to be script parameter 2.
It can be that your Booking ID and Node ID is eg parameter 3 and 4 depending on what happened to the script.
For example, if you would have defined 4 parameters at one point:
- Param 1 (ID 1)
- Param 2 (ID 2)
- Booking ID (ID 3)
- Node ID (ID 4)
And remove the first 2 params, Booking ID and Node ID would still have ID 3 and 4 assigned to them and the action config would not be able to find the right parameter.
To verify if your IDs are correct, you can check the inspect the GetAutomationScript web request in your brower:
If you notice that your parameters are not ID 1 and 2, I would suggest to remove those parameters from your script and add them again to reassign a new ID (starting from 1).
If the parameters are indeed ID 1 and 2, then this would be a software issue.
Good to know, the linking does not happen based on name, so you can name your parameters whatever you want.
In case of a persisting doubt, this is how I solved the problem (based on Gilles' answer above):
Thanks Gilles. The problem was indeed the assigned parameter ids, so a simple change in the ids at the automation XML file did the trick.