hl-core 0.0.10-beta.3 → 0.0.10-beta.30
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/api/base.api.ts +259 -190
- package/api/interceptors.ts +3 -5
- package/components/Complex/TextBlock.vue +2 -0
- package/components/Dialog/Dialog.vue +7 -1
- package/components/Dialog/FamilyDialog.vue +2 -0
- package/components/Form/DigitalDocument.vue +52 -0
- package/components/Form/DynamicForm.vue +1 -0
- package/components/Form/FormData.vue +1 -0
- package/components/Form/ManagerAttachment.vue +18 -8
- package/components/Form/ProductConditionsBlock.vue +12 -6
- package/components/Input/DynamicInput.vue +2 -0
- package/components/Input/FormInput.vue +2 -0
- package/components/Input/OtpInput.vue +25 -0
- package/components/Input/PanelInput.vue +1 -0
- package/components/Input/RoundedInput.vue +2 -0
- package/components/Input/RoundedSelect.vue +4 -0
- package/components/Input/SwitchInput.vue +2 -0
- package/components/Input/TextInput.vue +2 -0
- package/components/Layout/Drawer.vue +2 -0
- package/components/Pages/Anketa.vue +166 -167
- package/components/Pages/Auth.vue +2 -0
- package/components/Pages/ContragentForm.vue +2 -1
- package/components/Pages/Documents.vue +244 -6
- package/components/Pages/MemberForm.vue +276 -96
- package/components/Pages/ProductConditions.vue +275 -96
- package/components/Panel/PanelHandler.vue +236 -108
- package/components/Transitions/Animation.vue +2 -0
- package/components/Utilities/Chip.vue +3 -1
- package/components/Utilities/JsonViewer.vue +1 -2
- package/composables/classes.ts +117 -42
- package/composables/constants.ts +33 -0
- package/composables/fields.ts +6 -4
- package/composables/index.ts +243 -7
- package/composables/styles.ts +8 -24
- package/configs/pwa.ts +1 -7
- package/layouts/clear.vue +1 -1
- package/layouts/default.vue +1 -1
- package/layouts/full.vue +1 -1
- package/locales/ru.json +34 -10
- package/nuxt.config.ts +10 -13
- package/package.json +13 -12
- package/plugins/head.ts +2 -1
- package/store/data.store.ts +380 -389
- package/store/member.store.ts +3 -2
- package/store/rules.ts +19 -0
- package/tsconfig.json +3 -0
- package/types/enum.ts +19 -2
- package/types/env.d.ts +2 -2
- package/types/form.ts +71 -74
- package/types/index.ts +916 -873
package/api/base.api.ts
CHANGED
|
@@ -1,18 +1,19 @@
|
|
|
1
1
|
import { MemberCodes, Methods } from '../types/enum';
|
|
2
2
|
import { useAxiosInstance } from '../composables/axios';
|
|
3
3
|
import { Value, IDocument } from '../composables/classes';
|
|
4
|
+
import type * as Types from '../types';
|
|
4
5
|
|
|
5
6
|
export class ApiClass {
|
|
6
7
|
private readonly baseURL: string = import.meta.env.VITE_BASE_URL as string;
|
|
7
8
|
private readonly productUrl: string = import.meta.env.VITE_PRODUCT_URL as string;
|
|
8
9
|
|
|
9
|
-
private async axiosCall<T>(config: AxiosRequestLocalConfig): Promise<T> {
|
|
10
|
+
private async axiosCall<T>(config: Types.AxiosRequestLocalConfig): Promise<T> {
|
|
10
11
|
const { data } = await useAxiosInstance(this.baseURL).request<T>(config);
|
|
11
12
|
return data;
|
|
12
13
|
}
|
|
13
14
|
|
|
14
15
|
async getProjectConfig() {
|
|
15
|
-
return await this.axiosCall<Utils.ProjectConfig>({
|
|
16
|
+
return await this.axiosCall<Types.Utils.ProjectConfig>({
|
|
16
17
|
method: Methods.GET,
|
|
17
18
|
baseURL: getStrValuePerEnv('gatewayApiUrl'),
|
|
18
19
|
url: `/application/front/${import.meta.env.VITE_PARENT_PRODUCT === 'auletti' ? `auletti-${import.meta.env.VITE_PRODUCT}` : import.meta.env.VITE_PRODUCT}`,
|
|
@@ -178,10 +179,10 @@ export class ApiClass {
|
|
|
178
179
|
});
|
|
179
180
|
}
|
|
180
181
|
|
|
181
|
-
async getContragent(queryData: GetContragentRequest) {
|
|
182
|
-
return await this.axiosCall<GetContragentResponse>({
|
|
182
|
+
async getContragent(queryData: Types.GetContragentRequest) {
|
|
183
|
+
return await this.axiosCall<Types.GetContragentResponse>({
|
|
183
184
|
method: Methods.GET,
|
|
184
|
-
url: `/Ekk/api/Contragentinsis/Contragent?Iin=${queryData.iin}&FirstName=${queryData.firstName}&LastName=${queryData.lastName}&MiddleName=${queryData.middleName}`,
|
|
185
|
+
url: `/Ekk/api/Contragentinsis/Contragent?Iin=${queryData.iin}&FirstName=${queryData.firstName}&LastName=${queryData.lastName}&MiddleName=${queryData.middleName}&BirthDate=${queryData.birthDate ?? ''}`,
|
|
185
186
|
});
|
|
186
187
|
}
|
|
187
188
|
|
|
@@ -193,28 +194,28 @@ export class ApiClass {
|
|
|
193
194
|
}
|
|
194
195
|
|
|
195
196
|
async getQuestionList(surveyType: string, processInstanceId: string | number, insuredId: number | string) {
|
|
196
|
-
return await this.axiosCall<AnketaFirst>({
|
|
197
|
+
return await this.axiosCall<Types.AnketaFirst>({
|
|
197
198
|
method: Methods.GET,
|
|
198
199
|
url: `/${this.productUrl}/api/Application/Anketa/${surveyType}/${processInstanceId}/${insuredId}`,
|
|
199
200
|
});
|
|
200
201
|
}
|
|
201
202
|
|
|
202
203
|
async getClientQuestionList(surveyType: string, processInstanceId: string | number, insuredId: number | string) {
|
|
203
|
-
return await this.axiosCall<AnketaFirst>({
|
|
204
|
+
return await this.axiosCall<Types.AnketaFirst>({
|
|
204
205
|
method: Methods.GET,
|
|
205
206
|
url: `/${this.productUrl}/api/Application/AnketaClient/${surveyType}/${processInstanceId}/${insuredId}`,
|
|
206
207
|
});
|
|
207
208
|
}
|
|
208
209
|
|
|
209
210
|
async getQuestionListSecond(surveyType: string, processInstanceId: string | number, insuredId: number | string) {
|
|
210
|
-
return await this.axiosCall<AnketaSecond[]>({
|
|
211
|
+
return await this.axiosCall<Types.AnketaSecond[]>({
|
|
211
212
|
method: Methods.GET,
|
|
212
213
|
url: `/${this.productUrl}/api/Application/Anketa/${surveyType}/${processInstanceId}/${insuredId}`,
|
|
213
214
|
});
|
|
214
215
|
}
|
|
215
216
|
|
|
216
217
|
async getClientQuestionListSecond(surveyType: string, processInstanceId: string | number, insuredId: number | string) {
|
|
217
|
-
return await this.axiosCall<AnketaSecond[]>({
|
|
218
|
+
return await this.axiosCall<Types.AnketaSecond[]>({
|
|
218
219
|
method: Methods.GET,
|
|
219
220
|
url: `/${this.productUrl}/api/Application/AnketaClient/${surveyType}/${processInstanceId}/${insuredId}`,
|
|
220
221
|
});
|
|
@@ -227,7 +228,7 @@ export class ApiClass {
|
|
|
227
228
|
});
|
|
228
229
|
}
|
|
229
230
|
|
|
230
|
-
async setSurvey(surveyData: AnketaFirst) {
|
|
231
|
+
async setSurvey(surveyData: Types.AnketaFirst) {
|
|
231
232
|
return await this.axiosCall<string>({
|
|
232
233
|
method: Methods.POST,
|
|
233
234
|
data: surveyData,
|
|
@@ -250,14 +251,14 @@ export class ApiClass {
|
|
|
250
251
|
}
|
|
251
252
|
|
|
252
253
|
async getAdditionalInsuranceTermsAnswers(processCode: string | number, questionId: string) {
|
|
253
|
-
return await this.axiosCall<AddCoverAnswer[]>({
|
|
254
|
+
return await this.axiosCall<Types.AddCoverAnswer[]>({
|
|
254
255
|
method: Methods.GET,
|
|
255
256
|
url: `/Arm/api/Dictionary/ProcessCoverTypeSum/${processCode}/${questionId}`,
|
|
256
257
|
});
|
|
257
258
|
}
|
|
258
259
|
|
|
259
260
|
async getProcessCoverTypePeriod(processCode: string | number, questionId: string) {
|
|
260
|
-
return await this.axiosCall<AddCoverAnswer[]>({
|
|
261
|
+
return await this.axiosCall<Types.AddCoverAnswer[]>({
|
|
261
262
|
method: Methods.GET,
|
|
262
263
|
url: `/Arm/api/Dictionary/GetProcessCoverTypePeriod/${processCode}/${questionId}`,
|
|
263
264
|
});
|
|
@@ -278,18 +279,18 @@ export class ApiClass {
|
|
|
278
279
|
}
|
|
279
280
|
|
|
280
281
|
async getContragentById(id: number) {
|
|
281
|
-
return await this.axiosCall<GetContragentResponse>({
|
|
282
|
+
return await this.axiosCall<Types.GetContragentResponse>({
|
|
282
283
|
method: Methods.GET,
|
|
283
284
|
url: `/Ekk/api/Contragentinsis/Contragent?PersonId=${id}`,
|
|
284
285
|
});
|
|
285
286
|
}
|
|
286
287
|
|
|
287
288
|
async saveContragent(data: {
|
|
288
|
-
contragent: ContragentType;
|
|
289
|
-
questionaries: ContragentQuestionaries[];
|
|
290
|
-
contacts: ContragentContacts[];
|
|
291
|
-
documents: ContragentDocuments[];
|
|
292
|
-
addresses: ContragentAddress[];
|
|
289
|
+
contragent: Types.ContragentType;
|
|
290
|
+
questionaries: Types.ContragentQuestionaries[];
|
|
291
|
+
contacts: Types.ContragentContacts[];
|
|
292
|
+
documents: Types.ContragentDocuments[];
|
|
293
|
+
addresses: Types.ContragentAddress[];
|
|
293
294
|
}) {
|
|
294
295
|
return await this.axiosCall<number>({
|
|
295
296
|
method: Methods.POST,
|
|
@@ -298,17 +299,6 @@ export class ApiClass {
|
|
|
298
299
|
});
|
|
299
300
|
}
|
|
300
301
|
|
|
301
|
-
async getFile(id: string) {
|
|
302
|
-
return await this.axiosCall({
|
|
303
|
-
method: Methods.GET,
|
|
304
|
-
url: `/File/api/Data/DownloadFile/${id}`,
|
|
305
|
-
responseType: 'arraybuffer',
|
|
306
|
-
headers: {
|
|
307
|
-
'Content-Type': 'application/pdf',
|
|
308
|
-
},
|
|
309
|
-
});
|
|
310
|
-
}
|
|
311
|
-
|
|
312
302
|
async getDicFileTypeList() {
|
|
313
303
|
return await this.axiosCall<Value[]>({
|
|
314
304
|
method: Methods.GET,
|
|
@@ -317,35 +307,35 @@ export class ApiClass {
|
|
|
317
307
|
}
|
|
318
308
|
|
|
319
309
|
async getContrAgentData(personId: string | number) {
|
|
320
|
-
return await this.axiosCall<ContragentQuestionaries[]>({
|
|
310
|
+
return await this.axiosCall<Types.ContragentQuestionaries[]>({
|
|
321
311
|
method: Methods.GET,
|
|
322
312
|
url: `/Ekk/api/Contragentinsis/Questionaries?PersonId=${personId}`,
|
|
323
313
|
});
|
|
324
314
|
}
|
|
325
315
|
|
|
326
316
|
async getContrAgentContacts(personId: string | number) {
|
|
327
|
-
return await this.axiosCall<ContragentContacts[]>({
|
|
317
|
+
return await this.axiosCall<Types.ContragentContacts[]>({
|
|
328
318
|
method: Methods.GET,
|
|
329
319
|
url: `/Ekk/api/Contragentinsis/Contacts?PersonId=${personId}`,
|
|
330
320
|
});
|
|
331
321
|
}
|
|
332
322
|
|
|
333
323
|
async getContrAgentDocuments(personId: string | number) {
|
|
334
|
-
return await this.axiosCall<ContragentDocuments[]>({
|
|
324
|
+
return await this.axiosCall<Types.ContragentDocuments[]>({
|
|
335
325
|
method: Methods.GET,
|
|
336
326
|
url: `/Ekk/api/Contragentinsis/Documents?PersonId=${personId}`,
|
|
337
327
|
});
|
|
338
328
|
}
|
|
339
329
|
|
|
340
330
|
async getContrAgentAddress(personId: string | number) {
|
|
341
|
-
return await this.axiosCall<ContragentAddress[]>({
|
|
331
|
+
return await this.axiosCall<Types.ContragentAddress[]>({
|
|
342
332
|
method: Methods.GET,
|
|
343
333
|
url: `/Ekk/api/Contragentinsis/Address?PersonId=${personId}`,
|
|
344
334
|
});
|
|
345
335
|
}
|
|
346
336
|
|
|
347
337
|
async getTaskList(data: any) {
|
|
348
|
-
return await this.axiosCall<{ items: TaskListItem[]; totalItems: number }>({
|
|
338
|
+
return await this.axiosCall<{ items: Types.TaskListItem[]; totalItems: number }>({
|
|
349
339
|
method: Methods.POST,
|
|
350
340
|
url: `/Arm/api/Bpm/TaskList`,
|
|
351
341
|
data: data,
|
|
@@ -353,13 +343,13 @@ export class ApiClass {
|
|
|
353
343
|
}
|
|
354
344
|
|
|
355
345
|
async getProcessHistory(id: string) {
|
|
356
|
-
return await this.axiosCall<TaskHistory[]>({
|
|
346
|
+
return await this.axiosCall<Types.TaskHistory[]>({
|
|
357
347
|
method: Methods.GET,
|
|
358
348
|
url: `/Arm/api/Bpm/GetProcessHistory?processInstanceId=${id}`,
|
|
359
349
|
});
|
|
360
350
|
}
|
|
361
351
|
|
|
362
|
-
async registerNumber(data: RegNumberDataType) {
|
|
352
|
+
async registerNumber(data: Types.RegNumberDataType) {
|
|
363
353
|
return await this.axiosCall<string>({
|
|
364
354
|
method: Methods.POST,
|
|
365
355
|
url: `/${this.productUrl}/api/Application/FinCenterRegNumberSave`,
|
|
@@ -367,7 +357,7 @@ export class ApiClass {
|
|
|
367
357
|
});
|
|
368
358
|
}
|
|
369
359
|
|
|
370
|
-
async sendSms(data: SmsDataType) {
|
|
360
|
+
async sendSms(data: Types.SmsDataType) {
|
|
371
361
|
return await this.axiosCall<void>({
|
|
372
362
|
method: Methods.POST,
|
|
373
363
|
url: '/Arm/api/Otp/SmsText',
|
|
@@ -376,13 +366,13 @@ export class ApiClass {
|
|
|
376
366
|
}
|
|
377
367
|
|
|
378
368
|
async getUserGroups() {
|
|
379
|
-
return await this.axiosCall<Item[]>({
|
|
369
|
+
return await this.axiosCall<Types.Item[]>({
|
|
380
370
|
method: Methods.GET,
|
|
381
371
|
url: '/Arm/api/Bpm/TaskGroups',
|
|
382
372
|
});
|
|
383
373
|
}
|
|
384
374
|
|
|
385
|
-
async getOtpStatus(data: OtpDataType) {
|
|
375
|
+
async getOtpStatus(data: Types.OtpDataType) {
|
|
386
376
|
return await this.axiosCall<boolean>({
|
|
387
377
|
method: Methods.POST,
|
|
388
378
|
url: '/Arm/api/Otp/OtpLifeStatus',
|
|
@@ -390,8 +380,8 @@ export class ApiClass {
|
|
|
390
380
|
});
|
|
391
381
|
}
|
|
392
382
|
|
|
393
|
-
async sendOtp(data: OtpDataType) {
|
|
394
|
-
return await this.axiosCall<SendOtpResponse>({
|
|
383
|
+
async sendOtp(data: Types.OtpDataType) {
|
|
384
|
+
return await this.axiosCall<Types.SendOtpResponse>({
|
|
395
385
|
method: Methods.POST,
|
|
396
386
|
url: '/Arm/api/Otp/Get',
|
|
397
387
|
data: data,
|
|
@@ -399,7 +389,7 @@ export class ApiClass {
|
|
|
399
389
|
}
|
|
400
390
|
|
|
401
391
|
async checkOtp(data: { tokenId: string; phoneNumber: string; code: string }) {
|
|
402
|
-
return await this.axiosCall<SendOtpResponse>({
|
|
392
|
+
return await this.axiosCall<Types.SendOtpResponse>({
|
|
403
393
|
method: Methods.POST,
|
|
404
394
|
url: '/Arm/api/Otp/Check',
|
|
405
395
|
data: data,
|
|
@@ -407,7 +397,7 @@ export class ApiClass {
|
|
|
407
397
|
}
|
|
408
398
|
|
|
409
399
|
async getProcessList() {
|
|
410
|
-
return await this.axiosCall<Item[]>({
|
|
400
|
+
return await this.axiosCall<Types.Item[]>({
|
|
411
401
|
method: Methods.GET,
|
|
412
402
|
url: '/Arm/api/Bpm/ProcessList',
|
|
413
403
|
});
|
|
@@ -431,7 +421,7 @@ export class ApiClass {
|
|
|
431
421
|
}
|
|
432
422
|
|
|
433
423
|
async getGovernmentPremiums(id: string) {
|
|
434
|
-
return await this.axiosCall<GovPremiums>({
|
|
424
|
+
return await this.axiosCall<Types.GovPremiums>({
|
|
435
425
|
method: Methods.POST,
|
|
436
426
|
url: `/${this.productUrl}/api/Application/getGovernmentPremiums?processInstanceId=${id} `,
|
|
437
427
|
});
|
|
@@ -444,7 +434,7 @@ export class ApiClass {
|
|
|
444
434
|
});
|
|
445
435
|
}
|
|
446
436
|
|
|
447
|
-
async setApplication(data: SetApplicationRequest) {
|
|
437
|
+
async setApplication(data: Types.SetApplicationRequest) {
|
|
448
438
|
return await this.axiosCall<void>({
|
|
449
439
|
method: Methods.POST,
|
|
450
440
|
url: `/${this.productUrl}/api/Application/SetApplicationData`,
|
|
@@ -452,26 +442,7 @@ export class ApiClass {
|
|
|
452
442
|
});
|
|
453
443
|
}
|
|
454
444
|
|
|
455
|
-
async
|
|
456
|
-
return await this.axiosCall<void>({
|
|
457
|
-
method: Methods.POST,
|
|
458
|
-
url: '/File/api/Data/DeleteFiles',
|
|
459
|
-
data: data,
|
|
460
|
-
});
|
|
461
|
-
}
|
|
462
|
-
|
|
463
|
-
async uploadFiles(data: any) {
|
|
464
|
-
return await this.axiosCall({
|
|
465
|
-
method: Methods.POST,
|
|
466
|
-
url: '/File/api/Data/UploadFiles',
|
|
467
|
-
headers: {
|
|
468
|
-
'Content-Type': 'multipart/form-data',
|
|
469
|
-
},
|
|
470
|
-
data: data,
|
|
471
|
-
});
|
|
472
|
-
}
|
|
473
|
-
|
|
474
|
-
async sendTask(data: SendTask) {
|
|
445
|
+
async sendTask(data: Types.SendTask) {
|
|
475
446
|
return await this.axiosCall<void>({
|
|
476
447
|
method: Methods.POST,
|
|
477
448
|
url: `/${this.productUrl}/api/Application/SendTask`,
|
|
@@ -485,7 +456,12 @@ export class ApiClass {
|
|
|
485
456
|
url: `/${this.productUrl}/api/Application/CheckBeneficiariesInActualPolicy?iin=${iin}`,
|
|
486
457
|
});
|
|
487
458
|
}
|
|
488
|
-
|
|
459
|
+
async checkBeneficiariesActualPolicy(id: string) {
|
|
460
|
+
return await this.axiosCall<boolean>({
|
|
461
|
+
method: Methods.GET,
|
|
462
|
+
url: `/${this.productUrl}/api/Application/checkBeneficiariesActualPolicy?processInstanceId=${id}`,
|
|
463
|
+
});
|
|
464
|
+
}
|
|
489
465
|
async setMember(whichMember: keyof typeof MemberCodes, data: any) {
|
|
490
466
|
return await this.axiosCall({
|
|
491
467
|
method: Methods.POST,
|
|
@@ -502,7 +478,7 @@ export class ApiClass {
|
|
|
502
478
|
}
|
|
503
479
|
|
|
504
480
|
async getInvoiceData(processInstanceId: string | number) {
|
|
505
|
-
return await this.axiosCall<EpayResponse>({
|
|
481
|
+
return await this.axiosCall<Types.EpayResponse>({
|
|
506
482
|
method: Methods.GET,
|
|
507
483
|
url: `/Arm/api/Invoice/InvoiceData?processInstanceId=${processInstanceId}`,
|
|
508
484
|
});
|
|
@@ -523,47 +499,14 @@ export class ApiClass {
|
|
|
523
499
|
}
|
|
524
500
|
|
|
525
501
|
async sendToEpay(processInstanceId: string | number) {
|
|
526
|
-
return await this.axiosCall<EpayShortResponse>({
|
|
502
|
+
return await this.axiosCall<Types.EpayShortResponse>({
|
|
527
503
|
method: Methods.POST,
|
|
528
504
|
url: `/Arm/api/Invoice/SendToEpay/${processInstanceId}`,
|
|
529
505
|
});
|
|
530
506
|
}
|
|
531
507
|
|
|
532
|
-
async
|
|
533
|
-
return await this.axiosCall<
|
|
534
|
-
method: Methods.POST,
|
|
535
|
-
url: '/File/api/Document/SignBts',
|
|
536
|
-
data: data,
|
|
537
|
-
});
|
|
538
|
-
}
|
|
539
|
-
|
|
540
|
-
async signQR(data: SignDataType[]) {
|
|
541
|
-
return await this.axiosCall<ResponseStructure<any>>({
|
|
542
|
-
method: Methods.POST,
|
|
543
|
-
url: '/File/api/Sign/SignQr',
|
|
544
|
-
data: data,
|
|
545
|
-
});
|
|
546
|
-
}
|
|
547
|
-
|
|
548
|
-
async generateDocument(data: SignDataType) {
|
|
549
|
-
return await this.axiosCall<void>({
|
|
550
|
-
method: Methods.POST,
|
|
551
|
-
url: '/File/api/Document/Generate',
|
|
552
|
-
responseType: 'arraybuffer',
|
|
553
|
-
data: data,
|
|
554
|
-
});
|
|
555
|
-
}
|
|
556
|
-
|
|
557
|
-
async getSignedDocList(data: { processInstanceId: string | number }) {
|
|
558
|
-
return await this.axiosCall<IDocument[]>({
|
|
559
|
-
method: Methods.POST,
|
|
560
|
-
url: '/File/api/Data/List',
|
|
561
|
-
data: data,
|
|
562
|
-
});
|
|
563
|
-
}
|
|
564
|
-
|
|
565
|
-
async calculateWithoutApplication(data: RecalculationDataType, product: string | undefined | null = this.productUrl) {
|
|
566
|
-
return await this.axiosCall<RecalculationResponseType>({
|
|
508
|
+
async calculateWithoutApplication(data: Types.RecalculationDataType, product: string | undefined | null = this.productUrl) {
|
|
509
|
+
return await this.axiosCall<Types.RecalculationResponseType>({
|
|
567
510
|
method: Methods.POST,
|
|
568
511
|
url: `/${product}/api/Application/Calculate`,
|
|
569
512
|
data: data,
|
|
@@ -571,7 +514,7 @@ export class ApiClass {
|
|
|
571
514
|
}
|
|
572
515
|
|
|
573
516
|
async getDefaultCalculationData(product: string | undefined | null = this.productUrl) {
|
|
574
|
-
return await this.axiosCall<RecalculationDataType>({
|
|
517
|
+
return await this.axiosCall<Types.RecalculationDataType>({
|
|
575
518
|
method: Methods.GET,
|
|
576
519
|
url: `/${product}/api/Application/DefaultCalculatorValues`,
|
|
577
520
|
});
|
|
@@ -585,8 +528,8 @@ export class ApiClass {
|
|
|
585
528
|
});
|
|
586
529
|
}
|
|
587
530
|
|
|
588
|
-
async getValidateClientESBD(data: ESBDValidationType) {
|
|
589
|
-
return await this.axiosCall<ESBDResponseType>({
|
|
531
|
+
async getValidateClientESBD(data: Types.ESBDValidationType) {
|
|
532
|
+
return await this.axiosCall<Types.ESBDResponseType>({
|
|
590
533
|
method: Methods.POST,
|
|
591
534
|
url: '/externalservices/api/ExternalServices/GetValidateClientEsbd',
|
|
592
535
|
data: data,
|
|
@@ -616,16 +559,16 @@ export class ApiClass {
|
|
|
616
559
|
});
|
|
617
560
|
}
|
|
618
561
|
|
|
619
|
-
async getContragentFromGBDFL(data: Api.GBD.Request) {
|
|
620
|
-
return await this.axiosCall<Api.GBD.Response>({
|
|
562
|
+
async getContragentFromGBDFL(data: Types.Api.GBD.Request) {
|
|
563
|
+
return await this.axiosCall<Types.Api.GBD.Response>({
|
|
621
564
|
method: Methods.POST,
|
|
622
565
|
url: '/externalservices/api/ExternalServices/GetGbdflToken',
|
|
623
566
|
data: data,
|
|
624
567
|
});
|
|
625
568
|
}
|
|
626
569
|
|
|
627
|
-
async getFamilyInfo(data: Api.GBD.Request) {
|
|
628
|
-
return await this.axiosCall<Api.GKB.Response>({
|
|
570
|
+
async getFamilyInfo(data: Types.Api.GBD.Request) {
|
|
571
|
+
return await this.axiosCall<Types.Api.GKB.Response>({
|
|
629
572
|
method: Methods.POST,
|
|
630
573
|
url: '/externalservices/api/ExternalServices/GetFamilyInfoToken',
|
|
631
574
|
data: data,
|
|
@@ -633,7 +576,7 @@ export class ApiClass {
|
|
|
633
576
|
}
|
|
634
577
|
|
|
635
578
|
async getKgd(data: { iinBin: string }, timeout: number = 30000) {
|
|
636
|
-
return await this.axiosCall<Api.KGD.Response>({
|
|
579
|
+
return await this.axiosCall<Types.Api.KGD.Response>({
|
|
637
580
|
method: Methods.POST,
|
|
638
581
|
url: '/externalservices/api/ExternalServices/GetKgd',
|
|
639
582
|
data: data,
|
|
@@ -641,7 +584,7 @@ export class ApiClass {
|
|
|
641
584
|
});
|
|
642
585
|
}
|
|
643
586
|
|
|
644
|
-
async getGbdUl(data: Api.GBD.UlRequest) {
|
|
587
|
+
async getGbdUl(data: Types.Api.GBD.UlRequest) {
|
|
645
588
|
return await this.axiosCall({
|
|
646
589
|
method: Methods.POST,
|
|
647
590
|
url: '/integration/api/External/GetGbdUl',
|
|
@@ -668,7 +611,7 @@ export class ApiClass {
|
|
|
668
611
|
});
|
|
669
612
|
}
|
|
670
613
|
|
|
671
|
-
async sendUnderwritingCouncilTask(data: Partial<SendTask>) {
|
|
614
|
+
async sendUnderwritingCouncilTask(data: Partial<Types.SendTask>) {
|
|
672
615
|
return await this.axiosCall<void>({
|
|
673
616
|
method: Methods.POST,
|
|
674
617
|
url: '/Arm/api/UnderwritingCouncil/SendTask',
|
|
@@ -690,7 +633,7 @@ export class ApiClass {
|
|
|
690
633
|
});
|
|
691
634
|
}
|
|
692
635
|
|
|
693
|
-
async setINSISWorkData(data: InsisWorkDataApp) {
|
|
636
|
+
async setINSISWorkData(data: Types.InsisWorkDataApp) {
|
|
694
637
|
return await this.axiosCall({
|
|
695
638
|
method: Methods.POST,
|
|
696
639
|
url: `/Arm/api/Bpm/SetInsisWorkData`,
|
|
@@ -705,8 +648,15 @@ export class ApiClass {
|
|
|
705
648
|
});
|
|
706
649
|
}
|
|
707
650
|
|
|
651
|
+
async getBankByAccountNumber(accountNumber: string) {
|
|
652
|
+
return await this.axiosCall<Value>({
|
|
653
|
+
method: Methods.GET,
|
|
654
|
+
url: `/Ekk/api/ContragentInsis/GetBankByAccountNumber?accountNumber=${accountNumber}`,
|
|
655
|
+
});
|
|
656
|
+
}
|
|
657
|
+
|
|
708
658
|
async searchAgentByName(name: string, branchCode?: string) {
|
|
709
|
-
return await this.axiosCall<AgentData[]>({
|
|
659
|
+
return await this.axiosCall<Types.AgentData[]>({
|
|
710
660
|
method: Methods.GET,
|
|
711
661
|
url: `/Ekk/api/ContragentInsis/Agent${branchCode ? 's' : ''}ByName?${branchCode ? `branchCode=${branchCode}&` : ''}fullName=${name}`,
|
|
712
662
|
});
|
|
@@ -727,14 +677,14 @@ export class ApiClass {
|
|
|
727
677
|
}
|
|
728
678
|
|
|
729
679
|
async getTripInsuranceDaysOptions() {
|
|
730
|
-
return await this.axiosCall<TripInsuranceDaysOptions>({
|
|
680
|
+
return await this.axiosCall<Types.TripInsuranceDaysOptions>({
|
|
731
681
|
method: Methods.GET,
|
|
732
682
|
url: `/${this.productUrl}/api/Application/TripInsuranceDaysOptions`,
|
|
733
683
|
});
|
|
734
684
|
}
|
|
735
685
|
|
|
736
|
-
async getTripInsuredAmount(data: getTripInsuredAmountRequest) {
|
|
737
|
-
return await this.axiosCall<TripInsuranceAmount>({
|
|
686
|
+
async getTripInsuredAmount(data: Types.getTripInsuredAmountRequest) {
|
|
687
|
+
return await this.axiosCall<Types.TripInsuranceAmount>({
|
|
738
688
|
method: Methods.POST,
|
|
739
689
|
url: `/${this.productUrl}/api/Application/InsuranceAmountOptions`,
|
|
740
690
|
data: data,
|
|
@@ -766,7 +716,7 @@ export class ApiClass {
|
|
|
766
716
|
});
|
|
767
717
|
}
|
|
768
718
|
|
|
769
|
-
async getCalculator(data: SetApplicationRequest) {
|
|
719
|
+
async getCalculator(data: Types.SetApplicationRequest) {
|
|
770
720
|
return await this.axiosCall<number>({
|
|
771
721
|
method: Methods.POST,
|
|
772
722
|
url: `/${this.productUrl}/api/Application/Calculator`,
|
|
@@ -965,32 +915,8 @@ export class ApiClass {
|
|
|
965
915
|
});
|
|
966
916
|
}
|
|
967
917
|
|
|
968
|
-
async
|
|
969
|
-
return await this.axiosCall<
|
|
970
|
-
url: `/File/api/Document/UploadXml`,
|
|
971
|
-
method: Methods.POST,
|
|
972
|
-
data: data,
|
|
973
|
-
});
|
|
974
|
-
}
|
|
975
|
-
|
|
976
|
-
async signXml(data: any) {
|
|
977
|
-
return await this.axiosCall<ResponseStructure<any>>({
|
|
978
|
-
url: `/File/api/Sign/SignXml`,
|
|
979
|
-
method: Methods.POST,
|
|
980
|
-
data: data,
|
|
981
|
-
});
|
|
982
|
-
}
|
|
983
|
-
|
|
984
|
-
async signBts(data: any) {
|
|
985
|
-
return await this.axiosCall<ResponseStructure<SignUrlType[]>>({
|
|
986
|
-
url: `/File/api/Sign/SignBts`,
|
|
987
|
-
method: Methods.POST,
|
|
988
|
-
data: data,
|
|
989
|
-
});
|
|
990
|
-
}
|
|
991
|
-
|
|
992
|
-
async generateShortLink(data: Api.GenerateShortLink.Request) {
|
|
993
|
-
return await this.axiosCall<Api.GenerateShortLink.Response>({
|
|
918
|
+
async generateShortLink(data: Types.Api.GenerateShortLink.Request) {
|
|
919
|
+
return await this.axiosCall<Types.Api.GenerateShortLink.Response>({
|
|
994
920
|
url: '/notification/shorteners',
|
|
995
921
|
baseURL: getStrValuePerEnv('gatewayApiUrl'),
|
|
996
922
|
method: Methods.POST,
|
|
@@ -998,12 +924,13 @@ export class ApiClass {
|
|
|
998
924
|
});
|
|
999
925
|
}
|
|
1000
926
|
|
|
1001
|
-
async checkOsns(bin: string) {
|
|
927
|
+
async checkOsns(bin: string, date: string) {
|
|
1002
928
|
return await this.axiosCall<boolean>({
|
|
1003
929
|
method: Methods.GET,
|
|
1004
930
|
url: `/${this.productUrl}/api/Application/CheckOSNS`,
|
|
1005
931
|
params: {
|
|
1006
932
|
bin,
|
|
933
|
+
date,
|
|
1007
934
|
},
|
|
1008
935
|
});
|
|
1009
936
|
}
|
|
@@ -1018,7 +945,7 @@ export class ApiClass {
|
|
|
1018
945
|
});
|
|
1019
946
|
}
|
|
1020
947
|
|
|
1021
|
-
async getOsrnsToken(data: Api.GBD.Request) {
|
|
948
|
+
async getOsrnsToken(data: Types.Api.GBD.Request) {
|
|
1022
949
|
return await this.axiosCall({
|
|
1023
950
|
method: Methods.POST,
|
|
1024
951
|
url: '/externalservices/api/ExternalServices/GetOsrnsToken',
|
|
@@ -1036,28 +963,6 @@ export class ApiClass {
|
|
|
1036
963
|
});
|
|
1037
964
|
}
|
|
1038
965
|
|
|
1039
|
-
async uploadDigitalCertifijcate(data: any) {
|
|
1040
|
-
return await this.axiosCall<any>({
|
|
1041
|
-
method: Methods.POST,
|
|
1042
|
-
url: '/File/api/Document/UploadDigitalCertifijcate',
|
|
1043
|
-
headers: {
|
|
1044
|
-
'Content-Type': 'multipart/form-data',
|
|
1045
|
-
},
|
|
1046
|
-
data: data,
|
|
1047
|
-
});
|
|
1048
|
-
}
|
|
1049
|
-
|
|
1050
|
-
async uploadDigitalCertificatePensionAnnuityNew(data: any) {
|
|
1051
|
-
return await this.axiosCall<any>({
|
|
1052
|
-
method: Methods.POST,
|
|
1053
|
-
url: '/File/api/Document/UploadDigitalCertificatePensionAnnuityNew',
|
|
1054
|
-
headers: {
|
|
1055
|
-
'Content-Type': 'multipart/form-data',
|
|
1056
|
-
},
|
|
1057
|
-
data: data,
|
|
1058
|
-
});
|
|
1059
|
-
}
|
|
1060
|
-
|
|
1061
966
|
async startRejectedApplication(data: any) {
|
|
1062
967
|
return await this.axiosCall({
|
|
1063
968
|
method: Methods.POST,
|
|
@@ -1066,22 +971,15 @@ export class ApiClass {
|
|
|
1066
971
|
});
|
|
1067
972
|
}
|
|
1068
973
|
|
|
1069
|
-
async getDocumentsByEdsXmlId(edsXmlId: string) {
|
|
1070
|
-
return await this.axiosCall<ResponseStructure<any>>({
|
|
1071
|
-
method: Methods.GET,
|
|
1072
|
-
url: `/File/api/Sign/GetDocumentsByEdsXmlId/${edsXmlId}`,
|
|
1073
|
-
});
|
|
1074
|
-
}
|
|
1075
|
-
|
|
1076
974
|
async checkSign(id: string) {
|
|
1077
|
-
return await this.axiosCall<SignedState>({
|
|
975
|
+
return await this.axiosCall<Types.SignedState>({
|
|
1078
976
|
method: Methods.POST,
|
|
1079
977
|
url: `/${this.productUrl}/api/Application/CheckSign/${id}`,
|
|
1080
978
|
});
|
|
1081
979
|
}
|
|
1082
980
|
|
|
1083
981
|
async getWorkPosition(search: string) {
|
|
1084
|
-
return await this.axiosCall<Dicts.WorkPosition[]>({
|
|
982
|
+
return await this.axiosCall<Types.Dicts.WorkPosition[]>({
|
|
1085
983
|
method: Methods.POST,
|
|
1086
984
|
baseURL: getStrValuePerEnv('efoBaseApi'),
|
|
1087
985
|
url: '/dictionary/Dictionary/WorkPosition',
|
|
@@ -1089,21 +987,192 @@ export class ApiClass {
|
|
|
1089
987
|
});
|
|
1090
988
|
}
|
|
1091
989
|
|
|
1092
|
-
async
|
|
1093
|
-
return await this.axiosCall<{
|
|
1094
|
-
method: Methods.
|
|
1095
|
-
|
|
1096
|
-
|
|
1097
|
-
|
|
990
|
+
async getParentContractData(policyId: string) {
|
|
991
|
+
return await this.axiosCall<{ bin: string; name: string }>({
|
|
992
|
+
method: Methods.GET,
|
|
993
|
+
url: `/${this.productUrl}/api/Application/GetParentContractData`,
|
|
994
|
+
params: {
|
|
995
|
+
policyId,
|
|
996
|
+
},
|
|
1098
997
|
});
|
|
1099
998
|
}
|
|
1100
999
|
|
|
1101
|
-
async
|
|
1102
|
-
return await this.axiosCall<
|
|
1103
|
-
method: Methods.
|
|
1104
|
-
|
|
1105
|
-
|
|
1106
|
-
|
|
1000
|
+
async getContractByBin(bin: string) {
|
|
1001
|
+
return await this.axiosCall<Types.GetContractByBinResponse>({
|
|
1002
|
+
method: Methods.GET,
|
|
1003
|
+
url: `/${this.productUrl}/api/Application/getContractByBin`,
|
|
1004
|
+
params: {
|
|
1005
|
+
bin,
|
|
1006
|
+
},
|
|
1107
1007
|
});
|
|
1108
1008
|
}
|
|
1009
|
+
|
|
1010
|
+
async checkProActiveService(processInstanceId: string | number, iin: string) {
|
|
1011
|
+
return await this.axiosCall({
|
|
1012
|
+
method: Methods.GET,
|
|
1013
|
+
url: `/${this.productUrl}/api/Application/CheckProActiveService`,
|
|
1014
|
+
params: {
|
|
1015
|
+
processInstanceId,
|
|
1016
|
+
iin,
|
|
1017
|
+
},
|
|
1018
|
+
});
|
|
1019
|
+
}
|
|
1020
|
+
|
|
1021
|
+
pensionannuityNew = {
|
|
1022
|
+
base: '/pensionannuityNew',
|
|
1023
|
+
getEnpfRedirectUrl: async (id: string) => {
|
|
1024
|
+
return await this.axiosCall<{ redirectUrl: string }>({
|
|
1025
|
+
method: Methods.POST,
|
|
1026
|
+
baseURL: getStrValuePerEnv('efoBaseApi'),
|
|
1027
|
+
url: `${this.pensionannuityNew.base}/GetEnpfRedirectUrl?id=${id}`,
|
|
1028
|
+
});
|
|
1029
|
+
},
|
|
1030
|
+
setEnpfSharedId: async (sharedId: string, infoId: string, isProd: boolean) => {
|
|
1031
|
+
return await this.axiosCall<void>({
|
|
1032
|
+
method: Methods.POST,
|
|
1033
|
+
baseURL: isProd === false ? getStrValuePerEnv('efoBaseApi').replace('kz/efo', 'kz/test/efo') : getStrValuePerEnv('efoBaseApi'),
|
|
1034
|
+
url: `${this.pensionannuityNew.base}/SetEnpfSharedId/${sharedId}/${infoId}`,
|
|
1035
|
+
});
|
|
1036
|
+
},
|
|
1037
|
+
};
|
|
1038
|
+
|
|
1039
|
+
externalServices = {
|
|
1040
|
+
base: '/externalservices',
|
|
1041
|
+
getOnlineAccess: async (data: { iinBin: string; documentType: string }) => {
|
|
1042
|
+
return await this.axiosCall<{ code: string; message: string }>({
|
|
1043
|
+
method: Methods.POST,
|
|
1044
|
+
url: `${this.externalServices.base}/api/ExternalServices/GetOnlineAccess`,
|
|
1045
|
+
data: data,
|
|
1046
|
+
});
|
|
1047
|
+
},
|
|
1048
|
+
getDigitalDocuments: async (data: { iin: string; processInstanceId: string; code: string }) => {
|
|
1049
|
+
return await this.axiosCall<void>({
|
|
1050
|
+
method: Methods.POST,
|
|
1051
|
+
url: `${this.externalServices.base}/api/ExternalServices/DigitalDocuments`,
|
|
1052
|
+
data: data,
|
|
1053
|
+
});
|
|
1054
|
+
},
|
|
1055
|
+
};
|
|
1056
|
+
|
|
1057
|
+
file = {
|
|
1058
|
+
base: '/File',
|
|
1059
|
+
uploadFilesNew: async (groupId: string, data: any) => {
|
|
1060
|
+
return await this.axiosCall({
|
|
1061
|
+
method: Methods.POST,
|
|
1062
|
+
url: `${this.file.base}/api/GeneralSign/UploadPaper/${groupId}`,
|
|
1063
|
+
headers: {
|
|
1064
|
+
'Content-Type': 'multipart/form-data',
|
|
1065
|
+
},
|
|
1066
|
+
data: data,
|
|
1067
|
+
});
|
|
1068
|
+
},
|
|
1069
|
+
generalGetFile: async (groupId: string, documentSignType: number) => {
|
|
1070
|
+
return await this.axiosCall<any>({
|
|
1071
|
+
method: Methods.GET,
|
|
1072
|
+
url: `${this.file.base}/api/GeneralSign/Group/${groupId}/${documentSignType} `,
|
|
1073
|
+
responseType: documentSignType === 5 ? 'json' : 'arraybuffer',
|
|
1074
|
+
});
|
|
1075
|
+
},
|
|
1076
|
+
generalSign: async (data: Types.Api.Sign.New.GeneralResponse) => {
|
|
1077
|
+
return await this.axiosCall<Types.Api.Sign.New.Response>({
|
|
1078
|
+
method: Methods.POST,
|
|
1079
|
+
url: `${this.file.base}/api/GeneralSign/Sign`,
|
|
1080
|
+
data: data,
|
|
1081
|
+
});
|
|
1082
|
+
},
|
|
1083
|
+
generateSign: async (data: Types.Api.Sign.New.Request) => {
|
|
1084
|
+
return await this.axiosCall<Types.Api.Sign.New.GeneralResponse[]>({
|
|
1085
|
+
method: Methods.POST,
|
|
1086
|
+
url: `${this.file.base}/api/GeneralSign/GenerateSign`,
|
|
1087
|
+
data: data,
|
|
1088
|
+
});
|
|
1089
|
+
},
|
|
1090
|
+
uploadDigitalCertificateNca: async (groupId: string, data: any) => {
|
|
1091
|
+
return await this.axiosCall<void>({
|
|
1092
|
+
method: Methods.POST,
|
|
1093
|
+
url: `${this.file.base}/api/GeneralSign/UploadNClayer/${groupId}`,
|
|
1094
|
+
headers: {
|
|
1095
|
+
'Content-Type': 'multipart/form-data',
|
|
1096
|
+
},
|
|
1097
|
+
data: data,
|
|
1098
|
+
});
|
|
1099
|
+
},
|
|
1100
|
+
uploadXml: async (data: any) => {
|
|
1101
|
+
return await this.axiosCall<void>({
|
|
1102
|
+
url: `${this.file.base}/api/GeneralSign/UploadXml`,
|
|
1103
|
+
method: Methods.POST,
|
|
1104
|
+
data: data,
|
|
1105
|
+
});
|
|
1106
|
+
},
|
|
1107
|
+
signXml: async (data: any) => {
|
|
1108
|
+
return await this.axiosCall<Types.ResponseStructure<any>>({
|
|
1109
|
+
url: `${this.file.base}/api/Sign/SignXml`,
|
|
1110
|
+
method: Methods.POST,
|
|
1111
|
+
data: data,
|
|
1112
|
+
});
|
|
1113
|
+
},
|
|
1114
|
+
signBts: async (data: any) => {
|
|
1115
|
+
return await this.axiosCall<Types.ResponseStructure<Types.SignUrlType[]>>({
|
|
1116
|
+
url: `${this.file.base}/api/Sign/SignBts`,
|
|
1117
|
+
method: Methods.POST,
|
|
1118
|
+
data: data,
|
|
1119
|
+
});
|
|
1120
|
+
},
|
|
1121
|
+
getFile: async (id: string) => {
|
|
1122
|
+
return await this.axiosCall({
|
|
1123
|
+
method: Methods.GET,
|
|
1124
|
+
url: `${this.file.base}/api/Data/DownloadFile/${id}`,
|
|
1125
|
+
responseType: 'arraybuffer',
|
|
1126
|
+
headers: {
|
|
1127
|
+
'Content-Type': 'application/pdf',
|
|
1128
|
+
},
|
|
1129
|
+
});
|
|
1130
|
+
},
|
|
1131
|
+
deleteFile: async (data: any) => {
|
|
1132
|
+
return await this.axiosCall<void>({
|
|
1133
|
+
method: Methods.POST,
|
|
1134
|
+
url: `${this.file.base}/api/Data/DeleteFiles`,
|
|
1135
|
+
data: data,
|
|
1136
|
+
});
|
|
1137
|
+
},
|
|
1138
|
+
uploadFiles: async (data: any) => {
|
|
1139
|
+
return await this.axiosCall({
|
|
1140
|
+
method: Methods.POST,
|
|
1141
|
+
url: `${this.file.base}/api/Data/UploadFiles`,
|
|
1142
|
+
headers: {
|
|
1143
|
+
'Content-Type': 'multipart/form-data',
|
|
1144
|
+
},
|
|
1145
|
+
data: data,
|
|
1146
|
+
});
|
|
1147
|
+
},
|
|
1148
|
+
signDocument: async (data: Types.SignDataType[]) => {
|
|
1149
|
+
return await this.axiosCall<Types.SignUrlType[]>({
|
|
1150
|
+
method: Methods.POST,
|
|
1151
|
+
url: `${this.file.base}/api/Document/SignBts`,
|
|
1152
|
+
data: data,
|
|
1153
|
+
});
|
|
1154
|
+
},
|
|
1155
|
+
signQR: async (data: Types.SignDataType[]) => {
|
|
1156
|
+
return await this.axiosCall<Types.ResponseStructure<any>>({
|
|
1157
|
+
method: Methods.POST,
|
|
1158
|
+
url: `${this.file.base}/api/Sign/SignQr`,
|
|
1159
|
+
data: data,
|
|
1160
|
+
});
|
|
1161
|
+
},
|
|
1162
|
+
generateDocument: async (data: Types.SignDataType) => {
|
|
1163
|
+
return await this.axiosCall<void>({
|
|
1164
|
+
method: Methods.POST,
|
|
1165
|
+
url: `${this.file.base}/api/Document/Generate`,
|
|
1166
|
+
responseType: 'arraybuffer',
|
|
1167
|
+
data: data,
|
|
1168
|
+
});
|
|
1169
|
+
},
|
|
1170
|
+
getSignedDocList: async (data: { processInstanceId: string | number }) => {
|
|
1171
|
+
return await this.axiosCall<IDocument[]>({
|
|
1172
|
+
method: Methods.POST,
|
|
1173
|
+
url: `${this.file.base}/api/Data/List`,
|
|
1174
|
+
data: data,
|
|
1175
|
+
});
|
|
1176
|
+
},
|
|
1177
|
+
};
|
|
1109
1178
|
}
|