@ignos/api-client 20261110.361.1-alpha → 20261110.362.1-alpha
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/lib/ignosportal-api.d.ts +164 -136
- package/lib/ignosportal-api.js +102 -195
- package/package.json +1 -1
- package/src/ignosportal-api.ts +257 -323
package/lib/ignosportal-api.js
CHANGED
|
@@ -1354,8 +1354,9 @@ export class MachineUtilizationClient extends AuthorizedApiBase {
|
|
|
1354
1354
|
* @param favorites (optional)
|
|
1355
1355
|
* @param startTimeToday (optional) UTC offset for start of today's utilization is extracted from this value
|
|
1356
1356
|
* @param utcOffset (optional) Explicit UTC offset for start of today's utilization
|
|
1357
|
+
* @param assetExternalId (optional)
|
|
1357
1358
|
*/
|
|
1358
|
-
getMachineUtilizations(assetId, favorites, startTimeToday, utcOffset) {
|
|
1359
|
+
getMachineUtilizations(assetId, favorites, startTimeToday, utcOffset, assetExternalId) {
|
|
1359
1360
|
let url_ = this.baseUrl + "/machineutilization?";
|
|
1360
1361
|
if (assetId !== undefined && assetId !== null)
|
|
1361
1362
|
url_ += "assetId=" + encodeURIComponent("" + assetId) + "&";
|
|
@@ -1367,6 +1368,8 @@ export class MachineUtilizationClient extends AuthorizedApiBase {
|
|
|
1367
1368
|
url_ += "startTimeToday=" + encodeURIComponent(startTimeToday ? "" + startTimeToday.toISOString() : "") + "&";
|
|
1368
1369
|
if (utcOffset !== undefined && utcOffset !== null)
|
|
1369
1370
|
url_ += "utcOffset=" + encodeURIComponent("" + utcOffset) + "&";
|
|
1371
|
+
if (assetExternalId !== undefined && assetExternalId !== null)
|
|
1372
|
+
url_ += "assetExternalId=" + encodeURIComponent("" + assetExternalId) + "&";
|
|
1370
1373
|
url_ = url_.replace(/[?&]$/, "");
|
|
1371
1374
|
let options_ = {
|
|
1372
1375
|
method: "GET",
|
|
@@ -1814,8 +1817,9 @@ export class ResourceUtilizationClient extends AuthorizedApiBase {
|
|
|
1814
1817
|
* @param favorites (optional)
|
|
1815
1818
|
* @param startTimeToday (optional) UTC offset for start of today's utilization is extracted from this value
|
|
1816
1819
|
* @param utcOffset (optional) Explicit UTC offset for start of today's utilization
|
|
1820
|
+
* @param assetExternalId (optional)
|
|
1817
1821
|
*/
|
|
1818
|
-
getResourceUtilizations(assetId, favorites, startTimeToday, utcOffset) {
|
|
1822
|
+
getResourceUtilizations(assetId, favorites, startTimeToday, utcOffset, assetExternalId) {
|
|
1819
1823
|
let url_ = this.baseUrl + "/resourceutilization?";
|
|
1820
1824
|
if (assetId !== undefined && assetId !== null)
|
|
1821
1825
|
url_ += "assetId=" + encodeURIComponent("" + assetId) + "&";
|
|
@@ -1827,6 +1831,8 @@ export class ResourceUtilizationClient extends AuthorizedApiBase {
|
|
|
1827
1831
|
url_ += "startTimeToday=" + encodeURIComponent(startTimeToday ? "" + startTimeToday.toISOString() : "") + "&";
|
|
1828
1832
|
if (utcOffset !== undefined && utcOffset !== null)
|
|
1829
1833
|
url_ += "utcOffset=" + encodeURIComponent("" + utcOffset) + "&";
|
|
1834
|
+
if (assetExternalId !== undefined && assetExternalId !== null)
|
|
1835
|
+
url_ += "assetExternalId=" + encodeURIComponent("" + assetExternalId) + "&";
|
|
1830
1836
|
url_ = url_.replace(/[?&]$/, "");
|
|
1831
1837
|
let options_ = {
|
|
1832
1838
|
method: "GET",
|
|
@@ -2911,10 +2917,12 @@ export class SystemHealthDashboardClient extends AuthorizedApiBase {
|
|
|
2911
2917
|
this.http = http ? http : window;
|
|
2912
2918
|
this.baseUrl = baseUrl ?? "";
|
|
2913
2919
|
}
|
|
2914
|
-
getMachineDataHealth(assetId) {
|
|
2920
|
+
getMachineDataHealth(assetId, assetExternalId) {
|
|
2915
2921
|
let url_ = this.baseUrl + "/systemhealthdashboard?";
|
|
2916
2922
|
if (assetId !== undefined && assetId !== null)
|
|
2917
2923
|
url_ += "assetId=" + encodeURIComponent("" + assetId) + "&";
|
|
2924
|
+
if (assetExternalId !== undefined && assetExternalId !== null)
|
|
2925
|
+
url_ += "assetExternalId=" + encodeURIComponent("" + assetExternalId) + "&";
|
|
2918
2926
|
url_ = url_.replace(/[?&]$/, "");
|
|
2919
2927
|
let options_ = {
|
|
2920
2928
|
method: "GET",
|
|
@@ -3287,13 +3295,11 @@ export class MachineAlarmsClient extends AuthorizedApiBase {
|
|
|
3287
3295
|
this.http = http ? http : window;
|
|
3288
3296
|
this.baseUrl = baseUrl ?? "";
|
|
3289
3297
|
}
|
|
3290
|
-
listMachineAlarms(alarmType, assetId, startTime, endTime, subType, nativeCode, nativeSeverity, name, sequence, limit, continuationToken, orderBy, sortDirection) {
|
|
3298
|
+
listMachineAlarms(alarmType, assetId, startTime, endTime, subType, nativeCode, nativeSeverity, name, sequence, limit, continuationToken, orderBy, sortDirection, assetExternalId) {
|
|
3291
3299
|
let url_ = this.baseUrl + "/machinealarms?";
|
|
3292
3300
|
if (alarmType !== undefined && alarmType !== null)
|
|
3293
3301
|
url_ += "alarmType=" + encodeURIComponent("" + alarmType) + "&";
|
|
3294
|
-
if (assetId
|
|
3295
|
-
throw new globalThis.Error("The parameter 'assetId' cannot be null.");
|
|
3296
|
-
else if (assetId !== undefined)
|
|
3302
|
+
if (assetId !== undefined && assetId !== null)
|
|
3297
3303
|
url_ += "assetId=" + encodeURIComponent("" + assetId) + "&";
|
|
3298
3304
|
if (startTime === null)
|
|
3299
3305
|
throw new globalThis.Error("The parameter 'startTime' cannot be null.");
|
|
@@ -3321,6 +3327,8 @@ export class MachineAlarmsClient extends AuthorizedApiBase {
|
|
|
3321
3327
|
url_ += "orderBy=" + encodeURIComponent("" + orderBy) + "&";
|
|
3322
3328
|
if (sortDirection !== undefined && sortDirection !== null)
|
|
3323
3329
|
url_ += "sortDirection=" + encodeURIComponent("" + sortDirection) + "&";
|
|
3330
|
+
if (assetExternalId !== undefined && assetExternalId !== null)
|
|
3331
|
+
url_ += "assetExternalId=" + encodeURIComponent("" + assetExternalId) + "&";
|
|
3324
3332
|
url_ = url_.replace(/[?&]$/, "");
|
|
3325
3333
|
let options_ = {
|
|
3326
3334
|
method: "GET",
|
|
@@ -3478,13 +3486,11 @@ export class MachineAlarmsClient extends AuthorizedApiBase {
|
|
|
3478
3486
|
}
|
|
3479
3487
|
return Promise.resolve(null);
|
|
3480
3488
|
}
|
|
3481
|
-
countMachineAlarms(alarmType, assetId, startTime, endTime, subType, nativeCode, nativeSeverity, name, sequence) {
|
|
3489
|
+
countMachineAlarms(alarmType, assetId, startTime, endTime, subType, nativeCode, nativeSeverity, name, sequence, assetExternalId) {
|
|
3482
3490
|
let url_ = this.baseUrl + "/machinealarms/alarmcount?";
|
|
3483
3491
|
if (alarmType !== undefined && alarmType !== null)
|
|
3484
3492
|
url_ += "alarmType=" + encodeURIComponent("" + alarmType) + "&";
|
|
3485
|
-
if (assetId
|
|
3486
|
-
throw new globalThis.Error("The parameter 'assetId' cannot be null.");
|
|
3487
|
-
else if (assetId !== undefined)
|
|
3493
|
+
if (assetId !== undefined && assetId !== null)
|
|
3488
3494
|
url_ += "assetId=" + encodeURIComponent("" + assetId) + "&";
|
|
3489
3495
|
if (startTime === null)
|
|
3490
3496
|
throw new globalThis.Error("The parameter 'startTime' cannot be null.");
|
|
@@ -3502,6 +3508,8 @@ export class MachineAlarmsClient extends AuthorizedApiBase {
|
|
|
3502
3508
|
url_ += "name=" + encodeURIComponent("" + name) + "&";
|
|
3503
3509
|
if (sequence !== undefined && sequence !== null)
|
|
3504
3510
|
url_ += "sequence=" + encodeURIComponent("" + sequence) + "&";
|
|
3511
|
+
if (assetExternalId !== undefined && assetExternalId !== null)
|
|
3512
|
+
url_ += "assetExternalId=" + encodeURIComponent("" + assetExternalId) + "&";
|
|
3505
3513
|
url_ = url_.replace(/[?&]$/, "");
|
|
3506
3514
|
let options_ = {
|
|
3507
3515
|
method: "GET",
|
|
@@ -5315,10 +5323,12 @@ export class ResourcesClient extends AuthorizedApiBase {
|
|
|
5315
5323
|
}
|
|
5316
5324
|
return Promise.resolve(null);
|
|
5317
5325
|
}
|
|
5318
|
-
listCurrentMachineStates(assetId) {
|
|
5326
|
+
listCurrentMachineStates(assetId, assetExternalId) {
|
|
5319
5327
|
let url_ = this.baseUrl + "/resources/states/now?";
|
|
5320
5328
|
if (assetId !== undefined && assetId !== null)
|
|
5321
5329
|
url_ += "assetId=" + encodeURIComponent("" + assetId) + "&";
|
|
5330
|
+
if (assetExternalId !== undefined && assetExternalId !== null)
|
|
5331
|
+
url_ += "assetExternalId=" + encodeURIComponent("" + assetExternalId) + "&";
|
|
5322
5332
|
url_ = url_.replace(/[?&]$/, "");
|
|
5323
5333
|
let options_ = {
|
|
5324
5334
|
method: "GET",
|
|
@@ -6440,188 +6450,6 @@ export class PulseJournalClient extends AuthorizedApiBase {
|
|
|
6440
6450
|
}
|
|
6441
6451
|
return Promise.resolve(null);
|
|
6442
6452
|
}
|
|
6443
|
-
setNowLinePinned(resourceId, lineId, request) {
|
|
6444
|
-
let url_ = this.baseUrl + "/pulsejournal/{resourceId}/now/lines/{lineId}/pin";
|
|
6445
|
-
if (resourceId === undefined || resourceId === null)
|
|
6446
|
-
throw new globalThis.Error("The parameter 'resourceId' must be defined.");
|
|
6447
|
-
url_ = url_.replace("{resourceId}", encodeURIComponent("" + resourceId));
|
|
6448
|
-
if (lineId === undefined || lineId === null)
|
|
6449
|
-
throw new globalThis.Error("The parameter 'lineId' must be defined.");
|
|
6450
|
-
url_ = url_.replace("{lineId}", encodeURIComponent("" + lineId));
|
|
6451
|
-
url_ = url_.replace(/[?&]$/, "");
|
|
6452
|
-
const content_ = JSON.stringify(request);
|
|
6453
|
-
let options_ = {
|
|
6454
|
-
body: content_,
|
|
6455
|
-
method: "POST",
|
|
6456
|
-
headers: {
|
|
6457
|
-
"Content-Type": "application/json",
|
|
6458
|
-
"Accept": "application/json"
|
|
6459
|
-
}
|
|
6460
|
-
};
|
|
6461
|
-
return this.transformOptions(options_).then(transformedOptions_ => {
|
|
6462
|
-
return this.http.fetch(url_, transformedOptions_);
|
|
6463
|
-
}).then((_response) => {
|
|
6464
|
-
return this.processSetNowLinePinned(_response);
|
|
6465
|
-
});
|
|
6466
|
-
}
|
|
6467
|
-
processSetNowLinePinned(response) {
|
|
6468
|
-
const status = response.status;
|
|
6469
|
-
let _headers = {};
|
|
6470
|
-
if (response.headers && response.headers.forEach) {
|
|
6471
|
-
response.headers.forEach((v, k) => _headers[k] = v);
|
|
6472
|
-
}
|
|
6473
|
-
;
|
|
6474
|
-
if (status === 200) {
|
|
6475
|
-
return response.text().then((_responseText) => {
|
|
6476
|
-
let result200 = null;
|
|
6477
|
-
result200 = _responseText === "" ? null : JSON.parse(_responseText, this.jsonParseReviver);
|
|
6478
|
-
return result200;
|
|
6479
|
-
});
|
|
6480
|
-
}
|
|
6481
|
-
else if (status !== 200 && status !== 204) {
|
|
6482
|
-
return response.text().then((_responseText) => {
|
|
6483
|
-
return throwException("An unexpected server error occurred.", status, _responseText, _headers);
|
|
6484
|
-
});
|
|
6485
|
-
}
|
|
6486
|
-
return Promise.resolve(null);
|
|
6487
|
-
}
|
|
6488
|
-
setNowLineImportant(resourceId, lineId, request) {
|
|
6489
|
-
let url_ = this.baseUrl + "/pulsejournal/{resourceId}/now/lines/{lineId}/important";
|
|
6490
|
-
if (resourceId === undefined || resourceId === null)
|
|
6491
|
-
throw new globalThis.Error("The parameter 'resourceId' must be defined.");
|
|
6492
|
-
url_ = url_.replace("{resourceId}", encodeURIComponent("" + resourceId));
|
|
6493
|
-
if (lineId === undefined || lineId === null)
|
|
6494
|
-
throw new globalThis.Error("The parameter 'lineId' must be defined.");
|
|
6495
|
-
url_ = url_.replace("{lineId}", encodeURIComponent("" + lineId));
|
|
6496
|
-
url_ = url_.replace(/[?&]$/, "");
|
|
6497
|
-
const content_ = JSON.stringify(request);
|
|
6498
|
-
let options_ = {
|
|
6499
|
-
body: content_,
|
|
6500
|
-
method: "POST",
|
|
6501
|
-
headers: {
|
|
6502
|
-
"Content-Type": "application/json",
|
|
6503
|
-
"Accept": "application/json"
|
|
6504
|
-
}
|
|
6505
|
-
};
|
|
6506
|
-
return this.transformOptions(options_).then(transformedOptions_ => {
|
|
6507
|
-
return this.http.fetch(url_, transformedOptions_);
|
|
6508
|
-
}).then((_response) => {
|
|
6509
|
-
return this.processSetNowLineImportant(_response);
|
|
6510
|
-
});
|
|
6511
|
-
}
|
|
6512
|
-
processSetNowLineImportant(response) {
|
|
6513
|
-
const status = response.status;
|
|
6514
|
-
let _headers = {};
|
|
6515
|
-
if (response.headers && response.headers.forEach) {
|
|
6516
|
-
response.headers.forEach((v, k) => _headers[k] = v);
|
|
6517
|
-
}
|
|
6518
|
-
;
|
|
6519
|
-
if (status === 200) {
|
|
6520
|
-
return response.text().then((_responseText) => {
|
|
6521
|
-
let result200 = null;
|
|
6522
|
-
result200 = _responseText === "" ? null : JSON.parse(_responseText, this.jsonParseReviver);
|
|
6523
|
-
return result200;
|
|
6524
|
-
});
|
|
6525
|
-
}
|
|
6526
|
-
else if (status !== 200 && status !== 204) {
|
|
6527
|
-
return response.text().then((_responseText) => {
|
|
6528
|
-
return throwException("An unexpected server error occurred.", status, _responseText, _headers);
|
|
6529
|
-
});
|
|
6530
|
-
}
|
|
6531
|
-
return Promise.resolve(null);
|
|
6532
|
-
}
|
|
6533
|
-
addNowAttachment(resourceId, lineId, request) {
|
|
6534
|
-
let url_ = this.baseUrl + "/pulsejournal/{resourceId}/now/lines/{lineId}/attachments";
|
|
6535
|
-
if (resourceId === undefined || resourceId === null)
|
|
6536
|
-
throw new globalThis.Error("The parameter 'resourceId' must be defined.");
|
|
6537
|
-
url_ = url_.replace("{resourceId}", encodeURIComponent("" + resourceId));
|
|
6538
|
-
if (lineId === undefined || lineId === null)
|
|
6539
|
-
throw new globalThis.Error("The parameter 'lineId' must be defined.");
|
|
6540
|
-
url_ = url_.replace("{lineId}", encodeURIComponent("" + lineId));
|
|
6541
|
-
url_ = url_.replace(/[?&]$/, "");
|
|
6542
|
-
const content_ = JSON.stringify(request);
|
|
6543
|
-
let options_ = {
|
|
6544
|
-
body: content_,
|
|
6545
|
-
method: "POST",
|
|
6546
|
-
headers: {
|
|
6547
|
-
"Content-Type": "application/json",
|
|
6548
|
-
"Accept": "application/json"
|
|
6549
|
-
}
|
|
6550
|
-
};
|
|
6551
|
-
return this.transformOptions(options_).then(transformedOptions_ => {
|
|
6552
|
-
return this.http.fetch(url_, transformedOptions_);
|
|
6553
|
-
}).then((_response) => {
|
|
6554
|
-
return this.processAddNowAttachment(_response);
|
|
6555
|
-
});
|
|
6556
|
-
}
|
|
6557
|
-
processAddNowAttachment(response) {
|
|
6558
|
-
const status = response.status;
|
|
6559
|
-
let _headers = {};
|
|
6560
|
-
if (response.headers && response.headers.forEach) {
|
|
6561
|
-
response.headers.forEach((v, k) => _headers[k] = v);
|
|
6562
|
-
}
|
|
6563
|
-
;
|
|
6564
|
-
if (status === 200) {
|
|
6565
|
-
return response.text().then((_responseText) => {
|
|
6566
|
-
let result200 = null;
|
|
6567
|
-
result200 = _responseText === "" ? null : JSON.parse(_responseText, this.jsonParseReviver);
|
|
6568
|
-
return result200;
|
|
6569
|
-
});
|
|
6570
|
-
}
|
|
6571
|
-
else if (status !== 200 && status !== 204) {
|
|
6572
|
-
return response.text().then((_responseText) => {
|
|
6573
|
-
return throwException("An unexpected server error occurred.", status, _responseText, _headers);
|
|
6574
|
-
});
|
|
6575
|
-
}
|
|
6576
|
-
return Promise.resolve(null);
|
|
6577
|
-
}
|
|
6578
|
-
removeNowAttachment(resourceId, lineId, attachmentId, eTag) {
|
|
6579
|
-
let url_ = this.baseUrl + "/pulsejournal/{resourceId}/now/lines/{lineId}/attachments/{attachmentId}?";
|
|
6580
|
-
if (resourceId === undefined || resourceId === null)
|
|
6581
|
-
throw new globalThis.Error("The parameter 'resourceId' must be defined.");
|
|
6582
|
-
url_ = url_.replace("{resourceId}", encodeURIComponent("" + resourceId));
|
|
6583
|
-
if (lineId === undefined || lineId === null)
|
|
6584
|
-
throw new globalThis.Error("The parameter 'lineId' must be defined.");
|
|
6585
|
-
url_ = url_.replace("{lineId}", encodeURIComponent("" + lineId));
|
|
6586
|
-
if (attachmentId === undefined || attachmentId === null)
|
|
6587
|
-
throw new globalThis.Error("The parameter 'attachmentId' must be defined.");
|
|
6588
|
-
url_ = url_.replace("{attachmentId}", encodeURIComponent("" + attachmentId));
|
|
6589
|
-
if (eTag !== undefined && eTag !== null)
|
|
6590
|
-
url_ += "eTag=" + encodeURIComponent("" + eTag) + "&";
|
|
6591
|
-
url_ = url_.replace(/[?&]$/, "");
|
|
6592
|
-
let options_ = {
|
|
6593
|
-
method: "DELETE",
|
|
6594
|
-
headers: {
|
|
6595
|
-
"Accept": "application/json"
|
|
6596
|
-
}
|
|
6597
|
-
};
|
|
6598
|
-
return this.transformOptions(options_).then(transformedOptions_ => {
|
|
6599
|
-
return this.http.fetch(url_, transformedOptions_);
|
|
6600
|
-
}).then((_response) => {
|
|
6601
|
-
return this.processRemoveNowAttachment(_response);
|
|
6602
|
-
});
|
|
6603
|
-
}
|
|
6604
|
-
processRemoveNowAttachment(response) {
|
|
6605
|
-
const status = response.status;
|
|
6606
|
-
let _headers = {};
|
|
6607
|
-
if (response.headers && response.headers.forEach) {
|
|
6608
|
-
response.headers.forEach((v, k) => _headers[k] = v);
|
|
6609
|
-
}
|
|
6610
|
-
;
|
|
6611
|
-
if (status === 200) {
|
|
6612
|
-
return response.text().then((_responseText) => {
|
|
6613
|
-
let result200 = null;
|
|
6614
|
-
result200 = _responseText === "" ? null : JSON.parse(_responseText, this.jsonParseReviver);
|
|
6615
|
-
return result200;
|
|
6616
|
-
});
|
|
6617
|
-
}
|
|
6618
|
-
else if (status !== 200 && status !== 204) {
|
|
6619
|
-
return response.text().then((_responseText) => {
|
|
6620
|
-
return throwException("An unexpected server error occurred.", status, _responseText, _headers);
|
|
6621
|
-
});
|
|
6622
|
-
}
|
|
6623
|
-
return Promise.resolve(null);
|
|
6624
|
-
}
|
|
6625
6453
|
createAlwaysLine(resourceId, request) {
|
|
6626
6454
|
let url_ = this.baseUrl + "/pulsejournal/{resourceId}/always/lines";
|
|
6627
6455
|
if (resourceId === undefined || resourceId === null)
|
|
@@ -12200,10 +12028,12 @@ export class MachinesClient extends AuthorizedApiBase {
|
|
|
12200
12028
|
}
|
|
12201
12029
|
return Promise.resolve(null);
|
|
12202
12030
|
}
|
|
12203
|
-
listCurrentMachineStates(assetId) {
|
|
12031
|
+
listCurrentMachineStates(assetId, assetExternalId) {
|
|
12204
12032
|
let url_ = this.baseUrl + "/machines/states/now?";
|
|
12205
12033
|
if (assetId !== undefined && assetId !== null)
|
|
12206
12034
|
url_ += "assetId=" + encodeURIComponent("" + assetId) + "&";
|
|
12035
|
+
if (assetExternalId !== undefined && assetExternalId !== null)
|
|
12036
|
+
url_ += "assetExternalId=" + encodeURIComponent("" + assetExternalId) + "&";
|
|
12207
12037
|
url_ = url_.replace(/[?&]$/, "");
|
|
12208
12038
|
let options_ = {
|
|
12209
12039
|
method: "GET",
|
|
@@ -26328,6 +26158,44 @@ export class MeasurementFormSchemasAdminClient extends AuthorizedApiBase {
|
|
|
26328
26158
|
}
|
|
26329
26159
|
return Promise.resolve(null);
|
|
26330
26160
|
}
|
|
26161
|
+
deleteMeasurementFormSchemaFile(id, slot) {
|
|
26162
|
+
let url_ = this.baseUrl + "/measurementforms/schemas/{id}/files/{slot}";
|
|
26163
|
+
if (id === undefined || id === null)
|
|
26164
|
+
throw new globalThis.Error("The parameter 'id' must be defined.");
|
|
26165
|
+
url_ = url_.replace("{id}", encodeURIComponent("" + id));
|
|
26166
|
+
if (slot === undefined || slot === null)
|
|
26167
|
+
throw new globalThis.Error("The parameter 'slot' must be defined.");
|
|
26168
|
+
url_ = url_.replace("{slot}", encodeURIComponent("" + slot));
|
|
26169
|
+
url_ = url_.replace(/[?&]$/, "");
|
|
26170
|
+
let options_ = {
|
|
26171
|
+
method: "DELETE",
|
|
26172
|
+
headers: {}
|
|
26173
|
+
};
|
|
26174
|
+
return this.transformOptions(options_).then(transformedOptions_ => {
|
|
26175
|
+
return this.http.fetch(url_, transformedOptions_);
|
|
26176
|
+
}).then((_response) => {
|
|
26177
|
+
return this.processDeleteMeasurementFormSchemaFile(_response);
|
|
26178
|
+
});
|
|
26179
|
+
}
|
|
26180
|
+
processDeleteMeasurementFormSchemaFile(response) {
|
|
26181
|
+
const status = response.status;
|
|
26182
|
+
let _headers = {};
|
|
26183
|
+
if (response.headers && response.headers.forEach) {
|
|
26184
|
+
response.headers.forEach((v, k) => _headers[k] = v);
|
|
26185
|
+
}
|
|
26186
|
+
;
|
|
26187
|
+
if (status === 204) {
|
|
26188
|
+
return response.text().then((_responseText) => {
|
|
26189
|
+
return;
|
|
26190
|
+
});
|
|
26191
|
+
}
|
|
26192
|
+
else if (status !== 200 && status !== 204) {
|
|
26193
|
+
return response.text().then((_responseText) => {
|
|
26194
|
+
return throwException("An unexpected server error occurred.", status, _responseText, _headers);
|
|
26195
|
+
});
|
|
26196
|
+
}
|
|
26197
|
+
return Promise.resolve(null);
|
|
26198
|
+
}
|
|
26331
26199
|
getMeasurementFormImportStatus(id) {
|
|
26332
26200
|
let url_ = this.baseUrl + "/measurementforms/schemas/{id}/importstatus";
|
|
26333
26201
|
if (id === undefined || id === null)
|
|
@@ -28064,6 +27932,45 @@ export class MeasurementFormSchemasClient extends AuthorizedApiBase {
|
|
|
28064
27932
|
}
|
|
28065
27933
|
return Promise.resolve(null);
|
|
28066
27934
|
}
|
|
27935
|
+
listMeasurementFormSchemaFiles(id) {
|
|
27936
|
+
let url_ = this.baseUrl + "/measurementforms/schemas/{id}/files";
|
|
27937
|
+
if (id === undefined || id === null)
|
|
27938
|
+
throw new globalThis.Error("The parameter 'id' must be defined.");
|
|
27939
|
+
url_ = url_.replace("{id}", encodeURIComponent("" + id));
|
|
27940
|
+
url_ = url_.replace(/[?&]$/, "");
|
|
27941
|
+
let options_ = {
|
|
27942
|
+
method: "GET",
|
|
27943
|
+
headers: {
|
|
27944
|
+
"Accept": "application/json"
|
|
27945
|
+
}
|
|
27946
|
+
};
|
|
27947
|
+
return this.transformOptions(options_).then(transformedOptions_ => {
|
|
27948
|
+
return this.http.fetch(url_, transformedOptions_);
|
|
27949
|
+
}).then((_response) => {
|
|
27950
|
+
return this.processListMeasurementFormSchemaFiles(_response);
|
|
27951
|
+
});
|
|
27952
|
+
}
|
|
27953
|
+
processListMeasurementFormSchemaFiles(response) {
|
|
27954
|
+
const status = response.status;
|
|
27955
|
+
let _headers = {};
|
|
27956
|
+
if (response.headers && response.headers.forEach) {
|
|
27957
|
+
response.headers.forEach((v, k) => _headers[k] = v);
|
|
27958
|
+
}
|
|
27959
|
+
;
|
|
27960
|
+
if (status === 200) {
|
|
27961
|
+
return response.text().then((_responseText) => {
|
|
27962
|
+
let result200 = null;
|
|
27963
|
+
result200 = _responseText === "" ? null : JSON.parse(_responseText, this.jsonParseReviver);
|
|
27964
|
+
return result200;
|
|
27965
|
+
});
|
|
27966
|
+
}
|
|
27967
|
+
else if (status !== 200 && status !== 204) {
|
|
27968
|
+
return response.text().then((_responseText) => {
|
|
27969
|
+
return throwException("An unexpected server error occurred.", status, _responseText, _headers);
|
|
27970
|
+
});
|
|
27971
|
+
}
|
|
27972
|
+
return Promise.resolve(null);
|
|
27973
|
+
}
|
|
28067
27974
|
listMeasurementFormSchemaVersions(id) {
|
|
28068
27975
|
let url_ = this.baseUrl + "/measurementforms/schemas/{id}/versions";
|
|
28069
27976
|
if (id === undefined || id === null)
|