All Projects → dhis2 → maintenance-app

dhis2 / maintenance-app

Licence: other
DHIS 2 app for configuration of metadata

Programming Languages

javascript
184084 projects - #8 most used programming language

Projects that are alternatives of or similar to maintenance-app

image-discovery-app-js
JavaScript Image Discovery Web Application. Use to search, discover, filter, and manipulate imagery.
Stars: ✭ 22 (-26.67%)
Mutual labels:  web-app
Swiftly
Swiftly is an easy to use Qt/C++ web framework
Stars: ✭ 20 (-33.33%)
Mutual labels:  web-app
servant-beam-realworld-example-app
Exemplary fullstack Medium.com clone powered by Servant and Beam
Stars: ✭ 33 (+10%)
Mutual labels:  web-app
stockfish-chess-web-gui
Responsive chess web GUI to play against the Stockfish 10 chess engine. Multiple web GUI implementations have also been included.
Stars: ✭ 21 (-30%)
Mutual labels:  web-app
vollt
Java libraries implementing the IVOA protocol: ADQL, UWS and TAP
Stars: ✭ 21 (-30%)
Mutual labels:  web-app
stoqs
Geospatial database visualization software for oceanographic measurement data
Stars: ✭ 31 (+3.33%)
Mutual labels:  web-app
docker-horizon-core-web
🐳 Core and Web application service for Horizon by OpenNMS
Stars: ✭ 28 (-6.67%)
Mutual labels:  web-app
currency-converter
💰 Easily convert between 32 currencies
Stars: ✭ 16 (-46.67%)
Mutual labels:  web-app
d2
⛔ [DEPRECATED] Please refer to the App Platform for the modern way to build DHIS2 apps.
Stars: ✭ 21 (-30%)
Mutual labels:  synced-settings
web
Cloverleaf is a free, open source app to replace your password manager without storing your passwords anywhere.
Stars: ✭ 33 (+10%)
Mutual labels:  web-app
Smart-Web-App-Banner
Add this small jQuery script to your site & invite your visitors to save your site to their home screen alongside the rest of their apps!
Stars: ✭ 37 (+23.33%)
Mutual labels:  web-app
apertium-html-tools
Web application providing a fully localised interface for text/website/document translation, analysis and generation powered by Apertium.
Stars: ✭ 36 (+20%)
Mutual labels:  web-app
docker-rcon-web-admin
A Docker image that runs rcon-web-admin
Stars: ✭ 34 (+13.33%)
Mutual labels:  web-app
woapp
web模拟安卓操作系统,php开发,内置文件管理,电话,短信,拍照,用在树莓派上可做智能家居,视频监控,机顶盒等……
Stars: ✭ 22 (-26.67%)
Mutual labels:  web-app
tourney-bot
an app to run the Houston Ultimate Indoor Tournament
Stars: ✭ 16 (-46.67%)
Mutual labels:  web-app
schsrch
Simple and intuitive CIE search engine
Stars: ✭ 35 (+16.67%)
Mutual labels:  web-app
reactjs-portfolio
Welcome to my portfolio react.js repository page.
Stars: ✭ 109 (+263.33%)
Mutual labels:  web-app
quiz-app
🏆 QuizApp is a free and open-source quiz application that lets you play fully customized quizzes right in the browser.
Stars: ✭ 97 (+223.33%)
Mutual labels:  web-app
d2-ui
⛔ [DEPRECATED] Please refer to the DHIS2 App Platform
Stars: ✭ 14 (-53.33%)
Mutual labels:  synced-settings
music-app-electron
Music-Streaming app built with Electron, Webpack, Vue.js, Vuex and the Spotify api.
Stars: ✭ 74 (+146.67%)
Mutual labels:  web-app

maintenance-app

Build Status

App config

The maintenance app is largely driven by the app config and the schemas from the API. The schemas are read directly from the API (by D2). The following documents the app config:

  • within src/config/ ...
    • maintenance-models.js defines the model types that are shown in the app
    • field-config/ contains configuration for each model type
      • field-order.js defines the order of fields within the form for each model type
      • field-groups.js defines field grouping for the form for each model. This is currently only used for programRules, but it might be a good idea to expand it to other model types as well.
    • field-overrides/ contains extra configuration for fields that require non-standard behavior. Most commonly this means fields that require special components.
      • index.js lists all models that have one or more field overrides
      • The actual field overrides are specified in files named after each model type, which in turn are imported into index.js. Some model types or fields that require a lot of logic are separated into sub folders.
    • inlinehelp-mapping.json specifies mapping from each section/model-type to pages in the documentation.
    • field-rules.js contains conditional logic that can be used to show or hide fields or set field values based on the value of other fields.
    • periodTypes.json contains the list of period types that are supported by the current version of the API.
    • disabled-on-edit/ contains files that list fields that will always be displayed as read-only when an object is being edited.
      • index.js imports lists of field names from files named after each relevant model

For the record, "schemas" and "model types" are essentially the same thing and these terms are used interchangeably both in the maintenance app and elsewhere. Schemas are exposed by the API, but not every model type is listed in the schemas. To add to the confusion "models" are also some times referred to as "objects".

Sections, model types and fields

In order for a model type to show up in the maintenance app, the following conditions need to be met:

  • The model type is listed under a section in src/config/maintenance-models.js
  • The model type exists in the schemas endpoint in the API

Once these conditions are met, the model type will show up in the maintenance app under the section specified in maintenance-models.js. When creating or editing models of the new type, the form will by default only contain a handful of predefined fields. In order for additional fields to be shown in the form, the following conditions need to be met:

  • The field is listed under the model type in src/config/field-config/field-order.js
  • The field exists in the schemas endpoint for the specific model type in the API.

Adding a new model type

Adding a new model to the maintenance typically involves the following steps:

  1. Add the model type to src/config/maintenance-models.js
  2. Add the model type and the list of fields that should be shown in the form to src/config/field-config/field-order.js
    1. (Optional) If the fields should be separated into separate groups in the form, the groups can be specified in src/config/field-config/field-groups.js.
  3. The new model type should now be listed in the maintenance app. Navigate to the new model type and check the form both when creating a new instance of the model type and when editing an existing instance. If you're lucky, everything will just work at this point. More likely there will be one or more fields that require further customization.
  4. Create a new file named after the new model type in src/config/field-overrides/. Open src/config/field-overrides/index.js, import the newly created file and add it to the overridesByType object.
  5. Inside the new field override file (src/config/field-overrides/newType.js), start adding customizations for the fields that require it. This typically involves creating new components and/or overriding certain field properties. Look at the existing field overrides for examples.
  6. Strings that show up as ** string ** in the UI lack translations. These will need to be added to the translations files located in src/i18n/. Some strings are generated dynamically and may only show up in certain situations, for example when trying to delete a model. Note: the translation workflow should at some point change to using i18next in favor of d2.i18n.

Extra special cases

Certain models require customization beyond what's possible using the config and field overrides. In those cases it may be necessary to create a new top level component and associate that component with a special route in src/router.js

Examples of this approach includes:

  • Event program editor: src/EditModel/event-program/EditEventProgram.component.js
  • Custom form editor: src/EditModel/EditDataEntryForm.component.js
Note that the project description data, including the texts, logos, images, and/or trademarks, for each open source project belongs to its rightful owner. If you wish to add or remove any projects, please contact us at [email protected].