Replies: 2 comments 2 replies
-
Thanks for putting this together! I argue that it might be cleaner for nested object-references to just be an array of the ids. Eg. "dataSets": [{
"id": "lyLU2wR22tC",
"name": "ART",
"more": "fields here",
"dataSetElements": [{
"dataElement": "ofSrFzA676u"
}],
"sections": ["yzIGHd4A54j"],
"organisationUnits": ["rLeYbuFiIC0"]
}] Note that embedded-objects would of course still need the objects. This way we save some data that is unnecessary since these references will just contain ID's anyway. This is how we are currently getting the metadata, using the |
Beta Was this translation helpful? Give feedback.
-
The data that's needed in the context selection is:
|
Beta Was this translation helpful? Give feedback.
-
Context
The new data entry application needs to retrieve an extensive set of metadata on page load. Load time and network usage are of great importance as users are often on slow lines with prepaid data plans, and there could a huge amount of metadata. It is critical that the app only loads the necessary metadata and avoids loading metadata it does not need.
Endpoint
A new metadata endpoint dedicated for the data entry app should be created. The response should basically contain all the data sets for which the current user has data read sharing access to, and then metadata which are associated with the data sets. All metadata entities should be placed at the first level of the JSON response, and references between the objects should be done by ID (UID).
To summarize:
Metadata:
Format
The proposed format looks like this:
Questions
Beta Was this translation helpful? Give feedback.
All reactions