I am working on Maximo Anywhere (7.5.2) - Work Execution app. I need to pass the view id in runtime to the "transitionTo" command.
Ex: In app.xml, I can see few values are mentioned as {0} or {1}. How it works ? can the same way, I can pass the view id to tranisitionTo={1}
{0} or {1} are array values you dynamically set using resolverFunction. Below ex would help you understand better.In app.xml i have below code
<view id="WorkExecution.FailureListLookupView" label="Select {0}" resolverClass="application.handlers.FailureCodeHandler" resolverFunction="resolveNextFailureType">
resolveNextFailureType : function(eventContext) {
var failureListSet = eventContext.application.getResource('failureListResource');
var type;
if (failureListSet.data[0].type){
type = failureListSet.data[0].type;
} else {
type = this._failureClassMessage();
}
return [type];
},
[type] is {0} in app.xml