hl-core 0.0.9-beta.38 → 0.0.9-beta.40

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 CHANGED
@@ -854,7 +854,7 @@ export class ApiClass {
854
854
  url: `/${this.productUrl}/api/Application/SaveInsured`,
855
855
  params: {
856
856
  processInstanceId,
857
- insuredId,
857
+ insuredId: insuredId !== '0' ? insuredId : undefined,
858
858
  },
859
859
  data: data,
860
860
  });
@@ -866,7 +866,7 @@ export class ApiClass {
866
866
  url: `/${this.productUrl}/api/Application/SaveBenificiary`,
867
867
  params: {
868
868
  processInstanceId,
869
- benificiaryId,
869
+ benificiaryId: benificiaryId !== '0' ? benificiaryId : undefined,
870
870
  },
871
871
  data: data,
872
872
  });
@@ -878,7 +878,7 @@ export class ApiClass {
878
878
  url: `/${this.productUrl}/api/Application/SaveBeneficialOwner`,
879
879
  params: {
880
880
  processInstanceId,
881
- benificiaryId,
881
+ benificiaryId: benificiaryId !== '0' ? benificiaryId : undefined,
882
882
  },
883
883
  data: data,
884
884
  });
@@ -1,54 +1,60 @@
1
1
  <template>
2
2
  <div class="rounded-lg border-[1px]" :class="[$styles.whiteBg, disabled && $styles.disabled]">
3
- <div class="mt-3 ml-5">
4
- <p :class="[$styles.textTitle, $styles.greenText]">{{ $dataStore.t('form.attachManager') }}</p>
5
- </div>
6
- <v-form ref="vForm" class="flex flex-col mt-1">
7
- <base-panel-input
8
- class="pl-1"
9
- v-model="formStore.SaleChanellPolicy"
10
- :value="formStore.SaleChanellPolicy?.nameRu"
11
- :readonly="isSaleChanellReadonly"
12
- :clearable="!isSaleChanellReadonly"
13
- :label="$dataStore.t('form.salesChanell')"
14
- :rules="$rules.objectRequired"
15
- append-inner-icon="mdi mdi-chevron-right"
16
- @append="openPanel('SaleChanellPolicy', $dataStore.t('form.salesChanell'))"
17
- />
18
- <base-panel-input
19
- class="pl-1"
20
- v-model="formStore.RegionPolicy"
21
- :value="formStore.RegionPolicy?.nameRu"
22
- :readonly="isRegionReadonly"
23
- :clearable="!isRegionReadonly"
24
- :label="$dataStore.t('form.Region')"
25
- :rules="$rules.objectRequired"
26
- append-inner-icon="mdi mdi-chevron-right"
27
- @append="openPanel('RegionPolicy', $dataStore.t('form.Region'))"
28
- />
29
- <base-panel-input
30
- class="pl-1"
31
- v-model="formStore.ManagerPolicy"
32
- :value="formStore.ManagerPolicy?.nameRu"
33
- :readonly="isManagerReadonly"
34
- :clearable="!isManagerReadonly"
35
- :label="$dataStore.t('form.manager')"
36
- :rules="$rules.objectRequired"
37
- append-inner-icon="mdi mdi-chevron-right"
38
- @append="openPanel('ManagerPolicy', $dataStore.t('form.manager'))"
39
- />
40
- <base-panel-input
41
- class="pl-1"
42
- v-model="formStore.AgentData"
43
- :value="formStore.AgentData?.fullName"
44
- :readonly="isAgentReadonly"
45
- :clearable="!isAgentReadonly"
46
- :label="$dataStore.t('form.agent')"
47
- :rules="$rules.agentDataRequired"
48
- append-inner-icon="mdi mdi-chevron-right"
49
- @append="openPanel('AgentData', $dataStore.t('form.agent'))"
50
- />
51
- </v-form>
3
+ <v-expansion-panels>
4
+ <v-expansion-panel class="rounded-lg" elevation="0">
5
+ <v-expansion-panel-title :class="[$styles.textTitle, $styles.greenText]">
6
+ {{ $dataStore.t('form.attachManager') }}
7
+ </v-expansion-panel-title>
8
+ <v-expansion-panel-text class="border-t-[1px] no-padding">
9
+ <v-form ref="vForm" class="flex flex-col divide-y">
10
+ <base-panel-input
11
+ class="pl-1 pt-1"
12
+ v-model="formStore.SaleChanellPolicy"
13
+ :value="formStore.SaleChanellPolicy?.nameRu"
14
+ :readonly="isSaleChanellReadonly"
15
+ :clearable="!isSaleChanellReadonly"
16
+ :label="$dataStore.t('form.salesChanell')"
17
+ :rules="$rules.objectRequired"
18
+ append-inner-icon="mdi mdi-chevron-right"
19
+ @append="openPanel('SaleChanellPolicy', $dataStore.t('form.salesChanell'))"
20
+ />
21
+ <base-panel-input
22
+ class="pl-1 pt-1"
23
+ v-model="formStore.RegionPolicy"
24
+ :value="formStore.RegionPolicy?.nameRu"
25
+ :readonly="isRegionReadonly"
26
+ :clearable="!isRegionReadonly"
27
+ :label="$dataStore.t('form.Region')"
28
+ :rules="$rules.objectRequired"
29
+ append-inner-icon="mdi mdi-chevron-right"
30
+ @append="openPanel('RegionPolicy', $dataStore.t('form.Region'))"
31
+ />
32
+ <base-panel-input
33
+ class="pl-1 pt-1"
34
+ v-model="formStore.ManagerPolicy"
35
+ :value="formStore.ManagerPolicy?.nameRu"
36
+ :readonly="isManagerReadonly"
37
+ :clearable="!isManagerReadonly"
38
+ :label="$dataStore.t('form.manager')"
39
+ :rules="$rules.objectRequired"
40
+ append-inner-icon="mdi mdi-chevron-right"
41
+ @append="openPanel('ManagerPolicy', $dataStore.t('form.manager'))"
42
+ />
43
+ <base-panel-input
44
+ class="pl-1 pt-1"
45
+ v-model="formStore.AgentData"
46
+ :value="formStore.AgentData?.fullName"
47
+ :readonly="isAgentReadonly"
48
+ :clearable="!isAgentReadonly"
49
+ :label="$dataStore.t('form.agent')"
50
+ :rules="$rules.agentDataRequired"
51
+ append-inner-icon="mdi mdi-chevron-right"
52
+ @append="openPanel('AgentData', $dataStore.t('form.agent'))"
53
+ />
54
+ </v-form>
55
+ </v-expansion-panel-text>
56
+ </v-expansion-panel>
57
+ </v-expansion-panels>
52
58
  <Teleport v-if="isPanelOpen" to="#right-panel-actions">
53
59
  <div :class="[$styles.scrollPage]" class="flex flex-col items-center">
54
60
  <base-rounded-input
@@ -247,3 +253,9 @@ export default defineComponent({
247
253
  },
248
254
  });
249
255
  </script>
256
+
257
+ <style scoped>
258
+ .no-padding :deep(.v-expansion-panel-text__wrapper) {
259
+ padding: 0 !important;
260
+ }
261
+ </style>
@@ -7,10 +7,7 @@
7
7
  @update:modelValue="$emit('update:modelValue', $event)"
8
8
  locale="ru"
9
9
  model-type="dd.MM.yyyy"
10
- position="left"
11
- menu-class-name="!left-[30vw] md:!left-[70vw] lg:!left-[75vw]"
12
- :teleport="teleport"
13
- :offset="-50"
10
+ :teleport="true"
14
11
  :close-on-scroll="true"
15
12
  :enable-time-picker="false"
16
13
  cancel-text="Отменить"
@@ -36,10 +33,6 @@ export default defineComponent({
36
33
  type: Boolean,
37
34
  default: false,
38
35
  },
39
- teleport: {
40
- type: String,
41
- default: '.v-form',
42
- },
43
36
  },
44
37
  });
45
38
  </script>
@@ -39,7 +39,6 @@
39
39
  v-if="appendInnerIcon.includes('mdi-calendar-blank-outline') && !props.readonly"
40
40
  :model-value="modelValue"
41
41
  @update:modelValue="$emit('update:modelValue', $event)"
42
- :teleport="teleport"
43
42
  />
44
43
  </template>
45
44
  <template v-if="loading" #loader>
@@ -139,10 +138,9 @@ export default defineComponent({
139
138
  const submitted = (event: any) => {
140
139
  emit('submitted', event);
141
140
  };
142
-
143
141
  return {
144
- submitted,
145
142
  props,
143
+ submitted,
146
144
  };
147
145
  },
148
146
  });
@@ -1,17 +1,21 @@
1
1
  <template>
2
2
  <section class="flex flex-col gap-4 px-[10px]">
3
3
  <v-form v-if="member" ref="vForm" @submit="submitForm" class="max-h-[80svh] overflow-y-scroll">
4
- <div v-if="memberSetting && memberSetting.has === true && memberSetting.isMultiple === true" class="flex items-center mt-[14px] min-h-[54px]">
5
- <div :class="[$styles.blueBgLight]" class="flex flex-wrap items-center gap-2 p-1 rounded-t-[8px] h-full">
4
+ <div
5
+ v-if="memberSetting && memberSetting.has === true && whichForm !== 'policyholderForm' && whichForm !== 'policyholdersRepresentativeForm'"
6
+ class="flex items-center mt-[14px] min-h-[54px]"
7
+ >
8
+ <div :class="[$styles.blueBgLight]" class="flex flex-wrap items-center gap-2 p-2 rounded-t-[8px] h-full">
6
9
  <div
7
10
  v-for="(each, index) of formStore[whichForm]"
8
11
  :key="index"
9
- class="pl-3 pr-1 py-1 rounded-[8px] cursor-pointer flex items-center"
10
- :class="[Number(whichIndex) === index ? `${$styles.blueBg} ${$styles.whiteText}` : '', $styles.textSimple]"
12
+ class="rounded-[8px] cursor-pointer flex items-center"
13
+ :class="[Number(whichIndex) === index ? `${$styles.blueBg} ${$styles.whiteText}` : '', $styles.textSimple, isDisabled ? 'py-2 px-3' : 'py-1 pr-1 pl-3']"
11
14
  @click.self="index !== Number(whichIndex) ? selectMember(index) : null"
12
15
  >
13
16
  {{ `${$dataStore.menu.selectedItem.title} ${index + 1}` }}
14
17
  <v-btn
18
+ v-if="!isDisabled"
15
19
  icon="mdi-close !text-[20px]"
16
20
  size="x-small"
17
21
  :disabled="!memberStore.canMemberDeleted(whichForm, index) && !memberStore.canMemberCleared(whichForm, index)"
@@ -21,11 +25,23 @@
21
25
  />
22
26
  </div>
23
27
  </div>
24
- <v-btn class="ml-2" icon="mdi-plus !text-[24px]" @click="memberStore.addMember(whichForm)" size="small" color="#A0B3D8" variant="tonal" />
28
+ <v-btn
29
+ v-if="!isDisabled && memberSetting.isMultiple === true"
30
+ class="ml-2"
31
+ icon="mdi-plus !text-[24px]"
32
+ @click="memberStore.addMember(whichForm)"
33
+ size="small"
34
+ color="#A0B3D8"
35
+ variant="tonal"
36
+ />
25
37
  </div>
26
38
  <base-form-section
27
39
  :title="$dataStore.t('form.personalData')"
28
- :class="[memberSetting && memberSetting.has === true && memberSetting.isMultiple === true ? 'rounded-t-0 !mt-[-5px]' : 'mt-[14px]']"
40
+ :class="[
41
+ memberSetting && memberSetting.has === true && whichForm !== 'policyholderForm' && whichForm !== 'policyholdersRepresentativeForm'
42
+ ? 'rounded-t-0 !mt-[-5px]'
43
+ : 'mt-[14px]',
44
+ ]"
29
45
  >
30
46
  <base-panel-input
31
47
  v-if="$dataStore.isLifetrip"
@@ -331,7 +331,7 @@ export default defineComponent({
331
331
  // loading.value = false;
332
332
  // return;
333
333
  // }
334
- if (dataStore.isAML || dataStore.isCheckContract || dataStore.isCheckContragent) {
334
+ if (dataStore.isAML || dataStore.isCheckContract || dataStore.isCheckContragent || dataStore.isDas) {
335
335
  emit('task', [dataStore.panelAction, route.params.taskId as string, actionCause.value]);
336
336
  } else {
337
337
  await dataStore.handleTask(dataStore.panelAction, route.params.taskId as string, actionCause.value);
@@ -420,7 +420,7 @@ export default defineComponent({
420
420
  const price = computed(() => dataStore.getNumberWithSpaces(formStore.productConditionsForm.calculatorForm.price));
421
421
  const insuredAmount = computed(() => formStore.productConditionsForm.calculatorForm.amount!.nameRu! + dataStore.currency);
422
422
  const hasConditionsInfo = computed(() => {
423
- if (dataStore.isLifetrip) {
423
+ if (dataStore.isLifetrip || dataStore.isDas) {
424
424
  return false;
425
425
  }
426
426
  if (dataStore.isFinCenter()) {
@@ -1494,7 +1494,7 @@ export class MemberV2 {
1494
1494
  date: string | null;
1495
1495
  };
1496
1496
  kbe: string | null;
1497
- typeOfEconomicActivity: string | null;
1497
+ typeOfEconomicActivity: Value;
1498
1498
  legalAddress: Address;
1499
1499
  actualAddress: Address;
1500
1500
  activityTypes: {
@@ -1548,7 +1548,7 @@ export class MemberV2 {
1548
1548
  date: null,
1549
1549
  };
1550
1550
  this.kbe = null;
1551
- this.typeOfEconomicActivity = null;
1551
+ this.typeOfEconomicActivity = new Value();
1552
1552
  this.legalAddress = new Address();
1553
1553
  this.actualAddress = new Address();
1554
1554
  this.activityTypes = [
@@ -2,7 +2,8 @@ import { Actions, PostActions, Roles, Statuses } from '../types/enum';
2
2
 
3
3
  export const constants = Object.freeze({
4
4
  products: {
5
- pensionannuity: 1,
5
+ // TODO remove this after PA will be ready
6
+ pensionannuity: import.meta.env.VITE_MODE === 'production' ? 0 : 1,
6
7
  baiterek: 3,
7
8
  halykmycar: 5,
8
9
  lifetrip: 7,
@@ -22,6 +23,7 @@ export const constants = Object.freeze({
22
23
  editableStatuses: [Statuses.StartForm, Statuses.EditBeneficiaryForm, Statuses.EditForm, Statuses.InputDataForm],
23
24
  documentsLinkVisibleStatuses: [
24
25
  Statuses.DocumentsSignedFrom,
26
+ Statuses.DocumentsSignedClientFrom,
25
27
  Statuses.UnderwriterForm,
26
28
  Statuses.AffilationResolutionForm,
27
29
  Statuses.Completed,
@@ -33,7 +35,7 @@ export const constants = Object.freeze({
33
35
  Statuses.ContractSignedFrom,
34
36
  Statuses.WaitingInsurancePremiumForm,
35
37
  Statuses.UnderwriterForm,
36
- Statuses.InputDataForm,
38
+ Statuses.ApproveForm,
37
39
  ],
38
40
  cancelApplicationStatuses: [
39
41
  Statuses.StartForm,
@@ -42,7 +44,6 @@ export const constants = Object.freeze({
42
44
  Statuses.WaitingInsurancePremiumForm,
43
45
  Statuses.DocumentsSignedFrom,
44
46
  Statuses.DocumentsSignedClientFrom,
45
- Statuses.InputDataForm,
46
47
  Statuses.ContractSignedFrom,
47
48
  ],
48
49
  gbdErrors: ['INVALID', 'TIMEOUT', 'ERROR', 'NOT_FOUND'],
@@ -184,12 +184,13 @@ export const ESBDMessage = (ESBDObject: any, initialPoint: any) => {
184
184
 
185
185
  export const ErrorHandler = (err: unknown, errorText?: string) => {
186
186
  console.log(err);
187
+ const dataStore = useDataStore();
187
188
  if (err instanceof AxiosError) {
188
189
  if ('response' in err && err.response && err.response.data) {
189
190
  if ('status' in err.response && err.response.status === 403) {
190
- useDataStore().showToaster('error', useDataStore().t('toaster.noPermission'), 10000);
191
+ dataStore.showToaster('error', dataStore.t('toaster.noPermission'), 10000);
191
192
  } else if (err.response.data) {
192
- useDataStore().showToaster('error', errorText ? errorText : err.response.data, 10000);
193
+ dataStore.showToaster('error', errorText ? errorText : err.response.data, 10000);
193
194
  }
194
195
  }
195
196
  }
package/locales/ru.json CHANGED
@@ -27,7 +27,8 @@
27
27
  "noOtpResponse": "Отсутствует ответ при отправке OTP кода",
28
28
  "noOtpCode": "Заполните поля: ИИН, Номер телефона, Код подтверждения",
29
29
  "memberCopy": "Ошибка при копировании данных участников",
30
- "memberSave": "Ошибка при сохранении данных участников"
30
+ "memberSave": "Ошибка при сохранении данных участников",
31
+ "notValidIik": "Некорректный ИИК"
31
32
  },
32
33
  "toaster": {
33
34
  "wrongFormatOf": "Некорректный формат \"{text}\"",
@@ -762,7 +763,7 @@
762
763
  "iik": "ИИК должен состоять из 20 символов",
763
764
  "dataInPast": "Указанная дата осталась в прошлом"
764
765
  },
765
- "code": "КЭС",
766
+ "code": "КСЭ",
766
767
  "fontSize": "Размер шрифта",
767
768
  "policyholdersRepresentative": {
768
769
  "name": "ФИО",
@@ -816,7 +817,7 @@
816
817
  "job": "Профессия",
817
818
  "jobPosition": "Должность",
818
819
  "jobPlace": "Место работы",
819
- "jobDesk": "Занимаемая должность и точная описание служебных обязанностей",
820
+ "jobDesk": "Занимаемая должность и точное описание служебных обязанностей",
820
821
  "placeRegistration": "Место жительство или регистрации",
821
822
  "placePermanent": "Постоянный адрес проживания",
822
823
  "sameAddress": "Совпадает ли адрес с адресом Страхователя?",
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "hl-core",
3
- "version": "0.0.9-beta.38",
3
+ "version": "0.0.9-beta.40",
4
4
  "license": "MIT",
5
5
  "private": false,
6
6
  "main": "nuxt.config.ts",
@@ -1252,14 +1252,14 @@ export const useDataStore = defineStore('data', {
1252
1252
  if (!!keys.deepKey) {
1253
1253
  if (!!keys.subDeepKey) {
1254
1254
  //@ts-ignore
1255
- return this.states.filter(i => i.code === member[keys.key][keys.deepKey][keys.subDeepKey].ids);
1255
+ return this.states.filter(i => i.code === member[keys.key][keys.deepKey][keys.subDeepKey].ids || i.code === member[keys.key][keys.deepKey][keys.subDeepKey].id);
1256
1256
  } else {
1257
1257
  //@ts-ignore
1258
- return this.states.filter(i => i.code === member[keys.key][keys.deepKey].ids);
1258
+ return this.states.filter(i => i.code === member[keys.key][keys.deepKey].ids || i.code === member[keys.key][keys.deepKey].id);
1259
1259
  }
1260
1260
  } else {
1261
1261
  //@ts-ignore
1262
- return this.states.filter(i => i.code === member[keys.key].ids);
1262
+ return this.states.filter(i => i.code === member[keys.key].ids || i.code === member[keys.key].id);
1263
1263
  }
1264
1264
  }
1265
1265
  } else {
@@ -1275,14 +1275,14 @@ export const useDataStore = defineStore('data', {
1275
1275
  if (!!keys.deepKey) {
1276
1276
  if (!!keys.subDeepKey) {
1277
1277
  //@ts-ignore
1278
- return this.regions.filter(i => i.code === member[keys.key][keys.deepKey][keys.subDeepKey].ids);
1278
+ return this.regions.filter(i => i.code === member[keys.key][keys.deepKey][keys.subDeepKey].ids || i.code === member[keys.key][keys.deepKey][keys.subDeepKey].id);
1279
1279
  } else {
1280
1280
  //@ts-ignore
1281
- return this.regions.filter(i => i.code === member[keys.key][keys.deepKey].ids);
1281
+ return this.regions.filter(i => i.code === member[keys.key][keys.deepKey].ids || i.code === member[keys.key][keys.deepKey].id);
1282
1282
  }
1283
1283
  } else {
1284
1284
  //@ts-ignore
1285
- return this.regions.filter(i => i.code === member[keys.key].ids);
1285
+ return this.regions.filter(i => i.code === member[keys.key].ids || i.code === member[keys.key].id);
1286
1286
  }
1287
1287
  }
1288
1288
  } else {
@@ -1301,14 +1301,14 @@ export const useDataStore = defineStore('data', {
1301
1301
  if (!!keys.deepKey) {
1302
1302
  if (!!keys.subDeepKey) {
1303
1303
  //@ts-ignore
1304
- return this.cities.filter(i => i.code === member[keys.key][keys.deepKey][keys.subDeepKey].ids);
1304
+ return this.cities.filter(i => i.code === member[keys.key][keys.deepKey][keys.subDeepKey].ids || i.code === member[keys.key][keys.deepKey][keys.subDeepKey].id);
1305
1305
  } else {
1306
1306
  //@ts-ignore
1307
- return this.cities.filter(i => i.code === member[keys.key][keys.deepKey].ids);
1307
+ return this.cities.filter(i => i.code === member[keys.key][keys.deepKey].ids || i.code === member[keys.key][keys.deepKey].id);
1308
1308
  }
1309
1309
  } else {
1310
1310
  //@ts-ignore
1311
- return this.cities.filter(i => i.code === member[keys.key].ids);
1311
+ return this.cities.filter(i => i.code === member[keys.key].ids || i.code === member[keys.key].id);
1312
1312
  }
1313
1313
  }
1314
1314
  } else {
package/types/enum.ts CHANGED
@@ -8,18 +8,43 @@ export enum StoreMembers {
8
8
 
9
9
  export enum Actions {
10
10
  accept = 'accept',
11
+ acceptCustom = 'acceptCustom',
12
+
11
13
  rejectclient = 'rejectclient',
14
+ rejectclientCustom = 'rejectclientCustom',
15
+
12
16
  reject = 'reject',
17
+ rejectCustom = 'rejectCustom',
18
+
13
19
  return = 'return',
20
+ returnCustom = 'returnCustom',
21
+
14
22
  claim = 'claim',
23
+ claimCustom = 'claimCustom',
24
+
15
25
  sign = 'sign',
26
+ signCustom = 'signCustom',
27
+
16
28
  signed = 'signed',
29
+ signedCustom = 'signedCustom',
30
+
17
31
  pay = 'pay',
32
+ payCustom = 'payCustom',
33
+
18
34
  register = 'register',
35
+ registerCustom = 'registerCustom',
36
+
19
37
  send = 'send',
38
+ sendCustom = 'sendCustom',
39
+
20
40
  affiliate = 'affiliate',
41
+ affiliateCustom = 'affiliateCustom',
42
+
21
43
  template = 'template',
44
+ templateCustom = 'templateCustom',
45
+
22
46
  chooseSign = 'chooseSign',
47
+ chooseSignCustom = 'chooseSignCustom',
23
48
  }
24
49
 
25
50
  export enum PostActions {