cassproject 5.0.22 → 5.0.23
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/package.json +47 -50
- package/src/com/eduworks/ec/array/EcArray.js +1 -1
- package/src/com/eduworks/ec/array/EcAsyncHelper.js +1 -1
- package/src/com/eduworks/ec/array/EcObject.js +1 -1
- package/src/com/eduworks/ec/crypto/EcAes.js +1 -1
- package/src/com/eduworks/ec/crypto/EcAesCtrAsync.js +20 -22
- package/src/com/eduworks/ec/crypto/EcCrypto.js +8 -4
- package/src/com/eduworks/ec/crypto/EcPk.js +7 -7
- package/src/com/eduworks/ec/crypto/EcPpk.js +7 -7
- package/src/com/eduworks/ec/crypto/EcRsaOaepAsync.js +20 -19
- package/src/com/eduworks/ec/crypto/EcRsaOaepAsyncWorker.js +7 -6
- package/src/com/eduworks/ec/crypto/forgeAsyncNode.js +8 -8
- package/src/com/eduworks/ec/graph/EcDirectedGraph.js +1 -2
- package/src/com/eduworks/ec/graph/EcFrameworkGraph.js +18 -24
- package/src/com/eduworks/ec/promises/helpers.js +1 -3
- package/src/com/eduworks/ec/remote/EcRemote.js +9 -9
- package/src/com/eduworks/ec/task/EcAsyncTask.js +5 -20
- package/src/com/eduworks/ec/task/EcAsyncTaskManager.js +3 -4
- package/src/com/eduworks/ec/task/EcAsyncTaskWorker.js +9 -11
- package/src/com/eduworks/schema/cfd/competency/CfdFramework.js +36 -37
- package/src/com/eduworks/schema/ebac/EbacContact.js +3 -9
- package/src/com/eduworks/schema/ebac/EbacContactGrant.js +3 -9
- package/src/com/eduworks/schema/ebac/EbacCredential.js +3 -9
- package/src/com/eduworks/schema/ebac/EbacCredentialCommit.js +3 -9
- package/src/com/eduworks/schema/ebac/EbacCredentialRequest.js +3 -9
- package/src/com/eduworks/schema/ebac/EbacCredentials.js +3 -9
- package/src/com/eduworks/schema/ebac/EbacEncryptedSecret.js +3 -9
- package/src/com/eduworks/schema/ebac/EbacEncryptedValue.js +5 -12
- package/src/com/eduworks/schema/ebac/EbacSignature.js +1 -6
- package/src/index/env.js +6 -3
- package/src/index/polyfills.js +13 -27
- package/src/org/angles/schema/angles/VideoStory.js +1 -1
- package/src/org/cass/competency/EcCompetency.js +1 -2
- package/src/org/cass/competency/EcDirectory.js +1 -2
- package/src/org/cass/competency/EcFramework.js +9 -12
- package/src/org/cass/exporter/CSVExport.js +12 -13
- package/src/org/cass/importer/ASNImport.js +3 -6
- package/src/org/cass/importer/CSVImport.js +9 -17
- package/src/org/cass/importer/CTDLASNCSVConceptImport.js +25 -121
- package/src/org/cass/importer/CTDLASNCSVImport.js +88 -133
- package/src/org/cass/importer/FrameworkImport.js +16 -30
- package/src/org/cass/importer/MedbiqImport.js +3 -4
- package/src/org/cass/importer/TabStructuredImport.js +6 -6
- package/src/org/cass/profile/EcAssertion.js +40 -51
- package/src/org/cassproject/ebac/identity/EcContactGrant.js +2 -2
- package/src/org/cassproject/ebac/identity/EcIdentityManager.js +56 -62
- package/src/org/cassproject/ebac/identity/remote/EcRemoteIdentityManager.js +51 -62
- package/src/org/cassproject/ebac/identity/remote/OAuth2FileBasedRemoteIdentityManager.js +56 -70
- package/src/org/cassproject/ebac/identity/remote/RemoteIdentityManagerInterface.js +3 -3
- package/src/org/cassproject/ebac/repository/EcEncryptedValue.js +51 -44
- package/src/org/cassproject/ebac/repository/EcRepository.js +228 -301
- package/src/org/cassproject/general/repository/GeneralFile.js +8 -9
- package/src/org/cassproject/schema/cass/competency/Competency.js +10 -11
- package/src/org/cassproject/schema/cass/competency/Framework.js +10 -11
- package/src/org/cassproject/schema/cass/competency/Level.js +10 -11
- package/src/org/cassproject/schema/cass/competency/Relation.js +10 -11
- package/src/org/cassproject/schema/cass/competency/RollupRule.js +7 -7
- package/src/org/cassproject/schema/cass/profile/Assertion.js +20 -27
- package/src/org/cassproject/schema/cass/profile/AssertionEnvelope.js +3 -5
- package/src/org/cassproject/schema/general/EcRemoteLinkedData.js +41 -44
- package/src/org/json/ld/EcLinkedData.js +10 -12
- package/src/org/schema/EcOrganization.js +10 -10
- package/src/org/schema/EcQuestion.js +8 -8
- package/src/org/w3/skos/Concept.js +6 -6
- package/src/org/w3/skos/ConceptScheme.js +6 -6
- package/src/org/w3/skos/EcConcept.js +1 -2
- package/src/org/w3/skos/EcConceptScheme.js +1 -2
- package/src/test/0.start.test.js +1 -1
- package/src/test/0.testLibraries.test.js +172 -0
- package/src/test/1.ASNImport.test.js +122 -0
- package/src/test/1.CSVExport.test.js +57 -0
- package/src/test/1.CSVImport.test.js +185 -0
- package/src/test/1.CTDLASNCSVConceptImport.test.js +348 -0
- package/src/test/1.CTDLASNCSVImport.import.test.js +497 -0
- package/src/test/1.Ebac.schema.test.js +107 -0
- package/src/test/1.EcAssertion.decrypt.test.js +98 -0
- package/src/test/1.EcAssertion.pinned.test.js +160 -0
- package/src/test/1.EcCrypto.formats.test.js +293 -0
- package/src/test/1.EcCrypto.generateUUID.test.js +47 -0
- package/src/test/1.EcEncryptedValue.helpers.test.js +236 -0
- package/src/test/1.EcHelpers.misc.test.js +259 -0
- package/src/test/1.EcIdentityManager.keys.test.js +439 -0
- package/src/test/1.EcOrganization.rekey.test.js +68 -0
- package/src/test/1.EcRemote.responses.test.js +155 -0
- package/src/test/1.EcRemoteIdentityManager.flows.test.js +326 -0
- package/src/test/1.EcRemoteLinkedData.pinned.test.js +473 -0
- package/src/test/1.EcRepository.l0.test.js +14 -5
- package/src/test/1.EcRepository.l1.test.js +16 -7
- package/src/test/1.EcRepository.l2.test.js +20 -11
- package/src/test/1.EcRepository.unit.test.js +961 -0
- package/src/test/1.EcRsaOaep.test.js +2 -12
- package/src/test/1.EcRsaOaepAsync.test.js +2 -12
- package/src/test/1.EcRsaOaepAsyncWorker.test.js +2 -12
- package/src/test/1.EcRsaOaepAsyncWorker.workers.test.js +147 -0
- package/src/test/1.FrameworkImport.test.js +170 -0
- package/src/test/1.MedbiqImport.test.js +92 -0
- package/src/test/1.OAuth2FileBasedRemoteIdentityManager.test.js +399 -0
- package/src/test/1.TabStructuredImport.test.js +61 -0
- package/src/test/1.polyfills.test.js +89 -0
- package/src/test/1.schema.competency.pinned.test.js +384 -0
- package/src/test/3.EcFrameworkGraph.test.js +3 -2
- package/src/test/4.schema.test.js +33 -28
- package/src/test/4.skyId.test.js +4 -2
- package/src/test/cypressValue.js +9 -0
- package/src/test/2.EcCompetency.test.js +0 -17
package/src/index/polyfills.js
CHANGED
|
@@ -29,11 +29,6 @@ if (!String.prototype.endsWith) {
|
|
|
29
29
|
return this.substring(this.length - end.length, this.length) == end;
|
|
30
30
|
};
|
|
31
31
|
}
|
|
32
|
-
if (!String.prototype.trim) {
|
|
33
|
-
String.prototype.trim = function () {
|
|
34
|
-
return this.replace(/^\s+/, "").replace(/\s+$/, "");
|
|
35
|
-
};
|
|
36
|
-
}
|
|
37
32
|
if (!String.prototype.matches) {
|
|
38
33
|
String.prototype.matches = function (regexp) {
|
|
39
34
|
return this.match("^" + regexp + "$") != null;
|
|
@@ -127,65 +122,56 @@ let Short = Number;
|
|
|
127
122
|
/* type conversion - approximative as Javascript only has integers and doubles */
|
|
128
123
|
if (!Number.prototype.intValue) {
|
|
129
124
|
Number.prototype.intValue = function () {
|
|
130
|
-
return parseInt(this);
|
|
125
|
+
return Number.parseInt(this);
|
|
131
126
|
};
|
|
132
127
|
}
|
|
133
128
|
if (!Number.prototype.shortValue) {
|
|
134
129
|
Number.prototype.shortValue = function () {
|
|
135
|
-
return parseInt(this);
|
|
130
|
+
return Number.parseInt(this);
|
|
136
131
|
};
|
|
137
132
|
}
|
|
138
133
|
if (!Number.prototype.longValue) {
|
|
139
134
|
Number.prototype.longValue = function () {
|
|
140
|
-
return parseInt(this);
|
|
135
|
+
return Number.parseInt(this);
|
|
141
136
|
};
|
|
142
137
|
}
|
|
143
138
|
if (!Number.prototype.byteValue) {
|
|
144
139
|
Number.prototype.byteValue = function () {
|
|
145
|
-
return parseInt(this);
|
|
140
|
+
return Number.parseInt(this);
|
|
146
141
|
};
|
|
147
142
|
}
|
|
148
143
|
|
|
149
144
|
if (!Number.prototype.floatValue) {
|
|
150
145
|
Number.prototype.floatValue = function () {
|
|
151
|
-
return parseFloat(this);
|
|
146
|
+
return Number.parseFloat(this);
|
|
152
147
|
};
|
|
153
148
|
}
|
|
154
149
|
|
|
155
150
|
if (!Number.prototype.doubleValue) {
|
|
156
151
|
Number.prototype.doubleValue = function () {
|
|
157
|
-
return parseFloat(this);
|
|
152
|
+
return Number.parseFloat(this);
|
|
158
153
|
};
|
|
159
154
|
}
|
|
160
155
|
|
|
161
|
-
|
|
162
|
-
|
|
163
|
-
}
|
|
156
|
+
// Number.parseInt, Number.parseFloat, Number.isNaN and String.prototype.trim are
|
|
157
|
+
// built in to every engine this library runs on (ES2015+), so they need no polyfill.
|
|
164
158
|
if (!Number.parseShort) {
|
|
165
|
-
Number.parseShort = parseInt;
|
|
159
|
+
Number.parseShort = Number.parseInt;
|
|
166
160
|
}
|
|
167
161
|
if (!Number.parseLong) {
|
|
168
|
-
Number.parseLong = parseInt;
|
|
162
|
+
Number.parseLong = Number.parseInt;
|
|
169
163
|
}
|
|
170
164
|
if (!Number.parseByte) {
|
|
171
|
-
Number.parseByte = parseInt;
|
|
165
|
+
Number.parseByte = Number.parseInt;
|
|
172
166
|
}
|
|
173
167
|
|
|
174
168
|
if (!Number.parseDouble) {
|
|
175
|
-
Number.parseDouble = parseFloat;
|
|
176
|
-
}
|
|
177
|
-
|
|
178
|
-
if (!Number.parseFloat) {
|
|
179
|
-
Number.parseFloat = parseFloat;
|
|
180
|
-
}
|
|
181
|
-
|
|
182
|
-
if (!Number.isNaN) {
|
|
183
|
-
Number.isNaN = isNaN;
|
|
169
|
+
Number.parseDouble = Number.parseFloat;
|
|
184
170
|
}
|
|
185
171
|
|
|
186
172
|
if (!Number.prototype.isNaN) {
|
|
187
173
|
Number.prototype.isNaN = function () {
|
|
188
|
-
return isNaN(this);
|
|
174
|
+
return Number.isNaN(Number(this));
|
|
189
175
|
};
|
|
190
176
|
}
|
|
191
177
|
if (!Number.prototype.equals) {
|
|
@@ -9,7 +9,7 @@ module.exports = class VideoStory extends schema.VideoObject {
|
|
|
9
9
|
*/
|
|
10
10
|
constructor() {
|
|
11
11
|
super();
|
|
12
|
-
this.context = "http://schema.eduworks.com/angles/0.1/";
|
|
12
|
+
this.context = "http://schema.eduworks.com/angles/0.1/"; // NOSONAR - JSON-LD identifier, never fetched
|
|
13
13
|
this.type = "VideoStory";
|
|
14
14
|
}
|
|
15
15
|
/**
|
|
@@ -18,12 +18,11 @@ require("../../cassproject/general/AuditLogger.js");
|
|
|
18
18
|
module.exports = class EcCompetency extends Competency {
|
|
19
19
|
constructor() {
|
|
20
20
|
super();
|
|
21
|
-
let me = this;
|
|
22
21
|
if (EcCompetency.template != null) {
|
|
23
22
|
let you = EcCompetency.template;
|
|
24
23
|
for (let key in you) {
|
|
25
24
|
if (typeof you[key] != "function")
|
|
26
|
-
|
|
25
|
+
this[key.replace("@", "")] = you[key];
|
|
27
26
|
}
|
|
28
27
|
}
|
|
29
28
|
}
|
|
@@ -13,12 +13,11 @@ const Directory = require("../../cassproject/schema/cass/competency/Directory.js
|
|
|
13
13
|
module.exports = class EcDirectory extends Directory {
|
|
14
14
|
constructor() {
|
|
15
15
|
super();
|
|
16
|
-
let me = this;
|
|
17
16
|
if (EcDirectory.template != null) {
|
|
18
17
|
let you = EcDirectory.template;
|
|
19
18
|
for (let key in you) {
|
|
20
19
|
if (typeof you[key] != "function")
|
|
21
|
-
|
|
20
|
+
this[key.replace("@", "")] = you[key];
|
|
22
21
|
}
|
|
23
22
|
}
|
|
24
23
|
}
|
|
@@ -15,12 +15,11 @@ const EcRemoteLinkedData = require("../../cassproject/schema/general/EcRemoteLin
|
|
|
15
15
|
module.exports = class EcFramework extends Framework {
|
|
16
16
|
constructor() {
|
|
17
17
|
super();
|
|
18
|
-
let me = this;
|
|
19
18
|
if (EcFramework.template != null) {
|
|
20
19
|
let you = EcFramework.template;
|
|
21
20
|
for (let key in you) {
|
|
22
21
|
if (typeof you[key] != "function")
|
|
23
|
-
|
|
22
|
+
this[key.replace("@", "")] = you[key];
|
|
24
23
|
}
|
|
25
24
|
}
|
|
26
25
|
}
|
|
@@ -188,7 +187,6 @@ module.exports = class EcFramework extends Framework {
|
|
|
188
187
|
*/
|
|
189
188
|
removeRelationshipsThatInclude(id, i, success, failure, repo, eim) {
|
|
190
189
|
let shortId = EcRemoteLinkedData.trimVersionFromUrl(id);
|
|
191
|
-
let me = this;
|
|
192
190
|
if (i >= this.relation.length && success != null) success("");
|
|
193
191
|
else
|
|
194
192
|
return EcAlignment.get(
|
|
@@ -200,15 +198,15 @@ module.exports = class EcFramework extends Framework {
|
|
|
200
198
|
a.source == id ||
|
|
201
199
|
a.target == id
|
|
202
200
|
) {
|
|
203
|
-
|
|
204
|
-
await
|
|
201
|
+
this.relation.splice(i, 1);
|
|
202
|
+
await this.removeRelationshipsThatInclude(
|
|
205
203
|
id,
|
|
206
204
|
i,
|
|
207
205
|
success,
|
|
208
206
|
failure
|
|
209
207
|
);
|
|
210
208
|
} else
|
|
211
|
-
await
|
|
209
|
+
await this.removeRelationshipsThatInclude(
|
|
212
210
|
id,
|
|
213
211
|
i + 1,
|
|
214
212
|
success,
|
|
@@ -216,7 +214,7 @@ module.exports = class EcFramework extends Framework {
|
|
|
216
214
|
);
|
|
217
215
|
},
|
|
218
216
|
async(s) => {
|
|
219
|
-
await
|
|
217
|
+
await this.removeRelationshipsThatInclude(
|
|
220
218
|
id,
|
|
221
219
|
i + 1,
|
|
222
220
|
success,
|
|
@@ -242,22 +240,21 @@ module.exports = class EcFramework extends Framework {
|
|
|
242
240
|
*/
|
|
243
241
|
removeLevelsThatInclude(id, i, success, failure, repo, eim) {
|
|
244
242
|
let shortId = EcRemoteLinkedData.trimVersionFromUrl(id);
|
|
245
|
-
let me = this;
|
|
246
243
|
if (i >= this.level.length && success != null) success("");
|
|
247
244
|
else
|
|
248
245
|
return EcLevel.get(
|
|
249
246
|
this.level[i],
|
|
250
247
|
async(a) => {
|
|
251
248
|
if (a.competency == shortId || a.competency == id) {
|
|
252
|
-
|
|
253
|
-
await
|
|
249
|
+
this.level.splice(i, 1);
|
|
250
|
+
await this.removeLevelsThatInclude(
|
|
254
251
|
id,
|
|
255
252
|
i,
|
|
256
253
|
success,
|
|
257
254
|
failure
|
|
258
255
|
);
|
|
259
256
|
} else
|
|
260
|
-
await
|
|
257
|
+
await this.removeLevelsThatInclude(
|
|
261
258
|
id,
|
|
262
259
|
i + 1,
|
|
263
260
|
success,
|
|
@@ -265,7 +262,7 @@ module.exports = class EcFramework extends Framework {
|
|
|
265
262
|
);
|
|
266
263
|
},
|
|
267
264
|
async(s) => {
|
|
268
|
-
await
|
|
265
|
+
await this.removeLevelsThatInclude(
|
|
269
266
|
id,
|
|
270
267
|
i + 1,
|
|
271
268
|
success,
|
|
@@ -81,7 +81,8 @@ module.exports = class CSVExport extends Exporter {
|
|
|
81
81
|
if (fw.competency == null || fw.competency.length == 0)
|
|
82
82
|
failure("No Competencies in Framework");
|
|
83
83
|
for (let competencyUrl of fw.competency) {
|
|
84
|
-
|
|
84
|
+
//Results arrive through the callbacks; the promise is not needed.
|
|
85
|
+
void EcRepository.get(
|
|
85
86
|
competencyUrl,
|
|
86
87
|
function (competency) {
|
|
87
88
|
CSVExport.frameworkCompetencies.push(
|
|
@@ -119,7 +120,7 @@ module.exports = class CSVExport extends Exporter {
|
|
|
119
120
|
}, repo, eim);
|
|
120
121
|
}
|
|
121
122
|
for (let relationUrl of fw.relation) {
|
|
122
|
-
EcRepository.get(
|
|
123
|
+
void EcRepository.get(
|
|
123
124
|
relationUrl,
|
|
124
125
|
function (relation) {
|
|
125
126
|
CSVExport.frameworkRelations.push(relation);
|
|
@@ -202,17 +203,15 @@ module.exports = class CSVExport extends Exporter {
|
|
|
202
203
|
for (let prop3 in props2[prop2]) {
|
|
203
204
|
display += props2[prop2][prop3] + "|";
|
|
204
205
|
}
|
|
206
|
+
} else if (prop === 'ceterms:versionIdentifier') {
|
|
207
|
+
if (props2[prop2]['ceterms:identifierValueCode'])
|
|
208
|
+
display += props2[prop2]['ceterms:identifierValueCode'] + "~";
|
|
209
|
+
if (props2[prop2]['ceterms:identifierTypeName'])
|
|
210
|
+
display += Object.values(props2[prop2]['ceterms:identifierTypeName'])[0] + "~";
|
|
211
|
+
if (props2[prop2]['ceterms:identifierType'])
|
|
212
|
+
display += props2[prop2]['ceterms:identifierType'] + "|";
|
|
205
213
|
} else {
|
|
206
|
-
|
|
207
|
-
if (props2[prop2]['ceterms:identifierValueCode'])
|
|
208
|
-
display += props2[prop2]['ceterms:identifierValueCode'] + "~";
|
|
209
|
-
if (props2[prop2]['ceterms:identifierTypeName'])
|
|
210
|
-
display += Object.values(props2[prop2]['ceterms:identifierTypeName'])[0] + "~";
|
|
211
|
-
if (props2[prop2]['ceterms:identifierType'])
|
|
212
|
-
display += props2[prop2]['ceterms:identifierType'] + "|";
|
|
213
|
-
} else {
|
|
214
|
-
display += props2[prop2] + "|";
|
|
215
|
-
}
|
|
214
|
+
display += props2[prop2] + "|";
|
|
216
215
|
}
|
|
217
216
|
}
|
|
218
217
|
display = display.substring(0, display.length - 1);
|
|
@@ -242,7 +241,7 @@ module.exports = class CSVExport extends Exporter {
|
|
|
242
241
|
}
|
|
243
242
|
}
|
|
244
243
|
buildExport(objects, piped) {
|
|
245
|
-
for (let object of objects.filter(
|
|
244
|
+
for (let object of objects.filter(Boolean)) {
|
|
246
245
|
this.addCSVRow(object, piped);
|
|
247
246
|
}
|
|
248
247
|
}
|
|
@@ -258,10 +258,7 @@ module.exports = class ASNImport extends Importer {
|
|
|
258
258
|
];
|
|
259
259
|
comp.id = key;
|
|
260
260
|
if (comp.id == null) {
|
|
261
|
-
if (
|
|
262
|
-
repo == null ||
|
|
263
|
-
repo.selectedServer.indexOf(serverUrl) != -1
|
|
264
|
-
)
|
|
261
|
+
if (repo?.selectedServer.includes(serverUrl) ?? true)
|
|
265
262
|
comp.generateId(serverUrl);
|
|
266
263
|
else comp.generateShortId(serverUrl);
|
|
267
264
|
}
|
|
@@ -347,7 +344,7 @@ module.exports = class ASNImport extends Importer {
|
|
|
347
344
|
relation.relationType = "narrows";
|
|
348
345
|
relation.name = "";
|
|
349
346
|
relation.description = "";
|
|
350
|
-
if (repo
|
|
347
|
+
if (repo?.selectedServer.includes(serverUrl) ?? true)
|
|
351
348
|
relation.generateId(serverUrl);
|
|
352
349
|
else
|
|
353
350
|
relation.generateShortId(serverUrl);
|
|
@@ -424,7 +421,7 @@ module.exports = class ASNImport extends Importer {
|
|
|
424
421
|
ASNImport.importedFramework.description = ASNImport.jsonFramework["http://purl.org/dc/terms/description"]["0"]["value"];
|
|
425
422
|
ASNImport.importedFramework.id = ASNImport.frameworkUrl;
|
|
426
423
|
if (ASNImport.importedFramework.id == null) {
|
|
427
|
-
if (repo
|
|
424
|
+
if (repo?.selectedServer.includes(serverUrl) ?? true)
|
|
428
425
|
ASNImport.importedFramework.generateId(serverUrl);
|
|
429
426
|
else
|
|
430
427
|
ASNImport.importedFramework.generateShortId(serverUrl);
|
|
@@ -69,7 +69,7 @@ module.exports = class CSVImport {
|
|
|
69
69
|
if (
|
|
70
70
|
oldId == null ||
|
|
71
71
|
oldId == "" ||
|
|
72
|
-
oldId.toLowerCase().
|
|
72
|
+
!oldId.toLowerCase().includes("http")
|
|
73
73
|
)
|
|
74
74
|
newObject.assignId(selectedServer, oldId);
|
|
75
75
|
else {
|
|
@@ -182,7 +182,7 @@ module.exports = class CSVImport {
|
|
|
182
182
|
serverUrl,
|
|
183
183
|
repo
|
|
184
184
|
);
|
|
185
|
-
} else if (repo
|
|
185
|
+
} else if (repo?.selectedServer.includes(serverUrl) ?? true)
|
|
186
186
|
competency.generateId(serverUrl);
|
|
187
187
|
else
|
|
188
188
|
competency.generateShortId(serverUrl);
|
|
@@ -226,7 +226,7 @@ module.exports = class CSVImport {
|
|
|
226
226
|
name == null ||
|
|
227
227
|
name.trim() == "" ||
|
|
228
228
|
name.startsWith("@") ||
|
|
229
|
-
name.
|
|
229
|
+
name.includes(".") ||
|
|
230
230
|
tabularData[i][idx].trim() == "" ||
|
|
231
231
|
idx == nameIndex ||
|
|
232
232
|
idx == descriptionIndex ||
|
|
@@ -384,10 +384,7 @@ module.exports = class CSVImport {
|
|
|
384
384
|
else alignment.target = CSVImport.importCsvLookup[destKey];
|
|
385
385
|
alignment.relationType = relationTypeKey;
|
|
386
386
|
if (owner != null) alignment.addOwner(owner.ppk.toPk());
|
|
387
|
-
if (
|
|
388
|
-
repo == null ||
|
|
389
|
-
repo.selectedServer.indexOf(serverUrl) != -1
|
|
390
|
-
)
|
|
387
|
+
if (repo?.selectedServer.includes(serverUrl) ?? true)
|
|
391
388
|
alignment.generateId(serverUrl);
|
|
392
389
|
else alignment.generateShortId(serverUrl);
|
|
393
390
|
relations.push(alignment);
|
|
@@ -489,7 +486,7 @@ module.exports = class CSVImport {
|
|
|
489
486
|
if (
|
|
490
487
|
props[prop] == null ||
|
|
491
488
|
props[prop] == undefined ||
|
|
492
|
-
Object.toString.call(props[prop]).
|
|
489
|
+
!Object.toString.call(props[prop]).includes("String")
|
|
493
490
|
) {
|
|
494
491
|
if (EcObject.isObject(props[prop])) {
|
|
495
492
|
let nested = props[prop];
|
|
@@ -584,7 +581,7 @@ module.exports = class CSVImport {
|
|
|
584
581
|
idx == typeIdx
|
|
585
582
|
) {
|
|
586
583
|
continue;
|
|
587
|
-
} else if (name.
|
|
584
|
+
} else if (name.includes(".")) {
|
|
588
585
|
let split = name.split(".");
|
|
589
586
|
if (split.length > 1) {
|
|
590
587
|
let key = split[0];
|
|
@@ -623,14 +620,9 @@ module.exports = class CSVImport {
|
|
|
623
620
|
serverUrl,
|
|
624
621
|
repo
|
|
625
622
|
);
|
|
626
|
-
} else
|
|
627
|
-
|
|
628
|
-
|
|
629
|
-
repo.selectedServer.indexOf(serverUrl) != -1
|
|
630
|
-
)
|
|
631
|
-
data.generateId(serverUrl);
|
|
632
|
-
else data.generateShortId(serverUrl);
|
|
633
|
-
}
|
|
623
|
+
} else if (repo?.selectedServer.includes(serverUrl) ?? true)
|
|
624
|
+
data.generateId(serverUrl);
|
|
625
|
+
else data.generateShortId(serverUrl);
|
|
634
626
|
let shortId;
|
|
635
627
|
if (
|
|
636
628
|
idIndex != null &&
|