hl-core 0.0.9-beta.28 → 0.0.9-beta.29

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.
@@ -1,15 +1,15 @@
1
1
  <template>
2
2
  <div class="h-full z-[1]" :class="[$dataStore.hasLayoutMargins ? 'lg:mx-[22px] lg:my-[33px] lg:shadow-xl' : '']">
3
3
  <div :class="[$styles.greenBg]" class="hidden z-[-1] lg:block absolute left-0 top-0 h-[200px] w-full"></div>
4
- <section class="flex h-full" :class="$styles.blueBgLight">
4
+ <section class="flex h-full relative" :class="$styles.blueBgLight">
5
5
  <base-menu-nav
6
6
  v-if="$dataStore.showNav"
7
7
  :selected="$dataStore.menu.selectedItem"
8
8
  :title="$dataStore.menu.title ?? 'Страховые продукты'"
9
9
  :has-back="$dataStore.menu.hasBack ?? false"
10
10
  :back-icon="$dataStore.menu.backIcon ?? 'mdi-arrow-left'"
11
- :more-icon="$dataStore.menu.moreIcon ?? 'mdi-cog-outline'"
12
- :has-more="'hasMore' in $route.meta && $route.meta.hasMore ? !!$route.meta.hasMore : false"
11
+ :more-icon="$dataStore.menu.moreIcon ?? 'mdi-dots-vertical'"
12
+ :has-more="'hasMore' in $route.meta ? !!$route.meta.hasMore : true"
13
13
  :class="{
14
14
  // @ts-ignore
15
15
  '!hidden': !$display().lgAndUp.value && !!$dataStore.menu.selectedItem.title,
@@ -23,6 +23,7 @@
23
23
  </template>
24
24
  </base-menu-nav>
25
25
  <slot></slot>
26
+ <base-drawer which-panel="rightPanel" :panel-title="$dataStore.rightPanel.title" side="right" />
26
27
  <base-settings-panel />
27
28
  </section>
28
29
  </div>
@@ -44,6 +45,44 @@ const onLink = async (item: MenuItem) => {
44
45
  const onBack = async (item: MenuItem) => {
45
46
  if (dataStore.menu.onBack) await dataStore.menu.onBack(item);
46
47
  };
48
+
49
+ watch(
50
+ () => dataStore.settings.open,
51
+ () => {
52
+ if (dataStore.settings.open === true && dataStore.panel.open === true) {
53
+ dataStore.panel.open = false;
54
+ dataStore.panelAction = null;
55
+ }
56
+ if (dataStore.settings.open === true && dataStore.rightPanel.open === true) {
57
+ dataStore.rightPanel.open = false;
58
+ }
59
+ },
60
+ );
61
+
62
+ watch(
63
+ () => dataStore.rightPanel.open,
64
+ () => {
65
+ if (dataStore.rightPanel.open === true && dataStore.panel.open === true) {
66
+ dataStore.panel.open = false;
67
+ dataStore.panelAction = null;
68
+ }
69
+ if (dataStore.rightPanel.open === true && dataStore.settings.open === true) {
70
+ dataStore.settings.open = false;
71
+ }
72
+ },
73
+ );
74
+
75
+ watch(
76
+ () => dataStore.panel.open,
77
+ () => {
78
+ if (dataStore.panel.open === true && dataStore.settings.open === true) {
79
+ dataStore.settings.open = false;
80
+ }
81
+ if (dataStore.panel.open === true && dataStore.rightPanel.open === true) {
82
+ dataStore.rightPanel.open = false;
83
+ }
84
+ },
85
+ );
47
86
  </script>
48
87
  <style>
49
88
  .mainpage,
package/locales/ru.json CHANGED
@@ -130,7 +130,8 @@
130
130
  "templateSentToEmail": "Шаблона отправлен на почту",
131
131
  "fileOnlyBelow5mb": "Максимальный размер документа для загрузки - 5 МБ.",
132
132
  "fileOnlyBelow20mb": "Максимальный размер документа для загрузки - 20 МБ.",
133
- "onlyPDF": "Загружать документы можно только в формате PDF"
133
+ "onlyPDF": "Загружать документы можно только в формате PDF",
134
+ "notAllDocumentsAttached": "Не все документы вложены"
134
135
  },
135
136
  "notSignedContract": "Неподписанный Договор",
136
137
  "Contract": "Договор страхования",
@@ -205,7 +206,11 @@
205
206
  "sendOnPaper": "Отправить на бумажном носителе",
206
207
  "export": "Экспорт",
207
208
  "fromGBDUL": "ГБДЮЛ",
208
- "fromKGD": "КГД"
209
+ "fromKGD": "КГД",
210
+ "generatePrintedForms": "Сформировать печатные формы",
211
+ "downloadStatement": "Скачать заявление",
212
+ "downloadApplication": "Скачать приложение №1",
213
+ "downloadPowerOfAttorney": "Скачать доверенность"
209
214
  },
210
215
  "dialog": {
211
216
  "title": "Подтверждение",
@@ -448,7 +453,12 @@
448
453
  "createdDate": "Дата добавления",
449
454
  "isActive": "Активен",
450
455
  "countryName": "Место жительства",
451
- "countryResidence": "Налоговое резидентство"
456
+ "countryResidence": "Налоговое резидентство",
457
+ "complianceStatement": "Заключение службы комплайенс",
458
+ "parameters": "Параметры",
459
+ "chooseCheckType": "Выберите режим проверки",
460
+ "contracts": "Контракты",
461
+ "contragents": "Контрагенты"
452
462
  },
453
463
  "agent": {
454
464
  "currency": "Валюта",
@@ -679,7 +689,11 @@
679
689
  "jsonObject": "JSON значение",
680
690
  "epayPage": "Страница на ePay",
681
691
  "checkWithDoc": "Сверьте с документом",
682
- "inDetails": "Подробно"
692
+ "inDetails": "Подробно",
693
+ "attachContract": "Вложить договор",
694
+ "attachStatement": "Вложить заявление",
695
+ "attachApplication": "Вложить приложение №1",
696
+ "attachPowerOfAttorney": "Вложить доверенность"
683
697
  },
684
698
  "placeholders": {
685
699
  "login": "Логин",
@@ -862,6 +876,7 @@
862
876
  "dataBeneficialOwner": "Данные Бенефициарного собственника",
863
877
  "documentsBeneficialOwner": "Документы Бенефициарного собственника",
864
878
  "coveragePeriod": "Период покрытия",
879
+ "attachScansSignDocs": "Вложить сканы подписанных документов",
865
880
  "form": {
866
881
  "calculation": "Расчеты",
867
882
  "paymentAmount": "Размер выплаты",
@@ -924,10 +939,10 @@
924
939
  "consumption": "Расход",
925
940
  "remainder": "Остаток",
926
941
  "loans": "Займы",
927
- "loanNumber":"Номер займа",
928
- "rewardAmount":"Сумма вознаграждения",
929
- "loanType":"Тип займа",
930
- "writeOff":"Списание из ВС",
942
+ "loanNumber": "Номер займа",
943
+ "rewardAmount": "Сумма вознаграждения",
944
+ "loanType": "Тип займа",
945
+ "writeOff": "Списание из ВС",
931
946
  "paymentJournal": "Журнал оплат",
932
947
  "startDate": "Дата начала",
933
948
  "loanAmount": "Сумма займа",
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "hl-core",
3
- "version": "0.0.9-beta.28",
3
+ "version": "0.0.9-beta.29",
4
4
  "license": "MIT",
5
5
  "private": false,
6
6
  "main": "nuxt.config.ts",
@@ -299,6 +299,7 @@ export const useDataStore = defineStore('data', {
299
299
  },
300
300
  async resetSelected(route: RouteType) {
301
301
  this.settings.open = false;
302
+ this.rightPanel.open = false;
302
303
  this.panel.open = false;
303
304
  this.panelAction = null;
304
305
  this.menu.selectedItem = new MenuItem();
@@ -1778,6 +1779,10 @@ export const useDataStore = defineStore('data', {
1778
1779
  }
1779
1780
  if (this.isLifeBusiness) {
1780
1781
  this.formStore.productConditionsForm.insurancePremiumPerMonth = this.getNumberWithSpaces(result.value);
1782
+ if (applicationData.insuredApp && applicationData.insuredApp.length) {
1783
+ const res = await this.newInsuredList(applicationData.insuredApp);
1784
+ this.formStore.lfb.clients = res;
1785
+ }
1781
1786
  }
1782
1787
 
1783
1788
  this.showToaster('success', this.t('toaster.calculated'), 1000);
@@ -3014,7 +3019,7 @@ export const useDataStore = defineStore('data', {
3014
3019
  if (economySectorCode) member.economySectorCode = economySectorCode;
3015
3020
  },
3016
3021
  async startApplicationV2(policyholder: MemberV2) {
3017
- if (!policyholder.personalData.iin) return false;
3022
+ if (!policyholder.iin) return false;
3018
3023
  try {
3019
3024
  const response = await this.api.startApplication(policyholder);
3020
3025
  this.sendToParent(constants.postActions.applicationCreated, response.processInstanceId);
@@ -3067,16 +3072,16 @@ export const useDataStore = defineStore('data', {
3067
3072
  this.formStore.applicationData.processInstanceId = applicationData.processInstanceId;
3068
3073
  this.formStore.lfb.policyholder = clientData;
3069
3074
  this.formStore.lfb.clientId = clientId;
3070
- this.formStore.lfb.policyholder.clientPower.date = reformatDate(clientData.clientPower.date);
3075
+ this.formStore.lfb.policyholder.authorityDetails.date = reformatDate(clientData.authorityDetails.date);
3071
3076
 
3072
- if (clientData && clientData.activityTypes !== null) {
3073
- this.formStore.lfb.policyholderActivities = clientData.activityTypes;
3077
+ if (clientData && clientData.organizationInfo.activityTypes !== null) {
3078
+ this.formStore.lfb.policyholderActivities = clientData.organizationInfo.activityTypes;
3074
3079
  }
3075
3080
 
3076
3081
  if (beneficialOwnerApp && beneficialOwnerApp.length) {
3077
3082
  this.formStore.lfb.beneficialOwners = beneficialOwnerApp;
3078
3083
  this.formStore.lfb.beneficialOwners.forEach(beneficial => {
3079
- beneficial.beneficialOwnerData.identityCard!.validity = reformatDate(beneficial.beneficialOwnerData.identityCard!.validity as string);
3084
+ beneficial.beneficialOwnerData.identityDocument!.validUntil = reformatDate(beneficial.beneficialOwnerData.identityDocument!.validUntil as string);
3080
3085
  });
3081
3086
  }
3082
3087
 
@@ -3154,9 +3159,9 @@ export const useDataStore = defineStore('data', {
3154
3159
  return ErrorHandler(err);
3155
3160
  }
3156
3161
  },
3157
- async saveInsured(insuredId: any) {
3162
+ async saveInsured(insured: any) {
3158
3163
  try {
3159
- const response = await this.api.saveInsured(this.formStore.applicationData.processInstanceId, insuredId.id, insuredId);
3164
+ const response = await this.api.saveInsured(this.formStore.applicationData.processInstanceId, insured.id, insured);
3160
3165
  return response;
3161
3166
  } catch (err) {
3162
3167
  return ErrorHandler(err);
@@ -3167,11 +3172,11 @@ export const useDataStore = defineStore('data', {
3167
3172
  const client = item.insuredData;
3168
3173
  return {
3169
3174
  id: index,
3170
- fullName: client.personalData.longName,
3171
- sex: client.personalData.sex,
3172
- position: item.position,
3173
- birthDate: client.personalData.birthDate,
3174
- iin: client.personalData.iin,
3175
+ fullName: client.longName,
3176
+ gender: client.gender,
3177
+ position: item.workDetails?.position,
3178
+ birthDate: client.birthDate,
3179
+ iin: client.iin,
3175
3180
  insSum: client.insuredPolicyData.insSum,
3176
3181
  premium: client.insuredPolicyData.premium,
3177
3182
  };
@@ -3234,7 +3239,7 @@ export const useDataStore = defineStore('data', {
3234
3239
  }
3235
3240
 
3236
3241
  if (this.formStore.lfb.policyholderActivities) {
3237
- if (this.formStore.lfb.policyholderActivities.length !== this.formStore.applicationData.clientApp.clientData.activityTypes.length) {
3242
+ if (this.formStore.lfb.policyholderActivities.length !== this.formStore.applicationData.clientApp.clientData.organizationInfo.activityTypes.length) {
3238
3243
  this.showToaster('error', this.t('toaster.notSavedMember', { text: 'деятельности Страхователя' }), 3000);
3239
3244
  return false;
3240
3245
  }
package/types/index.ts CHANGED
@@ -29,7 +29,7 @@ declare global {
29
29
  type MemberFormTypes = 'policyholderForm' | 'insuredForm' | 'beneficiaryForm' | 'beneficialOwnerForm' | 'policyholdersRepresentativeForm' | 'productConditionsForm';
30
30
  type SingleMember = 'policyholderForm' | 'policyholdersRepresentativeForm';
31
31
  type MultipleMember = 'insuredForm' | 'beneficiaryForm' | 'beneficialOwnerForm';
32
- type PanelTypes = 'settings' | 'panel';
32
+ type PanelTypes = 'settings' | 'panel' | 'rightPanel';
33
33
  type FileActions = 'view' | 'download';
34
34
  type RouteType = RouteLocationNormalizedLoaded | RouteLocationNormalized;
35
35
  type InputVariants = 'solo' | 'filled' | 'outlined' | 'plain' | 'underlined';
@@ -273,7 +273,7 @@ declare global {
273
273
  id: string | number;
274
274
  iin: string;
275
275
  fullName: string;
276
- sex: number;
276
+ gender: number;
277
277
  birthDate: string;
278
278
  insSum: number;
279
279
  premium?: number;