Difference between revisions of "MnM"

From mn/ifi/inf5750
Jump to: navigation, search
(Git repo)
(Learning outcome and future thoughts)
Line 107: Line 107:
  
 
==Learning outcome and future thoughts ==
 
==Learning outcome and future thoughts ==
 +
 +
=== Learning outcome ===
 +
* Understanding how working together on a code-project works, using Git (e.g. we write better commit-messages for each other now).
 +
* Understanding how RESTful API's work and how such a modularised Service Oriented Architecture facilitates innovation of new services.
 +
* Understanding how a HMIS like DHIS2 work, and how its data structure is organised.
 +
* Understanding how webapps can be developed.
 +
* Understanding the use case of reporting on commodities in developing countries.
 +
* Understanding more about the HISP project, and DHIS2 as one of the world's largest open source projects.
 +
* Understanding of JavaScript, JQuery, AJAX -  and the combination of these into more useful webapps.
 +
* Exploring and testing design principles for web pages (e.g. the colors are the same throughout DHIS live, user feedback when entering wrong and right values into forms
 +
 +
=== Future thoughts ===
 +
* In the future, this app should support adding commodities to the PostGres database, into a new table.
 +
 
==Time schedule ==
 
==Time schedule ==
  

Revision as of 10:50, 5 December 2015

Project description

The DHIS2 software is originally designed to support the statistics of disease cases, and provide powerful tools for the analysis and presentation of this data.  Now, more and more of the using countries see the need for a robust information system handling the commodity logistics as well, and they want to use DHIS2 for this purpose. Some already use the system for out of stock registration, but we see that there are some development that needs to be done to make the system support this in a effective manner. 

In this project we will be developing a simple web-based app for DHIS2 where health workers at the clinic level can send requests for a variety of commodities. The request will end up in the DHIS2 messaging service, giving the managers at district level a notification, and specific details about the order. Our goal is to get a more detailed introduction to DHIS2 app development.

More information

Logistics Management Information System (LMIS) Light

Demo

Demo of our App can be downloaded from here (zip-file).

  To run our webapp using DHIS Live:

*Approach 1*
 1. Clone the whole project into "dhis-live/conf/apps/".
 2. The app should now be available through "App Management" in DHIS.
 
 *Approach 2*
 1. Zip the contents into a folder called "MnM"
 2. Upload to a running DHIS live test-server (optionally: Put the MnM-folder under the folder dhis-live/conf/apps/)
 
 *Implementation details*
 The webapp will automatically decide who it will send the commodity order to. It does so according to the following procedure:
 1. Determine the Organizational Unit (OU) of the current user.
 2. Determine the parent OU.
 3. Send the order to all users in the user group specified at the top of request_handler.js (currently "Logistics").
 
 - If the application finds no users in the specified group in the parent OU, then no order will be sent. The only exception is
 if the user belongs to the top level OU; then the order will be sent to the users in the specified user group at the current
 level. Consequently, if the specified user group does not exist, no order will ever be sent.
 
 Because of this, some configuration is required in order to test the web app. These are:
 1. The "Logistics" user group must be created.
 2. A user above the lowest OU level must be member of the "Logistics" user group.
 3. One level down in the hierarchy there must exist a user.
 
 To test the app, you have to log in with the user from step 3 and send a commodity order.
 The order should then be sent to the user from step 2.
 For more thorough testing, more users can be added to the group.
 
 The easiest way to configure this is to load the sample data, and create the Logistics user group.
 Thereafter add the user "Alain Traore" (username traore) in the "Sierra Leone" OU to the "Logistics" user group.
 Then log in with the user "Seydou Keita" (username keita) in the "Bo" OU and send a commodity order with the app.
 Check that the order is sent to "Alain Traore".
 
 
 *How to use*
 - A list of commidities are hardcoded into the search suggestion algorithm (see 'commidity_search_handler.js').
 - Try for example to enter 'M' in the input field, and you will get a list of commodities starting with 'M'
 - You may enter variable types of commidities by adding new forms with the '+'-button.
 - When you hit send, the forms are validated and a message will be displayed at the top of the webpage.  

List of group members 

  • Magnus Li (magl@ifi.uio.no)
  • Nicolai August Hagen (nicolhag@ifi.uio.no)
  • Magnus Søyland (magnusoy@ifi.uio.no)

Git repo

Private repository available at https://github.com/nicolhag/INF5750.  'mustafma' is given access.

Architecture / technology 

DHIS 2 Webapp

Javascript (and JQuery)

HTML5

CSS3

AJAX

Summary of Requirements

We have written down some requirements for the system. We will possible add requirements for more advanced functionality when the basics are covered.

Functional requirements

  • Users at clinic level must be able to order multiple commodities in a specified amount.
  • Users at clinic level most be able to order a specified amount of a specific commodity.
  • Managers at the district level must get a notification when new orders come in.
  • Managers at the district level most be able to see detailed information about the orders.

Group organization 

All group members know each other from earlier projects, and communicate on a daily basis. Therefore the task delegation have been pretty flexible, and the coordination have been easy.

Although, we had some independent responsibilities.

Nicolai Hagen: Understanding DHIS2 developer documentation, working on AJAX communication between our webapp and DHIS2 API.

Magnus Søyland: Architectural design, and working on communication between our webapp and the DHIS2 api.

Magnus Li: Main responsibility for the front-end HTML, CSS, Javascript, and the implementation of search suggestion functionality and form validation.

Since we have been working pretty close, everyone have been taking part in most decisions in all parts of the project.

Screenshots, implementation of features 

Initial picture
Choosing commodities
Multiple commodities and form validation
Message successfully sent
Commidity did not exist
No higher users in management in "Logistics" group available

Learning outcome and future thoughts 

Learning outcome

  • Understanding how working together on a code-project works, using Git (e.g. we write better commit-messages for each other now).
  • Understanding how RESTful API's work and how such a modularised Service Oriented Architecture facilitates innovation of new services.
  • Understanding how a HMIS like DHIS2 work, and how its data structure is organised.
  • Understanding how webapps can be developed.
  • Understanding the use case of reporting on commodities in developing countries.
  • Understanding more about the HISP project, and DHIS2 as one of the world's largest open source projects.
  • Understanding of JavaScript, JQuery, AJAX - and the combination of these into more useful webapps.
  • Exploring and testing design principles for web pages (e.g. the colors are the same throughout DHIS live, user feedback when entering wrong and right values into forms

Future thoughts

  • In the future, this app should support adding commodities to the PostGres database, into a new table.

Time schedule 

Milestone 1: November 8th 

  • Document features and architecture on Wiki
  • Show understanding of DHIS2 web apps
  • Set up the Github account
  • Set up a working demo server which we can test on

Milestone 2: November 22th 

  • First bare-bone version - static HTML
  • Uploadable as DHIS2 web app
  • All functional requirements above up and running in the app

Milestone 3: December 4th 

  • Functional requirements