Activity Status and Inventory Pool Changes
You can change the activity status (such as start, suspend, complete activity) by simply updating the field 'astatus' taking into account the available status transitions. You can perform actions (such as install, deinstall inventory, undo install) on the inventory pool for serialized inventory by simply updating the field 'pool' taking into account the available pool transitions, and update the required fields for the pool (for example, inv_aid for install pool).
Order of Applying Changes to Entity Data Collections
If a plug-in sends a few collections such as, 'activityList', 'activity',
'inventoryList', and 'inventory' in the 'close' method, the application tries to apply
the changes in this order:
- 'activityList'
- 'activity'
- 'inventoryList'
- 'inventory'
If a plug-in receives the same activity changes in the 'activityList' and 'activity'
entity data collections, only the changes from the 'activity' entity data collection are
applied. The changes from the 'activityList' entity data collection are ignored.
However, the current activity in the 'activityList' can be changed, if the 'activity'
entity data collection is not sent to the plug-in. This example shows the activity
changes that can and cannot be applied:
{
"apiVersion": 1,
"method": "close",
"backScreen": "default",
"wakeupNeeded": false,
"activity": {
"aid": "8761055",
"ACTIVITY_NOTES": "new changes 1" <--- these changes will be applied
},
"activityList": {
"8761054": {
"ACTIVITY_NOTES": "another activity"
},
"8761055": {
"ACTIVITY_NOTES": "new changes 2" <--- these changes won't be applied, they will be ignored
}
}
}
If a plug-in receives the same activity changes in the 'inventoryList' and 'inventory'
entity data collections, only the changes from the 'inventory' entity data collection
are applied. The changes from the 'inventoryList' entity data collection are ignored.
However, the current inventory in the 'inventoryList' can be changed, if the 'inventory'
entity data collection is not sent to the plug-in. This example shows the inventory
changes that can and cannot be applied:
{
"apiVersion": 1,
"method": "close",
"backScreen": "default",
"wakeupNeeded": false,
"inventory": {
"invid": "1055",
"INVENTORY_NOTES": "new changes 1" <--- these changes will be applied
},
"inventoryList": {
"1054": {
"INVENTORY_NOTES": "another inventory"
},
"1055": {
"INVENTORY_NOTES": "new changes 2" <--- these changes won't be applied, they will be ignored
}
}
}
Changing of Activity status
Activity status can be changed (e.g. start, suspend, complete activity) by simple update of
field 'astatus' regarding the available status transitions. This image shows the possible
transitions between activity statuses:
This image shows the possible transitions between inventory pools: