hl-core 0.0.10-beta.35 → 0.0.10-beta.37
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 +18 -0
- package/components/Menu/MenuNav.vue +1 -1
- package/components/Pages/ProductConditions.vue +97 -88
- package/components/Panel/PanelHandler.vue +4 -4
- package/composables/classes.ts +2 -0
- package/composables/constants.ts +1 -0
- package/composables/index.ts +16 -0
- package/locales/ru.json +14 -3
- package/package.json +1 -1
- package/store/data.store.ts +30 -13
- package/types/enum.ts +1 -0
- package/types/index.ts +2 -1
package/api/base.api.ts
CHANGED
|
@@ -306,6 +306,13 @@ export class ApiClass {
|
|
|
306
306
|
});
|
|
307
307
|
}
|
|
308
308
|
|
|
309
|
+
async getProgramType() {
|
|
310
|
+
return await this.axiosCall<Value[]>({
|
|
311
|
+
method: Methods.GET,
|
|
312
|
+
url: '/Arm/api/Dictionary/GetDictionaryItems/DicProgramType',
|
|
313
|
+
});
|
|
314
|
+
}
|
|
315
|
+
|
|
309
316
|
async getContrAgentData(personId: string | number) {
|
|
310
317
|
return await this.axiosCall<Types.ContragentQuestionaries[]>({
|
|
311
318
|
method: Methods.GET,
|
|
@@ -665,6 +672,17 @@ export class ApiClass {
|
|
|
665
672
|
});
|
|
666
673
|
}
|
|
667
674
|
|
|
675
|
+
async getContractIdByNumber(insuranceTypeEnum: number, policyNo: string) {
|
|
676
|
+
return await this.axiosCall<number>({
|
|
677
|
+
method: Methods.GET,
|
|
678
|
+
url: `/Ekk/api/PolicyInsis/GetContractIDbyNumber`,
|
|
679
|
+
params: {
|
|
680
|
+
insuranceTypeEnum,
|
|
681
|
+
policyNo,
|
|
682
|
+
},
|
|
683
|
+
});
|
|
684
|
+
}
|
|
685
|
+
|
|
668
686
|
async isCourseChanged(processInstanceId: string) {
|
|
669
687
|
return await this.axiosCall<boolean>({
|
|
670
688
|
method: Methods.GET,
|
|
@@ -15,7 +15,7 @@
|
|
|
15
15
|
@onMore="$emit('onMore')"
|
|
16
16
|
/>
|
|
17
17
|
<slot key="slot-content" name="content"></slot>
|
|
18
|
-
<section key="main" :class="[$styles.flexColNav]">
|
|
18
|
+
<section key="main" class="max-h-[90dvh] overflow-y-scroll" :class="[$styles.flexColNav]">
|
|
19
19
|
<slot name="start"></slot>
|
|
20
20
|
<base-fade-transition>
|
|
21
21
|
<div v-if="$dataStore.menuItems && $dataStore.menuItems.length" class="flex flex-col gap-[10px]">
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
<template>
|
|
2
|
-
<section class="flex flex-col gap-4 px-[10px]" :class="[$styles.scrollPage]">
|
|
2
|
+
<section v-if="!isLoading" class="flex flex-col gap-4 px-[10px]" :class="[$styles.scrollPage]">
|
|
3
3
|
<v-form ref="vForm" @submit="submitForm">
|
|
4
4
|
<base-message-block
|
|
5
5
|
v-if="isCalculator"
|
|
@@ -403,8 +403,8 @@
|
|
|
403
403
|
</base-animation>
|
|
404
404
|
<base-form-input
|
|
405
405
|
v-model="pensionForm.voluntaryContractAmount"
|
|
406
|
-
:readonly="isDisabled"
|
|
407
|
-
:clearable="!isDisabled"
|
|
406
|
+
:readonly="isDisabled || isEnpfSum"
|
|
407
|
+
:clearable="!isDisabled && !isEnpfSum"
|
|
408
408
|
:label="$dataStore.t('pension.voluntaryContractAmount')"
|
|
409
409
|
:rules="$dataStore.rules.sums"
|
|
410
410
|
:suffix="$constants.currencySymbols.kzt"
|
|
@@ -526,7 +526,7 @@
|
|
|
526
526
|
:readonly="isDisabled || formStore.applicationData.processCode !== 25"
|
|
527
527
|
:label="$dataStore.t('pension.pensionAmount')"
|
|
528
528
|
/>
|
|
529
|
-
<base-form-input :value="
|
|
529
|
+
<base-form-input :value="$dataStore.getNumberWithSpaces(pensionForm.payment)" :active="true" readonly :label="$dataStore.t('pension.pensionPayment')" />
|
|
530
530
|
</base-form-section>
|
|
531
531
|
</section>
|
|
532
532
|
<base-form-section v-if="hasAnnuityPayments" :title="$dataStore.t('calculationAnnuityPayments')">
|
|
@@ -843,6 +843,7 @@
|
|
|
843
843
|
</div>
|
|
844
844
|
</Teleport>
|
|
845
845
|
</section>
|
|
846
|
+
<div v-if="isLoading" class="w-full h-[80dvh] flex items-center justify-center"><base-loader :size="50" /></div>
|
|
846
847
|
</template>
|
|
847
848
|
|
|
848
849
|
<script lang="ts">
|
|
@@ -882,6 +883,7 @@ export default defineComponent({
|
|
|
882
883
|
const isPanelLoading = ref<boolean>(false);
|
|
883
884
|
const isPanelOpen = ref<boolean>(false);
|
|
884
885
|
const isTermsPanelOpen = ref<boolean>(false);
|
|
886
|
+
const isLoading = ref<boolean>(false);
|
|
885
887
|
const panelValue = ref<Value>(new Value());
|
|
886
888
|
const termValue = ref<AddCover>();
|
|
887
889
|
const subTermValue = ref<string>('');
|
|
@@ -1320,7 +1322,6 @@ export default defineComponent({
|
|
|
1320
1322
|
const totalInsPremium = computed(() =>
|
|
1321
1323
|
dataStore.getNumberWithSpaces(formatSpacedNumber(formStore.pensionApp?.amount) + formatSpacedNumber(formStore.pensionApp.slave?.amount)),
|
|
1322
1324
|
);
|
|
1323
|
-
const pensionPayment = computed(() => dataStore.getNumberWithSpaces(pensionForm.value.payment));
|
|
1324
1325
|
|
|
1325
1326
|
const getContragent = async () => {
|
|
1326
1327
|
const data = await dataStore.api.getContragentById(
|
|
@@ -1920,7 +1921,6 @@ export default defineComponent({
|
|
|
1920
1921
|
await dataStore.setApplication(data, true);
|
|
1921
1922
|
}
|
|
1922
1923
|
await dataStore.getApplicationData(String(route.params.taskId), false, false, false, true);
|
|
1923
|
-
pensionForm.value.payment = formStore.applicationData.pensionApp?.payment ?? 0;
|
|
1924
1924
|
dateOfBegin.value = reformatDate(formStore.applicationData.pensionApp.dateOfBegin);
|
|
1925
1925
|
} else {
|
|
1926
1926
|
if (whichSum.value === 'requestedSumInsured') {
|
|
@@ -1997,7 +1997,9 @@ export default defineComponent({
|
|
|
1997
1997
|
recalculationData.riskGroup = productConditionsForm.riskGroup?.id ? productConditionsForm.riskGroup.id : 1;
|
|
1998
1998
|
isCalculating.value = true;
|
|
1999
1999
|
if (whichProduct.value === 'lifebusiness' || whichProduct.value === 'gns') {
|
|
2000
|
-
|
|
2000
|
+
const setApplicationData = dataStore.getConditionsData();
|
|
2001
|
+
const hasSetApplication = await dataStore.setApplication(setApplicationData);
|
|
2002
|
+
if (hasSetApplication) await dataStore.calculate(route.params.taskId as string);
|
|
2001
2003
|
additionalTerms.value = formStore.additionalInsuranceTerms;
|
|
2002
2004
|
} else {
|
|
2003
2005
|
await dataStore.reCalculate(formStore.applicationData.processInstanceId, recalculationData, route.params.taskId as string, whichSum.value);
|
|
@@ -2058,92 +2060,99 @@ export default defineComponent({
|
|
|
2058
2060
|
};
|
|
2059
2061
|
|
|
2060
2062
|
onMounted(async () => {
|
|
2061
|
-
|
|
2062
|
-
|
|
2063
|
+
try {
|
|
2064
|
+
if (hasContragentData.value) await getContragent();
|
|
2065
|
+
if (props.isCalculator === true) {
|
|
2066
|
+
isLoading.value = true;
|
|
2067
|
+
if (dataStore.isCalculator) {
|
|
2068
|
+
clearFields();
|
|
2069
|
+
}
|
|
2070
|
+
if (whichProduct.value === 'gons') {
|
|
2071
|
+
formStore.isDisabled.productConditionsForm = false;
|
|
2072
|
+
dataStore.setFormsDisabled(false);
|
|
2073
|
+
}
|
|
2074
|
+
if (whichProduct.value !== 'lifetrip' && whichProduct.value !== 'pensionannuitynew') {
|
|
2075
|
+
if (
|
|
2076
|
+
(dataStore.isCalculator || route.params.taskId === '0' || fromIndexPage.value) &&
|
|
2077
|
+
productConditionsForm.requestedSumInsured === null &&
|
|
2078
|
+
productConditionsForm.insurancePremiumPerMonth === null
|
|
2079
|
+
) {
|
|
2080
|
+
// @ts-ignore
|
|
2081
|
+
const defaultData = await dataStore.getDefaultCalculationData(true, whichProduct.value);
|
|
2082
|
+
if (!defaultData) {
|
|
2083
|
+
dataStore.showToaster('error', 'Отсутствуют базовые данные');
|
|
2084
|
+
return;
|
|
2085
|
+
}
|
|
2086
|
+
formStore.additionalInsuranceTermsWithout = defaultData.addCovers;
|
|
2087
|
+
productConditionsForm.requestedSumInsured = defaultData.amount;
|
|
2088
|
+
productConditionsForm.insurancePremiumPerMonth = defaultData.premium;
|
|
2089
|
+
const indexRate = dataStore.processIndexRate.find(i => i.id === defaultData.indexRateId);
|
|
2090
|
+
if (indexRate) productConditionsForm.processIndexRate = indexRate;
|
|
2091
|
+
const paymendPeriod = dataStore.processPaymentPeriod.find(i => i.id === defaultData.paymentPeriodId);
|
|
2092
|
+
if (paymendPeriod) productConditionsForm.paymentPeriod = paymendPeriod;
|
|
2093
|
+
if (defaultData.signDate) {
|
|
2094
|
+
productConditionsForm.signDate = reformatDate(defaultData.signDate);
|
|
2095
|
+
}
|
|
2096
|
+
if (whichProduct.value === 'lifebusiness' || whichProduct.value === 'gns') {
|
|
2097
|
+
productConditionsForm.coverPeriod = defaultData.insTermInMonth ?? null;
|
|
2098
|
+
productConditionsForm.insurancePremiumPerMonth = null;
|
|
2099
|
+
}
|
|
2100
|
+
}
|
|
2101
|
+
}
|
|
2102
|
+
}
|
|
2103
|
+
additionalTerms.value = props.isCalculator ? formStore.additionalInsuranceTermsWithout : formStore.additionalInsuranceTerms;
|
|
2104
|
+
if (!!productConditionsForm.insurancePremiumPerMonth) {
|
|
2105
|
+
whichSum.value = 'insurancePremiumPerMonth';
|
|
2106
|
+
}
|
|
2107
|
+
if (!!productConditionsForm.requestedSumInsured) {
|
|
2108
|
+
whichSum.value = 'requestedSumInsured';
|
|
2109
|
+
}
|
|
2110
|
+
if ((whichProduct.value === 'lifebusiness' || whichProduct.value === 'gns') && !productConditionsForm.requestedSumInsured) {
|
|
2111
|
+
whichSum.value = 'requestedSumInsured';
|
|
2112
|
+
}
|
|
2063
2113
|
if (dataStore.isCalculator) {
|
|
2064
|
-
|
|
2114
|
+
dataStore.processCode = constants.products[whichProduct.value as keyof typeof constants.products];
|
|
2115
|
+
await dataStore.getProcessPaymentPeriod();
|
|
2065
2116
|
}
|
|
2066
|
-
if (whichProduct.value === 'gons') {
|
|
2067
|
-
|
|
2068
|
-
dataStore.setFormsDisabled(false);
|
|
2117
|
+
if (whichProduct.value === 'halykkazyna' || whichProduct.value === 'gons') {
|
|
2118
|
+
await dataStore.getCurrencies();
|
|
2069
2119
|
}
|
|
2070
|
-
if (whichProduct.value
|
|
2071
|
-
|
|
2072
|
-
|
|
2073
|
-
productConditionsForm.requestedSumInsured === null &&
|
|
2074
|
-
productConditionsForm.insurancePremiumPerMonth === null
|
|
2075
|
-
) {
|
|
2076
|
-
// @ts-ignore
|
|
2077
|
-
const defaultData = await dataStore.getDefaultCalculationData(true, whichProduct.value);
|
|
2078
|
-
if (!defaultData) {
|
|
2079
|
-
dataStore.showToaster('error', 'Отсутствуют базовые данные');
|
|
2080
|
-
return;
|
|
2081
|
-
}
|
|
2082
|
-
formStore.additionalInsuranceTermsWithout = defaultData.addCovers;
|
|
2083
|
-
productConditionsForm.requestedSumInsured = defaultData.amount;
|
|
2084
|
-
productConditionsForm.insurancePremiumPerMonth = defaultData.premium;
|
|
2085
|
-
const indexRate = dataStore.processIndexRate.find(i => i.id === defaultData.indexRateId);
|
|
2086
|
-
if (indexRate) productConditionsForm.processIndexRate = indexRate;
|
|
2087
|
-
const paymendPeriod = dataStore.processPaymentPeriod.find(i => i.id === defaultData.paymentPeriodId);
|
|
2088
|
-
if (paymendPeriod) productConditionsForm.paymentPeriod = paymendPeriod;
|
|
2089
|
-
if (defaultData.signDate) {
|
|
2090
|
-
productConditionsForm.signDate = reformatDate(defaultData.signDate);
|
|
2091
|
-
}
|
|
2092
|
-
if (whichProduct.value === 'lifebusiness' || whichProduct.value === 'gns') {
|
|
2093
|
-
productConditionsForm.coverPeriod = defaultData.insTermInMonth ?? null;
|
|
2094
|
-
productConditionsForm.insurancePremiumPerMonth = null;
|
|
2095
|
-
}
|
|
2096
|
-
}
|
|
2120
|
+
if (whichProduct.value === 'halykkazyna') {
|
|
2121
|
+
const kazynaPaymentPeriod = dataStore.processPaymentPeriod.find(i => i.code === 'single');
|
|
2122
|
+
if (kazynaPaymentPeriod) productConditionsForm.paymentPeriod = kazynaPaymentPeriod;
|
|
2097
2123
|
}
|
|
2098
|
-
|
|
2099
|
-
|
|
2100
|
-
|
|
2101
|
-
|
|
2102
|
-
|
|
2103
|
-
|
|
2104
|
-
|
|
2105
|
-
|
|
2106
|
-
|
|
2107
|
-
|
|
2108
|
-
|
|
2109
|
-
|
|
2110
|
-
|
|
2111
|
-
|
|
2112
|
-
|
|
2113
|
-
|
|
2114
|
-
|
|
2115
|
-
|
|
2116
|
-
|
|
2117
|
-
|
|
2118
|
-
|
|
2119
|
-
|
|
2120
|
-
|
|
2121
|
-
|
|
2122
|
-
|
|
2123
|
-
return sum + Number(i.insSum);
|
|
2124
|
-
}, 0),
|
|
2125
|
-
);
|
|
2126
|
-
}
|
|
2127
|
-
if (whichProduct.value === 'pensionannuitynew') {
|
|
2128
|
-
contractDate.value = reformatDate(pensionForm.value.contractDate ?? '');
|
|
2129
|
-
dateOfBegin.value = reformatDate(pensionForm.value.dateOfBegin);
|
|
2130
|
-
transferContractDate.value = reformatDate(pensionForm.value.transferContractDate);
|
|
2131
|
-
transferContractFirstPaymentDate.value = reformatDate(pensionForm.value.transferContractFirstPaymentDate ?? '');
|
|
2132
|
-
maxDate.value = await dataStore.getVariableData(formStore.applicationData.processCode ?? 19);
|
|
2133
|
-
if (!transferContracts.value.length && pensionForm.value.transferContracts && pensionForm.value.transferContracts.length) {
|
|
2134
|
-
pensionForm.value.transferContracts.forEach((contract: TransferContract) => {
|
|
2135
|
-
transferContracts.value.push({
|
|
2136
|
-
...contract,
|
|
2137
|
-
transferContractDate: constants.regex.isoDate.test(contract.transferContractDate) ? reformatDate(contract.transferContractDate)! : contract.transferContractDate,
|
|
2138
|
-
transferContractFirstPaymentDate: constants.regex.isoDate.test(contract.transferContractFirstPaymentDate)
|
|
2139
|
-
? reformatDate(contract.transferContractFirstPaymentDate)!
|
|
2140
|
-
: contract.transferContractFirstPaymentDate,
|
|
2141
|
-
transferContractCompany:
|
|
2142
|
-
typeof contract.transferContractCompany === 'string' ? ({ nameRu: contract.transferContractCompany } as any) : contract.transferContractCompany,
|
|
2143
|
-
transferContractAmount: dataStore.getNumberWithSpaces(contract.transferContractAmount) ?? '',
|
|
2124
|
+
if (!formStore.lfb.add && (whichProduct.value === 'lifebusiness' || whichProduct.value === 'gns')) {
|
|
2125
|
+
productConditionsForm.requestedSumInsured = dataStore.getNumberWithSpaces(
|
|
2126
|
+
formStore.lfb.clients.reduce((sum: number, i: any) => {
|
|
2127
|
+
return sum + Number(i.insSum);
|
|
2128
|
+
}, 0),
|
|
2129
|
+
);
|
|
2130
|
+
}
|
|
2131
|
+
if (whichProduct.value === 'pensionannuitynew') {
|
|
2132
|
+
contractDate.value = reformatDate(pensionForm.value.contractDate ?? '');
|
|
2133
|
+
dateOfBegin.value = reformatDate(pensionForm.value.dateOfBegin);
|
|
2134
|
+
transferContractDate.value = reformatDate(pensionForm.value.transferContractDate);
|
|
2135
|
+
transferContractFirstPaymentDate.value = reformatDate(pensionForm.value.transferContractFirstPaymentDate ?? '');
|
|
2136
|
+
maxDate.value = await dataStore.getVariableData(formStore.applicationData.processCode ?? 19);
|
|
2137
|
+
if (!transferContracts.value.length && pensionForm.value.transferContracts && pensionForm.value.transferContracts.length) {
|
|
2138
|
+
pensionForm.value.transferContracts.forEach((contract: TransferContract) => {
|
|
2139
|
+
transferContracts.value.push({
|
|
2140
|
+
...contract,
|
|
2141
|
+
transferContractDate: constants.regex.isoDate.test(contract.transferContractDate) ? reformatDate(contract.transferContractDate)! : contract.transferContractDate,
|
|
2142
|
+
transferContractFirstPaymentDate: constants.regex.isoDate.test(contract.transferContractFirstPaymentDate)
|
|
2143
|
+
? reformatDate(contract.transferContractFirstPaymentDate)!
|
|
2144
|
+
: contract.transferContractFirstPaymentDate,
|
|
2145
|
+
transferContractCompany:
|
|
2146
|
+
typeof contract.transferContractCompany === 'string' ? ({ nameRu: contract.transferContractCompany } as any) : contract.transferContractCompany,
|
|
2147
|
+
transferContractAmount: dataStore.getNumberWithSpaces(contract.transferContractAmount) ?? '',
|
|
2148
|
+
});
|
|
2144
2149
|
});
|
|
2145
|
-
}
|
|
2150
|
+
}
|
|
2146
2151
|
}
|
|
2152
|
+
} catch (err) {
|
|
2153
|
+
console.log(err);
|
|
2154
|
+
} finally {
|
|
2155
|
+
isLoading.value = false;
|
|
2147
2156
|
}
|
|
2148
2157
|
});
|
|
2149
2158
|
|
|
@@ -2310,6 +2319,7 @@ export default defineComponent({
|
|
|
2310
2319
|
// State
|
|
2311
2320
|
formStore,
|
|
2312
2321
|
vForm,
|
|
2322
|
+
isLoading,
|
|
2313
2323
|
whichProduct,
|
|
2314
2324
|
productConditionsForm,
|
|
2315
2325
|
additionalTerms,
|
|
@@ -2350,7 +2360,6 @@ export default defineComponent({
|
|
|
2350
2360
|
// Computed
|
|
2351
2361
|
isTask,
|
|
2352
2362
|
isDisabled,
|
|
2353
|
-
pensionPayment,
|
|
2354
2363
|
disabilityGroup,
|
|
2355
2364
|
totalInsPremium,
|
|
2356
2365
|
isTermsDisabled,
|
|
@@ -501,7 +501,7 @@ export default defineComponent({
|
|
|
501
501
|
// loading.value = false;
|
|
502
502
|
// return;
|
|
503
503
|
// }
|
|
504
|
-
if (dataStore.isAML || dataStore.isCheckContract || dataStore.isCheckContragent || dataStore.isDas || dataStore.isPrePension || dataStore.isUU) {
|
|
504
|
+
if (dataStore.isAML || dataStore.isCheckContract || dataStore.isCheckContragent || dataStore.isDas || dataStore.isPrePension || dataStore.isCritical || dataStore.isUU) {
|
|
505
505
|
emit('task', [dataStore.panelAction, route.params.taskId as string, actionCause.value]);
|
|
506
506
|
} else {
|
|
507
507
|
await dataStore.handleTask(dataStore.panelAction, route.params.taskId as string, actionCause.value);
|
|
@@ -603,7 +603,7 @@ export default defineComponent({
|
|
|
603
603
|
const price = computed(() => dataStore.getNumberWithSpaces(formStore.productConditionsForm.calculatorForm.price));
|
|
604
604
|
const insuredAmount = computed(() => formStore.productConditionsForm.calculatorForm.amount!.nameRu! + dataStore.currency);
|
|
605
605
|
const hasConditionsInfo = computed(() => {
|
|
606
|
-
if (dataStore.isLifetrip || dataStore.isDas || dataStore.isUU || dataStore.isPrePension || dataStore.isPension) {
|
|
606
|
+
if (dataStore.isLifetrip || dataStore.isDas || dataStore.isUU || dataStore.isPrePension || dataStore.isCritical || dataStore.isPension) {
|
|
607
607
|
return false;
|
|
608
608
|
}
|
|
609
609
|
if (dataStore.isFinCenter()) {
|
|
@@ -612,7 +612,7 @@ export default defineComponent({
|
|
|
612
612
|
return true;
|
|
613
613
|
});
|
|
614
614
|
const hasConditionsAction = computed(() => {
|
|
615
|
-
if (dataStore.isPrePension) {
|
|
615
|
+
if (dataStore.isPrePension || dataStore.isCritical) {
|
|
616
616
|
return false;
|
|
617
617
|
}
|
|
618
618
|
return true;
|
|
@@ -895,7 +895,7 @@ export default defineComponent({
|
|
|
895
895
|
for (let sign of signOptions.value.signIds) {
|
|
896
896
|
const response = await dataStore.nclayerSign(sign.id, signType, file[0].fileType === 43);
|
|
897
897
|
if (response === null) {
|
|
898
|
-
dataStore.showToaster('error', 'Ошибка при
|
|
898
|
+
dataStore.showToaster('error', 'Ошибка при подключении к приложению «NCALayer». Убедитесь, что запустили приложение «NCALayer»', 10000);
|
|
899
899
|
break;
|
|
900
900
|
}
|
|
901
901
|
if (!response) break;
|
package/composables/classes.ts
CHANGED
|
@@ -1123,6 +1123,7 @@ export class DataStoreClass {
|
|
|
1123
1123
|
workTypes: Value[];
|
|
1124
1124
|
sportsTypes: Value[];
|
|
1125
1125
|
purposes: Value[];
|
|
1126
|
+
programType: Value[];
|
|
1126
1127
|
constructor() {
|
|
1127
1128
|
this.projectConfig = null;
|
|
1128
1129
|
this.filters = {
|
|
@@ -1176,6 +1177,7 @@ export class DataStoreClass {
|
|
|
1176
1177
|
this.processIndexRate = [];
|
|
1177
1178
|
this.processGfot = [];
|
|
1178
1179
|
this.processPaymentPeriod = [];
|
|
1180
|
+
this.programType = [];
|
|
1179
1181
|
this.dicAnnuityTypeList = [];
|
|
1180
1182
|
this.processAnnuityPaymentPeriod = [];
|
|
1181
1183
|
this.questionRefs = [];
|
package/composables/constants.ts
CHANGED
package/composables/index.ts
CHANGED
|
@@ -794,6 +794,9 @@ export class RoleController {
|
|
|
794
794
|
isDsuio = () => {
|
|
795
795
|
return this.isRole(constants.roles.Dsuio);
|
|
796
796
|
};
|
|
797
|
+
isHeadDso = () => {
|
|
798
|
+
return this.isRole(constants.roles.HEADDSO);
|
|
799
|
+
};
|
|
797
800
|
isAdjuster = () => {
|
|
798
801
|
return this.isRole(constants.roles.SettlementLosses);
|
|
799
802
|
};
|
|
@@ -820,6 +823,19 @@ export class RoleController {
|
|
|
820
823
|
toAML: this.isCompliance() || baseAccessRoles,
|
|
821
824
|
toAULETTI: this.isAgentAuletti() || this.isManagerAuletti() || baseAccessRoles,
|
|
822
825
|
toLKA_A: this.isAgentAuletti() || baseAccessRoles,
|
|
826
|
+
toUU: this.isServiceManager() || this.isAccountant() || this.isAdjuster() || this.isHeadAdjuster() || baseAccessRoles,
|
|
827
|
+
toDSO:
|
|
828
|
+
this.isDsuio() ||
|
|
829
|
+
this.isManager() ||
|
|
830
|
+
this.isActuary() ||
|
|
831
|
+
this.isHeadOfDso() ||
|
|
832
|
+
this.isAccountant() ||
|
|
833
|
+
this.isUSNSACCINS() ||
|
|
834
|
+
this.isDsoDirector() ||
|
|
835
|
+
this.isServiceManager() ||
|
|
836
|
+
this.isUSNSsanctioner() ||
|
|
837
|
+
this.isAccountantDirector() ||
|
|
838
|
+
baseAccessRoles,
|
|
823
839
|
toEFO:
|
|
824
840
|
this.isManager() ||
|
|
825
841
|
this.isAgent() ||
|
package/locales/ru.json
CHANGED
|
@@ -248,7 +248,9 @@
|
|
|
248
248
|
"copyToClient": "Скопировать ссылку для клиента",
|
|
249
249
|
"searchByFio": "Поиск по ФИО",
|
|
250
250
|
"recalc": "Перерасчет",
|
|
251
|
-
"conclude": "Заключить"
|
|
251
|
+
"conclude": "Заключить",
|
|
252
|
+
"agree": "Согласен",
|
|
253
|
+
"disagree": "Не согласен",
|
|
252
254
|
},
|
|
253
255
|
"dialog": {
|
|
254
256
|
"title": "Подтверждение",
|
|
@@ -381,6 +383,8 @@
|
|
|
381
383
|
"isPolicyholderLegalEntity": "Является ли Страхователь Юридическим лицом?",
|
|
382
384
|
"additionalAgreement": "Заключить дополнительное соглашение",
|
|
383
385
|
"searchAgreementOSNS": "Поиск договора по ОСНС",
|
|
386
|
+
"legalPerson": "Юридическое лицо",
|
|
387
|
+
"physicalPerson": "Физическое лицо",
|
|
384
388
|
"productConditionsForm": {
|
|
385
389
|
"coverPeriod": "Срок страхования",
|
|
386
390
|
"payPeriod": "Период оплаты страховой премии",
|
|
@@ -432,7 +436,8 @@
|
|
|
432
436
|
"mrpPayment": "Выплата на погребение (в тенге)",
|
|
433
437
|
"fixInsSum": "Фиксированная сумма",
|
|
434
438
|
"amountRefunded": "Сумма к возврату",
|
|
435
|
-
"amountPaid": "Сумма к доплате"
|
|
439
|
+
"amountPaid": "Сумма к доплате",
|
|
440
|
+
"franchise": "Франшиза",
|
|
436
441
|
},
|
|
437
442
|
"calculatorForm": {
|
|
438
443
|
"selectedCountries": "Выбранные страны",
|
|
@@ -1197,5 +1202,11 @@
|
|
|
1197
1202
|
"agreementBlock": {
|
|
1198
1203
|
"title": "Согласие на сбор и обработку пресональных данных",
|
|
1199
1204
|
"text": "Я, предоставляю АО «Халык-Life» (БИН 051140004354) и (или) организациям, входящими в состав финансовой Группы «Халык» (Акционеру АО «Халык-Life» (БИН 940140000385) и его дочерним организациям), перестраховочным организациям, организации по формированию и ведению базы данных по страхованию (БИН 120940011577), юридическому лицу, осуществляющему деятельность по привлечению пенсионных взносов и пенсионным выплатам (БИН 971240002115), юридическому лицу, осуществляющему по решению Правительства Республики Казахстан деятельность по оказанию государственных услуг (БИН 160440007161), операторам/владельцам государственных баз данных согласие на сбор и обработку, трансграничную передачу и распространение моих персональных данных и информации, связанных со мной и моими близкими родственниками, из всех источников и баз данных, в том числе содержащих врачебную, налоговую, банковскую тайну, тайну пенсионных накоплений, и иную охраняемую законом тайну, зафиксированных на электронном, бумажном и (или) ином материальном носителе, с целью оказания АО «Халык-Life» функций страховой организации и вышеуказанными организациями финансовых и иных услуг, в том числе необходимых для заполнения/формирования заявлений и договоров, а также моей надлежащей идентификации, включая, но не ограничиваясь: фамилия, имя, отчество, гражданство, данные документа, удостоверяющего личность, индивидуальный идентификационный номер, дата и данные о рождении, пол, национальность, фото, биометрические данные, состояние здоровья, банковские реквизиты, сведения о дееспособности, сведения, необходимые для поддержания связи, сведения о размере суммы пенсионных накоплений и размере выкупной суммы, иные данные/информация, полученные и переданные на текущий момент и которые могут быть получены и переданы в будущем, из всех/во все возможных(-хабарлама ые) источников(-хабарлама и), в том числе любых(-хабарлама е) баз(-хабарлама ы) данных, в том числе баз данных: владельцев государственных баз данных, организации по формированию и ведению базы данных по страхованию, юридического лица, осуществляющего деятельность по привлечению пенсионных взносов и пенсионным выплатам, юридического лица, осуществляющего по решению Правительства Республики Казахстан деятельность по оказанию государственных услуг, которые будут или стали известны АО «Халык-Life» в процессе его деятельности и/или в рамках гражданско-хабарлама правовых и иных отношений с контрагентами в рамках соответствующего договора, предоставляю АО «Халык-Life» возможность передачи моих персональных данных уполномоченным органам, Акционеру АО «Халык-Life» и его дочерним организациям, аффилированным лицам АО «Халык-Life», организации по формированию и ведению базы данных по страхованию, операторам государственных баз данных, и иным третьим лицам, связанным, как в настоящее время, так и в будущем, с АО «Халык-Life» обстоятельствами или правоотношениями, и любым третьим лицам, когда АО «Халык-Life» обязан или вправе совершить такие действия в соответствии с требованиями законодательства и (или) внутренними документами. Настоящее согласие действует в период правоспособности АО «Халык-Life» (его правопреемника)."
|
|
1200
|
-
}
|
|
1205
|
+
},
|
|
1206
|
+
"healthDeclaration": "Декларация о здоровье Застрахованного",
|
|
1207
|
+
"attachNotification": "Вложить уведомление",
|
|
1208
|
+
"coverageFrom": "Период действия с",
|
|
1209
|
+
"coverageTo": "Период действия до",
|
|
1210
|
+
"recoveredFrom": "Восстановлен с"
|
|
1211
|
+
|
|
1201
1212
|
}
|
package/package.json
CHANGED
package/store/data.store.ts
CHANGED
|
@@ -63,6 +63,7 @@ export const useDataStore = defineStore('data', {
|
|
|
63
63
|
isCheckContract: state => state.product === 'checkcontract',
|
|
64
64
|
isCheckContragent: state => state.product === 'checkcontragent',
|
|
65
65
|
isPrePension: state => state.product === 'prepensionannuity',
|
|
66
|
+
isCritical: state => state.product === 'criticalillness',
|
|
66
67
|
isBalam: state => state.product === 'balam',
|
|
67
68
|
isDSO: state => state.product === 'dso',
|
|
68
69
|
isUU: state => state.product === 'uu',
|
|
@@ -432,7 +433,7 @@ export const useDataStore = defineStore('data', {
|
|
|
432
433
|
|
|
433
434
|
const contragentResponse = await this.api.getContragentById(id);
|
|
434
435
|
if (contragentResponse.totalItems > 0) {
|
|
435
|
-
await this.serializeContragentData(member, contragentResponse.items[0]);
|
|
436
|
+
await this.serializeContragentData(member, contragentResponse.items[0], whichForm);
|
|
436
437
|
} else {
|
|
437
438
|
this.showToaster('error', this.t('toaster.notFoundUser'));
|
|
438
439
|
}
|
|
@@ -442,7 +443,7 @@ export const useDataStore = defineStore('data', {
|
|
|
442
443
|
this.isLoading = false;
|
|
443
444
|
}
|
|
444
445
|
},
|
|
445
|
-
async serializeContragentData(member: Member, contragent: Types.ContragentType) {
|
|
446
|
+
async serializeContragentData(member: Member, contragent: Types.ContragentType, whichForm?: keyof typeof StoreMembers | 'slaveInsuredForm') {
|
|
446
447
|
const [questionairesResponse, contactsResponse, documentsResponse, addressResponse] = await Promise.allSettled([
|
|
447
448
|
this.api.getContrAgentData(contragent.id),
|
|
448
449
|
this.api.getContrAgentContacts(contragent.id),
|
|
@@ -464,13 +465,17 @@ export const useDataStore = defineStore('data', {
|
|
|
464
465
|
if (addressResponse.status === 'fulfilled' && addressResponse.value && addressResponse.value.length) {
|
|
465
466
|
member.response.addresses = addressResponse.value;
|
|
466
467
|
}
|
|
467
|
-
this.parseContragent(
|
|
468
|
-
|
|
469
|
-
|
|
470
|
-
|
|
471
|
-
|
|
472
|
-
|
|
473
|
-
|
|
468
|
+
this.parseContragent(
|
|
469
|
+
member,
|
|
470
|
+
{
|
|
471
|
+
personalData: contragent,
|
|
472
|
+
data: questionairesResponse.status === 'fulfilled' ? questionairesResponse.value : undefined,
|
|
473
|
+
contacts: contactsResponse.status === 'fulfilled' ? contactsResponse.value : undefined,
|
|
474
|
+
documents: documentsResponse.status === 'fulfilled' ? documentsResponse.value : undefined,
|
|
475
|
+
address: addressResponse.status === 'fulfilled' ? addressResponse.value : undefined,
|
|
476
|
+
},
|
|
477
|
+
whichForm,
|
|
478
|
+
);
|
|
474
479
|
},
|
|
475
480
|
parseContragent(
|
|
476
481
|
member: Member,
|
|
@@ -481,6 +486,7 @@ export const useDataStore = defineStore('data', {
|
|
|
481
486
|
documents?: Types.ContragentDocuments[];
|
|
482
487
|
address?: Types.ContragentAddress[];
|
|
483
488
|
},
|
|
489
|
+
whichForm?: keyof typeof StoreMembers | 'slaveInsuredForm',
|
|
484
490
|
) {
|
|
485
491
|
member.verifyType = user.personalData.verifyType;
|
|
486
492
|
member.verifyDate = user.personalData.verifyDate;
|
|
@@ -503,7 +509,12 @@ export const useDataStore = defineStore('data', {
|
|
|
503
509
|
|
|
504
510
|
if ('documents' in user && user.documents && user.documents.length) {
|
|
505
511
|
member.documentsList = user.documents;
|
|
506
|
-
const documentByPriority = user.documents.find(i =>
|
|
512
|
+
const documentByPriority = user.documents.find(i => {
|
|
513
|
+
if (this.isLifetrip && (whichForm !== this.formStore.policyholderFormKey || this.formStore.isPolicyholderInsured === true)) {
|
|
514
|
+
return i.type === CoreEnums.Insis.DocTypes['PS'];
|
|
515
|
+
}
|
|
516
|
+
return i.type === CoreEnums.Insis.DocTypes['1UDL'];
|
|
517
|
+
});
|
|
507
518
|
const userDocument = documentByPriority ? documentByPriority : user.documents[0];
|
|
508
519
|
const documentType = this.documentTypes.find((i: Value) => i.ids === userDocument.type);
|
|
509
520
|
const documentIssuer = this.documentIssuers.find((i: Value) => i.nameRu === userDocument.issuerNameRu);
|
|
@@ -1453,7 +1464,7 @@ export const useDataStore = defineStore('data', {
|
|
|
1453
1464
|
return await this.getFromApi('economySectorCode', 'getSectorCode');
|
|
1454
1465
|
},
|
|
1455
1466
|
async getEconomicActivityType() {
|
|
1456
|
-
const makeCall = this.isLifeBusiness || this.isGns || this.isDas || this.isUU || this.isPrePension;
|
|
1467
|
+
const makeCall = this.isLifeBusiness || this.isGns || this.isDas || this.isUU || this.isPrePension || this.isCritical;
|
|
1457
1468
|
if (makeCall) return await this.getFromApi('economicActivityType', 'getEconomicActivityType');
|
|
1458
1469
|
},
|
|
1459
1470
|
async getFamilyStatuses() {
|
|
@@ -1466,7 +1477,7 @@ export const useDataStore = defineStore('data', {
|
|
|
1466
1477
|
return await this.getFromApi('relations', 'getRelationTypes');
|
|
1467
1478
|
},
|
|
1468
1479
|
async getBanks() {
|
|
1469
|
-
const makeCall = this.isLifeBusiness || this.isDas || this.isUU || this.isPension || this.isGns || this.isPrePension || this.isDSO;
|
|
1480
|
+
const makeCall = this.isLifeBusiness || this.isDas || this.isUU || this.isPension || this.isGns || this.isPrePension || this.isDSO || this.isCritical;
|
|
1470
1481
|
if (makeCall) return await this.getFromApi('banks', 'getBanks');
|
|
1471
1482
|
},
|
|
1472
1483
|
async getInsuranceCompanies() {
|
|
@@ -1480,6 +1491,10 @@ export const useDataStore = defineStore('data', {
|
|
|
1480
1491
|
const makeCall = !this.isPension && this.processCode;
|
|
1481
1492
|
if (makeCall) return await this.getFromApi('processPaymentPeriod', 'getProcessPaymentPeriod', this.processCode);
|
|
1482
1493
|
},
|
|
1494
|
+
async getProgramType() {
|
|
1495
|
+
const makeCall = this.isCritical && this.processCode;
|
|
1496
|
+
if (makeCall) return await this.getFromApi('programType', 'getProgramType', this.processCode);
|
|
1497
|
+
},
|
|
1483
1498
|
async getQuestionRefs(id?: string) {
|
|
1484
1499
|
return await this.getFromApi('questionRefs', 'getQuestionRefs', id, true);
|
|
1485
1500
|
},
|
|
@@ -1514,7 +1529,8 @@ export const useDataStore = defineStore('data', {
|
|
|
1514
1529
|
return this.gender;
|
|
1515
1530
|
},
|
|
1516
1531
|
async getAuthorityBasis() {
|
|
1517
|
-
if (this.isDas || this.isLifeBusiness || this.isGns || this.isUU || this.isPrePension
|
|
1532
|
+
if (this.isDas || this.isLifeBusiness || this.isGns || this.isUU || this.isPrePension || this.isCritical)
|
|
1533
|
+
return await this.getFromApi('authorityBasis', 'getArmDicts', 'DicAuthorityBasis');
|
|
1518
1534
|
},
|
|
1519
1535
|
async getWorkPosition(search: string) {
|
|
1520
1536
|
try {
|
|
@@ -1543,6 +1559,7 @@ export const useDataStore = defineStore('data', {
|
|
|
1543
1559
|
this.getRelationTypes(),
|
|
1544
1560
|
this.getProcessIndexRate(),
|
|
1545
1561
|
this.getProcessPaymentPeriod(),
|
|
1562
|
+
this.getProgramType(),
|
|
1546
1563
|
this.getDicFileTypeList(),
|
|
1547
1564
|
this.getDicAnnuityTypeList(),
|
|
1548
1565
|
this.getProcessAnnuityPaymentPeriod(),
|
package/types/enum.ts
CHANGED
|
@@ -108,6 +108,7 @@ export enum Roles {
|
|
|
108
108
|
BranchDirector = 'BranchDirector',
|
|
109
109
|
USNSACCINS = 'USNSACCINS',
|
|
110
110
|
Dsuio = 'Dsuio',
|
|
111
|
+
HEADDSO = 'HEADDSO',
|
|
111
112
|
SettlementLosses = 'SettlementLosses',
|
|
112
113
|
HeadSettlementLosses = 'HeadSettlementLosses',
|
|
113
114
|
DsoDirector = 'DsoDirector',
|
package/types/index.ts
CHANGED
|
@@ -31,7 +31,8 @@ export type Projects =
|
|
|
31
31
|
| 'auletti'
|
|
32
32
|
| 'lka-auletti'
|
|
33
33
|
| 'prepensionannuity'
|
|
34
|
-
| 'balam'
|
|
34
|
+
| 'balam'
|
|
35
|
+
| 'criticalillness';
|
|
35
36
|
export type MemberKeys = keyof ReturnType<typeof useFormStore>;
|
|
36
37
|
export type MemberFormTypes = 'policyholderForm' | 'insuredForm' | 'beneficiaryForm' | 'beneficialOwnerForm' | 'policyholdersRepresentativeForm' | 'productConditionsForm';
|
|
37
38
|
export type SingleMember = 'policyholderForm' | 'policyholdersRepresentativeForm';
|