@ignos/api-client 20260521.133.1 → 20260527.135.1
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 +52 -61
- package/lib/ignosportal-api.js +40 -47
- package/package.json +1 -1
- package/src/ignosportal-api.ts +96 -110
package/lib/ignosportal-api.d.ts
CHANGED
|
@@ -598,6 +598,16 @@ export interface IKpiAdminResourceClient {
|
|
|
598
598
|
updateCalendarCapacityAdmin(request: UpdateCalendarCapacity): Promise<CalendarCapacityDto>;
|
|
599
599
|
getCalendarSettings(): Promise<CalendarSettingsDto>;
|
|
600
600
|
updateCalendarSettings(cmd: UpdateCalendarSettingsCommand): Promise<CalendarSettingsDto>;
|
|
601
|
+
listShiftPlans(): Promise<ShiftPlansDto>;
|
|
602
|
+
createShiftPlan(request: CreateShiftPlan): Promise<ShiftPlanDto>;
|
|
603
|
+
updateShiftPlan(id: string, request: UpdateShiftPlanRequest): Promise<ShiftPlanDto>;
|
|
604
|
+
deleteShiftPlan(id: string): Promise<void>;
|
|
605
|
+
listShiftSettingPeriods(): Promise<ShiftSettingsDto>;
|
|
606
|
+
addShiftSettingPeriods(request: AddShiftSettingPeriods): Promise<ShiftSettingsPeriodDto[]>;
|
|
607
|
+
deleteShiftSettingPeriods(request: DeleteShiftSettingsPeriod): Promise<FileResponse>;
|
|
608
|
+
updateShiftSettingsPeriod(resourceExternalId: string, effectiveFrom: string, request: UpdateShiftSettingsPeriodRequest): Promise<ShiftSettingsPeriodDto>;
|
|
609
|
+
copyShiftSettingsPeriod(sourceResourceExternalId: string, sourceEffectiveFrom: string, request: CopyShiftSettingsPeriodRequest): Promise<ShiftSettingsPeriodDto>;
|
|
610
|
+
migrateCapacityToSettings(): Promise<MigrationResultDto>;
|
|
601
611
|
}
|
|
602
612
|
export declare class KpiAdminResourceClient extends AuthorizedApiBase implements IKpiAdminResourceClient {
|
|
603
613
|
private http;
|
|
@@ -617,45 +627,26 @@ export declare class KpiAdminResourceClient extends AuthorizedApiBase implements
|
|
|
617
627
|
protected processGetCalendarSettings(response: Response): Promise<CalendarSettingsDto>;
|
|
618
628
|
updateCalendarSettings(cmd: UpdateCalendarSettingsCommand): Promise<CalendarSettingsDto>;
|
|
619
629
|
protected processUpdateCalendarSettings(response: Response): Promise<CalendarSettingsDto>;
|
|
620
|
-
|
|
621
|
-
|
|
622
|
-
|
|
623
|
-
|
|
624
|
-
|
|
625
|
-
|
|
626
|
-
|
|
627
|
-
|
|
628
|
-
|
|
629
|
-
|
|
630
|
-
|
|
631
|
-
|
|
632
|
-
|
|
633
|
-
|
|
634
|
-
|
|
635
|
-
|
|
636
|
-
|
|
637
|
-
|
|
638
|
-
|
|
639
|
-
|
|
640
|
-
protected processListCalendarDefinitions(response: Response): Promise<CalendarDefinitionsDto>;
|
|
641
|
-
createCalendarDefinition(request: CreateCalendarDefinition): Promise<CalendarDefinitionDto>;
|
|
642
|
-
protected processCreateCalendarDefinition(response: Response): Promise<CalendarDefinitionDto>;
|
|
643
|
-
updateCalendarDefinition(id: string, request: UpdateCalendarDefinitionRequest): Promise<CalendarDefinitionDto>;
|
|
644
|
-
protected processUpdateCalendarDefinition(response: Response): Promise<CalendarDefinitionDto>;
|
|
645
|
-
deleteCalendarDefinition(id: string): Promise<void>;
|
|
646
|
-
protected processDeleteCalendarDefinition(response: Response): Promise<void>;
|
|
647
|
-
listResourceCalendarPeriods(): Promise<ResourceCalendarPeriodSchedulesDto>;
|
|
648
|
-
protected processListResourceCalendarPeriods(response: Response): Promise<ResourceCalendarPeriodSchedulesDto>;
|
|
649
|
-
addResourceCalendarPeriods(request: AddResourceCalendarPeriod): Promise<ResourceCalendarPeriodDto[]>;
|
|
650
|
-
protected processAddResourceCalendarPeriods(response: Response): Promise<ResourceCalendarPeriodDto[]>;
|
|
651
|
-
deleteResourceCalendarPeriods(request: DeleteResourceCalendarPeriod): Promise<FileResponse>;
|
|
652
|
-
protected processDeleteResourceCalendarPeriods(response: Response): Promise<FileResponse>;
|
|
653
|
-
updateResourceCalendarPeriod(resourceExternalId: string, effectiveFrom: string, request: UpdateResourceCalendarPeriodRequest): Promise<ResourceCalendarPeriodDto>;
|
|
654
|
-
protected processUpdateResourceCalendarPeriod(response: Response): Promise<ResourceCalendarPeriodDto>;
|
|
655
|
-
copyResourceCalendarPeriod(sourceResourceExternalId: string, sourceEffectiveFrom: string, request: CopyResourceCalendarPeriodRequest): Promise<ResourceCalendarPeriodDto>;
|
|
656
|
-
protected processCopyResourceCalendarPeriod(response: Response): Promise<ResourceCalendarPeriodDto>;
|
|
657
|
-
migrateCapacityToSchedules(): Promise<MigrationResultDto>;
|
|
658
|
-
protected processMigrateCapacityToSchedules(response: Response): Promise<MigrationResultDto>;
|
|
630
|
+
listShiftPlans(): Promise<ShiftPlansDto>;
|
|
631
|
+
protected processListShiftPlans(response: Response): Promise<ShiftPlansDto>;
|
|
632
|
+
createShiftPlan(request: CreateShiftPlan): Promise<ShiftPlanDto>;
|
|
633
|
+
protected processCreateShiftPlan(response: Response): Promise<ShiftPlanDto>;
|
|
634
|
+
updateShiftPlan(id: string, request: UpdateShiftPlanRequest): Promise<ShiftPlanDto>;
|
|
635
|
+
protected processUpdateShiftPlan(response: Response): Promise<ShiftPlanDto>;
|
|
636
|
+
deleteShiftPlan(id: string): Promise<void>;
|
|
637
|
+
protected processDeleteShiftPlan(response: Response): Promise<void>;
|
|
638
|
+
listShiftSettingPeriods(): Promise<ShiftSettingsDto>;
|
|
639
|
+
protected processListShiftSettingPeriods(response: Response): Promise<ShiftSettingsDto>;
|
|
640
|
+
addShiftSettingPeriods(request: AddShiftSettingPeriods): Promise<ShiftSettingsPeriodDto[]>;
|
|
641
|
+
protected processAddShiftSettingPeriods(response: Response): Promise<ShiftSettingsPeriodDto[]>;
|
|
642
|
+
deleteShiftSettingPeriods(request: DeleteShiftSettingsPeriod): Promise<FileResponse>;
|
|
643
|
+
protected processDeleteShiftSettingPeriods(response: Response): Promise<FileResponse>;
|
|
644
|
+
updateShiftSettingsPeriod(resourceExternalId: string, effectiveFrom: string, request: UpdateShiftSettingsPeriodRequest): Promise<ShiftSettingsPeriodDto>;
|
|
645
|
+
protected processUpdateShiftSettingsPeriod(response: Response): Promise<ShiftSettingsPeriodDto>;
|
|
646
|
+
copyShiftSettingsPeriod(sourceResourceExternalId: string, sourceEffectiveFrom: string, request: CopyShiftSettingsPeriodRequest): Promise<ShiftSettingsPeriodDto>;
|
|
647
|
+
protected processCopyShiftSettingsPeriod(response: Response): Promise<ShiftSettingsPeriodDto>;
|
|
648
|
+
migrateCapacityToSettings(): Promise<MigrationResultDto>;
|
|
649
|
+
protected processMigrateCapacityToSettings(response: Response): Promise<MigrationResultDto>;
|
|
659
650
|
}
|
|
660
651
|
export interface IKpiResourceClient {
|
|
661
652
|
getResourceKpi(resourceExternalId: string | undefined, previousPeriodStartDate: Date | undefined, startDate: Date | undefined, endDate: Date | undefined, utcOffset: number | undefined): Promise<ResourceKpiDto>;
|
|
@@ -4162,11 +4153,11 @@ export interface UpdateCalendarSettingsCommand {
|
|
|
4162
4153
|
holidayHours?: number;
|
|
4163
4154
|
defaultPerformancePercent?: number | null;
|
|
4164
4155
|
}
|
|
4165
|
-
export interface
|
|
4166
|
-
active:
|
|
4167
|
-
archived:
|
|
4156
|
+
export interface ShiftPlansDto {
|
|
4157
|
+
active: ShiftPlanDto[];
|
|
4158
|
+
archived: ShiftPlanDto[];
|
|
4168
4159
|
}
|
|
4169
|
-
export interface
|
|
4160
|
+
export interface ShiftPlanDto {
|
|
4170
4161
|
id: string;
|
|
4171
4162
|
name: string;
|
|
4172
4163
|
hoursPerWeekday: {
|
|
@@ -4176,62 +4167,62 @@ export interface CalendarDefinitionDto {
|
|
|
4176
4167
|
updatedBy?: string | null;
|
|
4177
4168
|
isArchived?: boolean;
|
|
4178
4169
|
}
|
|
4179
|
-
export interface
|
|
4170
|
+
export interface CreateShiftPlan {
|
|
4180
4171
|
name: string;
|
|
4181
4172
|
hoursPerWeekday: {
|
|
4182
4173
|
[key in DayOfWeek]?: number;
|
|
4183
4174
|
};
|
|
4184
4175
|
}
|
|
4185
|
-
export interface
|
|
4176
|
+
export interface UpdateShiftPlanRequest {
|
|
4186
4177
|
name?: string | null;
|
|
4187
4178
|
hoursPerWeekday?: {
|
|
4188
4179
|
[key in DayOfWeek]?: number;
|
|
4189
4180
|
} | null;
|
|
4190
4181
|
unarchive?: boolean | null;
|
|
4191
4182
|
}
|
|
4192
|
-
export interface
|
|
4193
|
-
groups:
|
|
4194
|
-
ungroupedResources:
|
|
4183
|
+
export interface ShiftSettingsDto {
|
|
4184
|
+
groups: ShiftSettingsPeriodGroupDto[];
|
|
4185
|
+
ungroupedResources: ShiftSettingPeriodsDto[];
|
|
4195
4186
|
}
|
|
4196
|
-
export interface
|
|
4187
|
+
export interface ShiftSettingsPeriodGroupDto {
|
|
4197
4188
|
resourceGroupName: string;
|
|
4198
|
-
resources:
|
|
4189
|
+
resources: ShiftSettingPeriodsDto[];
|
|
4199
4190
|
}
|
|
4200
|
-
export interface
|
|
4191
|
+
export interface ShiftSettingPeriodsDto {
|
|
4201
4192
|
resourceExternalId: string;
|
|
4202
4193
|
resourceName: string;
|
|
4203
|
-
periods:
|
|
4194
|
+
periods: ShiftSettingsPeriodDto[];
|
|
4204
4195
|
}
|
|
4205
|
-
export interface
|
|
4196
|
+
export interface ShiftSettingsPeriodDto {
|
|
4206
4197
|
resourceExternalId: string;
|
|
4207
|
-
|
|
4208
|
-
|
|
4198
|
+
shiftPlanId: string;
|
|
4199
|
+
shiftPlanName: string;
|
|
4209
4200
|
effectiveFrom: string;
|
|
4210
4201
|
effectiveTo?: string | null;
|
|
4211
4202
|
targetPercent: number;
|
|
4212
4203
|
comment?: string | null;
|
|
4213
4204
|
}
|
|
4214
|
-
export interface
|
|
4205
|
+
export interface AddShiftSettingPeriods {
|
|
4215
4206
|
resourceExternalIds: string[];
|
|
4216
|
-
|
|
4207
|
+
shiftPlanId: string;
|
|
4217
4208
|
effectiveFrom: string;
|
|
4218
4209
|
targetPercent: number;
|
|
4219
4210
|
comment?: string | null;
|
|
4220
4211
|
}
|
|
4221
|
-
export interface
|
|
4222
|
-
|
|
4212
|
+
export interface UpdateShiftSettingsPeriodRequest {
|
|
4213
|
+
shiftPlanId?: string | null;
|
|
4223
4214
|
targetPercent?: number | null;
|
|
4224
4215
|
newEffectiveFrom?: string | null;
|
|
4225
4216
|
comment?: string | null;
|
|
4226
4217
|
}
|
|
4227
|
-
export interface
|
|
4218
|
+
export interface DeleteShiftSettingsPeriod {
|
|
4228
4219
|
periods: PeriodKey[];
|
|
4229
4220
|
}
|
|
4230
4221
|
export interface PeriodKey {
|
|
4231
4222
|
resourceExternalId: string;
|
|
4232
4223
|
effectiveFrom: string;
|
|
4233
4224
|
}
|
|
4234
|
-
export interface
|
|
4225
|
+
export interface CopyShiftSettingsPeriodRequest {
|
|
4235
4226
|
targetResourceExternalId: string;
|
|
4236
4227
|
effectiveFrom: string;
|
|
4237
4228
|
}
|
package/lib/ignosportal-api.js
CHANGED
|
@@ -4515,15 +4515,8 @@ export class KpiAdminResourceClient extends AuthorizedApiBase {
|
|
|
4515
4515
|
}
|
|
4516
4516
|
return Promise.resolve(null);
|
|
4517
4517
|
}
|
|
4518
|
-
|
|
4519
|
-
|
|
4520
|
-
constructor(configuration, baseUrl, http) {
|
|
4521
|
-
super(configuration);
|
|
4522
|
-
this.http = http ? http : window;
|
|
4523
|
-
this.baseUrl = baseUrl !== null && baseUrl !== void 0 ? baseUrl : "";
|
|
4524
|
-
}
|
|
4525
|
-
listCalendarDefinitions() {
|
|
4526
|
-
let url_ = this.baseUrl + "/resources/kpi/calendar-definitions";
|
|
4518
|
+
listShiftPlans() {
|
|
4519
|
+
let url_ = this.baseUrl + "/kpiadminresource/shift-plans";
|
|
4527
4520
|
url_ = url_.replace(/[?&]$/, "");
|
|
4528
4521
|
let options_ = {
|
|
4529
4522
|
method: "GET",
|
|
@@ -4534,10 +4527,10 @@ export class KpiCalendarClient extends AuthorizedApiBase {
|
|
|
4534
4527
|
return this.transformOptions(options_).then(transformedOptions_ => {
|
|
4535
4528
|
return this.http.fetch(url_, transformedOptions_);
|
|
4536
4529
|
}).then((_response) => {
|
|
4537
|
-
return this.
|
|
4530
|
+
return this.processListShiftPlans(_response);
|
|
4538
4531
|
});
|
|
4539
4532
|
}
|
|
4540
|
-
|
|
4533
|
+
processListShiftPlans(response) {
|
|
4541
4534
|
const status = response.status;
|
|
4542
4535
|
let _headers = {};
|
|
4543
4536
|
if (response.headers && response.headers.forEach) {
|
|
@@ -4558,8 +4551,8 @@ export class KpiCalendarClient extends AuthorizedApiBase {
|
|
|
4558
4551
|
}
|
|
4559
4552
|
return Promise.resolve(null);
|
|
4560
4553
|
}
|
|
4561
|
-
|
|
4562
|
-
let url_ = this.baseUrl + "/
|
|
4554
|
+
createShiftPlan(request) {
|
|
4555
|
+
let url_ = this.baseUrl + "/kpiadminresource/shift-plans";
|
|
4563
4556
|
url_ = url_.replace(/[?&]$/, "");
|
|
4564
4557
|
const content_ = JSON.stringify(request);
|
|
4565
4558
|
let options_ = {
|
|
@@ -4573,10 +4566,10 @@ export class KpiCalendarClient extends AuthorizedApiBase {
|
|
|
4573
4566
|
return this.transformOptions(options_).then(transformedOptions_ => {
|
|
4574
4567
|
return this.http.fetch(url_, transformedOptions_);
|
|
4575
4568
|
}).then((_response) => {
|
|
4576
|
-
return this.
|
|
4569
|
+
return this.processCreateShiftPlan(_response);
|
|
4577
4570
|
});
|
|
4578
4571
|
}
|
|
4579
|
-
|
|
4572
|
+
processCreateShiftPlan(response) {
|
|
4580
4573
|
const status = response.status;
|
|
4581
4574
|
let _headers = {};
|
|
4582
4575
|
if (response.headers && response.headers.forEach) {
|
|
@@ -4597,8 +4590,8 @@ export class KpiCalendarClient extends AuthorizedApiBase {
|
|
|
4597
4590
|
}
|
|
4598
4591
|
return Promise.resolve(null);
|
|
4599
4592
|
}
|
|
4600
|
-
|
|
4601
|
-
let url_ = this.baseUrl + "/
|
|
4593
|
+
updateShiftPlan(id, request) {
|
|
4594
|
+
let url_ = this.baseUrl + "/kpiadminresource/shift-plans/{id}";
|
|
4602
4595
|
if (id === undefined || id === null)
|
|
4603
4596
|
throw new globalThis.Error("The parameter 'id' must be defined.");
|
|
4604
4597
|
url_ = url_.replace("{id}", encodeURIComponent("" + id));
|
|
@@ -4615,10 +4608,10 @@ export class KpiCalendarClient extends AuthorizedApiBase {
|
|
|
4615
4608
|
return this.transformOptions(options_).then(transformedOptions_ => {
|
|
4616
4609
|
return this.http.fetch(url_, transformedOptions_);
|
|
4617
4610
|
}).then((_response) => {
|
|
4618
|
-
return this.
|
|
4611
|
+
return this.processUpdateShiftPlan(_response);
|
|
4619
4612
|
});
|
|
4620
4613
|
}
|
|
4621
|
-
|
|
4614
|
+
processUpdateShiftPlan(response) {
|
|
4622
4615
|
const status = response.status;
|
|
4623
4616
|
let _headers = {};
|
|
4624
4617
|
if (response.headers && response.headers.forEach) {
|
|
@@ -4639,8 +4632,8 @@ export class KpiCalendarClient extends AuthorizedApiBase {
|
|
|
4639
4632
|
}
|
|
4640
4633
|
return Promise.resolve(null);
|
|
4641
4634
|
}
|
|
4642
|
-
|
|
4643
|
-
let url_ = this.baseUrl + "/
|
|
4635
|
+
deleteShiftPlan(id) {
|
|
4636
|
+
let url_ = this.baseUrl + "/kpiadminresource/shift-plans/{id}";
|
|
4644
4637
|
if (id === undefined || id === null)
|
|
4645
4638
|
throw new globalThis.Error("The parameter 'id' must be defined.");
|
|
4646
4639
|
url_ = url_.replace("{id}", encodeURIComponent("" + id));
|
|
@@ -4652,10 +4645,10 @@ export class KpiCalendarClient extends AuthorizedApiBase {
|
|
|
4652
4645
|
return this.transformOptions(options_).then(transformedOptions_ => {
|
|
4653
4646
|
return this.http.fetch(url_, transformedOptions_);
|
|
4654
4647
|
}).then((_response) => {
|
|
4655
|
-
return this.
|
|
4648
|
+
return this.processDeleteShiftPlan(_response);
|
|
4656
4649
|
});
|
|
4657
4650
|
}
|
|
4658
|
-
|
|
4651
|
+
processDeleteShiftPlan(response) {
|
|
4659
4652
|
const status = response.status;
|
|
4660
4653
|
let _headers = {};
|
|
4661
4654
|
if (response.headers && response.headers.forEach) {
|
|
@@ -4674,8 +4667,8 @@ export class KpiCalendarClient extends AuthorizedApiBase {
|
|
|
4674
4667
|
}
|
|
4675
4668
|
return Promise.resolve(null);
|
|
4676
4669
|
}
|
|
4677
|
-
|
|
4678
|
-
let url_ = this.baseUrl + "/
|
|
4670
|
+
listShiftSettingPeriods() {
|
|
4671
|
+
let url_ = this.baseUrl + "/kpiadminresource/shift-settings";
|
|
4679
4672
|
url_ = url_.replace(/[?&]$/, "");
|
|
4680
4673
|
let options_ = {
|
|
4681
4674
|
method: "GET",
|
|
@@ -4686,10 +4679,10 @@ export class KpiCalendarClient extends AuthorizedApiBase {
|
|
|
4686
4679
|
return this.transformOptions(options_).then(transformedOptions_ => {
|
|
4687
4680
|
return this.http.fetch(url_, transformedOptions_);
|
|
4688
4681
|
}).then((_response) => {
|
|
4689
|
-
return this.
|
|
4682
|
+
return this.processListShiftSettingPeriods(_response);
|
|
4690
4683
|
});
|
|
4691
4684
|
}
|
|
4692
|
-
|
|
4685
|
+
processListShiftSettingPeriods(response) {
|
|
4693
4686
|
const status = response.status;
|
|
4694
4687
|
let _headers = {};
|
|
4695
4688
|
if (response.headers && response.headers.forEach) {
|
|
@@ -4710,8 +4703,8 @@ export class KpiCalendarClient extends AuthorizedApiBase {
|
|
|
4710
4703
|
}
|
|
4711
4704
|
return Promise.resolve(null);
|
|
4712
4705
|
}
|
|
4713
|
-
|
|
4714
|
-
let url_ = this.baseUrl + "/
|
|
4706
|
+
addShiftSettingPeriods(request) {
|
|
4707
|
+
let url_ = this.baseUrl + "/kpiadminresource/shift-settings";
|
|
4715
4708
|
url_ = url_.replace(/[?&]$/, "");
|
|
4716
4709
|
const content_ = JSON.stringify(request);
|
|
4717
4710
|
let options_ = {
|
|
@@ -4725,10 +4718,10 @@ export class KpiCalendarClient extends AuthorizedApiBase {
|
|
|
4725
4718
|
return this.transformOptions(options_).then(transformedOptions_ => {
|
|
4726
4719
|
return this.http.fetch(url_, transformedOptions_);
|
|
4727
4720
|
}).then((_response) => {
|
|
4728
|
-
return this.
|
|
4721
|
+
return this.processAddShiftSettingPeriods(_response);
|
|
4729
4722
|
});
|
|
4730
4723
|
}
|
|
4731
|
-
|
|
4724
|
+
processAddShiftSettingPeriods(response) {
|
|
4732
4725
|
const status = response.status;
|
|
4733
4726
|
let _headers = {};
|
|
4734
4727
|
if (response.headers && response.headers.forEach) {
|
|
@@ -4749,8 +4742,8 @@ export class KpiCalendarClient extends AuthorizedApiBase {
|
|
|
4749
4742
|
}
|
|
4750
4743
|
return Promise.resolve(null);
|
|
4751
4744
|
}
|
|
4752
|
-
|
|
4753
|
-
let url_ = this.baseUrl + "/
|
|
4745
|
+
deleteShiftSettingPeriods(request) {
|
|
4746
|
+
let url_ = this.baseUrl + "/kpiadminresource/shift-settings";
|
|
4754
4747
|
url_ = url_.replace(/[?&]$/, "");
|
|
4755
4748
|
const content_ = JSON.stringify(request);
|
|
4756
4749
|
let options_ = {
|
|
@@ -4764,10 +4757,10 @@ export class KpiCalendarClient extends AuthorizedApiBase {
|
|
|
4764
4757
|
return this.transformOptions(options_).then(transformedOptions_ => {
|
|
4765
4758
|
return this.http.fetch(url_, transformedOptions_);
|
|
4766
4759
|
}).then((_response) => {
|
|
4767
|
-
return this.
|
|
4760
|
+
return this.processDeleteShiftSettingPeriods(_response);
|
|
4768
4761
|
});
|
|
4769
4762
|
}
|
|
4770
|
-
|
|
4763
|
+
processDeleteShiftSettingPeriods(response) {
|
|
4771
4764
|
const status = response.status;
|
|
4772
4765
|
let _headers = {};
|
|
4773
4766
|
if (response.headers && response.headers.forEach) {
|
|
@@ -4794,8 +4787,8 @@ export class KpiCalendarClient extends AuthorizedApiBase {
|
|
|
4794
4787
|
}
|
|
4795
4788
|
return Promise.resolve(null);
|
|
4796
4789
|
}
|
|
4797
|
-
|
|
4798
|
-
let url_ = this.baseUrl + "/
|
|
4790
|
+
updateShiftSettingsPeriod(resourceExternalId, effectiveFrom, request) {
|
|
4791
|
+
let url_ = this.baseUrl + "/kpiadminresource/shift-settings/{resourceExternalId}/{effectiveFrom}";
|
|
4799
4792
|
if (resourceExternalId === undefined || resourceExternalId === null)
|
|
4800
4793
|
throw new globalThis.Error("The parameter 'resourceExternalId' must be defined.");
|
|
4801
4794
|
url_ = url_.replace("{resourceExternalId}", encodeURIComponent("" + resourceExternalId));
|
|
@@ -4815,10 +4808,10 @@ export class KpiCalendarClient extends AuthorizedApiBase {
|
|
|
4815
4808
|
return this.transformOptions(options_).then(transformedOptions_ => {
|
|
4816
4809
|
return this.http.fetch(url_, transformedOptions_);
|
|
4817
4810
|
}).then((_response) => {
|
|
4818
|
-
return this.
|
|
4811
|
+
return this.processUpdateShiftSettingsPeriod(_response);
|
|
4819
4812
|
});
|
|
4820
4813
|
}
|
|
4821
|
-
|
|
4814
|
+
processUpdateShiftSettingsPeriod(response) {
|
|
4822
4815
|
const status = response.status;
|
|
4823
4816
|
let _headers = {};
|
|
4824
4817
|
if (response.headers && response.headers.forEach) {
|
|
@@ -4839,8 +4832,8 @@ export class KpiCalendarClient extends AuthorizedApiBase {
|
|
|
4839
4832
|
}
|
|
4840
4833
|
return Promise.resolve(null);
|
|
4841
4834
|
}
|
|
4842
|
-
|
|
4843
|
-
let url_ = this.baseUrl + "/
|
|
4835
|
+
copyShiftSettingsPeriod(sourceResourceExternalId, sourceEffectiveFrom, request) {
|
|
4836
|
+
let url_ = this.baseUrl + "/kpiadminresource/shift-settings/{sourceResourceExternalId}/{sourceEffectiveFrom}/copy";
|
|
4844
4837
|
if (sourceResourceExternalId === undefined || sourceResourceExternalId === null)
|
|
4845
4838
|
throw new globalThis.Error("The parameter 'sourceResourceExternalId' must be defined.");
|
|
4846
4839
|
url_ = url_.replace("{sourceResourceExternalId}", encodeURIComponent("" + sourceResourceExternalId));
|
|
@@ -4860,10 +4853,10 @@ export class KpiCalendarClient extends AuthorizedApiBase {
|
|
|
4860
4853
|
return this.transformOptions(options_).then(transformedOptions_ => {
|
|
4861
4854
|
return this.http.fetch(url_, transformedOptions_);
|
|
4862
4855
|
}).then((_response) => {
|
|
4863
|
-
return this.
|
|
4856
|
+
return this.processCopyShiftSettingsPeriod(_response);
|
|
4864
4857
|
});
|
|
4865
4858
|
}
|
|
4866
|
-
|
|
4859
|
+
processCopyShiftSettingsPeriod(response) {
|
|
4867
4860
|
const status = response.status;
|
|
4868
4861
|
let _headers = {};
|
|
4869
4862
|
if (response.headers && response.headers.forEach) {
|
|
@@ -4884,8 +4877,8 @@ export class KpiCalendarClient extends AuthorizedApiBase {
|
|
|
4884
4877
|
}
|
|
4885
4878
|
return Promise.resolve(null);
|
|
4886
4879
|
}
|
|
4887
|
-
|
|
4888
|
-
let url_ = this.baseUrl + "/
|
|
4880
|
+
migrateCapacityToSettings() {
|
|
4881
|
+
let url_ = this.baseUrl + "/kpiadminresource/shift-settings/migrate-capacity";
|
|
4889
4882
|
url_ = url_.replace(/[?&]$/, "");
|
|
4890
4883
|
let options_ = {
|
|
4891
4884
|
method: "POST",
|
|
@@ -4896,10 +4889,10 @@ export class KpiCalendarClient extends AuthorizedApiBase {
|
|
|
4896
4889
|
return this.transformOptions(options_).then(transformedOptions_ => {
|
|
4897
4890
|
return this.http.fetch(url_, transformedOptions_);
|
|
4898
4891
|
}).then((_response) => {
|
|
4899
|
-
return this.
|
|
4892
|
+
return this.processMigrateCapacityToSettings(_response);
|
|
4900
4893
|
});
|
|
4901
4894
|
}
|
|
4902
|
-
|
|
4895
|
+
processMigrateCapacityToSettings(response) {
|
|
4903
4896
|
const status = response.status;
|
|
4904
4897
|
let _headers = {};
|
|
4905
4898
|
if (response.headers && response.headers.forEach) {
|
package/package.json
CHANGED
package/src/ignosportal-api.ts
CHANGED
|
@@ -4633,6 +4633,26 @@ export interface IKpiAdminResourceClient {
|
|
|
4633
4633
|
getCalendarSettings(): Promise<CalendarSettingsDto>;
|
|
4634
4634
|
|
|
4635
4635
|
updateCalendarSettings(cmd: UpdateCalendarSettingsCommand): Promise<CalendarSettingsDto>;
|
|
4636
|
+
|
|
4637
|
+
listShiftPlans(): Promise<ShiftPlansDto>;
|
|
4638
|
+
|
|
4639
|
+
createShiftPlan(request: CreateShiftPlan): Promise<ShiftPlanDto>;
|
|
4640
|
+
|
|
4641
|
+
updateShiftPlan(id: string, request: UpdateShiftPlanRequest): Promise<ShiftPlanDto>;
|
|
4642
|
+
|
|
4643
|
+
deleteShiftPlan(id: string): Promise<void>;
|
|
4644
|
+
|
|
4645
|
+
listShiftSettingPeriods(): Promise<ShiftSettingsDto>;
|
|
4646
|
+
|
|
4647
|
+
addShiftSettingPeriods(request: AddShiftSettingPeriods): Promise<ShiftSettingsPeriodDto[]>;
|
|
4648
|
+
|
|
4649
|
+
deleteShiftSettingPeriods(request: DeleteShiftSettingsPeriod): Promise<FileResponse>;
|
|
4650
|
+
|
|
4651
|
+
updateShiftSettingsPeriod(resourceExternalId: string, effectiveFrom: string, request: UpdateShiftSettingsPeriodRequest): Promise<ShiftSettingsPeriodDto>;
|
|
4652
|
+
|
|
4653
|
+
copyShiftSettingsPeriod(sourceResourceExternalId: string, sourceEffectiveFrom: string, request: CopyShiftSettingsPeriodRequest): Promise<ShiftSettingsPeriodDto>;
|
|
4654
|
+
|
|
4655
|
+
migrateCapacityToSettings(): Promise<MigrationResultDto>;
|
|
4636
4656
|
}
|
|
4637
4657
|
|
|
4638
4658
|
export class KpiAdminResourceClient extends AuthorizedApiBase implements IKpiAdminResourceClient {
|
|
@@ -4874,43 +4894,9 @@ export class KpiAdminResourceClient extends AuthorizedApiBase implements IKpiAdm
|
|
|
4874
4894
|
}
|
|
4875
4895
|
return Promise.resolve<CalendarSettingsDto>(null as any);
|
|
4876
4896
|
}
|
|
4877
|
-
}
|
|
4878
|
-
|
|
4879
|
-
export interface IKpiCalendarClient {
|
|
4880
|
-
|
|
4881
|
-
listCalendarDefinitions(): Promise<CalendarDefinitionsDto>;
|
|
4882
|
-
|
|
4883
|
-
createCalendarDefinition(request: CreateCalendarDefinition): Promise<CalendarDefinitionDto>;
|
|
4884
|
-
|
|
4885
|
-
updateCalendarDefinition(id: string, request: UpdateCalendarDefinitionRequest): Promise<CalendarDefinitionDto>;
|
|
4886
|
-
|
|
4887
|
-
deleteCalendarDefinition(id: string): Promise<void>;
|
|
4888
|
-
|
|
4889
|
-
listResourceCalendarPeriods(): Promise<ResourceCalendarPeriodSchedulesDto>;
|
|
4890
|
-
|
|
4891
|
-
addResourceCalendarPeriods(request: AddResourceCalendarPeriod): Promise<ResourceCalendarPeriodDto[]>;
|
|
4892
|
-
|
|
4893
|
-
deleteResourceCalendarPeriods(request: DeleteResourceCalendarPeriod): Promise<FileResponse>;
|
|
4894
|
-
|
|
4895
|
-
updateResourceCalendarPeriod(resourceExternalId: string, effectiveFrom: string, request: UpdateResourceCalendarPeriodRequest): Promise<ResourceCalendarPeriodDto>;
|
|
4896
|
-
|
|
4897
|
-
copyResourceCalendarPeriod(sourceResourceExternalId: string, sourceEffectiveFrom: string, request: CopyResourceCalendarPeriodRequest): Promise<ResourceCalendarPeriodDto>;
|
|
4898
|
-
|
|
4899
|
-
migrateCapacityToSchedules(): Promise<MigrationResultDto>;
|
|
4900
|
-
}
|
|
4901
|
-
|
|
4902
|
-
export class KpiCalendarClient extends AuthorizedApiBase implements IKpiCalendarClient {
|
|
4903
|
-
private http: { fetch(url: RequestInfo, init?: RequestInit): Promise<Response> };
|
|
4904
|
-
private baseUrl: string;
|
|
4905
|
-
|
|
4906
|
-
constructor(configuration: IAccessTokenProvider, baseUrl?: string, http?: { fetch(url: RequestInfo, init?: RequestInit): Promise<Response> }) {
|
|
4907
|
-
super(configuration);
|
|
4908
|
-
this.http = http ? http : window as any;
|
|
4909
|
-
this.baseUrl = baseUrl ?? "";
|
|
4910
|
-
}
|
|
4911
4897
|
|
|
4912
|
-
|
|
4913
|
-
let url_ = this.baseUrl + "/
|
|
4898
|
+
listShiftPlans(): Promise<ShiftPlansDto> {
|
|
4899
|
+
let url_ = this.baseUrl + "/kpiadminresource/shift-plans";
|
|
4914
4900
|
url_ = url_.replace(/[?&]$/, "");
|
|
4915
4901
|
|
|
4916
4902
|
let options_: RequestInit = {
|
|
@@ -4923,17 +4909,17 @@ export class KpiCalendarClient extends AuthorizedApiBase implements IKpiCalendar
|
|
|
4923
4909
|
return this.transformOptions(options_).then(transformedOptions_ => {
|
|
4924
4910
|
return this.http.fetch(url_, transformedOptions_);
|
|
4925
4911
|
}).then((_response: Response) => {
|
|
4926
|
-
return this.
|
|
4912
|
+
return this.processListShiftPlans(_response);
|
|
4927
4913
|
});
|
|
4928
4914
|
}
|
|
4929
4915
|
|
|
4930
|
-
protected
|
|
4916
|
+
protected processListShiftPlans(response: Response): Promise<ShiftPlansDto> {
|
|
4931
4917
|
const status = response.status;
|
|
4932
4918
|
let _headers: any = {}; if (response.headers && response.headers.forEach) { response.headers.forEach((v: any, k: any) => _headers[k] = v); };
|
|
4933
4919
|
if (status === 200) {
|
|
4934
4920
|
return response.text().then((_responseText) => {
|
|
4935
4921
|
let result200: any = null;
|
|
4936
|
-
result200 = _responseText === "" ? null : JSON.parse(_responseText, this.jsonParseReviver) as
|
|
4922
|
+
result200 = _responseText === "" ? null : JSON.parse(_responseText, this.jsonParseReviver) as ShiftPlansDto;
|
|
4937
4923
|
return result200;
|
|
4938
4924
|
});
|
|
4939
4925
|
} else if (status !== 200 && status !== 204) {
|
|
@@ -4941,11 +4927,11 @@ export class KpiCalendarClient extends AuthorizedApiBase implements IKpiCalendar
|
|
|
4941
4927
|
return throwException("An unexpected server error occurred.", status, _responseText, _headers);
|
|
4942
4928
|
});
|
|
4943
4929
|
}
|
|
4944
|
-
return Promise.resolve<
|
|
4930
|
+
return Promise.resolve<ShiftPlansDto>(null as any);
|
|
4945
4931
|
}
|
|
4946
4932
|
|
|
4947
|
-
|
|
4948
|
-
let url_ = this.baseUrl + "/
|
|
4933
|
+
createShiftPlan(request: CreateShiftPlan): Promise<ShiftPlanDto> {
|
|
4934
|
+
let url_ = this.baseUrl + "/kpiadminresource/shift-plans";
|
|
4949
4935
|
url_ = url_.replace(/[?&]$/, "");
|
|
4950
4936
|
|
|
4951
4937
|
const content_ = JSON.stringify(request);
|
|
@@ -4962,17 +4948,17 @@ export class KpiCalendarClient extends AuthorizedApiBase implements IKpiCalendar
|
|
|
4962
4948
|
return this.transformOptions(options_).then(transformedOptions_ => {
|
|
4963
4949
|
return this.http.fetch(url_, transformedOptions_);
|
|
4964
4950
|
}).then((_response: Response) => {
|
|
4965
|
-
return this.
|
|
4951
|
+
return this.processCreateShiftPlan(_response);
|
|
4966
4952
|
});
|
|
4967
4953
|
}
|
|
4968
4954
|
|
|
4969
|
-
protected
|
|
4955
|
+
protected processCreateShiftPlan(response: Response): Promise<ShiftPlanDto> {
|
|
4970
4956
|
const status = response.status;
|
|
4971
4957
|
let _headers: any = {}; if (response.headers && response.headers.forEach) { response.headers.forEach((v: any, k: any) => _headers[k] = v); };
|
|
4972
4958
|
if (status === 200) {
|
|
4973
4959
|
return response.text().then((_responseText) => {
|
|
4974
4960
|
let result200: any = null;
|
|
4975
|
-
result200 = _responseText === "" ? null : JSON.parse(_responseText, this.jsonParseReviver) as
|
|
4961
|
+
result200 = _responseText === "" ? null : JSON.parse(_responseText, this.jsonParseReviver) as ShiftPlanDto;
|
|
4976
4962
|
return result200;
|
|
4977
4963
|
});
|
|
4978
4964
|
} else if (status !== 200 && status !== 204) {
|
|
@@ -4980,11 +4966,11 @@ export class KpiCalendarClient extends AuthorizedApiBase implements IKpiCalendar
|
|
|
4980
4966
|
return throwException("An unexpected server error occurred.", status, _responseText, _headers);
|
|
4981
4967
|
});
|
|
4982
4968
|
}
|
|
4983
|
-
return Promise.resolve<
|
|
4969
|
+
return Promise.resolve<ShiftPlanDto>(null as any);
|
|
4984
4970
|
}
|
|
4985
4971
|
|
|
4986
|
-
|
|
4987
|
-
let url_ = this.baseUrl + "/
|
|
4972
|
+
updateShiftPlan(id: string, request: UpdateShiftPlanRequest): Promise<ShiftPlanDto> {
|
|
4973
|
+
let url_ = this.baseUrl + "/kpiadminresource/shift-plans/{id}";
|
|
4988
4974
|
if (id === undefined || id === null)
|
|
4989
4975
|
throw new globalThis.Error("The parameter 'id' must be defined.");
|
|
4990
4976
|
url_ = url_.replace("{id}", encodeURIComponent("" + id));
|
|
@@ -5004,17 +4990,17 @@ export class KpiCalendarClient extends AuthorizedApiBase implements IKpiCalendar
|
|
|
5004
4990
|
return this.transformOptions(options_).then(transformedOptions_ => {
|
|
5005
4991
|
return this.http.fetch(url_, transformedOptions_);
|
|
5006
4992
|
}).then((_response: Response) => {
|
|
5007
|
-
return this.
|
|
4993
|
+
return this.processUpdateShiftPlan(_response);
|
|
5008
4994
|
});
|
|
5009
4995
|
}
|
|
5010
4996
|
|
|
5011
|
-
protected
|
|
4997
|
+
protected processUpdateShiftPlan(response: Response): Promise<ShiftPlanDto> {
|
|
5012
4998
|
const status = response.status;
|
|
5013
4999
|
let _headers: any = {}; if (response.headers && response.headers.forEach) { response.headers.forEach((v: any, k: any) => _headers[k] = v); };
|
|
5014
5000
|
if (status === 200) {
|
|
5015
5001
|
return response.text().then((_responseText) => {
|
|
5016
5002
|
let result200: any = null;
|
|
5017
|
-
result200 = _responseText === "" ? null : JSON.parse(_responseText, this.jsonParseReviver) as
|
|
5003
|
+
result200 = _responseText === "" ? null : JSON.parse(_responseText, this.jsonParseReviver) as ShiftPlanDto;
|
|
5018
5004
|
return result200;
|
|
5019
5005
|
});
|
|
5020
5006
|
} else if (status !== 200 && status !== 204) {
|
|
@@ -5022,11 +5008,11 @@ export class KpiCalendarClient extends AuthorizedApiBase implements IKpiCalendar
|
|
|
5022
5008
|
return throwException("An unexpected server error occurred.", status, _responseText, _headers);
|
|
5023
5009
|
});
|
|
5024
5010
|
}
|
|
5025
|
-
return Promise.resolve<
|
|
5011
|
+
return Promise.resolve<ShiftPlanDto>(null as any);
|
|
5026
5012
|
}
|
|
5027
5013
|
|
|
5028
|
-
|
|
5029
|
-
let url_ = this.baseUrl + "/
|
|
5014
|
+
deleteShiftPlan(id: string): Promise<void> {
|
|
5015
|
+
let url_ = this.baseUrl + "/kpiadminresource/shift-plans/{id}";
|
|
5030
5016
|
if (id === undefined || id === null)
|
|
5031
5017
|
throw new globalThis.Error("The parameter 'id' must be defined.");
|
|
5032
5018
|
url_ = url_.replace("{id}", encodeURIComponent("" + id));
|
|
@@ -5041,11 +5027,11 @@ export class KpiCalendarClient extends AuthorizedApiBase implements IKpiCalendar
|
|
|
5041
5027
|
return this.transformOptions(options_).then(transformedOptions_ => {
|
|
5042
5028
|
return this.http.fetch(url_, transformedOptions_);
|
|
5043
5029
|
}).then((_response: Response) => {
|
|
5044
|
-
return this.
|
|
5030
|
+
return this.processDeleteShiftPlan(_response);
|
|
5045
5031
|
});
|
|
5046
5032
|
}
|
|
5047
5033
|
|
|
5048
|
-
protected
|
|
5034
|
+
protected processDeleteShiftPlan(response: Response): Promise<void> {
|
|
5049
5035
|
const status = response.status;
|
|
5050
5036
|
let _headers: any = {}; if (response.headers && response.headers.forEach) { response.headers.forEach((v: any, k: any) => _headers[k] = v); };
|
|
5051
5037
|
if (status === 204) {
|
|
@@ -5060,8 +5046,8 @@ export class KpiCalendarClient extends AuthorizedApiBase implements IKpiCalendar
|
|
|
5060
5046
|
return Promise.resolve<void>(null as any);
|
|
5061
5047
|
}
|
|
5062
5048
|
|
|
5063
|
-
|
|
5064
|
-
let url_ = this.baseUrl + "/
|
|
5049
|
+
listShiftSettingPeriods(): Promise<ShiftSettingsDto> {
|
|
5050
|
+
let url_ = this.baseUrl + "/kpiadminresource/shift-settings";
|
|
5065
5051
|
url_ = url_.replace(/[?&]$/, "");
|
|
5066
5052
|
|
|
5067
5053
|
let options_: RequestInit = {
|
|
@@ -5074,17 +5060,17 @@ export class KpiCalendarClient extends AuthorizedApiBase implements IKpiCalendar
|
|
|
5074
5060
|
return this.transformOptions(options_).then(transformedOptions_ => {
|
|
5075
5061
|
return this.http.fetch(url_, transformedOptions_);
|
|
5076
5062
|
}).then((_response: Response) => {
|
|
5077
|
-
return this.
|
|
5063
|
+
return this.processListShiftSettingPeriods(_response);
|
|
5078
5064
|
});
|
|
5079
5065
|
}
|
|
5080
5066
|
|
|
5081
|
-
protected
|
|
5067
|
+
protected processListShiftSettingPeriods(response: Response): Promise<ShiftSettingsDto> {
|
|
5082
5068
|
const status = response.status;
|
|
5083
5069
|
let _headers: any = {}; if (response.headers && response.headers.forEach) { response.headers.forEach((v: any, k: any) => _headers[k] = v); };
|
|
5084
5070
|
if (status === 200) {
|
|
5085
5071
|
return response.text().then((_responseText) => {
|
|
5086
5072
|
let result200: any = null;
|
|
5087
|
-
result200 = _responseText === "" ? null : JSON.parse(_responseText, this.jsonParseReviver) as
|
|
5073
|
+
result200 = _responseText === "" ? null : JSON.parse(_responseText, this.jsonParseReviver) as ShiftSettingsDto;
|
|
5088
5074
|
return result200;
|
|
5089
5075
|
});
|
|
5090
5076
|
} else if (status !== 200 && status !== 204) {
|
|
@@ -5092,11 +5078,11 @@ export class KpiCalendarClient extends AuthorizedApiBase implements IKpiCalendar
|
|
|
5092
5078
|
return throwException("An unexpected server error occurred.", status, _responseText, _headers);
|
|
5093
5079
|
});
|
|
5094
5080
|
}
|
|
5095
|
-
return Promise.resolve<
|
|
5081
|
+
return Promise.resolve<ShiftSettingsDto>(null as any);
|
|
5096
5082
|
}
|
|
5097
5083
|
|
|
5098
|
-
|
|
5099
|
-
let url_ = this.baseUrl + "/
|
|
5084
|
+
addShiftSettingPeriods(request: AddShiftSettingPeriods): Promise<ShiftSettingsPeriodDto[]> {
|
|
5085
|
+
let url_ = this.baseUrl + "/kpiadminresource/shift-settings";
|
|
5100
5086
|
url_ = url_.replace(/[?&]$/, "");
|
|
5101
5087
|
|
|
5102
5088
|
const content_ = JSON.stringify(request);
|
|
@@ -5113,17 +5099,17 @@ export class KpiCalendarClient extends AuthorizedApiBase implements IKpiCalendar
|
|
|
5113
5099
|
return this.transformOptions(options_).then(transformedOptions_ => {
|
|
5114
5100
|
return this.http.fetch(url_, transformedOptions_);
|
|
5115
5101
|
}).then((_response: Response) => {
|
|
5116
|
-
return this.
|
|
5102
|
+
return this.processAddShiftSettingPeriods(_response);
|
|
5117
5103
|
});
|
|
5118
5104
|
}
|
|
5119
5105
|
|
|
5120
|
-
protected
|
|
5106
|
+
protected processAddShiftSettingPeriods(response: Response): Promise<ShiftSettingsPeriodDto[]> {
|
|
5121
5107
|
const status = response.status;
|
|
5122
5108
|
let _headers: any = {}; if (response.headers && response.headers.forEach) { response.headers.forEach((v: any, k: any) => _headers[k] = v); };
|
|
5123
5109
|
if (status === 200) {
|
|
5124
5110
|
return response.text().then((_responseText) => {
|
|
5125
5111
|
let result200: any = null;
|
|
5126
|
-
result200 = _responseText === "" ? null : JSON.parse(_responseText, this.jsonParseReviver) as
|
|
5112
|
+
result200 = _responseText === "" ? null : JSON.parse(_responseText, this.jsonParseReviver) as ShiftSettingsPeriodDto[];
|
|
5127
5113
|
return result200;
|
|
5128
5114
|
});
|
|
5129
5115
|
} else if (status !== 200 && status !== 204) {
|
|
@@ -5131,11 +5117,11 @@ export class KpiCalendarClient extends AuthorizedApiBase implements IKpiCalendar
|
|
|
5131
5117
|
return throwException("An unexpected server error occurred.", status, _responseText, _headers);
|
|
5132
5118
|
});
|
|
5133
5119
|
}
|
|
5134
|
-
return Promise.resolve<
|
|
5120
|
+
return Promise.resolve<ShiftSettingsPeriodDto[]>(null as any);
|
|
5135
5121
|
}
|
|
5136
5122
|
|
|
5137
|
-
|
|
5138
|
-
let url_ = this.baseUrl + "/
|
|
5123
|
+
deleteShiftSettingPeriods(request: DeleteShiftSettingsPeriod): Promise<FileResponse> {
|
|
5124
|
+
let url_ = this.baseUrl + "/kpiadminresource/shift-settings";
|
|
5139
5125
|
url_ = url_.replace(/[?&]$/, "");
|
|
5140
5126
|
|
|
5141
5127
|
const content_ = JSON.stringify(request);
|
|
@@ -5152,11 +5138,11 @@ export class KpiCalendarClient extends AuthorizedApiBase implements IKpiCalendar
|
|
|
5152
5138
|
return this.transformOptions(options_).then(transformedOptions_ => {
|
|
5153
5139
|
return this.http.fetch(url_, transformedOptions_);
|
|
5154
5140
|
}).then((_response: Response) => {
|
|
5155
|
-
return this.
|
|
5141
|
+
return this.processDeleteShiftSettingPeriods(_response);
|
|
5156
5142
|
});
|
|
5157
5143
|
}
|
|
5158
5144
|
|
|
5159
|
-
protected
|
|
5145
|
+
protected processDeleteShiftSettingPeriods(response: Response): Promise<FileResponse> {
|
|
5160
5146
|
const status = response.status;
|
|
5161
5147
|
let _headers: any = {}; if (response.headers && response.headers.forEach) { response.headers.forEach((v: any, k: any) => _headers[k] = v); };
|
|
5162
5148
|
if (status === 200 || status === 206) {
|
|
@@ -5178,8 +5164,8 @@ export class KpiCalendarClient extends AuthorizedApiBase implements IKpiCalendar
|
|
|
5178
5164
|
return Promise.resolve<FileResponse>(null as any);
|
|
5179
5165
|
}
|
|
5180
5166
|
|
|
5181
|
-
|
|
5182
|
-
let url_ = this.baseUrl + "/
|
|
5167
|
+
updateShiftSettingsPeriod(resourceExternalId: string, effectiveFrom: string, request: UpdateShiftSettingsPeriodRequest): Promise<ShiftSettingsPeriodDto> {
|
|
5168
|
+
let url_ = this.baseUrl + "/kpiadminresource/shift-settings/{resourceExternalId}/{effectiveFrom}";
|
|
5183
5169
|
if (resourceExternalId === undefined || resourceExternalId === null)
|
|
5184
5170
|
throw new globalThis.Error("The parameter 'resourceExternalId' must be defined.");
|
|
5185
5171
|
url_ = url_.replace("{resourceExternalId}", encodeURIComponent("" + resourceExternalId));
|
|
@@ -5202,17 +5188,17 @@ export class KpiCalendarClient extends AuthorizedApiBase implements IKpiCalendar
|
|
|
5202
5188
|
return this.transformOptions(options_).then(transformedOptions_ => {
|
|
5203
5189
|
return this.http.fetch(url_, transformedOptions_);
|
|
5204
5190
|
}).then((_response: Response) => {
|
|
5205
|
-
return this.
|
|
5191
|
+
return this.processUpdateShiftSettingsPeriod(_response);
|
|
5206
5192
|
});
|
|
5207
5193
|
}
|
|
5208
5194
|
|
|
5209
|
-
protected
|
|
5195
|
+
protected processUpdateShiftSettingsPeriod(response: Response): Promise<ShiftSettingsPeriodDto> {
|
|
5210
5196
|
const status = response.status;
|
|
5211
5197
|
let _headers: any = {}; if (response.headers && response.headers.forEach) { response.headers.forEach((v: any, k: any) => _headers[k] = v); };
|
|
5212
5198
|
if (status === 200) {
|
|
5213
5199
|
return response.text().then((_responseText) => {
|
|
5214
5200
|
let result200: any = null;
|
|
5215
|
-
result200 = _responseText === "" ? null : JSON.parse(_responseText, this.jsonParseReviver) as
|
|
5201
|
+
result200 = _responseText === "" ? null : JSON.parse(_responseText, this.jsonParseReviver) as ShiftSettingsPeriodDto;
|
|
5216
5202
|
return result200;
|
|
5217
5203
|
});
|
|
5218
5204
|
} else if (status !== 200 && status !== 204) {
|
|
@@ -5220,11 +5206,11 @@ export class KpiCalendarClient extends AuthorizedApiBase implements IKpiCalendar
|
|
|
5220
5206
|
return throwException("An unexpected server error occurred.", status, _responseText, _headers);
|
|
5221
5207
|
});
|
|
5222
5208
|
}
|
|
5223
|
-
return Promise.resolve<
|
|
5209
|
+
return Promise.resolve<ShiftSettingsPeriodDto>(null as any);
|
|
5224
5210
|
}
|
|
5225
5211
|
|
|
5226
|
-
|
|
5227
|
-
let url_ = this.baseUrl + "/
|
|
5212
|
+
copyShiftSettingsPeriod(sourceResourceExternalId: string, sourceEffectiveFrom: string, request: CopyShiftSettingsPeriodRequest): Promise<ShiftSettingsPeriodDto> {
|
|
5213
|
+
let url_ = this.baseUrl + "/kpiadminresource/shift-settings/{sourceResourceExternalId}/{sourceEffectiveFrom}/copy";
|
|
5228
5214
|
if (sourceResourceExternalId === undefined || sourceResourceExternalId === null)
|
|
5229
5215
|
throw new globalThis.Error("The parameter 'sourceResourceExternalId' must be defined.");
|
|
5230
5216
|
url_ = url_.replace("{sourceResourceExternalId}", encodeURIComponent("" + sourceResourceExternalId));
|
|
@@ -5247,17 +5233,17 @@ export class KpiCalendarClient extends AuthorizedApiBase implements IKpiCalendar
|
|
|
5247
5233
|
return this.transformOptions(options_).then(transformedOptions_ => {
|
|
5248
5234
|
return this.http.fetch(url_, transformedOptions_);
|
|
5249
5235
|
}).then((_response: Response) => {
|
|
5250
|
-
return this.
|
|
5236
|
+
return this.processCopyShiftSettingsPeriod(_response);
|
|
5251
5237
|
});
|
|
5252
5238
|
}
|
|
5253
5239
|
|
|
5254
|
-
protected
|
|
5240
|
+
protected processCopyShiftSettingsPeriod(response: Response): Promise<ShiftSettingsPeriodDto> {
|
|
5255
5241
|
const status = response.status;
|
|
5256
5242
|
let _headers: any = {}; if (response.headers && response.headers.forEach) { response.headers.forEach((v: any, k: any) => _headers[k] = v); };
|
|
5257
5243
|
if (status === 200) {
|
|
5258
5244
|
return response.text().then((_responseText) => {
|
|
5259
5245
|
let result200: any = null;
|
|
5260
|
-
result200 = _responseText === "" ? null : JSON.parse(_responseText, this.jsonParseReviver) as
|
|
5246
|
+
result200 = _responseText === "" ? null : JSON.parse(_responseText, this.jsonParseReviver) as ShiftSettingsPeriodDto;
|
|
5261
5247
|
return result200;
|
|
5262
5248
|
});
|
|
5263
5249
|
} else if (status !== 200 && status !== 204) {
|
|
@@ -5265,11 +5251,11 @@ export class KpiCalendarClient extends AuthorizedApiBase implements IKpiCalendar
|
|
|
5265
5251
|
return throwException("An unexpected server error occurred.", status, _responseText, _headers);
|
|
5266
5252
|
});
|
|
5267
5253
|
}
|
|
5268
|
-
return Promise.resolve<
|
|
5254
|
+
return Promise.resolve<ShiftSettingsPeriodDto>(null as any);
|
|
5269
5255
|
}
|
|
5270
5256
|
|
|
5271
|
-
|
|
5272
|
-
let url_ = this.baseUrl + "/
|
|
5257
|
+
migrateCapacityToSettings(): Promise<MigrationResultDto> {
|
|
5258
|
+
let url_ = this.baseUrl + "/kpiadminresource/shift-settings/migrate-capacity";
|
|
5273
5259
|
url_ = url_.replace(/[?&]$/, "");
|
|
5274
5260
|
|
|
5275
5261
|
let options_: RequestInit = {
|
|
@@ -5282,11 +5268,11 @@ export class KpiCalendarClient extends AuthorizedApiBase implements IKpiCalendar
|
|
|
5282
5268
|
return this.transformOptions(options_).then(transformedOptions_ => {
|
|
5283
5269
|
return this.http.fetch(url_, transformedOptions_);
|
|
5284
5270
|
}).then((_response: Response) => {
|
|
5285
|
-
return this.
|
|
5271
|
+
return this.processMigrateCapacityToSettings(_response);
|
|
5286
5272
|
});
|
|
5287
5273
|
}
|
|
5288
5274
|
|
|
5289
|
-
protected
|
|
5275
|
+
protected processMigrateCapacityToSettings(response: Response): Promise<MigrationResultDto> {
|
|
5290
5276
|
const status = response.status;
|
|
5291
5277
|
let _headers: any = {}; if (response.headers && response.headers.forEach) { response.headers.forEach((v: any, k: any) => _headers[k] = v); };
|
|
5292
5278
|
if (status === 200) {
|
|
@@ -30986,12 +30972,12 @@ export interface UpdateCalendarSettingsCommand {
|
|
|
30986
30972
|
defaultPerformancePercent?: number | null;
|
|
30987
30973
|
}
|
|
30988
30974
|
|
|
30989
|
-
export interface
|
|
30990
|
-
active:
|
|
30991
|
-
archived:
|
|
30975
|
+
export interface ShiftPlansDto {
|
|
30976
|
+
active: ShiftPlanDto[];
|
|
30977
|
+
archived: ShiftPlanDto[];
|
|
30992
30978
|
}
|
|
30993
30979
|
|
|
30994
|
-
export interface
|
|
30980
|
+
export interface ShiftPlanDto {
|
|
30995
30981
|
id: string;
|
|
30996
30982
|
name: string;
|
|
30997
30983
|
hoursPerWeekday: { [key in DayOfWeek]?: number; };
|
|
@@ -31000,59 +30986,59 @@ export interface CalendarDefinitionDto {
|
|
|
31000
30986
|
isArchived?: boolean;
|
|
31001
30987
|
}
|
|
31002
30988
|
|
|
31003
|
-
export interface
|
|
30989
|
+
export interface CreateShiftPlan {
|
|
31004
30990
|
name: string;
|
|
31005
30991
|
hoursPerWeekday: { [key in DayOfWeek]?: number; };
|
|
31006
30992
|
}
|
|
31007
30993
|
|
|
31008
|
-
export interface
|
|
30994
|
+
export interface UpdateShiftPlanRequest {
|
|
31009
30995
|
name?: string | null;
|
|
31010
30996
|
hoursPerWeekday?: { [key in DayOfWeek]?: number; } | null;
|
|
31011
30997
|
unarchive?: boolean | null;
|
|
31012
30998
|
}
|
|
31013
30999
|
|
|
31014
|
-
export interface
|
|
31015
|
-
groups:
|
|
31016
|
-
ungroupedResources:
|
|
31000
|
+
export interface ShiftSettingsDto {
|
|
31001
|
+
groups: ShiftSettingsPeriodGroupDto[];
|
|
31002
|
+
ungroupedResources: ShiftSettingPeriodsDto[];
|
|
31017
31003
|
}
|
|
31018
31004
|
|
|
31019
|
-
export interface
|
|
31005
|
+
export interface ShiftSettingsPeriodGroupDto {
|
|
31020
31006
|
resourceGroupName: string;
|
|
31021
|
-
resources:
|
|
31007
|
+
resources: ShiftSettingPeriodsDto[];
|
|
31022
31008
|
}
|
|
31023
31009
|
|
|
31024
|
-
export interface
|
|
31010
|
+
export interface ShiftSettingPeriodsDto {
|
|
31025
31011
|
resourceExternalId: string;
|
|
31026
31012
|
resourceName: string;
|
|
31027
|
-
periods:
|
|
31013
|
+
periods: ShiftSettingsPeriodDto[];
|
|
31028
31014
|
}
|
|
31029
31015
|
|
|
31030
|
-
export interface
|
|
31016
|
+
export interface ShiftSettingsPeriodDto {
|
|
31031
31017
|
resourceExternalId: string;
|
|
31032
|
-
|
|
31033
|
-
|
|
31018
|
+
shiftPlanId: string;
|
|
31019
|
+
shiftPlanName: string;
|
|
31034
31020
|
effectiveFrom: string;
|
|
31035
31021
|
effectiveTo?: string | null;
|
|
31036
31022
|
targetPercent: number;
|
|
31037
31023
|
comment?: string | null;
|
|
31038
31024
|
}
|
|
31039
31025
|
|
|
31040
|
-
export interface
|
|
31026
|
+
export interface AddShiftSettingPeriods {
|
|
31041
31027
|
resourceExternalIds: string[];
|
|
31042
|
-
|
|
31028
|
+
shiftPlanId: string;
|
|
31043
31029
|
effectiveFrom: string;
|
|
31044
31030
|
targetPercent: number;
|
|
31045
31031
|
comment?: string | null;
|
|
31046
31032
|
}
|
|
31047
31033
|
|
|
31048
|
-
export interface
|
|
31049
|
-
|
|
31034
|
+
export interface UpdateShiftSettingsPeriodRequest {
|
|
31035
|
+
shiftPlanId?: string | null;
|
|
31050
31036
|
targetPercent?: number | null;
|
|
31051
31037
|
newEffectiveFrom?: string | null;
|
|
31052
31038
|
comment?: string | null;
|
|
31053
31039
|
}
|
|
31054
31040
|
|
|
31055
|
-
export interface
|
|
31041
|
+
export interface DeleteShiftSettingsPeriod {
|
|
31056
31042
|
periods: PeriodKey[];
|
|
31057
31043
|
}
|
|
31058
31044
|
|
|
@@ -31061,7 +31047,7 @@ export interface PeriodKey {
|
|
|
31061
31047
|
effectiveFrom: string;
|
|
31062
31048
|
}
|
|
31063
31049
|
|
|
31064
|
-
export interface
|
|
31050
|
+
export interface CopyShiftSettingsPeriodRequest {
|
|
31065
31051
|
targetResourceExternalId: string;
|
|
31066
31052
|
effectiveFrom: string;
|
|
31067
31053
|
}
|