↓ Skip to main content
A reverse glass painting of a dark storeroom shelf with three boards. The top and the bottom board hold four teal boxes each. The middle board holds three, and one place is empty. An orange tally counter lies on the floor in front of the shelf.

ICMOBILE - Inventory Count

Somebody has to walk through the storeroom and count what is really on the shelf. Inventory Counting is the Maximo Mobile app for that walk. Its application id is icmobile. It does one job in three ways, and its source is small enough to read from the first line to the last. We counted a demo storeroom with it and counted the app itself in our MAF editor.

MAS 9.2 series case study

We looked at the app on our test system, on the MAS 9.2 series, with IBM’s demo data. The numbers belong to that release and change with every new version of the app, so read them as a size. This case study follows the same plan as TECHMOBILE - The Technician App, and its table carries the numbers of Technician for comparison.

A count in four screens
#

The app opens with a menu of three entries: count books, an ad hoc count, and the reconciliation.

Four screens of the Inventory Counting app. First, the menu with the entries “Count books”, “Ad hoc count” and “Reconciliation”. Second, the drawer “Select storeroom” with a search field and seven storerooms, among them CENTRAL, the central storeroom, and GARAGE. Third, the ad hoc count of the storeroom CENTRAL: the tabs “In progress” with 151 and “Counted” with 0, a search field, and a card for item 39224, brake shoes, with its ABC type, striped bars for the empty fields, the issue unit EACH, and a count field with a minus and a plus button. Fourth, the reconciliation of the same storeroom: the tabs “Mismatched” and “Matched”, both with 0, and the text “No results found”.
The menu, the choice of a storeroom, an ad hoc count, and the reconciliation

A count book is a planned count. Somebody prepares it in Maximo Manage, with the items to count, and the person in the storeroom works through it. Our test system has no count book, so we took the second way.

An ad hoc count needs no preparation. The user picks a storeroom, and the app lists its items: 151 for the central storeroom of the demo data. Each card shows the item, its ABC type, the bin and the unit, and a field for the counted quantity with a minus and a plus button. Two tabs split the items into those still in progress and those counted.

The reconciliation compares what was counted with the balance in Maximo. Its two tabs separate the items that match from those that differ. We had counted nothing, so both tabs read 0.

The app in numbers
#

We opened the source of the app in our MAF editor. Its structure view counts the app as the build sees it:

PartInventory CountingTechnician
Pages628
Datasources26148
of these: maximo-datasource789
of these: maximo-datasource-override1224
of these: json-datasource735
Object structures626
Dialogs691
Sliding drawers322
States71147
Controller classes1150
Methods in these classes1451,012
Ways from one page to another865
Lines in app.xml1,3966,133
XML files, with app.xml249
Lines in all XML files1,4709,932
JavaScript files, without tests and mock data14118
Lines in these JavaScript files4,30243,613

Both apps as shipped with our system of the MAS 9.2 series, where Inventory Counting is app version 9.2.109 and Technician is app version 9.2.124. The lines are counted with wc -l over the source folder, the other rows by the structure view of our MAF editor.

The app has a tenth of the JavaScript of Technician and less than a quarter of its app.xml. Almost all of its markup is in one file. The whole app reads through six object structures.

One row stands out. The app has more overrides than plain maximo-datasource elements. It defines a datasource once, with its schema, and then uses it again with another saved query or another filter. Technician does the same for its work lists. Here the pattern shapes almost half of all datasources. The two tabs of the reconciliation are such a pair: two overrides with the same saved query and a different filter.

A good first app to read
#

Most projects we see are about Technician, so a developer who starts with Maximo Mobile opens Technician first. That is the hardest start. Technician has 28 pages and more than 40,000 lines of JavaScript.

Inventory Counting has everything a real app has, in a size a person can hold in the head:

What you want to seeWhere it is in this app
a menu page that leads to the workthe start page
a list with a search field and tabsthe ad hoc count
a drawer that picks a value for the whole pagethe choice of the storeroom
a datasource that is defined once and used several timesthe overrides
a page controller with a clear jobeleven classes, about 13 methods each on average
a write that changes Maximothe save of a count

Read this app before you read Technician. The patterns are the same, and here they are easy to find.

Where the weight sits
#

PageDatasourcesDialogsDrawersStates
the start page2010
the list of count books0102
one count book02017
the ad hoc count31112
the reconciliation0014
the sync of records2103

Parts declared on the page itself, in the same version of the app on the MAS 9.2 series. One more dialog belongs to the application.

The pages declare seven of the 26 datasources. All others belong to the application, so every page can use them. The page for one count book has the most states and the largest controller class.

How the pages connect
#

The Map panel of the MAF editor for the Inventory Counting app. The top line reads 6 pages, 8 ways, 4 calls named at run time, and is cut off after that. The page countBookDetail is selected. Under “Goes to” it lists countBook with 3 ways. Under “Comes from” it lists the app and countBook, both with the file and line of the call. Below, the list of the six pages: main, countBookDetail, countBook, adHoc, reconcile and manageRecordSync.
One count book in the page map of our MAF editor

Our MAF editor finds eight fixed ways between the six pages. Four more calls compute the name of the next page at run time. Follow these four in the running app before you change the navigation.

What the app asks of Maximo
#

  • Storerooms and balances. The ad hoc count lists the items of a storeroom from the inventory balances. Three datasources name the object structure mxapiinvbal.
  • Count books. The planned count needs count books and their lines, which are prepared in Maximo Manage.
  • The rights to adjust a count. A saved count changes inventory data, so the users of this app need the rights for that.

What to read next#

TECHMOBILE - The Technician App is the large app with the same patterns. Anatomy of a Maximo Mobile App explains the parts that the table of this case study counts.


IBM describes the Inventory Counting app in the documentation of Maximo Mobile, and count books in the documentation of the inventory applications of Maximo Manage.