Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.

This page will be extended to cover information around building CommCare Supply mobile applications. For now, we just have a writeup on how to access product data in the phone. 

...

Accessing Products: When building a mobile application, product data can be accessed through the auto-created product fixture on the phone. The format for accessing the data is:

 

<fixture id="CommCare Supplycommtrack:products" user_id="3ce8b1611c38e956d3b3b84dd3a7ac18">
  
<products>
     
<product id="some-guid-here">
              
<name>Coartem</name>
              
<unit>pills</unit>
              
<code>co</code>
              
<description>common antimalarial</description>
              
<category>antimalarials</category>
              
<program_id>some-program-guid</program_id>
              
<cost>1.00</cost>
     
</product>
  
</products>
</fixture>