Maximo Anywhere notes to rememmber
MaximoAnywhere App development points that some people might find to be useful:
- Use an xml editor like in eclipse with xsd validator to avoid errors
- The App XML XSD is very useful in finding out possible attributes/values and elements while designing the application
- Different types of events in Application elements include click|changestate|datachange|render|validate
- Resouces in the Anywhere Application use OSLC Resources defined in Maximo environment
- When its APP Based Access to that OS can be granted from Security Groups App using application authorizations tab
- When its OS Based you can grant using Object Structure authorization tab in Security Groups App.
- Use might have to use eventContext.viewControl.refresh() sometimes after updating DOM in the application to avoid undesirable glitches
- For setting fields to Required/Readonly on the screen use
var mbo = CommonHandler._getAdditionalResource(eventContext,"sr").getCurrentRecord();var person = incident.getRuntimeFieldMetadata('person');person .set('readonly', true);
person .set('required', false);
- Sample Validate methodvalidateFieldtype: function(eventContext){
var currSR = CommonHandler._getAdditionalResource(eventContext,"workorder").getCurrentRecord(); var fldType= currSR.getPendingOrOriginalValue('myfield1');
if(!inctype) { currSR.set('myfield','');
return; } var myFieldsDomain = CommonHandler._getAdditionalResource(eventContext,'myfieldsDomain');
CommonHandler._clearFilterForResource(eventContext, myfieldsDomain);
//Searches the value being set in the resource
//find method searches the value against the expression below var isValidType = myFieldsDomain.find('value == $1', fldType);
if(isValidType.length == 0){ currSR.set('myfield2','');
throw new PlatformRuntimeWarning('invalidType'); return ; } else {
//Set related field using the value in the resource currSR.set('myfield2',isValidType[0].description);
} return; }
Installation notes:
- App Container and Maximo Anywhere can be installed without any access to Maximo environment using the existing files.
- You can build android/ipa files using the AppContainer without any Maximo Access as long as all the configuration and steps are followed as per IBM and all compatible libraries are available.
Comments
Post a Comment