23.14 Manage external map layers

23.14.1 About external map layers

You can customize GIS by including map layers from various sources and combine them with your own data in DHIS2. DHIS2 supports common map service formats such as Web Map Service (WMS), Tile Map Service (TMS) and XYZ tiles.

23.14.2 Create or edit an external map layer

Note

DHIS2 only supports the Web Mercator projection ( EPSG:3857 ) so make sure that the external service supports this projection.

External map layer objects in the Maintenance app

Object type

Available functions

External map layer

Create, edit, clone, delete, show details and translate

  1. Open the Maintenance app and click Other > External map layer .

  2. Click the add button.

  3. In the Name field, type a name that describes the content of the external map layer.

    This is the name you’ll see in the GIS app.

  4. (Optional) In the Code field, assign a code.

  5. Select a Map service format.

    DHIS2 supports three common map service formats:

    • Web Map Service (WMS)

      Image format : PNG format allows layers to be transparent, JPG format offers better compression and is often faster to load.

      Layers : A WMS can contain several individual layers, and you can specify which you want to include (comma separated). Refer to the WMS GetCapabilities document to see the available layers.

    • Tile Map Service (TMS)

    • XYZ tiles (can also be used for WMTS)

  6. Enter the URL to the map service.

    Note

    XYZ and TMS URLs must contain placeholders {}, for example: http://{s}.tile.osm.org/{z}/{x}/{y}.png.

  7. (Optional) Enter Source of the map layers. The field can contain HTML tags if you want to link to the source.

    When you use an external map service it is important to highlight where the data comes from.

  8. Select a Placement :

    • Bottom - basemap : For the GIS app, this places the external map layer above other DHIS2 base maps but below the thematic map layers. For the Maps app, this makes the external map layer selectable as the base map (i.e. as an alternative to the DHIS2 base maps).

    • Top - overlay : For the GIS app, this places the external map layer above the thematic map layers but below facility and event data layers. For the Maps app, this allows the external map to be added from the Add Layer selection and placed anywhere above the base map.

  9. (Optional) Add a legend.

    You can add a legend in two ways:

    • Select a predefined Legend to describe the colors of the map layer.

      Tip

      Click Add new to create legends that you’re missing. In the form that opens, create the legends you need. When you’re done, click Refresh values .

    • Enter a link to an external image legend in Legend image URL .

      These are often provided for WMS. See under LegendURL in the WMS GetCapabilites document.

  10. Click Save .

23.14.3 Clone metadata objects

Cloning a data element or other objects can save time when you create many similar objects.

  1. Open the Maintenance app and find the type of metadata object you want to clone.

  2. In the object list, click the options menu and select Clone .

  3. Modify the options you want.

  4. Click Save .

23.14.4 Delete metadata objects

Note

You can only delete a data element and other data element objects if no data is associated to the data element itself.

Warning

Any data set that you delete from the system is irrevocably lost. All data entry forms, and section forms which may have been developed will also be removed. Make sure that you have made a backup of your database before deleting any data set in case you need to restore it at some point in time.

  1. Open the Maintenance app and find the type of metadata object you want to delete.

  2. In the object list, click the options menu and select Delete .

  3. Click Confirm .

23.14.5 Display details of metadata objects

  1. Open the Maintenance app and find the type of metadata object you want to view.

  2. In the object list, click the options menu and select Show details .

23.14.6 Translate metadata objects

DHIS2 provides functionality for translations of database content, for example data elements, data element groups, indicators, indicator groups or organisation units. You can translate these elements to any number of locales. A locale represents a specific geographical, political, or cultural region.

Tip

To activate a translation, open the System Settings app, click > Appearance and select a language.

  1. Open the Maintenance app and find the type of metadata object you want to translate.

  2. In the object list, click the options menu and select Translate .

    Tip

    If you want to translate an organisation unit level, click directly on the Translate icon next to each list item.

  3. Select a locale.

  4. Type a Name , Short name and Description .

  5. Click Save .