@redneckz/wildless-cms-uni-blocks 0.14.621 → 0.14.623
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/bundle/api/RetailAPI/updateUserProfile.d.ts +1 -1
- package/bundle/blocks.schema.json +1 -1
- package/bundle/bundle.umd.js +43 -34
- package/bundle/bundle.umd.min.js +1 -1
- package/bundle/components/ApplicationForm/ApplicationFormContent.d.ts +1 -1
- package/bundle/components/ApplicationLeadForm/ApplicationLeadFormContent.d.ts +1 -1
- package/bundle/components/ApplicationLeadForm/getInitialFormState.d.ts +1 -1
- package/bundle/components/CreditForm/CreditFormStep.d.ts +1 -2
- package/bundle/components/CreditForm/StepsNavigationButtons.d.ts +0 -1
- package/bundle/components/CreditForm/creditFormStepsData.d.ts +2 -178
- package/bundle/ui-kit/FormField/NameFieldDef.d.ts +1 -1
- package/bundle/ui-kit/FormField/getNamesFromInput.d.ts +1 -1
- package/dist/api/RetailAPI/updateUserProfile.d.ts +1 -1
- package/dist/api/RetailAPI/utils/getUpdateUserProfile.js +2 -2
- package/dist/api/RetailAPI/utils/getUpdateUserProfile.js.map +1 -1
- package/dist/api/dadataHints/hintsListsOptions.js +1 -0
- package/dist/api/dadataHints/hintsListsOptions.js.map +1 -1
- package/dist/components/ApplicationForm/ApplicationFormContent.d.ts +1 -1
- package/dist/components/ApplicationForm/getInitialFormState.js +1 -1
- package/dist/components/ApplicationForm/getInitialFormState.js.map +1 -1
- package/dist/components/ApplicationForm/renderInputs.js +2 -2
- package/dist/components/ApplicationForm/renderInputs.js.map +1 -1
- package/dist/components/ApplicationLeadForm/ApplicationLeadFormContent.d.ts +1 -1
- package/dist/components/ApplicationLeadForm/GroupedConsents.js.map +1 -1
- package/dist/components/ApplicationLeadForm/consents.js +1 -1
- package/dist/components/ApplicationLeadForm/consents.js.map +1 -1
- package/dist/components/ApplicationLeadForm/getInitialFormState.d.ts +1 -1
- package/dist/components/ApplicationLeadForm/getInitialFormState.js +2 -2
- package/dist/components/ApplicationLeadForm/getInitialFormState.js.map +1 -1
- package/dist/components/ApplicationLeadForm/useInitApplicationLead.js +1 -1
- package/dist/components/ApplicationLeadForm/useInitApplicationLead.js.map +1 -1
- package/dist/components/CreditForm/CreditForm.js +3 -3
- package/dist/components/CreditForm/CreditForm.js.map +1 -1
- package/dist/components/CreditForm/CreditFormProgress.js +3 -3
- package/dist/components/CreditForm/CreditFormProgress.js.map +1 -1
- package/dist/components/CreditForm/CreditFormStep.d.ts +1 -2
- package/dist/components/CreditForm/CreditFormStep.js +3 -3
- package/dist/components/CreditForm/CreditFormStep.js.map +1 -1
- package/dist/components/CreditForm/StepsNavigationButtons.d.ts +0 -1
- package/dist/components/CreditForm/StepsNavigationButtons.js +2 -1
- package/dist/components/CreditForm/StepsNavigationButtons.js.map +1 -1
- package/dist/components/CreditForm/creditFormStepsData.d.ts +2 -178
- package/dist/components/CreditForm/creditFormStepsData.js +8 -9
- package/dist/components/CreditForm/creditFormStepsData.js.map +1 -1
- package/dist/ui-kit/FormField/Fields/PartInBusinessField.js +9 -1
- package/dist/ui-kit/FormField/Fields/PartInBusinessField.js.map +1 -1
- package/dist/ui-kit/FormField/NameFieldDef.d.ts +1 -1
- package/dist/ui-kit/FormField/getField.js +2 -2
- package/dist/ui-kit/FormField/getField.js.map +1 -1
- package/dist/ui-kit/FormField/getNamesFromInput.d.ts +1 -1
- package/dist/ui-kit/FormField/getObjectValidator.js +2 -2
- package/dist/ui-kit/FormField/getObjectValidator.js.map +1 -1
- package/lib/api/RetailAPI/updateUserProfile.d.ts +1 -1
- package/lib/api/RetailAPI/utils/getUpdateUserProfile.js +2 -2
- package/lib/api/RetailAPI/utils/getUpdateUserProfile.js.map +1 -1
- package/lib/api/dadataHints/hintsListsOptions.js +1 -0
- package/lib/api/dadataHints/hintsListsOptions.js.map +1 -1
- package/lib/components/ApplicationForm/ApplicationFormContent.d.ts +1 -1
- package/lib/components/ApplicationForm/getInitialFormState.js +1 -1
- package/lib/components/ApplicationForm/getInitialFormState.js.map +1 -1
- package/lib/components/ApplicationForm/renderInputs.js +2 -2
- package/lib/components/ApplicationForm/renderInputs.js.map +1 -1
- package/lib/components/ApplicationLeadForm/ApplicationLeadForm.fixture.d.ts +0 -2
- package/lib/components/ApplicationLeadForm/ApplicationLeadFormContent.d.ts +1 -1
- package/lib/components/ApplicationLeadForm/GroupedConsents.js.map +1 -1
- package/lib/components/ApplicationLeadForm/consents.js +1 -1
- package/lib/components/ApplicationLeadForm/consents.js.map +1 -1
- package/lib/components/ApplicationLeadForm/getInitialFormState.d.ts +1 -1
- package/lib/components/ApplicationLeadForm/getInitialFormState.js +2 -2
- package/lib/components/ApplicationLeadForm/getInitialFormState.js.map +1 -1
- package/lib/components/ApplicationLeadForm/useInitApplicationLead.js +1 -1
- package/lib/components/ApplicationLeadForm/useInitApplicationLead.js.map +1 -1
- package/lib/components/CreditForm/CreditForm.js +3 -3
- package/lib/components/CreditForm/CreditForm.js.map +1 -1
- package/lib/components/CreditForm/CreditFormProgress.js +3 -3
- package/lib/components/CreditForm/CreditFormProgress.js.map +1 -1
- package/lib/components/CreditForm/CreditFormStep.d.ts +1 -2
- package/lib/components/CreditForm/CreditFormStep.js +3 -3
- package/lib/components/CreditForm/CreditFormStep.js.map +1 -1
- package/lib/components/CreditForm/StepsNavigationButtons.d.ts +0 -1
- package/lib/components/CreditForm/StepsNavigationButtons.js +2 -1
- package/lib/components/CreditForm/StepsNavigationButtons.js.map +1 -1
- package/lib/components/CreditForm/creditFormStepsData.d.ts +2 -178
- package/lib/components/CreditForm/creditFormStepsData.js +8 -9
- package/lib/components/CreditForm/creditFormStepsData.js.map +1 -1
- package/lib/components/OfficesAtmsMap/OfficesAtmsMapLayout.d.ts +1 -1
- package/lib/ui-kit/FormField/Fields/PartInBusinessField.js +9 -1
- package/lib/ui-kit/FormField/Fields/PartInBusinessField.js.map +1 -1
- package/lib/ui-kit/FormField/NameFieldDef.d.ts +1 -1
- package/lib/ui-kit/FormField/getField.js +2 -2
- package/lib/ui-kit/FormField/getField.js.map +1 -1
- package/lib/ui-kit/FormField/getNamesFromInput.d.ts +1 -1
- package/lib/ui-kit/FormField/getObjectValidator.js +2 -2
- package/lib/ui-kit/FormField/getObjectValidator.js.map +1 -1
- package/mobile/bundle/api/RetailAPI/updateUserProfile.d.ts +1 -1
- package/mobile/bundle/bundle.umd.js +43 -34
- package/mobile/bundle/bundle.umd.min.js +1 -1
- package/mobile/bundle/components/ApplicationForm/ApplicationFormContent.d.ts +1 -1
- package/mobile/bundle/components/ApplicationLeadForm/ApplicationLeadFormContent.d.ts +1 -1
- package/mobile/bundle/components/ApplicationLeadForm/getInitialFormState.d.ts +1 -1
- package/mobile/bundle/components/CreditForm/CreditFormStep.d.ts +1 -2
- package/mobile/bundle/components/CreditForm/StepsNavigationButtons.d.ts +0 -1
- package/mobile/bundle/components/CreditForm/creditFormStepsData.d.ts +2 -178
- package/mobile/bundle/ui-kit/FormField/NameFieldDef.d.ts +1 -1
- package/mobile/bundle/ui-kit/FormField/getNamesFromInput.d.ts +1 -1
- package/mobile/dist/api/RetailAPI/updateUserProfile.d.ts +1 -1
- package/mobile/dist/api/RetailAPI/utils/getUpdateUserProfile.js +2 -2
- package/mobile/dist/api/RetailAPI/utils/getUpdateUserProfile.js.map +1 -1
- package/mobile/dist/api/dadataHints/hintsListsOptions.js +1 -0
- package/mobile/dist/api/dadataHints/hintsListsOptions.js.map +1 -1
- package/mobile/dist/components/ApplicationForm/ApplicationFormContent.d.ts +1 -1
- package/mobile/dist/components/ApplicationForm/getInitialFormState.js +1 -1
- package/mobile/dist/components/ApplicationForm/getInitialFormState.js.map +1 -1
- package/mobile/dist/components/ApplicationForm/renderInputs.js +2 -2
- package/mobile/dist/components/ApplicationForm/renderInputs.js.map +1 -1
- package/mobile/dist/components/ApplicationLeadForm/ApplicationLeadFormContent.d.ts +1 -1
- package/mobile/dist/components/ApplicationLeadForm/GroupedConsents.js.map +1 -1
- package/mobile/dist/components/ApplicationLeadForm/consents.js +1 -1
- package/mobile/dist/components/ApplicationLeadForm/consents.js.map +1 -1
- package/mobile/dist/components/ApplicationLeadForm/getInitialFormState.d.ts +1 -1
- package/mobile/dist/components/ApplicationLeadForm/getInitialFormState.js +2 -2
- package/mobile/dist/components/ApplicationLeadForm/getInitialFormState.js.map +1 -1
- package/mobile/dist/components/ApplicationLeadForm/useInitApplicationLead.js +1 -1
- package/mobile/dist/components/ApplicationLeadForm/useInitApplicationLead.js.map +1 -1
- package/mobile/dist/components/CreditForm/CreditForm.js +3 -3
- package/mobile/dist/components/CreditForm/CreditForm.js.map +1 -1
- package/mobile/dist/components/CreditForm/CreditFormProgress.js +3 -3
- package/mobile/dist/components/CreditForm/CreditFormProgress.js.map +1 -1
- package/mobile/dist/components/CreditForm/CreditFormStep.d.ts +1 -2
- package/mobile/dist/components/CreditForm/CreditFormStep.js +3 -3
- package/mobile/dist/components/CreditForm/CreditFormStep.js.map +1 -1
- package/mobile/dist/components/CreditForm/StepsNavigationButtons.d.ts +0 -1
- package/mobile/dist/components/CreditForm/StepsNavigationButtons.js +2 -1
- package/mobile/dist/components/CreditForm/StepsNavigationButtons.js.map +1 -1
- package/mobile/dist/components/CreditForm/creditFormStepsData.d.ts +2 -178
- package/mobile/dist/components/CreditForm/creditFormStepsData.js +8 -9
- package/mobile/dist/components/CreditForm/creditFormStepsData.js.map +1 -1
- package/mobile/dist/ui-kit/FormField/Fields/PartInBusinessField.js +9 -1
- package/mobile/dist/ui-kit/FormField/Fields/PartInBusinessField.js.map +1 -1
- package/mobile/dist/ui-kit/FormField/NameFieldDef.d.ts +1 -1
- package/mobile/dist/ui-kit/FormField/getField.js +2 -2
- package/mobile/dist/ui-kit/FormField/getField.js.map +1 -1
- package/mobile/dist/ui-kit/FormField/getNamesFromInput.d.ts +1 -1
- package/mobile/dist/ui-kit/FormField/getObjectValidator.js +2 -2
- package/mobile/dist/ui-kit/FormField/getObjectValidator.js.map +1 -1
- package/mobile/lib/api/RetailAPI/updateUserProfile.d.ts +1 -1
- package/mobile/lib/api/RetailAPI/utils/getUpdateUserProfile.js +2 -2
- package/mobile/lib/api/RetailAPI/utils/getUpdateUserProfile.js.map +1 -1
- package/mobile/lib/api/dadataHints/hintsListsOptions.js +1 -0
- package/mobile/lib/api/dadataHints/hintsListsOptions.js.map +1 -1
- package/mobile/lib/components/ApplicationForm/ApplicationFormContent.d.ts +1 -1
- package/mobile/lib/components/ApplicationForm/getInitialFormState.js +1 -1
- package/mobile/lib/components/ApplicationForm/getInitialFormState.js.map +1 -1
- package/mobile/lib/components/ApplicationForm/renderInputs.js +2 -2
- package/mobile/lib/components/ApplicationForm/renderInputs.js.map +1 -1
- package/mobile/lib/components/ApplicationLeadForm/ApplicationLeadFormContent.d.ts +1 -1
- package/mobile/lib/components/ApplicationLeadForm/GroupedConsents.js.map +1 -1
- package/mobile/lib/components/ApplicationLeadForm/consents.js +1 -1
- package/mobile/lib/components/ApplicationLeadForm/consents.js.map +1 -1
- package/mobile/lib/components/ApplicationLeadForm/getInitialFormState.d.ts +1 -1
- package/mobile/lib/components/ApplicationLeadForm/getInitialFormState.js +2 -2
- package/mobile/lib/components/ApplicationLeadForm/getInitialFormState.js.map +1 -1
- package/mobile/lib/components/ApplicationLeadForm/useInitApplicationLead.js +1 -1
- package/mobile/lib/components/ApplicationLeadForm/useInitApplicationLead.js.map +1 -1
- package/mobile/lib/components/CreditForm/CreditForm.js +3 -3
- package/mobile/lib/components/CreditForm/CreditForm.js.map +1 -1
- package/mobile/lib/components/CreditForm/CreditFormProgress.js +3 -3
- package/mobile/lib/components/CreditForm/CreditFormProgress.js.map +1 -1
- package/mobile/lib/components/CreditForm/CreditFormStep.d.ts +1 -2
- package/mobile/lib/components/CreditForm/CreditFormStep.js +3 -3
- package/mobile/lib/components/CreditForm/CreditFormStep.js.map +1 -1
- package/mobile/lib/components/CreditForm/StepsNavigationButtons.d.ts +0 -1
- package/mobile/lib/components/CreditForm/StepsNavigationButtons.js +2 -1
- package/mobile/lib/components/CreditForm/StepsNavigationButtons.js.map +1 -1
- package/mobile/lib/components/CreditForm/creditFormStepsData.d.ts +2 -178
- package/mobile/lib/components/CreditForm/creditFormStepsData.js +8 -9
- package/mobile/lib/components/CreditForm/creditFormStepsData.js.map +1 -1
- package/mobile/lib/ui-kit/FormField/Fields/PartInBusinessField.js +9 -1
- package/mobile/lib/ui-kit/FormField/Fields/PartInBusinessField.js.map +1 -1
- package/mobile/lib/ui-kit/FormField/NameFieldDef.d.ts +1 -1
- package/mobile/lib/ui-kit/FormField/getField.js +2 -2
- package/mobile/lib/ui-kit/FormField/getField.js.map +1 -1
- package/mobile/lib/ui-kit/FormField/getNamesFromInput.d.ts +1 -1
- package/mobile/lib/ui-kit/FormField/getObjectValidator.js +2 -2
- package/mobile/lib/ui-kit/FormField/getObjectValidator.js.map +1 -1
- package/mobile/src/api/RetailAPI/updateUserProfile.ts +1 -1
- package/mobile/src/api/RetailAPI/utils/getUpdateUserProfile.ts +2 -2
- package/mobile/src/api/dadataHints/hintsListsOptions.ts +1 -0
- package/mobile/src/components/ApplicationForm/ApplicationFormContent.ts +1 -1
- package/mobile/src/components/ApplicationForm/getInitialFormState.tsx +1 -1
- package/mobile/src/components/ApplicationForm/renderInputs.tsx +2 -2
- package/mobile/src/components/ApplicationLeadForm/ApplicationLeadForm.example.json +1 -1
- package/mobile/src/components/ApplicationLeadForm/ApplicationLeadFormContent.ts +1 -1
- package/mobile/src/components/ApplicationLeadForm/GroupedConsents.tsx +9 -2
- package/mobile/src/components/ApplicationLeadForm/consents.ts +1 -1
- package/mobile/src/components/ApplicationLeadForm/getInitialFormState.tsx +3 -3
- package/mobile/src/components/ApplicationLeadForm/useInitApplicationLead.ts +1 -1
- package/mobile/src/components/CreditForm/CreditForm.tsx +7 -5
- package/mobile/src/components/CreditForm/CreditFormProgress.tsx +5 -5
- package/mobile/src/components/CreditForm/CreditFormStep.tsx +4 -5
- package/mobile/src/components/CreditForm/StepsNavigationButtons.tsx +3 -2
- package/mobile/src/components/CreditForm/creditFormStepsData.tsx +10 -9
- package/mobile/src/ui-kit/FormField/Fields/PartInBusinessField.tsx +25 -9
- package/mobile/src/ui-kit/FormField/NameFieldDef.ts +1 -1
- package/mobile/src/ui-kit/FormField/getField.tsx +2 -2
- package/mobile/src/ui-kit/FormField/getObjectValidator.tsx +2 -2
- package/package.json +1 -1
- package/src/api/RetailAPI/updateUserProfile.ts +1 -1
- package/src/api/RetailAPI/utils/getUpdateUserProfile.ts +2 -2
- package/src/api/dadataHints/hintsListsOptions.ts +1 -0
- package/src/components/ApplicationForm/ApplicationFormContent.ts +1 -1
- package/src/components/ApplicationForm/getInitialFormState.tsx +1 -1
- package/src/components/ApplicationForm/renderInputs.tsx +2 -2
- package/src/components/ApplicationLeadForm/ApplicationLeadForm.example.json +1 -1
- package/src/components/ApplicationLeadForm/ApplicationLeadForm.fixture.mobile.tsx +1 -1
- package/src/components/ApplicationLeadForm/ApplicationLeadForm.fixture.tsx +1 -122
- package/src/components/ApplicationLeadForm/ApplicationLeadFormContent.ts +1 -1
- package/src/components/ApplicationLeadForm/GroupedConsents.tsx +9 -2
- package/src/components/ApplicationLeadForm/consents.ts +1 -1
- package/src/components/ApplicationLeadForm/getInitialFormState.tsx +3 -3
- package/src/components/ApplicationLeadForm/useInitApplicationLead.ts +1 -1
- package/src/components/CreditForm/CreditForm.tsx +7 -5
- package/src/components/CreditForm/CreditFormProgress.tsx +5 -5
- package/src/components/CreditForm/CreditFormStep.tsx +4 -5
- package/src/components/CreditForm/StepsNavigationButtons.tsx +3 -2
- package/src/components/CreditForm/creditFormStepsData.tsx +10 -9
- package/src/icons/IconName.ts +6 -360
- package/src/ui-kit/FormField/Fields/PartInBusinessField.tsx +25 -9
- package/src/ui-kit/FormField/NameFieldDef.ts +1 -1
- package/src/ui-kit/FormField/getField.tsx +2 -2
- package/src/ui-kit/FormField/getObjectValidator.tsx +2 -2
|
@@ -1239,6 +1239,7 @@
|
|
|
1239
1239
|
organizationName: ORGANIZATION_NAME_HINTS_LIST_OPTIONS,
|
|
1240
1240
|
inn: ORGANIZATION_INN_HINTS_LIST_OPTIONS,
|
|
1241
1241
|
participantAddress: ADDRESS_HINTS_LIST_OPTIONS,
|
|
1242
|
+
fullAddress: ADDRESS_HINTS_LIST_OPTIONS,
|
|
1242
1243
|
};
|
|
1243
1244
|
|
|
1244
1245
|
const debounce = (fn, delay = 600) => {
|
|
@@ -1496,7 +1497,7 @@
|
|
|
1496
1497
|
consentDataProcessing: agreementValidator,
|
|
1497
1498
|
annualRevenue: defaultValidator(),
|
|
1498
1499
|
consentToReceiveMaterials: agreementValidator,
|
|
1499
|
-
|
|
1500
|
+
processPersonalDataFlg: agreementValidator,
|
|
1500
1501
|
consentProviderFlg: agreementValidator,
|
|
1501
1502
|
consentPfrFlg: agreementValidator,
|
|
1502
1503
|
consentOthersFlg: agreementValidator,
|
|
@@ -1526,7 +1527,7 @@
|
|
|
1526
1527
|
};
|
|
1527
1528
|
const getObjectValidator = (inputs) => {
|
|
1528
1529
|
const requiredInputs = getNamesFromInput(inputs.filter((_) => Boolean(_?.required)));
|
|
1529
|
-
return Object.fromEntries(requiredInputs.map((_) => [_, validatorObj?.[_]]));
|
|
1530
|
+
return Object.fromEntries(requiredInputs.map((_) => [_, validatorObj?.[_ || '']]));
|
|
1530
1531
|
};
|
|
1531
1532
|
|
|
1532
1533
|
const withValidator = (props, validator) => {
|
|
@@ -2088,7 +2089,7 @@
|
|
|
2088
2089
|
});
|
|
2089
2090
|
|
|
2090
2091
|
const CONSENTS = {
|
|
2091
|
-
|
|
2092
|
+
processPersonalDataFlg: {
|
|
2092
2093
|
text: 'Согласие на обработку персональных данных',
|
|
2093
2094
|
docId: 4,
|
|
2094
2095
|
},
|
|
@@ -2337,7 +2338,15 @@
|
|
|
2337
2338
|
|
|
2338
2339
|
const ParticipantDateRegistrationField = JSX(({ field, input }) => (jsx(DatePickerControl, { label: "\u0414\u0430\u0442\u0430 \u0440\u0435\u0433\u0438\u0441\u0442\u0440\u0430\u0446\u0438\u0438 \u043F\u043E \u043C\u0435\u0441\u0442\u0443 \u0436\u0438\u0442\u0435\u043B\u044C\u0441\u0442\u0432\u0430", ...getValidation(field('participantDateRegistration'), validatorObj.participantDateRegistration, input?.required) })));
|
|
2339
2340
|
|
|
2340
|
-
const
|
|
2341
|
+
const MAX_PART = 100;
|
|
2342
|
+
const PartInBusinessField = JSX(({ field, input }) => {
|
|
2343
|
+
const partInBusinessField = {
|
|
2344
|
+
...getValidation(field('partInBusiness'), validatorObj.partInBusiness, input?.required),
|
|
2345
|
+
};
|
|
2346
|
+
const handleChange = (value) => partInBusinessField?.onChange &&
|
|
2347
|
+
partInBusinessField?.onChange(String(Number(value) > MAX_PART ? MAX_PART : Number(value) || ''));
|
|
2348
|
+
return (jsx(InputControl, { label: "\u0414\u043E\u043B\u044F \u0443\u0447\u0430\u0441\u0442\u0438\u044F \u0432 \u0431\u0438\u0437\u043D\u0435\u0441\u0435", placeholder: "\u0432 %", inputLength: 3, type: "number", ...partInBusinessField, ...input, onChange: handleChange }));
|
|
2349
|
+
});
|
|
2341
2350
|
|
|
2342
2351
|
const PartnerCommentsField = JSX(({ field, input }) => {
|
|
2343
2352
|
const { required, ...rest } = input;
|
|
@@ -2524,7 +2533,7 @@
|
|
|
2524
2533
|
bankEmpolee: jsx(BankEmpoleeField, { field: field }),
|
|
2525
2534
|
secondaryPhone: jsx(SecondaryPhoneField, { field: field }),
|
|
2526
2535
|
consentToReceiveMaterials: jsx(ConsentField, { field: field, input: input }),
|
|
2527
|
-
|
|
2536
|
+
processPersonalDataFlg: jsx(ConsentField, { field: field, input: input }),
|
|
2528
2537
|
consentProviderFlg: jsx(ConsentField, { field: field, input: input }),
|
|
2529
2538
|
consentOthersFlg: jsx(ConsentField, { field: field, input: input }),
|
|
2530
2539
|
consentInformFlg: jsx(ConsentField, { field: field, input: input }),
|
|
@@ -2568,7 +2577,7 @@
|
|
|
2568
2577
|
bankEmployeeCode: jsx(BankEmpoleeCodeField, { field: field, input: input }),
|
|
2569
2578
|
partInBusiness: jsx(PartInBusinessField, { field: field, input: input }),
|
|
2570
2579
|
};
|
|
2571
|
-
return isRenderField({ input, field }) ? (jsx("div", { children: InputsMap[input?.name] }, String(i))) : null;
|
|
2580
|
+
return isRenderField({ input, field }) ? (jsx("div", { children: InputsMap[input?.name || ''] }, String(i))) : null;
|
|
2572
2581
|
};
|
|
2573
2582
|
|
|
2574
2583
|
const inputColumnStyles = (column) => column === 2 ? '@xl:grid-cols-2' : '';
|
|
@@ -2695,7 +2704,7 @@
|
|
|
2695
2704
|
const getInitialFormState$2 = (inputs, typeForm = '') => {
|
|
2696
2705
|
const formState = Object.fromEntries(inputs.map((_) => [
|
|
2697
2706
|
_.name,
|
|
2698
|
-
(_.fieldType === 'ved' && _?.defaultValue) || initialFormState$1[_.name],
|
|
2707
|
+
(_.fieldType === 'ved' && _?.defaultValue) || initialFormState$1[_.name || ''],
|
|
2699
2708
|
]));
|
|
2700
2709
|
if (formState?.serviceType && typeForm === 'PREMIUMSERVICE') {
|
|
2701
2710
|
formState.serviceType = SERVICE_TYPES[1];
|
|
@@ -2831,8 +2840,8 @@
|
|
|
2831
2840
|
return consentInputs.length > 2 ? (jsxs("div", { children: [restInputs.map(getField(field, typeForm)), jsx(GroupedConsents, { inputs: consentInputs, field: field })] })) : ((inputs || [])?.map(getField(field, typeForm)));
|
|
2832
2841
|
};
|
|
2833
2842
|
const splitInputs = (inputs) => ({
|
|
2834
|
-
consentInputs: inputs?.filter((_) => Object.keys(CONSENTS).includes(_.name)) || [],
|
|
2835
|
-
restInputs: inputs?.filter((_) => !Object.keys(CONSENTS).includes(_.name)) || [],
|
|
2843
|
+
consentInputs: inputs?.filter((_) => Object.keys(CONSENTS).includes(_.name || '')) || [],
|
|
2844
|
+
restInputs: inputs?.filter((_) => !Object.keys(CONSENTS).includes(_.name || '')) || [],
|
|
2836
2845
|
});
|
|
2837
2846
|
|
|
2838
2847
|
/* eslint-disable max-lines */
|
|
@@ -2861,7 +2870,7 @@
|
|
|
2861
2870
|
posTerminal: false,
|
|
2862
2871
|
consentToReceiveMaterials: false,
|
|
2863
2872
|
consentDataProcessing: false,
|
|
2864
|
-
|
|
2873
|
+
processPersonalDataFlg: false,
|
|
2865
2874
|
consentProviderFlg: false,
|
|
2866
2875
|
consentOthersFlg: false,
|
|
2867
2876
|
consentInformFlg: false,
|
|
@@ -2876,7 +2885,7 @@
|
|
|
2876
2885
|
}
|
|
2877
2886
|
const formState = Object.fromEntries(inputs.map((_) => [
|
|
2878
2887
|
_.name,
|
|
2879
|
-
(_.fieldType === 'ved' && _?.defaultValue) || initialFormState[_.name],
|
|
2888
|
+
(_.fieldType === 'ved' && _?.defaultValue) || initialFormState[_.name || ''],
|
|
2880
2889
|
]));
|
|
2881
2890
|
return { ...formState, typeForm: { key: typeForm, text: '' } };
|
|
2882
2891
|
};
|
|
@@ -2892,7 +2901,7 @@
|
|
|
2892
2901
|
const updateUserTask = (body) => doRequest('/user-data/updateUserTask', 'PUT', body);
|
|
2893
2902
|
|
|
2894
2903
|
const getUpdateUserProfileData = (profileId, formData) => {
|
|
2895
|
-
const { name = '', surname = '', middleName = '', birthday = '', phone = '', email = '',
|
|
2904
|
+
const { name = '', surname = '', middleName = '', birthday = '', phone = '', email = '', processPersonalDataFlg, consentProviderFlg, consentPfrFlg, consentPhotoFlg, consentAssignmentClaimsFlg, consentCollectionFlg, consentInformFlg, } = formData;
|
|
2896
2905
|
return {
|
|
2897
2906
|
profile: {
|
|
2898
2907
|
id: profileId,
|
|
@@ -2902,7 +2911,7 @@
|
|
|
2902
2911
|
birthDate: birthday && formatDate(birthday, true),
|
|
2903
2912
|
email,
|
|
2904
2913
|
phone: formatPhone(phone),
|
|
2905
|
-
|
|
2914
|
+
processPersonalDataFlg: Boolean(processPersonalDataFlg),
|
|
2906
2915
|
consentProviderFlg: Boolean(consentProviderFlg),
|
|
2907
2916
|
consentPfrFlg: Boolean(consentPfrFlg),
|
|
2908
2917
|
consentPhotoFlg: Boolean(consentPhotoFlg),
|
|
@@ -3385,7 +3394,7 @@
|
|
|
3385
3394
|
const [isLoading, setIsLoading] = useState(false);
|
|
3386
3395
|
const [profileId] = useLocalStorage('profileId');
|
|
3387
3396
|
const [, setEsiaData] = useLocalStorage('esiaData');
|
|
3388
|
-
const params = new URLSearchParams(decodeURIComponent(
|
|
3397
|
+
const params = new URLSearchParams(decodeURIComponent(globalThis.location.search));
|
|
3389
3398
|
const esiaAuth = params.get('esiaAuth');
|
|
3390
3399
|
const updateEsiaProfile = useCallback(async () => {
|
|
3391
3400
|
const code = params.get('code');
|
|
@@ -5065,9 +5074,9 @@
|
|
|
5065
5074
|
|
|
5066
5075
|
const ProgressBar = JSX(({ step = 10, description, showPercentage = true }) => (jsxs("div", { children: [jsx("div", { className: "h-4 w-full bg-gray relative", children: jsx("div", { className: "h-4 bg-green", style: { width: `${step}%` } }) }), jsxs("div", { className: "relative", children: [showPercentage ? jsxs("div", { className: "absolute left-2/4 text-green", children: [step, "%"] }) : null, description ? jsx("div", { className: "text-right mr-4 text-gray", children: description }) : null] })] })));
|
|
5067
5076
|
|
|
5068
|
-
const CreditFormProgress = JSX(({ step =
|
|
5069
|
-
const progress = useMemo(() => (step / totalSteps) * 100, [step, totalSteps]);
|
|
5070
|
-
return (jsx("div", { className: "py-lg px-5xl bg-white col-span-12", children: jsxs("div", { children: [jsxs("span", { className: "font-bold", children: ["\u0428\u0430\u0433 ", step, " \u0438\u0437 ", totalSteps, "."] }),
|
|
5077
|
+
const CreditFormProgress = JSX(({ step = 0, totalSteps = 5, stepsTitles = [] }) => {
|
|
5078
|
+
const progress = useMemo(() => ((step + 1) / totalSteps) * 100, [step, totalSteps]);
|
|
5079
|
+
return (jsx("div", { className: "py-lg px-5xl bg-white col-span-12", children: jsxs("div", { children: [jsxs("span", { className: "font-bold", children: ["\u0428\u0430\u0433 ", step + 1, " \u0438\u0437 ", totalSteps, "."] }), stepsTitles[step] || null, jsx(ProgressBar, { step: progress, showPercentage: false })] }) }));
|
|
5071
5080
|
});
|
|
5072
5081
|
|
|
5073
5082
|
const InfoCard = JSX(({ __html, icon = 'InfoCircleIcon', iconVersion = 'black', link }) => (jsxs("div", { className: "flex flex-row items-center w-full min-h-14 bg-main-gray rounded-lg gap-m p-m", children: [jsx("div", { className: "rounded-full bg-white p-xs", children: jsx(Icon, { name: icon, width: "24", height: "24", iconVersion: iconVersion }) }), jsxs("div", { className: "", children: [jsx(RichText, { __html: __html }), link?.text ? jsx(LinkButton, { className: "text-primary-main", children: link.text }) : null] })] })));
|
|
@@ -5151,7 +5160,8 @@
|
|
|
5151
5160
|
};
|
|
5152
5161
|
|
|
5153
5162
|
const StepsNavigationButtons = JSX(({ step, onPrevStep }) => {
|
|
5154
|
-
|
|
5163
|
+
const isFirstStep = step === 0;
|
|
5164
|
+
return (jsxs("div", { className: 'flex justify-between', children: [jsx(Button, { onClick: onPrevStep, className: style('w-full @xl:w-auto'), type: "button", version: "secondary", disabled: isFirstStep, children: "\u041D\u0430\u0437\u0430\u0434" }), jsx(Button, { className: style('w-full @xl:w-auto'), type: "submit", children: "\u0414\u0430\u043B\u0435\u0435" })] }));
|
|
5155
5165
|
});
|
|
5156
5166
|
|
|
5157
5167
|
const useCreditFormApi = ({ inputs, onNextStep, saveStep }) => {
|
|
@@ -5169,7 +5179,7 @@
|
|
|
5169
5179
|
};
|
|
5170
5180
|
};
|
|
5171
5181
|
|
|
5172
|
-
const CreditFormStep = JSX(({
|
|
5182
|
+
const CreditFormStep = JSX(({ step, sections, onPrevStep, onNextStep, inputs }) => {
|
|
5173
5183
|
const [localStorageData, saveStep] = useLocalStorage('leadForm');
|
|
5174
5184
|
const initialState = getInitialFormState(step, localStorageData);
|
|
5175
5185
|
const { handleSubmit } = useCreditFormApi({
|
|
@@ -5178,10 +5188,10 @@
|
|
|
5178
5188
|
saveStep,
|
|
5179
5189
|
});
|
|
5180
5190
|
const [, { field, onSubmit }] = useForm(initialState, { onSubmit: handleSubmit });
|
|
5181
|
-
return (jsxs("form", { onSubmit: onSubmit, className: "space-y-m", children: [renderStep({ sections, field }), jsx(StepsNavigationButtons, { step: step,
|
|
5191
|
+
return (jsxs("form", { onSubmit: onSubmit, className: "space-y-m", children: [renderStep({ sections, field }), jsx(StepsNavigationButtons, { step: step, onPrevStep: onPrevStep })] }));
|
|
5182
5192
|
});
|
|
5183
5193
|
const renderStep = ({ sections, field }) => {
|
|
5184
|
-
return sections
|
|
5194
|
+
return sections?.map((_, i) => (jsxs("div", { className: style(inputColumnStyles(_.columns), 'grid gap-x-m'), children: [renderInfo$1(_?.inputs), renderTitle(_?.title), renderInputs({ field, inputs: _?.inputs })] }, `section-${i}`)));
|
|
5185
5195
|
};
|
|
5186
5196
|
const renderInfo$1 = (inputs = []) => {
|
|
5187
5197
|
const infoInputs = inputs.filter((_) => _.fieldType === 'info');
|
|
@@ -5190,9 +5200,8 @@
|
|
|
5190
5200
|
|
|
5191
5201
|
/* eslint-disable max-lines */
|
|
5192
5202
|
/* eslint-disable max-len */
|
|
5193
|
-
|
|
5194
|
-
|
|
5195
|
-
1: [
|
|
5203
|
+
const stepsSectionsMap = [
|
|
5204
|
+
[
|
|
5196
5205
|
{
|
|
5197
5206
|
title: 'Персональные данные',
|
|
5198
5207
|
columns: 2,
|
|
@@ -5247,7 +5256,7 @@
|
|
|
5247
5256
|
],
|
|
5248
5257
|
},
|
|
5249
5258
|
],
|
|
5250
|
-
|
|
5259
|
+
[
|
|
5251
5260
|
{
|
|
5252
5261
|
title: 'Данные о трудоустройстве',
|
|
5253
5262
|
inputs: [],
|
|
@@ -5308,10 +5317,10 @@
|
|
|
5308
5317
|
inputs: [],
|
|
5309
5318
|
},
|
|
5310
5319
|
{
|
|
5311
|
-
inputs: [{ fieldType: 'common', name: 'fullAddress', required: true }],
|
|
5320
|
+
inputs: [{ fieldType: 'common', name: 'fullAddress', required: true, dadata: true }],
|
|
5312
5321
|
},
|
|
5313
5322
|
],
|
|
5314
|
-
|
|
5323
|
+
[
|
|
5315
5324
|
{
|
|
5316
5325
|
title: 'Семейное положение',
|
|
5317
5326
|
},
|
|
@@ -5355,7 +5364,7 @@
|
|
|
5355
5364
|
inputs: [{ fieldType: 'common', name: 'armyIdFlg' }],
|
|
5356
5365
|
},
|
|
5357
5366
|
],
|
|
5358
|
-
|
|
5367
|
+
[
|
|
5359
5368
|
{
|
|
5360
5369
|
title: 'Дополнительные сведения',
|
|
5361
5370
|
columns: 1,
|
|
@@ -5377,7 +5386,7 @@
|
|
|
5377
5386
|
inputs: [{ fieldType: 'common', name: 'creditInRshbCd' }],
|
|
5378
5387
|
},
|
|
5379
5388
|
],
|
|
5380
|
-
|
|
5389
|
+
[
|
|
5381
5390
|
{
|
|
5382
5391
|
title: 'Отделение Банка',
|
|
5383
5392
|
columns: 1,
|
|
@@ -5406,7 +5415,7 @@
|
|
|
5406
5415
|
inputs: [{ fieldType: 'common', name: 'bankEmployeeCode' }],
|
|
5407
5416
|
},
|
|
5408
5417
|
],
|
|
5409
|
-
|
|
5418
|
+
];
|
|
5410
5419
|
|
|
5411
5420
|
const STEPS_COUNT = 5;
|
|
5412
5421
|
const STEPS_TITLES = [
|
|
@@ -5417,17 +5426,17 @@
|
|
|
5417
5426
|
'Отделение Банка',
|
|
5418
5427
|
];
|
|
5419
5428
|
const CreditForm = JSX(({ className, ...rest }) => {
|
|
5420
|
-
const [step, setStep] = useState(
|
|
5429
|
+
const [step, setStep] = useState(0);
|
|
5421
5430
|
const sections = useMemo(() => stepsSectionsMap[step], [step]);
|
|
5422
5431
|
const inputs = (sections?.flatMap((_) => _?.inputs) || []);
|
|
5423
5432
|
const handleNextStep = useCallback(() => {
|
|
5424
|
-
setStep((_) => Math.min(_ + 1, STEPS_COUNT));
|
|
5433
|
+
setStep((_) => Math.min(_ + 1, STEPS_COUNT - 1));
|
|
5425
5434
|
}, []);
|
|
5426
5435
|
const handlePrevStep = useCallback(() => {
|
|
5427
5436
|
//TODO search hook - 1,
|
|
5428
5437
|
setStep((_) => Math.max(_ - 1, 0));
|
|
5429
5438
|
}, []);
|
|
5430
|
-
return (jsx(BlockWrapper, { className: style('bg-transparent', className), defaultPadding: "p-6xl", ...rest, children: jsxs("div", { className: "container grid grid-cols-12", children: [jsx(CreditFormProgress, { stepsTitles: STEPS_TITLES, step: step, totalSteps: STEPS_COUNT }), jsx("div", { className: "py-lg px-5xl mt-2xs bg-white col-span-12", children: jsx(CreditFormStep, { inputs: inputs,
|
|
5439
|
+
return (jsx(BlockWrapper, { className: style('bg-transparent', className), defaultPadding: "p-6xl", ...rest, children: jsxs("div", { className: "container grid grid-cols-12", children: [jsx(CreditFormProgress, { stepsTitles: STEPS_TITLES, step: step, totalSteps: STEPS_COUNT }), jsx("div", { className: "py-lg px-5xl mt-2xs bg-white col-span-12", children: jsx(CreditFormStep, { inputs: inputs, step: step, sections: sections, onNextStep: handleNextStep, onPrevStep: handlePrevStep }, String(step)) })] }) }));
|
|
5431
5440
|
});
|
|
5432
5441
|
|
|
5433
5442
|
const isRateRow = (rateRow) => typeof rateRow?.minMonths === 'number' && typeof rateRow?.maxMonths === 'number';
|
|
@@ -7855,7 +7864,7 @@
|
|
|
7855
7864
|
slots: () => [HEADER_SLOT, FOOTER_SLOT, STICKY_FOOTER_SLOT],
|
|
7856
7865
|
});
|
|
7857
7866
|
|
|
7858
|
-
const packageVersion = "0.14.
|
|
7867
|
+
const packageVersion = "0.14.622";
|
|
7859
7868
|
|
|
7860
7869
|
exports.Blocks = Blocks;
|
|
7861
7870
|
exports.ContentPage = ContentPage;
|