Exporting Standardized Data

From IHRIS Wiki

In this tutorial we show how to export standardized cadre data from a central site to be shared among regional and district installations.

Note: This module assume that the cadre form is stored in magic data. This is the default for iHRIS Manage version 4.0.


Overview

We will create a module called standard-data-cadre that will contain all of the cadre's defined in the system. We will use the Magic Data Browser to automatically generate a configuration .xml file which we will save as standard-data-cadre.xml. Once we have created this module, we should make it available and required to each of the regional and district installations.

First Steps -- Enabling the Magic Data Browser

We will export the cadre list using the "Magic Data Browser" module. If it is not available under the "Configure System" menu, then follow these steps to enable it:

  • Browse to "Configure System"
  • Click the "Configure Modules" link
  • Click the link "Sub-Modules" to the right of the "Pages" module
  • Check the check box next to "Magic Data Browser"
  • Click the "Enable" button at the bottom of the page

Creating the module

Browsing in Magic Data

Creating the module is very easy. Go to:

  • Browse to "Configure System"
  • Click the "Browse Magic Data" link
  • Click the "I2CE" link
  • Click the "formsData" link
  • Click the "forms" link
  • Click the "cadre" link

You should now see a page that looks like:

Magic Data Browser

Setting Export Options

Now that we have browser in magic data to /I2CE/formsData/forms/cadre we are ready to export the module:

  • Click on the "(options)" link under the "Export" button
  • Set the following data:
    • Module Name: "standard-data-cadre"
    • Displayed Named: "Standardized Cadre List"
    • Version: Change it from "1.0.2010.08.20" to "4.0.2010.08.20"
    • Description: "The Standardized Cadre list set by the central office of the Ministry of Health"

Your page should look like:

Export Options

Now click the "Export" button and your web-browser should ask you where to save the .xml file. We will save it as the file standard-data-cadre.xml. See the next section for some hints about where to save this file.


Note: The module in general should have version 4.0.YYYY.MM.DD where we replace YYYY with the year, MM with the numeric month and DD with the numeric day. For example the version would be 4.0.2010.08.17 if the data was exported on August 27, 2010. If we update the cadre list, at a later date (August 20, 2010), then we can re-export the list into the same module standard-data-cadre but this time with version 4.0.2010.08.20.

Managing Decentralized iHRIS with Launchpad

First please see the article Decentralized iHRIS Data Policy for some background explanation.

Please also read Managing A Site In Launchpad for some background information on creating teams and working with bazaar on Launchpad.

Let us assume that we are working with a national site (National), and four regional sites (North,South,East and West) in the fictional country Taifeki

Launchpad

Team

Create a launchpad team, called ihris+taifeki, which you and all members of your development team will join.

Project

Create a launchpad project called ihris-manage-taifeki. Once it is created, edit the project details and:

  • set it to be "Part of:" the 'ihris-suite' project
  • Check Code for this project is published in Bazaar branches on Launchpad
  • Check Bugs are tracked in launchpad
  • Hit the Change button
  • Return to editing the project details, scroll down to the bottom of the page and choose the Edit People link
  • Set the Mainter to be the ihris+taifeki team

Series

Within the ihris-manage-taifeki we will create a Series for each tier of of structure. As we are working with iHRIS Manage 4.0, we will also want to indicate that in the Series name. Each series will contain all of the sites that exist on that tier. Here are series we will create:

  • national-4.0 One site, the national site which aggregates from all the regions
  • region-4.0 One site for each regions, each region will aggregate from all the districts contained within it
  • district-4.0 One site for each district

ce To create the series, and do the following for each of the series above:

  • Click on the 'Code' tab on the project home page
  • Click on the 'Register Series' link
  • Set the owner to be ihris+taifeki
  • Set the name to be the same name as the series (e.g. national-4.0)
  • Set the branch type to be 'Hosted'
  • Click on the 'Register Branch' button
  • Return to the project home page by clicking on the 'Overview' tab
  • Select "Register a series"
  • Enter in the name of the series (e.g. national-4.0)
  • Enter in the Bazaar branch (e.g. ~ihris+taifeki/ihris-manage-taifeki/national-4.0)

Modules

Data Policy Module

Within each of the series we will, create the modules as appropriate:

  • ihris-manage-taifeki-national-data-policy
  • ihris-manage-taifeki-regional-data-policy
  • ihris-manage-taifeki-district-data-policy

which defines the form storage/data management policy for that tier and which requires ihris-manage. If the data for a form is contained in a module that it should also require that module:

  • The national site would require the ihris-manage-taifeki-national-data-policy
  • Each site on regional level will require the ihris-manage-taifieki-regional-data-policy module.
  • Each site on the district level would require ihris-manage-taifieki-district-data-policy. Also, in the example above, for any district in the northern region, we would have it's site module require ihris-manage-tafaiki-northern-region-facility and ihris-manage-tafaiki-northern-region-facility_contact.