Need
Goonj org needs its Avni source entities, Address Text fields to be in "StartCase".
We have implemented the logic as Decision rule for each of those Entity Types.
This works as expected in Avni-client,for all entity types.
It works fine for Activity on DEA.
But, for Distribution entityType, decisionRule exection on rules-server fails, with following error-stack-trace.
rulesController catchRuleError TypeError: Cannot read property 'name' of undefined
at Function.fromResource (/opt/rules-server/node_modules/openchs-models/dist/Concept.js:121:36)
at Function.constructConceptModel (/opt/rules-server/node_modules/openchs-models/dist/observation/QuestionGroup.js:63:38)
at _lodash.default.map (/opt/rules-server/node_modules/openchs-models/dist/observation/QuestionGroup.js:52:43)
at arrayMap (/opt/rules-server/node_modules/lodash/lodash.js:639:23)
at Function.map (/opt/rules-server/node_modules/lodash/lodash.js:9554:14)
at Function.fromObs (/opt/rules-server/node_modules/openchs-models/dist/observation/QuestionGroup.js:47:36)
at Concept.getValueWrapperFor (/opt/rules-server/node_modules/openchs-models/dist/Concept.js:247:129)
at mapObservation (/opt/rules-server/src/models/observationModel.js:74:56)
at /opt/rules-server/src/models/observationModel.js:12:20
at Array.map (<anonymous>)
Additional info
Complex elements used in Distribution entity are:
AC
- Decision rule execution for Distribution Entity Type of Goonj works as expected.
Need
Goonj org needs its Avni source entities, Address Text fields to be in "StartCase".
We have implemented the logic as Decision rule for each of those Entity Types.
This works as expected in Avni-client,for all entity types.
It works fine for Activity on DEA.
But, for Distribution entityType, decisionRule exection on rules-server fails, with following error-stack-trace.
Additional info
Complex elements used in Distribution entity are:
AC