Customize a Data Entry form with Sections

Hey y’all,

I am building out a few Data Entry forms as part of migration away from MS Power Apps to DHIS2. I am becoming familiar with the different types of forms, such as Default, Section and Custom and have created a few Custom forms. But this is a bit of a time-consuming process, so I was wondering what customization options there are for Section forms.

Specifically I am wondering if I can create columns using HTML on the page somewhere, so that all my sections don’t appear in one long scrolling column on the left side of the window. I have attached a GIF to show you what I mean regarding a specific form.

DHIS2ColumnsNeeded

When I create a Section in the Data Set customization menu there is a box labeled:
“Content before and after section (HTML links and basic styling allowed).”

But it appears to ignore my attempts at adding in HTML tags to this box. What HTML is recognized here by the Section form? Just tags? Can I do anything with

or or will these be ignored.

Thanks in advance for the clarification!

Hi @pmacmillan

Thanks for the detailed post. It would’ve been great if you could share the HTML code itself so we’d know why it’s being “ignored” ? Basically, it will not allow “script” there or anything complex.

I have a feeling you are looking for plugins… which is one of the latest features mentioned in the conference in June:

What HTML is recognized here by the Section form?

The allowed tags for that section are: [‘a’, ‘b’, ‘strong’, ‘u’, ‘em’]. Anything else will be removed. I will note that we should clarify this some more in the documentation.

Specifically I am wondering if I can create columns using HTML on the page somewhere, so that all my sections don’t appear in one long scrolling column on the left side of the window.
Data sets can be configured (e.g. in the maintenance app) to have sections rendered as tabs:

image

which will then look like this:
(you can toggle between Immunization/Nutrition sections by either clicking on the tabs, or clicking on the selector in the top bar)

(Screenshot from Child Health data set on Login app | DHIS2 after setting “Render sections as tabs” as true.)

We are working on also updating this to allow vertically oriented tabs as well as horizontally tabs.

I have a feeling you are looking for plugins… which is one of the latest features mentioned in the conference in June:

Thanks for mentioning this @Gassim and encouraging the use of plugins :blush:. Just to note though that plugins are not currently supported in the data entry app, and it’s not in our immediate upcoming development plans to add them.

If there’s functionality that you feel is missing, @pmacmillan, we’d be happy to have the feedback/a feature request.

1 Like