Differences

This shows you the differences between two versions of the page.

Link to this comparison view

Both sides previous revision Previous revision
Next revision
Previous revision
integration:dhis2_integration [2024/08/14 12:19] – [mSupply preferences] Gary Willettsintegration:dhis2_integration [2024/11/04 09:43] (current) – [mSupply preferences] Gary Willetts
Line 14: Line 14:
  
  
-Common types of data that you can send to DHIS2 from mSupply for an item:+The types of data that you can send to DHIS2 from mSupply for an item:
   - Current stock on hand   - Current stock on hand
   - Current months of stock on hand   - Current months of stock on hand
Line 22: Line 22:
   - The amount of stock expiring within 90 days   - The amount of stock expiring within 90 days
   - The amount of stock expired   - The amount of stock expired
-  - Value of stock on hand 
   - Average monthly consumption   - Average monthly consumption
   - Days out of stock   - Days out of stock
Line 57: Line 56:
   * **Username:** The username mSupply will use to access the DHIS2 database.   * **Username:** The username mSupply will use to access the DHIS2 database.
   * **Password:** The password mSupply will use to access the DHI2 database.   * **Password:** The password mSupply will use to access the DHI2 database.
-  * **Client:** The client name mSupply must use to access the database. +  * **Client:** Only visible and used if **Basic authentication** is not checked. The client name mSupply must use to access the database. 
-  * **Secret:** The secret that is used for mSupply to access the DHIS2 database. No need to enter this if none was provided.+  * **Secret:** Only visible and used if **Basic authentication** is not checked. The secret that is used for mSupply to access the DHIS2 database. No need to enter this if none was provided.
   * **Setup:** Here you choose how to identify the elements of data that you send to DHIS2 must be identified. Your choice depends on how DHIS2 is configured.   * **Setup:** Here you choose how to identify the elements of data that you send to DHIS2 must be identified. Your choice depends on how DHIS2 is configured.
     * **Using category option combo:** Choose this if DHIS2 is using attribute option combos where there is one category option combo assigned per data element (AMC, stock on hand etc.) for an entire data set. For this option, you need to tell mSupply what the DHIS2 category option combo ID is for each data element you want to push (i.e. //Active// column is checked) in the //Data elements to push// table.     * **Using category option combo:** Choose this if DHIS2 is using attribute option combos where there is one category option combo assigned per data element (AMC, stock on hand etc.) for an entire data set. For this option, you need to tell mSupply what the DHIS2 category option combo ID is for each data element you want to push (i.e. //Active// column is checked) in the //Data elements to push// table.
Line 69: Line 68:
     * **Interval column:** Select the interval between successive sends of the data element. Select one of //monthly//, //weekly//, //daily//, //first day of the month// and //last day of the month// by clicking on the down arrow in the cell and selecting the appropriate option.     * **Interval column:** Select the interval between successive sends of the data element. Select one of //monthly//, //weekly//, //daily//, //first day of the month// and //last day of the month// by clicking on the down arrow in the cell and selecting the appropriate option.
     * **Push data basis column:** Select the basis of the data to be sent, one of //previous month// or //current day//. Again, click on the down arrow in the cell and click on the appropriate option to select it.     * **Push data basis column:** Select the basis of the data to be sent, one of //previous month// or //current day//. Again, click on the down arrow in the cell and click on the appropriate option to select it.
 +    * **Prefix column:** If the data element ID needs to have a prefix added to it before it is sent to DHIS2 then enter that in this column.
   * **Data set ID:** Enter the ID of the dataset in DHIS2 that you want to push the data to.   * **Data set ID:** Enter the ID of the dataset in DHIS2 that you want to push the data to.
   * **Period format:** Enter the format to send the period information to DHIS2. Something like "YYYYMM", where YYYY represents the year, MM represents the month and DD represents the day.   * **Period format:** Enter the format to send the period information to DHIS2. Something like "YYYYMM", where YYYY represents the year, MM represents the month and DD represents the day.
   * **Item field reference:** Required for "Using category option combo" and "Push only 1 data element" setup. This tells mSupply where the DHIS2 item reference is stored in mSupply. If //Universal code// is selected then the code shown in the **Universal code** field of an item's details page is used (see the [[items:item_basics:tab_general|]] page for details). If //Custom field// is selected then the DHIS2 item reference is taken from the item custom field entered in the accompanying text field (which should contain one of "user_field_1", "user_field_2", "user_field_3" and "user_field_6" (see the [[items:item_basics:tab_general|]] page for details of these custom fields).   * **Item field reference:** Required for "Using category option combo" and "Push only 1 data element" setup. This tells mSupply where the DHIS2 item reference is stored in mSupply. If //Universal code// is selected then the code shown in the **Universal code** field of an item's details page is used (see the [[items:item_basics:tab_general|]] page for details). If //Custom field// is selected then the DHIS2 item reference is taken from the item custom field entered in the accompanying text field (which should contain one of "user_field_1", "user_field_2", "user_field_3" and "user_field_6" (see the [[items:item_basics:tab_general|]] page for details of these custom fields).
   * **Data element ID scheme:** This tells mSupply what kind of DHIS2 item identifiers are stored in mSupply (in the place defined by the **Item field reference** section above), item codes or UIDs.   * **Data element ID scheme:** This tells mSupply what kind of DHIS2 item identifiers are stored in mSupply (in the place defined by the **Item field reference** section above), item codes or UIDs.
 +  * **Store field reference:** Enter the name of the store custom data field that identifies which stores to send data to DHIS2 for. Data will be sent for all stores that have a value in the store custom data field with this name.
   * **Round off checkbox:** If checked then mSupply will round numerical data values to the nearest whole number as some DHIS2 setup only accept integers.   * **Round off checkbox:** If checked then mSupply will round numerical data values to the nearest whole number as some DHIS2 setup only accept integers.
 +  * **No. of items per payload:** Enter the number of pieces of information to send in a particular call to the DHIS2 server. If there are more than this number of pieces to send then they will be split up into separate calls with this number of pieces of information in them. Helpful if there is a lot of information to send but the DHIS2 server can't handle the volume of information (which usually results in internal errors being returned).
   * **Test connection button:** Click this to test the connection to the DHIS2 server. You will be shown a message that tells you whether mSupply was able to connect to the DHIS2 server with the credentials you have provided.   * **Test connection button:** Click this to test the connection to the DHIS2 server. You will be shown a message that tells you whether mSupply was able to connect to the DHIS2 server with the credentials you have provided.
   * **Manual push data button:** Click this button to immediately attempt to push the data as setup in this window to DHIS2. The data will, of course, be pushed on a //current day// basis. View the log (see the [[admin:the_log|]] section for details) to see the results of the attempt.   * **Manual push data button:** Click this button to immediately attempt to push the data as setup in this window to DHIS2. The data will, of course, be pushed on a //current day// basis. View the log (see the [[admin:the_log|]] section for details) to see the results of the attempt.
Line 92: Line 94:
 \\ \\
 \\ \\
-|  //  Previous:  **[[integration:]]** | | Next: **[[integration:frontlinesms_integration]]** //  |+|  //  Previous:  **[[integration:]]** | | Next: **[[integration:dhis2_lmis_integration]]** //  |
  
 ---- struct data ---- ---- struct data ----
  • Last modified: 2024/08/14 12:19
  • by Gary Willetts