openchs-models 1.33.30 → 1.33.31
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/Schema.js +8 -1
- package/package.json +1 -1
package/dist/Schema.js
CHANGED
|
@@ -180,7 +180,7 @@ function createRealmConfig() {
|
|
|
180
180
|
return doCompact;
|
|
181
181
|
},
|
|
182
182
|
//order is important, should be arranged according to the dependency
|
|
183
|
-
schemaVersion:
|
|
183
|
+
schemaVersion: 208,
|
|
184
184
|
onMigration: function (oldDB, newDB) {
|
|
185
185
|
console.log("[AvniModels.Schema]", `Running migration with old schema version: ${oldDB.schemaVersion} and new schema version: ${newDB.schemaVersion}`);
|
|
186
186
|
if (oldDB.schemaVersion === VersionWithEmbeddedMigrationProblem) throw new Error(`Update from schema version ${VersionWithEmbeddedMigrationProblem} is not allowed. Please uninstall and install app.`);
|
|
@@ -776,6 +776,13 @@ function createRealmConfig() {
|
|
|
776
776
|
}
|
|
777
777
|
});
|
|
778
778
|
}
|
|
779
|
+
if (oldDB.schemaVersion < 208) {
|
|
780
|
+
_lodash.default.forEach(newDB.objects(_EntitySyncStatus.default.schema.name), ess => {
|
|
781
|
+
if (ess.entityName === 'ReportCard') {
|
|
782
|
+
ess.loadedSince = _EntitySyncStatus.default.REALLY_OLD_DATE;
|
|
783
|
+
}
|
|
784
|
+
});
|
|
785
|
+
}
|
|
779
786
|
if (oldDB.schemaVersion < 207) {
|
|
780
787
|
const now = new Date();
|
|
781
788
|
_lodash.default.forEach(newDB.objects("DraftEncounter"), draftEncounter => {
|