hl-core 0.0.10-beta.25 → 0.0.10-beta.27
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 +10 -33
- package/components/Form/ManagerAttachment.vue +16 -4
- package/components/Pages/ContragentForm.vue +1 -1
- package/components/Pages/MemberForm.vue +29 -59
- package/components/Pages/ProductConditions.vue +34 -154
- package/components/Panel/PanelHandler.vue +12 -30
- package/components/Utilities/Chip.vue +1 -1
- package/composables/classes.ts +0 -8
- package/composables/constants.ts +1 -17
- package/composables/index.ts +5 -2
- package/locales/ru.json +3 -5
- package/package.json +1 -1
- package/store/data.store.ts +59 -239
- package/store/member.store.ts +4 -15
- package/store/rules.ts +6 -0
- package/types/enum.ts +1 -1
- package/types/index.ts +2 -1
|
@@ -56,7 +56,7 @@
|
|
|
56
56
|
</div>
|
|
57
57
|
</base-form-section>
|
|
58
58
|
<base-form-section
|
|
59
|
-
v-if="isUnderwriterRole && whichProduct !== 'lifebusiness' && whichProduct !== 'gns' && whichProduct !== 'pensionannuitynew'"
|
|
59
|
+
v-if="isUnderwriterRole && whichProduct !== 'lifebusiness' && whichProduct !== 'gns' && whichProduct !== 'pensionannuitynew' && whichProduct !== 'balam'"
|
|
60
60
|
:title="$dataStore.t('recalculationInfo')"
|
|
61
61
|
>
|
|
62
62
|
<base-form-input
|
|
@@ -152,17 +152,6 @@
|
|
|
152
152
|
@append="openPanel($dataStore.t('form.gender'), $dataStore.gender, 'gender')"
|
|
153
153
|
/>
|
|
154
154
|
</div>
|
|
155
|
-
<base-panel-input
|
|
156
|
-
v-if="hasCurrency"
|
|
157
|
-
v-model="productConditionsForm.currency"
|
|
158
|
-
:value="productConditionsForm.currency.nameRu"
|
|
159
|
-
:readonly="isDisabled"
|
|
160
|
-
:clearable="!isDisabled"
|
|
161
|
-
:label="$dataStore.t('agent.currency')"
|
|
162
|
-
:rules="$rules.objectRequired"
|
|
163
|
-
append-inner-icon="mdi mdi-chevron-right"
|
|
164
|
-
@append="openPanel($dataStore.t('agent.currency'), $constants.currencyList, 'currency')"
|
|
165
|
-
/>
|
|
166
155
|
<base-form-input
|
|
167
156
|
v-if="hasInsStartDate"
|
|
168
157
|
v-model="productConditionsForm.calcDate"
|
|
@@ -196,8 +185,8 @@
|
|
|
196
185
|
v-if="hasPaymentPeriod"
|
|
197
186
|
v-model="productConditionsForm.paymentPeriod"
|
|
198
187
|
:value="productConditionsForm.paymentPeriod?.nameRu"
|
|
199
|
-
:readonly="
|
|
200
|
-
:clearable="!
|
|
188
|
+
:readonly="isDisabled"
|
|
189
|
+
:clearable="!isDisabled"
|
|
201
190
|
:rules="$rules.objectRequired"
|
|
202
191
|
:label="$dataStore.t('productConditionsForm.processPaymentPeriod')"
|
|
203
192
|
append-inner-icon="mdi mdi-chevron-right"
|
|
@@ -267,10 +256,10 @@
|
|
|
267
256
|
@onClear="onClearPremiumDollar"
|
|
268
257
|
/>
|
|
269
258
|
<base-form-input
|
|
270
|
-
v-if="
|
|
259
|
+
v-if="hasCurrency && $dataStore.currencies.usd"
|
|
271
260
|
v-model="$dataStore.currencies.usd"
|
|
272
261
|
:readonly="true"
|
|
273
|
-
:label="
|
|
262
|
+
:label="$dataStore.t('productConditionsForm.dollarExchangeRateNBRK')"
|
|
274
263
|
:suffix="$constants.currencySymbols.kzt"
|
|
275
264
|
/>
|
|
276
265
|
<base-form-input
|
|
@@ -312,37 +301,14 @@
|
|
|
312
301
|
</base-form-section>
|
|
313
302
|
<section v-if="whichProduct === 'pensionannuitynew'">
|
|
314
303
|
<base-animation>
|
|
315
|
-
<
|
|
316
|
-
v-if="
|
|
317
|
-
:
|
|
318
|
-
class="h-[
|
|
319
|
-
|
|
320
|
-
|
|
321
|
-
</div>
|
|
304
|
+
<base-btn
|
|
305
|
+
v-if="formStore.applicationData.processCode === 19 && !isDisabled"
|
|
306
|
+
:text="$dataStore.t('buttons.copyToClient')"
|
|
307
|
+
class="mt-4 min-h-[60px]"
|
|
308
|
+
@click="copyRedirect"
|
|
309
|
+
/>
|
|
322
310
|
</base-animation>
|
|
323
|
-
<
|
|
324
|
-
<div :class="[$styles.blueBgLight]" class="flex flex-wrap items-center gap-2 p-1 rounded-t-[8px] h-full">
|
|
325
|
-
<div
|
|
326
|
-
class="h-full px-4 py-1 rounded-[8px] cursor-pointer flex items-center"
|
|
327
|
-
:class="[$styles.textSimple, !isSlavePensionForm ? `${$styles.blueBg} ${$styles.whiteText}` : '']"
|
|
328
|
-
@click="$router.replace({ query: { ...$route.query, which: undefined, upd: 'true' } })"
|
|
329
|
-
>
|
|
330
|
-
Страхователь
|
|
331
|
-
</div>
|
|
332
|
-
<div
|
|
333
|
-
class="h-full px-4 py-1 rounded-[8px] cursor-pointer flex items-center"
|
|
334
|
-
:class="[$styles.textSimple, isSlavePensionForm ? `${$styles.blueBg} ${$styles.whiteText}` : '']"
|
|
335
|
-
@click="$router.replace({ query: { ...$route.query, which: 'slave', upd: 'true' } })"
|
|
336
|
-
>
|
|
337
|
-
Страхователь 1
|
|
338
|
-
</div>
|
|
339
|
-
</div>
|
|
340
|
-
</div>
|
|
341
|
-
<base-form-section
|
|
342
|
-
v-if="formStore.applicationData.processCode !== 2"
|
|
343
|
-
:title="$dataStore.t('pension.compulsoryAmount&Prof')"
|
|
344
|
-
:class="[formStore.applicationData.processCode === 4 ? 'mt-0 rounded-tl-none' : '']"
|
|
345
|
-
>
|
|
311
|
+
<base-form-section :title="$dataStore.t('pension.compulsoryAmount&Prof')">
|
|
346
312
|
<base-form-input
|
|
347
313
|
v-model="pensionCalculationParams.compulsoryContractAmount"
|
|
348
314
|
:maska="$maska.numbers"
|
|
@@ -425,7 +391,7 @@
|
|
|
425
391
|
v-model="contractDate"
|
|
426
392
|
:maska="$maska.date"
|
|
427
393
|
:rules="!isDisabled ? $rules.required.concat($rules.date) : []"
|
|
428
|
-
:readonly="isDisabled
|
|
394
|
+
:readonly="isDisabled"
|
|
429
395
|
:clearable="!isDisabled"
|
|
430
396
|
:min-date="new Date()"
|
|
431
397
|
:label="$dataStore.t('pension.contractDate')"
|
|
@@ -446,13 +412,6 @@
|
|
|
446
412
|
<base-form-input v-model="pensionForm.frequencyPayments" disabled :label="$dataStore.t('pension.frequencyPayments')" />
|
|
447
413
|
<base-form-input v-model="pensionForm.periodPayments" disabled :label="$dataStore.t('pension.paymentPeriod')" />
|
|
448
414
|
<base-form-input v-model="pensionForm.insuranceProgramType" disabled :label="$dataStore.t('pension.insuranceProgramType')" />
|
|
449
|
-
<base-form-input
|
|
450
|
-
v-if="formStore.applicationData.processCode === 4 && formStore.applicationData.slave?.pensionApp?.amount"
|
|
451
|
-
:value="Number(formStore.applicationData.pensionApp.amount) + Number(formStore.applicationData.slave.pensionApp.amount)"
|
|
452
|
-
:active="true"
|
|
453
|
-
label="Общая страховая премия в тенге"
|
|
454
|
-
readonly
|
|
455
|
-
/>
|
|
456
415
|
<base-form-input v-model="pensionAmount" readonly :maska="$maska.numbers" :label="$dataStore.t('pension.pensionAmount')" />
|
|
457
416
|
<base-form-input v-model="pensionForm.payment" readonly :maska="$maska.numbers" :label="$dataStore.t('pension.pensionPayment')" />
|
|
458
417
|
</base-form-section>
|
|
@@ -822,8 +781,7 @@ export default defineComponent({
|
|
|
822
781
|
const transferContractDate = ref();
|
|
823
782
|
const transferContractFirstPaymentDate = ref();
|
|
824
783
|
const guaranteedPeriodList = Array.from(Array(35), (e, i) => i + 1);
|
|
825
|
-
const
|
|
826
|
-
const pensionForm = isSlavePensionForm.value ? formStore.applicationData?.slave?.pensionApp : formStore.applicationData?.pensionApp ?? undefined;
|
|
784
|
+
const pensionForm = formStore.applicationData?.pensionApp ?? undefined;
|
|
827
785
|
const isEnpfSum = (formStore.applicationData?.isEnpfSum ?? false) && useEnv().isProduction;
|
|
828
786
|
|
|
829
787
|
const transferContracts = ref<TransferContract[]>([]);
|
|
@@ -861,9 +819,7 @@ export default defineComponent({
|
|
|
861
819
|
const isTask = computed(() => (route.params.taskId === '0' && props.isCalculator === true) || dataStore.isTask() || fromIndexPage.value);
|
|
862
820
|
const isRecalculationDisabled = computed(() => formStore.isDisabled.recalculationForm || formStore.canBeClaimed === true);
|
|
863
821
|
const isUnderwriterRole = computed(() => dataStore.isUnderwriter() || dataStore.isAdmin() || dataStore.isSupport());
|
|
864
|
-
const insurancePremiumPerMonthRule = computed(() =>
|
|
865
|
-
!!productConditionsForm.insurancePremiumPerMonth ? (whichProduct.value === 'gons' ? dataStore.rules.required : dataStore.rules.required.concat(dataStore.rules.sums)) : [],
|
|
866
|
-
);
|
|
822
|
+
const insurancePremiumPerMonthRule = computed(() => (!!productConditionsForm.insurancePremiumPerMonth ? dataStore.rules.required.concat(dataStore.rules.sums) : []));
|
|
867
823
|
const insurancePremiumPerMonthDisabled = computed(() => {
|
|
868
824
|
if (whichProduct.value === 'lifebusiness' || whichProduct.value === 'gns') {
|
|
869
825
|
return true;
|
|
@@ -873,9 +829,7 @@ export default defineComponent({
|
|
|
873
829
|
}
|
|
874
830
|
return isDisabled.value;
|
|
875
831
|
});
|
|
876
|
-
const requestedSumInsuredRule = computed(() =>
|
|
877
|
-
!!productConditionsForm.requestedSumInsured ? (whichProduct.value === 'gons' ? dataStore.rules.required : dataStore.rules.required.concat(dataStore.rules.sums)) : [],
|
|
878
|
-
);
|
|
832
|
+
const requestedSumInsuredRule = computed(() => (!!productConditionsForm.requestedSumInsured ? dataStore.rules.required.concat(dataStore.rules.sums) : []));
|
|
879
833
|
const fixInsSumRule = computed(() =>
|
|
880
834
|
!!productConditionsForm.fixInsSum
|
|
881
835
|
? dataStore.rules.required.concat(dataStore.rules.sums, dataStore.rules.fixInsSumLimit(getNumber(productConditionsForm.fixInsSum as string), minInsSum.value))
|
|
@@ -895,7 +849,8 @@ export default defineComponent({
|
|
|
895
849
|
whichProduct.value === 'liferenta' ||
|
|
896
850
|
whichProduct.value === 'lifebusiness' ||
|
|
897
851
|
whichProduct.value === 'amuletlife' ||
|
|
898
|
-
whichProduct.value === 'gns'
|
|
852
|
+
whichProduct.value === 'gns' ||
|
|
853
|
+
whichProduct.value === 'balam'
|
|
899
854
|
) {
|
|
900
855
|
return false;
|
|
901
856
|
}
|
|
@@ -917,27 +872,18 @@ export default defineComponent({
|
|
|
917
872
|
if (whichProduct.value === 'halykkazyna') {
|
|
918
873
|
return true;
|
|
919
874
|
}
|
|
920
|
-
if (whichProduct.value === 'gons' && productConditionsForm.currency.code === 'USD') {
|
|
921
|
-
return true;
|
|
922
|
-
}
|
|
923
875
|
return false;
|
|
924
876
|
});
|
|
925
877
|
const hasInsurancePremiumPerMonthInDollar = computed(() => {
|
|
926
878
|
if (whichProduct.value === 'halykkazyna') {
|
|
927
879
|
return true;
|
|
928
880
|
}
|
|
929
|
-
if (whichProduct.value === 'gons' && productConditionsForm.currency.code === 'USD') {
|
|
930
|
-
return true;
|
|
931
|
-
}
|
|
932
881
|
return false;
|
|
933
882
|
});
|
|
934
|
-
const
|
|
883
|
+
const hasCurrency = computed(() => {
|
|
935
884
|
if (whichProduct.value === 'halykkazyna') {
|
|
936
885
|
return true;
|
|
937
886
|
}
|
|
938
|
-
if (whichProduct.value === 'gons' && productConditionsForm.currency.code === 'USD') {
|
|
939
|
-
return true;
|
|
940
|
-
}
|
|
941
887
|
return false;
|
|
942
888
|
});
|
|
943
889
|
const hasAdbMultiply = computed(() => {
|
|
@@ -1040,12 +986,6 @@ export default defineComponent({
|
|
|
1040
986
|
}
|
|
1041
987
|
return dataStore.t('productConditionsForm.insurancePremiumAmount');
|
|
1042
988
|
});
|
|
1043
|
-
const currencySymbolsLabel = computed(() => {
|
|
1044
|
-
if (whichProduct.value === 'gons') {
|
|
1045
|
-
return dataStore.t('productConditionsForm.exchangeRateSettlementDate');
|
|
1046
|
-
}
|
|
1047
|
-
return dataStore.t('productConditionsForm.dollarExchangeRateNBRK');
|
|
1048
|
-
});
|
|
1049
989
|
const isDisabledFixInsSum = computed(() => {
|
|
1050
990
|
if (dataStore.isUnderwriter() && !isRecalculationDisabled.value) {
|
|
1051
991
|
return false;
|
|
@@ -1140,18 +1080,6 @@ export default defineComponent({
|
|
|
1140
1080
|
}
|
|
1141
1081
|
return false;
|
|
1142
1082
|
});
|
|
1143
|
-
const hasCurrency = computed(() => {
|
|
1144
|
-
if (whichProduct.value === 'gons') {
|
|
1145
|
-
return true;
|
|
1146
|
-
}
|
|
1147
|
-
return false;
|
|
1148
|
-
});
|
|
1149
|
-
const isDisabledPaymentPeriod = computed(() => {
|
|
1150
|
-
if (whichProduct.value === 'gons' && productConditionsForm.currency.code === 'USD') {
|
|
1151
|
-
return true;
|
|
1152
|
-
}
|
|
1153
|
-
return isDisabled.value;
|
|
1154
|
-
});
|
|
1155
1083
|
|
|
1156
1084
|
const pensionCalculationParams = ref({
|
|
1157
1085
|
compulsoryContractAmount: pensionForm && pensionForm.compulsoryContractAmount && pensionForm.compulsoryContractAmount != 0 ? pensionForm.compulsoryContractAmount : null,
|
|
@@ -1163,7 +1091,8 @@ export default defineComponent({
|
|
|
1163
1091
|
transferContractCompany: pensionForm && pensionForm.transferContractCompany ? pensionForm.transferContractCompany : null,
|
|
1164
1092
|
});
|
|
1165
1093
|
|
|
1166
|
-
const contractsAmount = computed(() => transferContracts.value?.reduce((accumulator, currentValue) => accumulator +
|
|
1094
|
+
const contractsAmount = computed(() => transferContracts.value?.reduce((accumulator, currentValue) => accumulator + currentValue.transferContractAmount, 0));
|
|
1095
|
+
|
|
1167
1096
|
const pensionAmount = computed(() =>
|
|
1168
1097
|
pensionCalculationParams.value
|
|
1169
1098
|
? (Number(pensionCalculationParams.value.compulsoryContractAmount) ?? 0) +
|
|
@@ -1452,7 +1381,7 @@ export default defineComponent({
|
|
|
1452
1381
|
const calculatedPremiumDollar = getNumber(event.target.value as string);
|
|
1453
1382
|
if (calculatedPremiumDollar) {
|
|
1454
1383
|
productConditionsForm.insurancePremiumPerMonth = dataStore.getNumberWithSpaces(productConditionsForm.insurancePremiumPerMonth);
|
|
1455
|
-
if (whichProduct.value === 'halykkazyna'
|
|
1384
|
+
if (whichProduct.value === 'halykkazyna') {
|
|
1456
1385
|
if (typeof dataStore.currencies.usd === 'number') {
|
|
1457
1386
|
productConditionsForm.insurancePremiumPerMonthInDollar = dataStore.getNumberWithSpaces(calculatedPremiumDollar / dataStore.currencies.usd);
|
|
1458
1387
|
} else {
|
|
@@ -1480,7 +1409,7 @@ export default defineComponent({
|
|
|
1480
1409
|
const calculatedSumDollar = getNumber(event.target.value as string);
|
|
1481
1410
|
if (calculatedSumDollar) {
|
|
1482
1411
|
productConditionsForm.requestedSumInsured = dataStore.getNumberWithSpaces(productConditionsForm.requestedSumInsured);
|
|
1483
|
-
if (whichProduct.value === 'halykkazyna'
|
|
1412
|
+
if (whichProduct.value === 'halykkazyna') {
|
|
1484
1413
|
if (typeof dataStore.currencies.usd === 'number') {
|
|
1485
1414
|
productConditionsForm.requestedSumInsuredInDollar = dataStore.getNumberWithSpaces(calculatedSumDollar / dataStore.currencies.usd);
|
|
1486
1415
|
} else {
|
|
@@ -1546,7 +1475,7 @@ export default defineComponent({
|
|
|
1546
1475
|
};
|
|
1547
1476
|
|
|
1548
1477
|
const filterTermConditions = (term: AddCover) => {
|
|
1549
|
-
if (term.coverTypeCode === 10) {
|
|
1478
|
+
if (term.coverTypeCode === 10 && !props.isCalculator) {
|
|
1550
1479
|
return !!formStore.insuredForm.find((member: Member) => member.iin === formStore.policyholderForm.iin) === false;
|
|
1551
1480
|
}
|
|
1552
1481
|
return true;
|
|
@@ -1599,7 +1528,6 @@ export default defineComponent({
|
|
|
1599
1528
|
transferContractFirstPaymentDate: formatedFirstPaymentDate?.toISOString() ?? '',
|
|
1600
1529
|
// @ts-ignore
|
|
1601
1530
|
transferContractCompany: formatedNameRu,
|
|
1602
|
-
transferContractCompanyId: transferContracts.value[index].transferContractCompany?.ids,
|
|
1603
1531
|
id: transferContracts.value[index].id ?? null,
|
|
1604
1532
|
});
|
|
1605
1533
|
});
|
|
@@ -1615,23 +1543,19 @@ export default defineComponent({
|
|
|
1615
1543
|
transferContractAmount: Number(pensionCalculationParams.value.transferContractAmount),
|
|
1616
1544
|
transferContractCompany: pensionForm?.transferContractCompany?.nameRu ?? '',
|
|
1617
1545
|
}),
|
|
1618
|
-
amount: pensionAmount.value,
|
|
1619
1546
|
transferContracts: formatedContracts,
|
|
1620
1547
|
};
|
|
1621
|
-
await dataStore.setApplication(
|
|
1622
|
-
isSlavePensionForm.value ? { ...formStore.applicationData.pensionApp, slave: data } : { ...data, slave: formStore.applicationData.slave?.pensionApp ?? null },
|
|
1623
|
-
true,
|
|
1624
|
-
);
|
|
1548
|
+
await dataStore.setApplication(data, true);
|
|
1625
1549
|
} else {
|
|
1626
1550
|
if (whichSum.value === 'requestedSumInsured') {
|
|
1627
1551
|
productConditionsForm.insurancePremiumPerMonth = null;
|
|
1628
|
-
if (whichProduct.value === 'halykkazyna'
|
|
1552
|
+
if (whichProduct.value === 'halykkazyna') {
|
|
1629
1553
|
productConditionsForm.insurancePremiumPerMonthInDollar = null;
|
|
1630
1554
|
}
|
|
1631
1555
|
}
|
|
1632
1556
|
if (whichSum.value === 'insurancePremiumPerMonth') {
|
|
1633
1557
|
productConditionsForm.requestedSumInsured = null;
|
|
1634
|
-
if (whichProduct.value === 'halykkazyna'
|
|
1558
|
+
if (whichProduct.value === 'halykkazyna') {
|
|
1635
1559
|
productConditionsForm.requestedSumInsuredInDollar = null;
|
|
1636
1560
|
}
|
|
1637
1561
|
}
|
|
@@ -1745,10 +1669,6 @@ export default defineComponent({
|
|
|
1745
1669
|
if (dataStore.isCalculator) {
|
|
1746
1670
|
clearFields();
|
|
1747
1671
|
}
|
|
1748
|
-
if (whichProduct.value === 'gons') {
|
|
1749
|
-
formStore.isDisabled.productConditionsForm = false;
|
|
1750
|
-
dataStore.setFormsDisabled(false);
|
|
1751
|
-
}
|
|
1752
1672
|
if (whichProduct.value !== 'lifetrip' && whichProduct.value !== 'pensionannuitynew') {
|
|
1753
1673
|
if (
|
|
1754
1674
|
(dataStore.isCalculator || route.params.taskId === '0' || fromIndexPage.value) &&
|
|
@@ -1792,12 +1712,10 @@ export default defineComponent({
|
|
|
1792
1712
|
dataStore.processCode = constants.products[whichProduct.value as keyof typeof constants.products];
|
|
1793
1713
|
await dataStore.getProcessPaymentPeriod();
|
|
1794
1714
|
}
|
|
1795
|
-
if (whichProduct.value === 'halykkazyna' || whichProduct.value === 'gons') {
|
|
1796
|
-
await dataStore.getCurrencies();
|
|
1797
|
-
}
|
|
1798
1715
|
if (whichProduct.value === 'halykkazyna') {
|
|
1799
1716
|
const kazynaPaymentPeriod = dataStore.processPaymentPeriod.find(i => i.code === 'single');
|
|
1800
1717
|
if (kazynaPaymentPeriod) productConditionsForm.paymentPeriod = kazynaPaymentPeriod;
|
|
1718
|
+
await dataStore.getCurrencies();
|
|
1801
1719
|
}
|
|
1802
1720
|
if (whichProduct.value === 'lifebusiness' || whichProduct.value === 'gns') {
|
|
1803
1721
|
productConditionsForm.requestedSumInsured = dataStore.getNumberWithSpaces(
|
|
@@ -1807,12 +1725,12 @@ export default defineComponent({
|
|
|
1807
1725
|
);
|
|
1808
1726
|
}
|
|
1809
1727
|
if (whichProduct.value === 'pensionannuitynew') {
|
|
1810
|
-
contractDate.value = reformatDate(
|
|
1811
|
-
dateOfBegin.value = reformatDate(
|
|
1812
|
-
transferContractDate.value = reformatDate(
|
|
1813
|
-
transferContractFirstPaymentDate.value = reformatDate(
|
|
1728
|
+
contractDate.value = reformatDate(formStore.applicationData.pensionApp.contractDate);
|
|
1729
|
+
dateOfBegin.value = reformatDate(formStore.applicationData.pensionApp.dateOfBegin);
|
|
1730
|
+
transferContractDate.value = reformatDate(formStore.applicationData.pensionApp.transferContractDate);
|
|
1731
|
+
transferContractFirstPaymentDate.value = reformatDate(formStore.applicationData.pensionApp.transferContractFirstPaymentDate);
|
|
1814
1732
|
maxDate.value = await dataStore.getVariableData(formStore.applicationData.processCode ?? 19);
|
|
1815
|
-
if (
|
|
1733
|
+
if (transferContracts.value && transferContracts.value.length) {
|
|
1816
1734
|
transferContracts.value = pensionForm.transferContracts?.map((contract: TransferContract) => {
|
|
1817
1735
|
contract.transferContractDate = reformatDate(contract.transferContractDate)!;
|
|
1818
1736
|
contract.transferContractFirstPaymentDate = reformatDate(contract.transferContractFirstPaymentDate)!;
|
|
@@ -1853,23 +1771,6 @@ export default defineComponent({
|
|
|
1853
1771
|
{ immediate: true },
|
|
1854
1772
|
);
|
|
1855
1773
|
|
|
1856
|
-
if (hasCurrency.value) {
|
|
1857
|
-
watch(
|
|
1858
|
-
() => productConditionsForm.currency,
|
|
1859
|
-
async val => {
|
|
1860
|
-
if (val.code === 'USD') {
|
|
1861
|
-
if (!dataStore.processPaymentPeriod.length) {
|
|
1862
|
-
await dataStore.getProcessPaymentPeriod();
|
|
1863
|
-
}
|
|
1864
|
-
const paymentPeriod = dataStore.processPaymentPeriod.find(item => item.nameRu === 'единовременно');
|
|
1865
|
-
if (paymentPeriod) {
|
|
1866
|
-
productConditionsForm.paymentPeriod = paymentPeriod;
|
|
1867
|
-
}
|
|
1868
|
-
}
|
|
1869
|
-
},
|
|
1870
|
-
);
|
|
1871
|
-
}
|
|
1872
|
-
|
|
1873
1774
|
if (hasInsStartDate.value) {
|
|
1874
1775
|
watch(
|
|
1875
1776
|
() => productConditionsForm.calcDate,
|
|
@@ -1938,25 +1839,8 @@ export default defineComponent({
|
|
|
1938
1839
|
);
|
|
1939
1840
|
}
|
|
1940
1841
|
|
|
1941
|
-
if (whichProduct.value === 'pensionannuitynew') {
|
|
1942
|
-
watch(
|
|
1943
|
-
() => pensionForm.guaranteedPeriod,
|
|
1944
|
-
async () => {
|
|
1945
|
-
if (formStore.applicationData.processCode === 2) {
|
|
1946
|
-
await dataStore.reCalculateRefund(
|
|
1947
|
-
pensionForm.parentContractAmount,
|
|
1948
|
-
pensionForm.parentContractMainAmount,
|
|
1949
|
-
pensionForm.guaranteedPeriod,
|
|
1950
|
-
pensionForm.transferContractIsOppv,
|
|
1951
|
-
pensionForm.compulsoryProfMonthCount ?? 0,
|
|
1952
|
-
);
|
|
1953
|
-
}
|
|
1954
|
-
},
|
|
1955
|
-
);
|
|
1956
|
-
}
|
|
1957
|
-
|
|
1958
1842
|
const copyRedirect = async () => {
|
|
1959
|
-
const url = await dataStore.api.pensionannuityNew.getEnpfRedirectUrl(String(
|
|
1843
|
+
const url = await dataStore.api.pensionannuityNew.getEnpfRedirectUrl(String(formStore.applicationData.processInstanceId));
|
|
1960
1844
|
dataStore.copyToClipboard(url.redirectUrl);
|
|
1961
1845
|
};
|
|
1962
1846
|
|
|
@@ -2002,9 +1886,6 @@ export default defineComponent({
|
|
|
2002
1886
|
isDisabled,
|
|
2003
1887
|
isTermsDisabled,
|
|
2004
1888
|
isUnderwriterForm,
|
|
2005
|
-
hasCurrencySymbols,
|
|
2006
|
-
currencySymbolsLabel,
|
|
2007
|
-
isDisabledPaymentPeriod,
|
|
2008
1889
|
insurancePremiumPerMonthRule,
|
|
2009
1890
|
insurancePremiumPerMonthDisabled,
|
|
2010
1891
|
requestedSumInsuredRule,
|
|
@@ -2050,7 +1931,6 @@ export default defineComponent({
|
|
|
2050
1931
|
hasCoverPeriod,
|
|
2051
1932
|
hasInsStartDate,
|
|
2052
1933
|
hasInsEndDate,
|
|
2053
|
-
isSlavePensionForm,
|
|
2054
1934
|
|
|
2055
1935
|
// Rules
|
|
2056
1936
|
coverPeriodRule,
|
|
@@ -73,21 +73,18 @@
|
|
|
73
73
|
</base-form-section>
|
|
74
74
|
</div>
|
|
75
75
|
<div v-if="!(formStore.signatories.length === 0) && !isQr && !isScansDocuments" :class="[$styles.flexColNav]">
|
|
76
|
-
<div v-if="(processCode == 19 || processCode == 4) && formStore.applicationData.statusCode === 'AttachAppContractForm'" :class="[$styles.blueBgLight]" class="rounded-lg p-4">
|
|
77
|
-
<base-form-toggle v-model="isOnlineEnpf" title="Онлайн подписание согласия для ЕНПФ" :has-border="false" @clicked="setActualEnpf" />
|
|
78
|
-
</div>
|
|
79
76
|
<div :class="[$styles.blueBgLight]" class="rounded-lg p-4">
|
|
80
|
-
<v-expansion-panels v-if="formStore.signatories.length" variant="accordion"
|
|
77
|
+
<v-expansion-panels v-if="formStore.signatories.length" variant="accordion" multiple>
|
|
81
78
|
<v-expansion-panel v-for="(person, index) of formStore.signatories" :key="person.personId!" class="border-[1px]" elevation="0" bg-color="#FFF">
|
|
82
79
|
<v-expansion-panel-title class="h-[80px]" :class="$styles.textTitle">
|
|
83
80
|
{{ person.longName }}
|
|
84
81
|
</v-expansion-panel-title>
|
|
85
82
|
<v-expansion-panel-text class="border-t-[1px]">
|
|
86
83
|
<section class="flex flex-col" :class="$styles.textSimple">
|
|
87
|
-
<v-expansion-panels v-if="person.fileDatas.length" v-model="currentFilePanel"
|
|
84
|
+
<v-expansion-panels v-if="person.fileDatas.length" v-model="currentFilePanel">
|
|
88
85
|
<v-expansion-panel
|
|
89
86
|
v-for="(file, fileIndex) in groupBy(person.fileDatas, 'orderFile')"
|
|
90
|
-
:value="
|
|
87
|
+
:value="fileIndex"
|
|
91
88
|
:disabled="inSigningOrder(person.fileDatas, fileIndex) || file[0].isSigned"
|
|
92
89
|
>
|
|
93
90
|
<v-expansion-panel-title v-for="name in file" class="h-[80px]" :class="$styles.textTitle">
|
|
@@ -252,7 +249,7 @@
|
|
|
252
249
|
import { DocumentItem, Value } from '../../composables/classes';
|
|
253
250
|
import { HubConnectionBuilder } from '@microsoft/signalr';
|
|
254
251
|
import { uuid } from 'vue-uuid';
|
|
255
|
-
import type
|
|
252
|
+
import type { Api, SignUrlType } from '../../types';
|
|
256
253
|
import { CoreEnums } from '../../types/enum';
|
|
257
254
|
|
|
258
255
|
export default defineComponent({
|
|
@@ -275,16 +272,15 @@ export default defineComponent({
|
|
|
275
272
|
const isOfflinePay = ref<boolean>(false);
|
|
276
273
|
const isQrDialog = ref<boolean>(false);
|
|
277
274
|
const email = ref<string>('');
|
|
278
|
-
const signOptions = ref<
|
|
279
|
-
const signingFiles = ref<
|
|
275
|
+
const signOptions = ref<Api.Sign.New.Response>();
|
|
276
|
+
const signingFiles = ref<Api.Sign.New.FileDatas[]>([]);
|
|
280
277
|
const allDocumentsSigned = ref<boolean>(false);
|
|
281
|
-
const isOnlineEnpf = ref<boolean>(true);
|
|
282
278
|
const currentFilePanel = ref<string[]>([]);
|
|
283
279
|
|
|
284
280
|
const vForm = ref<any>();
|
|
285
281
|
const isSendNumberOpen = ref<boolean>(false);
|
|
286
282
|
const phoneNumber = ref<string | null>(formStore.policyholderForm.phoneNumber ?? '');
|
|
287
|
-
const selectedClient = ref<
|
|
283
|
+
const selectedClient = ref<SignUrlType>();
|
|
288
284
|
const documentDict = computed(() => dataStore.dicFileTypeList.find(i => i.nameRu === 'Решение АС'));
|
|
289
285
|
const affiliationDocument = computed(() => formStore.signedDocumentList.find((file: DocumentItem) => file.fileTypeName === 'Решение АС'));
|
|
290
286
|
const affiliationData = ref<{
|
|
@@ -302,7 +298,7 @@ export default defineComponent({
|
|
|
302
298
|
const scansFiles = ref<any[]>([]);
|
|
303
299
|
const processCode = formStore.applicationData.processCode;
|
|
304
300
|
|
|
305
|
-
const openSmsPanel = (signInfo:
|
|
301
|
+
const openSmsPanel = (signInfo: SignUrlType) => {
|
|
306
302
|
if (signInfo) {
|
|
307
303
|
isSendNumberOpen.value = true;
|
|
308
304
|
selectedClient.value = signInfo;
|
|
@@ -516,8 +512,6 @@ export default defineComponent({
|
|
|
516
512
|
}
|
|
517
513
|
}
|
|
518
514
|
if (dataStore.isPension) {
|
|
519
|
-
const isOnlineEnpfAgreement = formStore.applicationData.pensionApp.isOnlineEnpfAgreement;
|
|
520
|
-
isOnlineEnpf.value = isOnlineEnpfAgreement === null ? true : isOnlineEnpfAgreement;
|
|
521
515
|
await dataStore.getSignedDocList(formStore.applicationData.processInstanceId);
|
|
522
516
|
}
|
|
523
517
|
};
|
|
@@ -778,7 +772,7 @@ export default defineComponent({
|
|
|
778
772
|
await dataStore.generateDocument();
|
|
779
773
|
};
|
|
780
774
|
|
|
781
|
-
const convertQr = async (url: string | null, template?:
|
|
775
|
+
const convertQr = async (url: string | null, template?: Api.GenerateShortLink.Templates) => {
|
|
782
776
|
if (url) {
|
|
783
777
|
const shortedUrl = await dataStore.generateShortLink(url, template);
|
|
784
778
|
qrUrl.value = typeof shortedUrl === 'string' && !!shortedUrl ? shortedUrl : url;
|
|
@@ -858,9 +852,9 @@ export default defineComponent({
|
|
|
858
852
|
...formStore.signatories[index],
|
|
859
853
|
signType: signType,
|
|
860
854
|
fileDatas: file,
|
|
861
|
-
}
|
|
855
|
+
};
|
|
862
856
|
try {
|
|
863
|
-
signOptions.value = await dataStore.generalSign(data);
|
|
857
|
+
signOptions.value = await dataStore.api.file.generalSign(data);
|
|
864
858
|
const message = [];
|
|
865
859
|
for (let i of file) {
|
|
866
860
|
message.push(i.fileName);
|
|
@@ -875,7 +869,7 @@ export default defineComponent({
|
|
|
875
869
|
break;
|
|
876
870
|
case CoreEnums.Sign.Types.scans:
|
|
877
871
|
isScansDocuments.value = true;
|
|
878
|
-
signingFiles.value = data.fileDatas
|
|
872
|
+
signingFiles.value = data.fileDatas;
|
|
879
873
|
message.length = 0;
|
|
880
874
|
break;
|
|
881
875
|
case CoreEnums.Sign.Types.qr:
|
|
@@ -913,16 +907,6 @@ export default defineComponent({
|
|
|
913
907
|
loading.value = false;
|
|
914
908
|
};
|
|
915
909
|
|
|
916
|
-
const setActualEnpf = useDebounceFn(async () => {
|
|
917
|
-
try {
|
|
918
|
-
await dataStore.api.file.setActualEnpf({ processId: String(formStore.applicationData.processInstanceId), isOnlineEnpfAgreement: isOnlineEnpf.value });
|
|
919
|
-
await dataStore.generateSign(String(route.params.taskId));
|
|
920
|
-
} catch (err) {
|
|
921
|
-
ErrorHandler(err);
|
|
922
|
-
}
|
|
923
|
-
currentFilePanel.value = [];
|
|
924
|
-
}, 1000);
|
|
925
|
-
|
|
926
910
|
return {
|
|
927
911
|
// State
|
|
928
912
|
formStore,
|
|
@@ -946,7 +930,6 @@ export default defineComponent({
|
|
|
946
930
|
email,
|
|
947
931
|
signOptions,
|
|
948
932
|
signingFiles,
|
|
949
|
-
isOnlineEnpf,
|
|
950
933
|
allDocumentsSigned,
|
|
951
934
|
currentFilePanel,
|
|
952
935
|
|
|
@@ -966,7 +949,6 @@ export default defineComponent({
|
|
|
966
949
|
handlePayAction,
|
|
967
950
|
payEpay,
|
|
968
951
|
convertQr,
|
|
969
|
-
setActualEnpf,
|
|
970
952
|
sendInvoiceToEmail,
|
|
971
953
|
hasConditionsAction,
|
|
972
954
|
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
<template>
|
|
2
|
-
<label v-if="chip && chip.title" class="transition-all leading-6 px-3
|
|
2
|
+
<label v-if="chip && chip.title" class="transition-all leading-6 px-3 rounded-pill border-[1px] border-white mr-4 whitespace-nowrap" :class="[textSize, color]"
|
|
3
3
|
>{{ chip.title }}<v-tooltip v-if="chip.description" activator="parent" location="bottom" :max-width="maxWidth">{{ chip.description }}</v-tooltip></label
|
|
4
4
|
>
|
|
5
5
|
</template>
|
package/composables/classes.ts
CHANGED
|
@@ -825,7 +825,6 @@ export class ProductConditions {
|
|
|
825
825
|
fixInsSum: number | string | null;
|
|
826
826
|
calcDate: string | null;
|
|
827
827
|
contractEndDate: string | null;
|
|
828
|
-
currency: Value;
|
|
829
828
|
|
|
830
829
|
constructor(
|
|
831
830
|
insuranceCase = null,
|
|
@@ -874,7 +873,6 @@ export class ProductConditions {
|
|
|
874
873
|
fixInsSum = null,
|
|
875
874
|
calcDate = null,
|
|
876
875
|
contractEndDate = null,
|
|
877
|
-
currency = new Value(),
|
|
878
876
|
) {
|
|
879
877
|
this.requestedSumInsuredInDollar = null;
|
|
880
878
|
this.insurancePremiumPerMonthInDollar = null;
|
|
@@ -927,7 +925,6 @@ export class ProductConditions {
|
|
|
927
925
|
this.fixInsSum = fixInsSum;
|
|
928
926
|
this.calcDate = calcDate;
|
|
929
927
|
this.contractEndDate = contractEndDate;
|
|
930
|
-
this.currency = currency;
|
|
931
928
|
}
|
|
932
929
|
|
|
933
930
|
getSingleTripDays() {
|
|
@@ -1386,7 +1383,6 @@ export class FormStoreClass {
|
|
|
1386
1383
|
beneficiaryForm: boolean;
|
|
1387
1384
|
beneficialOwnerForm: boolean;
|
|
1388
1385
|
insuredForm: boolean;
|
|
1389
|
-
slaveInsuredForm: boolean;
|
|
1390
1386
|
policyholdersRepresentativeForm: boolean;
|
|
1391
1387
|
productConditionsForm: boolean;
|
|
1392
1388
|
calculatorForm: boolean;
|
|
@@ -1421,7 +1417,6 @@ export class FormStoreClass {
|
|
|
1421
1417
|
policyAppDto?: Types.PolicyAppDto;
|
|
1422
1418
|
insisWorkDataApp?: Types.InsisWorkDataApp;
|
|
1423
1419
|
addCoverDto?: Types.AddCover[];
|
|
1424
|
-
slave?: any;
|
|
1425
1420
|
};
|
|
1426
1421
|
policyholderForm: Member;
|
|
1427
1422
|
policyholderFormKey: StoreMembers.policyholderForm;
|
|
@@ -1434,7 +1429,6 @@ export class FormStoreClass {
|
|
|
1434
1429
|
beneficialOwnerFormIndex: number;
|
|
1435
1430
|
beneficialOwnerFormKey: StoreMembers.beneficialOwnerForm;
|
|
1436
1431
|
insuredForm: Member[];
|
|
1437
|
-
slaveInsuredForm: Member;
|
|
1438
1432
|
insuredFormKey: StoreMembers.insuredForm;
|
|
1439
1433
|
insuredFormIndex: number;
|
|
1440
1434
|
productConditionsForm: ProductConditions;
|
|
@@ -1511,7 +1505,6 @@ export class FormStoreClass {
|
|
|
1511
1505
|
beneficiaryForm: true,
|
|
1512
1506
|
beneficialOwnerForm: true,
|
|
1513
1507
|
insuredForm: true,
|
|
1514
|
-
slaveInsuredForm: true,
|
|
1515
1508
|
policyholdersRepresentativeForm: true,
|
|
1516
1509
|
productConditionsForm: true,
|
|
1517
1510
|
calculatorForm: true,
|
|
@@ -1540,7 +1533,6 @@ export class FormStoreClass {
|
|
|
1540
1533
|
this.beneficialOwnerFormIndex = 0;
|
|
1541
1534
|
this.beneficialOwnerFormKey = StoreMembers.beneficialOwnerForm;
|
|
1542
1535
|
this.insuredForm = [new Member()];
|
|
1543
|
-
this.slaveInsuredForm = new Member();
|
|
1544
1536
|
this.insuredFormKey = StoreMembers.insuredForm;
|
|
1545
1537
|
this.insuredFormIndex = 0;
|
|
1546
1538
|
this.productConditionsForm = new ProductConditions();
|
package/composables/constants.ts
CHANGED
|
@@ -18,6 +18,7 @@ export const constants = Object.freeze({
|
|
|
18
18
|
gns: 16,
|
|
19
19
|
prepensionannuity: 18,
|
|
20
20
|
pensionannuitynew: 19,
|
|
21
|
+
balam: 21,
|
|
21
22
|
},
|
|
22
23
|
amlProducts: {
|
|
23
24
|
checkcontragent: 1,
|
|
@@ -36,7 +37,6 @@ export const constants = Object.freeze({
|
|
|
36
37
|
returnStatementStatuses: [
|
|
37
38
|
Statuses.ApproveForm,
|
|
38
39
|
Statuses.ActuaryForm,
|
|
39
|
-
Statuses.JuristForm,
|
|
40
40
|
Statuses.DsoUsnsForm,
|
|
41
41
|
Statuses.AccountantForm,
|
|
42
42
|
Statuses.UnderwriterForm,
|
|
@@ -163,20 +163,4 @@ export const constants = Object.freeze({
|
|
|
163
163
|
ids: '',
|
|
164
164
|
},
|
|
165
165
|
],
|
|
166
|
-
currencyList: [
|
|
167
|
-
{
|
|
168
|
-
code: 'KZT',
|
|
169
|
-
id: '1',
|
|
170
|
-
nameKz: 'Тенге',
|
|
171
|
-
nameRu: 'Тенге',
|
|
172
|
-
ids: '',
|
|
173
|
-
},
|
|
174
|
-
{
|
|
175
|
-
code: 'USD',
|
|
176
|
-
id: '2',
|
|
177
|
-
nameKz: 'С индексацией на курс USD',
|
|
178
|
-
nameRu: 'С индексацией на курс USD',
|
|
179
|
-
ids: '',
|
|
180
|
-
},
|
|
181
|
-
],
|
|
182
166
|
});
|
package/composables/index.ts
CHANGED
|
@@ -795,6 +795,9 @@ export class RoleController {
|
|
|
795
795
|
isHeadOfDso = () => {
|
|
796
796
|
return this.isRole(constants.roles.HeadOfDso);
|
|
797
797
|
};
|
|
798
|
+
isUrsp = () => {
|
|
799
|
+
return this.isRole(constants.roles.URSP);
|
|
800
|
+
};
|
|
798
801
|
hasAccess = () => {
|
|
799
802
|
const baseAccessRoles = this.isAdmin() || this.isSupport() || this.isAnalyst() || this.isDrn();
|
|
800
803
|
return {
|
|
@@ -822,7 +825,6 @@ export class RoleController {
|
|
|
822
825
|
this.isDrn() ||
|
|
823
826
|
this.isUrp() ||
|
|
824
827
|
this.isUsns() ||
|
|
825
|
-
this.isJurist() ||
|
|
826
828
|
this.isAccountant() ||
|
|
827
829
|
this.isBranchDirector() ||
|
|
828
830
|
this.isUSNSACCINS() ||
|
|
@@ -831,7 +833,8 @@ export class RoleController {
|
|
|
831
833
|
this.isDsoDirector() ||
|
|
832
834
|
this.isAccountantDirector() ||
|
|
833
835
|
this.isHeadAdjuster() ||
|
|
834
|
-
this.isHeadOfDso()
|
|
836
|
+
this.isHeadOfDso() ||
|
|
837
|
+
this.isUrsp(),
|
|
835
838
|
};
|
|
836
839
|
};
|
|
837
840
|
}
|