← Back to team overview

dhis2-devs team mailing list archive

Re: Dynamic option list in data entry

 

Hi,

I don't know much about the logic behind this, but talking on technical side of it. To have drop down on custom dataentry screen we do not need to persist any dataValueOption object and its collection<dataValueOption >. We can bind all possible values while binding dataelement combo to custom dataentry HTML, e.g. datavalue options are stored in HTML as "select bla bla bla" saved. As dataelement is related to dataset and values are available in dropdown there should not be a problem with dataset to dataelement relation. So, this means creating custom forms for such data entry is a must as datavalueoption is not persisted in database and there is no relation defined as such. 
This is simple solution to make set of value options mandatory for data entry. Any other crazy and cool ideas?

regards,
murod


P.S: By the way this could be extended to persist this relation in database, but seems unnecessary.



________________________________
From: Calle Hedberg <chedberg@xxxxxxxxxxxx>
To: Lars Helge Øverland <larshelge@xxxxxxxxx>; miri <murodlatifov@xxxxxxxxx>; Calle Hedberg <calle.hedberg@xxxxxxxxx>; DHIS 2 developers <dhis2-devs@xxxxxxxxxxxxxxxxxxx>
Cc: vshaw@xxxxxxxx
Sent: Saturday, April 18, 2009 1:10:49 PM
Subject: Dynamic option list in data entry

 
Lars,
 
You definitely want to bind those values to a combination of
data set and data element, because different data sets will have different
scopes. This should be even more obvious when moving into survey data, where
drop-downs are a must.
 
Simple example:
 
You have two data sets related to different types of disease
notifications – let us say one is about haemorrhagic fevers (ebola, Marburg,
etc) and the other about vaccination related diseases. Both data sets are using
the data element “Diagnosis” or “Disease”, but the
possible diagnoses for each will be different. You do not want “measles”
to appear when capturing haemorrhagic fever data, and you do not want “Marburg”
to appear when you capture vaccine-related diseases.
 
Regards
Calle
 
 
From:Lars Helge Øverland
[mailto:larshelge@xxxxxxxxx] 
Sent: 18 April 2009 12:54 PM
To: miri; Calle Hedberg; Calle Hedberg; DHIS 2 developers
Subject: Re: [Blueprint dynamic-option-list-in-data-entry] Dynamic
option list in data entry
 
 
On Sat, Apr 18, 2009 at 12:37 PM, miri <murodlatifov@xxxxxxxxx> wrote:
Blueprint changed by miri:

Whiteboard changed to:
What this dynamic values used for? Is this dynamic value
used in more
than one dataset? If this is single time usage, we could implement it
using dataset custom form edit functionality (creating drop down with
custom values). By single I mean only one form uses this set of
predefined data values.

--
 Dynamic option list in data entry
 https://blueprints.launchpad.net/dhis2/+spec/dynamic-option-list-in-data-entry


This is a good question. Binding a set of dynamic values to one data element
would be simple and nice. DHIS 1.4 is binding a set of dynamic values to a
combination of data element and data set, making things even more flexible.
There is probably a good reason for that. Will have to explore this further.


      

Follow ups

References