openchs-models 1.32.24 → 1.32.26
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/Concept.js +3 -2
- package/dist/Schema.js +7 -1
- package/dist/application/FormElement.js +1 -2
- package/dist/index.js +8 -0
- package/package.json +1 -1
package/dist/Concept.js
CHANGED
|
@@ -267,7 +267,7 @@ class Concept extends _BaseEntity.default {
|
|
|
267
267
|
}
|
|
268
268
|
|
|
269
269
|
isMediaConcept() {
|
|
270
|
-
return _lodash.default.includes([Concept.dataType.Image, Concept.dataType.Video, Concept.dataType.File], this.datatype);
|
|
270
|
+
return _lodash.default.includes([Concept.dataType.Image, Concept.dataType.ImageV2, Concept.dataType.Video, Concept.dataType.File], this.datatype);
|
|
271
271
|
}
|
|
272
272
|
|
|
273
273
|
isSelectConcept() {
|
|
@@ -406,6 +406,7 @@ _defineProperty(Concept, "dataType", {
|
|
|
406
406
|
Notes: "Notes",
|
|
407
407
|
NA: "NA",
|
|
408
408
|
Image: "Image",
|
|
409
|
+
ImageV2: "ImageV2",
|
|
409
410
|
Video: "Video",
|
|
410
411
|
Audio: "Audio",
|
|
411
412
|
Id: "Id",
|
|
@@ -418,7 +419,7 @@ _defineProperty(Concept, "dataType", {
|
|
|
418
419
|
Encounter: "Encounter",
|
|
419
420
|
|
|
420
421
|
get Media() {
|
|
421
|
-
return [this.Image, this.Video, this.Audio, this.File];
|
|
422
|
+
return [this.Image, this.ImageV2, this.Video, this.Audio, this.File];
|
|
422
423
|
}
|
|
423
424
|
|
|
424
425
|
});
|
package/dist/Schema.js
CHANGED
|
@@ -283,7 +283,7 @@ function createRealmConfig() {
|
|
|
283
283
|
return doCompact;
|
|
284
284
|
},
|
|
285
285
|
//order is important, should be arranged according to the dependency
|
|
286
|
-
schemaVersion:
|
|
286
|
+
schemaVersion: 199,
|
|
287
287
|
onMigration: function (oldDB, newDB) {
|
|
288
288
|
console.log("[AvniModels.Schema]", `Running migration with old schema version: ${oldDB.schemaVersion} and new schema version: ${newDB.schemaVersion}`);
|
|
289
289
|
if (oldDB.schemaVersion === VersionWithEmbeddedMigrationProblem) throw new Error(`Update from schema version ${VersionWithEmbeddedMigrationProblem} is not allowed. Please uninstall and install app.`);
|
|
@@ -965,6 +965,12 @@ function createRealmConfig() {
|
|
|
965
965
|
}
|
|
966
966
|
}
|
|
967
967
|
}
|
|
968
|
+
|
|
969
|
+
if (oldDB.schemaVersion < 199) {
|
|
970
|
+
_lodash.default.forEach(newDB.objects("Program"), program => {
|
|
971
|
+
program.showGrowthChart = _lodash.default.toLower(program.name) === "child";
|
|
972
|
+
});
|
|
973
|
+
}
|
|
968
974
|
}
|
|
969
975
|
};
|
|
970
976
|
}
|
|
@@ -478,8 +478,7 @@ _defineProperty(FormElement, "keys", {
|
|
|
478
478
|
groupSubjectRoleUUID: "groupSubjectRoleUUID",
|
|
479
479
|
allowedTypes: "allowedTypes",
|
|
480
480
|
allowedMaxSize: "allowedMaxSize",
|
|
481
|
-
displayAllGroupMembers: "displayAllGroupMembers"
|
|
482
|
-
searchOptions: "searchOptions"
|
|
481
|
+
displayAllGroupMembers: "displayAllGroupMembers"
|
|
483
482
|
});
|
|
484
483
|
|
|
485
484
|
_defineProperty(FormElement, "values", {
|
package/dist/index.js
CHANGED
|
@@ -165,6 +165,12 @@ Object.defineProperty(exports, "FormMapping", {
|
|
|
165
165
|
return _FormMapping.default;
|
|
166
166
|
}
|
|
167
167
|
});
|
|
168
|
+
Object.defineProperty(exports, "findMediaObservations", {
|
|
169
|
+
enumerable: true,
|
|
170
|
+
get: function () {
|
|
171
|
+
return _Media.findMediaObservations;
|
|
172
|
+
}
|
|
173
|
+
});
|
|
168
174
|
Object.defineProperty(exports, "MenuItem", {
|
|
169
175
|
enumerable: true,
|
|
170
176
|
get: function () {
|
|
@@ -864,6 +870,8 @@ var _Form = _interopRequireDefault(require("./application/Form"));
|
|
|
864
870
|
|
|
865
871
|
var _FormMapping = _interopRequireDefault(require("./application/FormMapping"));
|
|
866
872
|
|
|
873
|
+
var _Media = require("./Media");
|
|
874
|
+
|
|
867
875
|
var _MenuItem = _interopRequireDefault(require("./application/MenuItem"));
|
|
868
876
|
|
|
869
877
|
var _Gender = _interopRequireDefault(require("./Gender"));
|