Mandatory elements in archetypes, and user interfaces

Thomas Beale thomas.beale at openehr.org
Fri Nov 10 08:25:04 EST 2017


Hi Silje,

On 10/11/2017 08:47, Bakke, Silje Ljosland wrote:
>
> Crossposting this between the clinical and implementers lists, since 
> it belongs in both:
>
> In some archetypes, one or more elements are set as mandatory 
> (typically occurrences 1..1 or 1..*), because the rest of the concept 
> makes no sense without this particular element recorded. Examples are 
> Problem/diagnosis name in Problem/diagnosis, and Temperature in Body 
> temperature. This is not intended to mean that it’s mandatory to enter 
> data into the element in a UI, but that this particular element is 
> mandatory in any persisted composition that uses the archetype.
>

and that it should have a value, but the value may be derived by other 
means, e.g. a default value, or just set to 0 or other equivalent.

> Recently however, we received a request to change the Head 
> circumference element in the Head circumference archetype from 1..1 to 
> 0..1 because the element being mandatory in the archetype 
> automatically made the UI form builder mandate the entering of data 
> into the UI field, and removing the archetype on the fly made more 
> unnecessary clicks.
>

I'm not sure I understand; what was the reason the head circumference 
should not have been visible on the form? A value doesn't have to be 
entered; the form can use default value or current value pre-fill.

> In a fit of mental hiccups, I agreed with and performed this change, 
> but have since realised this is wrong, because:
>
> ·A mandatory archetype element is not the same as a mandatory UI field
>
> ·A mandatory UI field is more like a field where you only allow 
> persisting non /null/ values, while a mandatory archetype element can 
> be persisted with a /null/ value without a problem.
>

well it depends on what you mean by a 'null' value; in mainstream 
programming languages, this means /no value/, i.e. nothing. This is not 
the same thing as an empty string or zero-valued number.

What does 'a mandatory UI field' mean? It could mean:

  * must be displayed and filled
  * must be displayed; will be prefilled in some way and may be
    optionally filled by the user


> How are implementers actually handling this? Do you separate UI field 
> mandation and archetype element mandation?
>
> Kind regards,
> *Silje Ljosland Bakke*
>
> **
>
>

-- 
Thomas Beale
Principal, Ars Semantica <http://www.arssemantica.com>
Consultant, ABD Team, Intermountain Healthcare 
<https://intermountainhealthcare.org/>
Management Board, Specifications Program Lead, openEHR Foundation 
<http://www.openehr.org>
Chartered IT Professional Fellow, BCS, British Computer Society 
<http://www.bcs.org/category/6044>
Health IT blog <http://wolandscat.net/> | Culture blog 
<http://wolandsothercat.net/>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.openehr.org/pipermail/openehr-clinical_lists.openehr.org/attachments/20171110/a8ac7757/attachment-0002.html>


More information about the openEHR-clinical mailing list