@redneckz/wildless-cms-uni-blocks 0.14.709 → 0.14.711
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/bundle.umd.js +789 -1140
- package/bundle/bundle.umd.min.js +1 -1
- package/bundle/components/ApplicationLeadForm/useSaveUserData.d.ts +1 -1
- package/bundle/components/CreditCardForm/CreditCardFormStep.d.ts +2 -2
- package/bundle/components/CreditCardForm/{getSixthStepData.d.ts → getDeliveryCreditCardData.d.ts} +1 -1
- package/bundle/components/CreditCardForm/getInitialFormState.d.ts +1 -1
- package/bundle/components/CreditCardForm/useCreditCardFormAPI.d.ts +4 -17
- package/bundle/components/CreditForm/CreditFormStep.d.ts +3 -3
- package/bundle/components/CreditForm/getInitialFormState.d.ts +1 -1
- package/bundle/components/CreditForm/useCreditFormAPI.d.ts +4 -17
- package/bundle/hooks/useRetailFormStore.d.ts +33 -0
- package/bundle/services/retail/adaptors/getAdditionalInfoData.d.ts +3 -0
- package/bundle/services/retail/adaptors/getCalculatorData.d.ts +3 -0
- package/bundle/services/retail/adaptors/getCardOptionsData.d.ts +3 -0
- package/{dist/components/CreditForm → bundle/services/retail/adaptors}/getCreditFormTaskData.d.ts +2 -2
- package/bundle/services/retail/adaptors/getDeliveryCreditData.d.ts +3 -0
- package/bundle/services/retail/adaptors/getEmploymentData.d.ts +3 -0
- package/bundle/services/retail/adaptors/getFamilyStatusAndIncomeData.d.ts +3 -0
- package/bundle/services/retail/adaptors/getPersonalInfoData.d.ts +3 -0
- package/bundle/services/retail/content.d.ts +6 -0
- package/bundle/ui-kit/FormField/updateOrganizationFields.d.ts +2 -2
- package/dist/components/ApplicationLeadForm/useSaveUserData.d.ts +1 -1
- package/dist/components/ApplicationLeadForm/useSaveUserData.js +2 -4
- package/dist/components/ApplicationLeadForm/useSaveUserData.js.map +1 -1
- package/dist/components/CreditCardForm/CreditCardForm.js +3 -2
- package/dist/components/CreditCardForm/CreditCardForm.js.map +1 -1
- package/dist/components/CreditCardForm/CreditCardFormStatusTracker.js +2 -2
- package/dist/components/CreditCardForm/CreditCardFormStatusTracker.js.map +1 -1
- package/dist/components/CreditCardForm/CreditCardFormStep.d.ts +2 -2
- package/dist/components/CreditCardForm/CreditCardFormStep.js +7 -13
- package/dist/components/CreditCardForm/CreditCardFormStep.js.map +1 -1
- package/dist/components/CreditCardForm/PendingStatusContent.js +2 -2
- package/dist/components/CreditCardForm/PendingStatusContent.js.map +1 -1
- package/dist/components/CreditCardForm/ReworkStatusContent.js +2 -2
- package/dist/components/CreditCardForm/ReworkStatusContent.js.map +1 -1
- package/dist/components/CreditCardForm/SuccessStatusContent.js +2 -2
- package/dist/components/CreditCardForm/SuccessStatusContent.js.map +1 -1
- package/dist/components/CreditCardForm/creditCardFormStepsData.js +4 -346
- package/dist/components/CreditCardForm/creditCardFormStepsData.js.map +1 -1
- package/dist/components/CreditCardForm/formStateMap.js +1 -4
- package/dist/components/CreditCardForm/formStateMap.js.map +1 -1
- package/dist/components/CreditCardForm/getCreditCardFormTaskData.js +14 -14
- package/dist/components/CreditCardForm/getCreditCardFormTaskData.js.map +1 -1
- package/{lib/components/CreditCardForm/getSixthStepData.d.ts → dist/components/CreditCardForm/getDeliveryCreditCardData.d.ts} +1 -1
- package/{mobile/dist/components/CreditCardForm/getSixthStepData.js → dist/components/CreditCardForm/getDeliveryCreditCardData.js} +4 -4
- package/dist/components/CreditCardForm/getDeliveryCreditCardData.js.map +1 -0
- package/dist/components/CreditCardForm/getInitialFormState.d.ts +1 -1
- package/dist/components/CreditCardForm/getInitialFormState.js +8 -11
- package/dist/components/CreditCardForm/getInitialFormState.js.map +1 -1
- package/dist/components/CreditCardForm/useCreditCardFormAPI.d.ts +4 -17
- package/dist/components/CreditCardForm/useCreditCardFormAPI.js +32 -34
- package/dist/components/CreditCardForm/useCreditCardFormAPI.js.map +1 -1
- package/dist/components/CreditForm/CreditForm.js +3 -2
- package/dist/components/CreditForm/CreditForm.js.map +1 -1
- package/dist/components/CreditForm/CreditFormStatusTracker.js +2 -2
- package/dist/components/CreditForm/CreditFormStatusTracker.js.map +1 -1
- package/dist/components/CreditForm/CreditFormStep.d.ts +3 -3
- package/dist/components/CreditForm/CreditFormStep.js +9 -14
- package/dist/components/CreditForm/CreditFormStep.js.map +1 -1
- package/dist/components/CreditForm/PendingStatusContent.js +2 -2
- package/dist/components/CreditForm/PendingStatusContent.js.map +1 -1
- package/dist/components/CreditForm/ReworkStatusContent.js +2 -2
- package/dist/components/CreditForm/ReworkStatusContent.js.map +1 -1
- package/dist/components/CreditForm/SuccessStatusContent.js +2 -2
- package/dist/components/CreditForm/SuccessStatusContent.js.map +1 -1
- package/dist/components/CreditForm/creditFormStepsData.js +4 -279
- package/dist/components/CreditForm/creditFormStepsData.js.map +1 -1
- package/dist/components/CreditForm/getInitialFormState.d.ts +1 -1
- package/dist/components/CreditForm/getInitialFormState.js +8 -11
- package/dist/components/CreditForm/getInitialFormState.js.map +1 -1
- package/dist/components/CreditForm/useCreditFormAPI.d.ts +4 -17
- package/dist/components/CreditForm/useCreditFormAPI.js +33 -40
- package/dist/components/CreditForm/useCreditFormAPI.js.map +1 -1
- package/dist/hooks/useRetailFormStore.d.ts +33 -0
- package/dist/hooks/{useCreditFormStore.js → useRetailFormStore.js} +4 -4
- package/dist/hooks/useRetailFormStore.js.map +1 -0
- package/dist/services/retail/adaptors/getAdditionalInfoData.d.ts +3 -0
- package/{mobile/dist/components/CreditCardForm/getFifthStepData.js → dist/services/retail/adaptors/getAdditionalInfoData.js} +4 -4
- package/dist/services/retail/adaptors/getAdditionalInfoData.js.map +1 -0
- package/dist/services/retail/adaptors/getCalculatorData.d.ts +3 -0
- package/{mobile/dist/components/CreditForm/getZeroStepData.js → dist/services/retail/adaptors/getCalculatorData.js} +4 -4
- package/dist/services/retail/adaptors/getCalculatorData.js.map +1 -0
- package/dist/services/retail/adaptors/getCardOptionsData.d.ts +3 -0
- package/{mobile/dist/components/CreditCardForm/getCardData.js → dist/services/retail/adaptors/getCardOptionsData.js} +4 -4
- package/dist/services/retail/adaptors/getCardOptionsData.js.map +1 -0
- package/{bundle/components/CreditForm → dist/services/retail/adaptors}/getCreditFormTaskData.d.ts +2 -2
- package/{mobile/dist/components/CreditForm → dist/services/retail/adaptors}/getCreditFormTaskData.js +14 -14
- package/dist/services/retail/adaptors/getCreditFormTaskData.js.map +1 -0
- package/dist/services/retail/adaptors/getDeliveryCreditData.d.ts +3 -0
- package/dist/{components/CreditForm/getFifthStepData.js → services/retail/adaptors/getDeliveryCreditData.js} +4 -4
- package/dist/services/retail/adaptors/getDeliveryCreditData.js.map +1 -0
- package/dist/services/retail/adaptors/getEmploymentData.d.ts +3 -0
- package/dist/{components/CreditForm/getSecondStepData.js → services/retail/adaptors/getEmploymentData.js} +7 -7
- package/dist/services/retail/adaptors/getEmploymentData.js.map +1 -0
- package/dist/services/retail/adaptors/getFamilyStatusAndIncomeData.d.ts +3 -0
- package/{mobile/dist/components/CreditCardForm/getFourthStepData.js → dist/services/retail/adaptors/getFamilyStatusAndIncomeData.js} +5 -5
- package/dist/services/retail/adaptors/getFamilyStatusAndIncomeData.js.map +1 -0
- package/dist/services/retail/adaptors/getPersonalInfoData.d.ts +3 -0
- package/{mobile/dist/components/CreditCardForm/getSecondStepData.js → dist/services/retail/adaptors/getPersonalInfoData.js} +7 -7
- package/dist/services/retail/adaptors/getPersonalInfoData.js.map +1 -0
- package/dist/services/retail/content.d.ts +6 -0
- package/dist/services/retail/content.js +389 -0
- package/dist/services/retail/content.js.map +1 -0
- package/dist/ui-kit/DraftDialog/DraftDialog.js +7 -9
- package/dist/ui-kit/DraftDialog/DraftDialog.js.map +1 -1
- package/dist/ui-kit/EsiaLoginDialog/EsiaLoginDialog.js +6 -6
- package/dist/ui-kit/EsiaLoginDialog/EsiaLoginDialog.js.map +1 -1
- package/dist/ui-kit/FormField/Fields/AmountWorkersField.js +2 -2
- package/dist/ui-kit/FormField/Fields/AmountWorkersField.js.map +1 -1
- package/dist/ui-kit/FormField/Fields/EmployerActivitiesField.js +2 -2
- package/dist/ui-kit/FormField/Fields/EmployerActivitiesField.js.map +1 -1
- package/dist/ui-kit/FormField/Fields/EmployerOrganizationField.js +2 -2
- package/dist/ui-kit/FormField/Fields/EmployerOrganizationField.js.map +1 -1
- package/dist/ui-kit/FormField/Fields/InnField.js +2 -2
- package/dist/ui-kit/FormField/Fields/OrganizationField.js +2 -2
- package/dist/ui-kit/FormField/Fields/OrganizationField.js.map +1 -1
- package/dist/ui-kit/FormField/Fields/OrganizationNameField.js +2 -2
- package/dist/ui-kit/FormField/updateOrganizationFields.d.ts +2 -2
- package/dist/ui-kit/FormField/updateOrganizationFields.js.map +1 -1
- package/lib/components/ApplicationLeadForm/useSaveUserData.d.ts +1 -1
- package/lib/components/ApplicationLeadForm/useSaveUserData.js +2 -4
- package/lib/components/ApplicationLeadForm/useSaveUserData.js.map +1 -1
- package/lib/components/CreditCardForm/CreditCardForm.js +3 -2
- package/lib/components/CreditCardForm/CreditCardForm.js.map +1 -1
- package/lib/components/CreditCardForm/CreditCardFormStatusTracker.js +2 -2
- package/lib/components/CreditCardForm/CreditCardFormStatusTracker.js.map +1 -1
- package/lib/components/CreditCardForm/CreditCardFormStep.d.ts +2 -2
- package/lib/components/CreditCardForm/CreditCardFormStep.js +7 -13
- package/lib/components/CreditCardForm/CreditCardFormStep.js.map +1 -1
- package/lib/components/CreditCardForm/PendingStatusContent.js +2 -2
- package/lib/components/CreditCardForm/PendingStatusContent.js.map +1 -1
- package/lib/components/CreditCardForm/ReworkStatusContent.js +2 -2
- package/lib/components/CreditCardForm/ReworkStatusContent.js.map +1 -1
- package/lib/components/CreditCardForm/SuccessStatusContent.js +2 -2
- package/lib/components/CreditCardForm/SuccessStatusContent.js.map +1 -1
- package/lib/components/CreditCardForm/creditCardFormStepsData.js +4 -346
- package/lib/components/CreditCardForm/creditCardFormStepsData.js.map +1 -1
- package/lib/components/CreditCardForm/formStateMap.js +1 -4
- package/lib/components/CreditCardForm/formStateMap.js.map +1 -1
- package/lib/components/CreditCardForm/getCreditCardFormTaskData.js +12 -12
- package/lib/components/CreditCardForm/getCreditCardFormTaskData.js.map +1 -1
- package/{dist/components/CreditCardForm/getSixthStepData.d.ts → lib/components/CreditCardForm/getDeliveryCreditCardData.d.ts} +1 -1
- package/lib/components/CreditCardForm/{getSixthStepData.js → getDeliveryCreditCardData.js} +2 -2
- package/lib/components/CreditCardForm/getDeliveryCreditCardData.js.map +1 -0
- package/lib/components/CreditCardForm/getInitialFormState.d.ts +1 -1
- package/lib/components/CreditCardForm/getInitialFormState.js +8 -11
- package/lib/components/CreditCardForm/getInitialFormState.js.map +1 -1
- package/lib/components/CreditCardForm/useCreditCardFormAPI.d.ts +4 -17
- package/lib/components/CreditCardForm/useCreditCardFormAPI.js +33 -35
- package/lib/components/CreditCardForm/useCreditCardFormAPI.js.map +1 -1
- package/lib/components/CreditForm/CreditForm.js +3 -2
- package/lib/components/CreditForm/CreditForm.js.map +1 -1
- package/lib/components/CreditForm/CreditFormStatusTracker.js +2 -2
- package/lib/components/CreditForm/CreditFormStatusTracker.js.map +1 -1
- package/lib/components/CreditForm/CreditFormStep.d.ts +3 -3
- package/lib/components/CreditForm/CreditFormStep.js +9 -14
- package/lib/components/CreditForm/CreditFormStep.js.map +1 -1
- package/lib/components/CreditForm/PendingStatusContent.js +2 -2
- package/lib/components/CreditForm/PendingStatusContent.js.map +1 -1
- package/lib/components/CreditForm/ReworkStatusContent.js +2 -2
- package/lib/components/CreditForm/ReworkStatusContent.js.map +1 -1
- package/lib/components/CreditForm/SuccessStatusContent.js +2 -2
- package/lib/components/CreditForm/SuccessStatusContent.js.map +1 -1
- package/lib/components/CreditForm/creditFormStepsData.js +4 -279
- package/lib/components/CreditForm/creditFormStepsData.js.map +1 -1
- package/lib/components/CreditForm/getInitialFormState.d.ts +1 -1
- package/lib/components/CreditForm/getInitialFormState.js +8 -11
- package/lib/components/CreditForm/getInitialFormState.js.map +1 -1
- package/lib/components/CreditForm/useCreditFormAPI.d.ts +4 -17
- package/lib/components/CreditForm/useCreditFormAPI.js +34 -41
- package/lib/components/CreditForm/useCreditFormAPI.js.map +1 -1
- package/lib/hooks/useRetailFormStore.d.ts +33 -0
- package/lib/hooks/{useCreditFormStore.js → useRetailFormStore.js} +2 -2
- package/lib/hooks/useRetailFormStore.js.map +1 -0
- package/lib/services/retail/adaptors/getAdditionalInfoData.d.ts +3 -0
- package/lib/{components/CreditCardForm/getFifthStepData.js → services/retail/adaptors/getAdditionalInfoData.js} +2 -2
- package/lib/services/retail/adaptors/getAdditionalInfoData.js.map +1 -0
- package/lib/services/retail/adaptors/getCalculatorData.d.ts +3 -0
- package/{mobile/lib/components/CreditForm/getZeroStepData.js → lib/services/retail/adaptors/getCalculatorData.js} +2 -2
- package/lib/services/retail/adaptors/getCalculatorData.js.map +1 -0
- package/lib/services/retail/adaptors/getCardOptionsData.d.ts +3 -0
- package/{mobile/lib/components/CreditCardForm/getCardData.js → lib/services/retail/adaptors/getCardOptionsData.js} +2 -2
- package/lib/services/retail/adaptors/getCardOptionsData.js.map +1 -0
- package/lib/{components/CreditForm → services/retail/adaptors}/getCreditFormTaskData.d.ts +2 -2
- package/lib/{components/CreditForm → services/retail/adaptors}/getCreditFormTaskData.js +14 -14
- package/lib/services/retail/adaptors/getCreditFormTaskData.js.map +1 -0
- package/lib/services/retail/adaptors/getDeliveryCreditData.d.ts +3 -0
- package/lib/{components/CreditForm/getFifthStepData.js → services/retail/adaptors/getDeliveryCreditData.js} +2 -2
- package/lib/services/retail/adaptors/getDeliveryCreditData.js.map +1 -0
- package/lib/services/retail/adaptors/getEmploymentData.d.ts +3 -0
- package/lib/{components/CreditForm/getSecondStepData.js → services/retail/adaptors/getEmploymentData.js} +5 -5
- package/lib/services/retail/adaptors/getEmploymentData.js.map +1 -0
- package/lib/services/retail/adaptors/getFamilyStatusAndIncomeData.d.ts +3 -0
- package/{mobile/lib/components/CreditCardForm/getFourthStepData.js → lib/services/retail/adaptors/getFamilyStatusAndIncomeData.js} +3 -3
- package/lib/services/retail/adaptors/getFamilyStatusAndIncomeData.js.map +1 -0
- package/lib/services/retail/adaptors/getPersonalInfoData.d.ts +3 -0
- package/lib/{components/CreditCardForm/getSecondStepData.js → services/retail/adaptors/getPersonalInfoData.js} +5 -5
- package/lib/services/retail/adaptors/getPersonalInfoData.js.map +1 -0
- package/lib/services/retail/content.d.ts +6 -0
- package/lib/services/retail/content.js +387 -0
- package/lib/services/retail/content.js.map +1 -0
- package/lib/ui-kit/DraftDialog/DraftDialog.js +7 -9
- package/lib/ui-kit/DraftDialog/DraftDialog.js.map +1 -1
- package/lib/ui-kit/EsiaLoginDialog/EsiaLoginDialog.js +6 -6
- package/lib/ui-kit/EsiaLoginDialog/EsiaLoginDialog.js.map +1 -1
- package/lib/ui-kit/FormField/Fields/AmountWorkersField.js +2 -2
- package/lib/ui-kit/FormField/Fields/AmountWorkersField.js.map +1 -1
- package/lib/ui-kit/FormField/Fields/EmployerActivitiesField.js +2 -2
- package/lib/ui-kit/FormField/Fields/EmployerActivitiesField.js.map +1 -1
- package/lib/ui-kit/FormField/Fields/EmployerOrganizationField.js +2 -2
- package/lib/ui-kit/FormField/Fields/EmployerOrganizationField.js.map +1 -1
- package/lib/ui-kit/FormField/Fields/InnField.js +2 -2
- package/lib/ui-kit/FormField/Fields/OrganizationField.js +2 -2
- package/lib/ui-kit/FormField/Fields/OrganizationField.js.map +1 -1
- package/lib/ui-kit/FormField/Fields/OrganizationNameField.js +2 -2
- package/lib/ui-kit/FormField/updateOrganizationFields.d.ts +2 -2
- package/lib/ui-kit/FormField/updateOrganizationFields.js.map +1 -1
- package/mobile/bundle/bundle.umd.js +789 -1140
- package/mobile/bundle/bundle.umd.min.js +1 -1
- package/mobile/bundle/components/ApplicationLeadForm/useSaveUserData.d.ts +1 -1
- package/mobile/bundle/components/CreditCardForm/CreditCardFormStep.d.ts +2 -2
- package/mobile/bundle/components/CreditCardForm/{getSixthStepData.d.ts → getDeliveryCreditCardData.d.ts} +1 -1
- package/mobile/bundle/components/CreditCardForm/getInitialFormState.d.ts +1 -1
- package/mobile/bundle/components/CreditCardForm/useCreditCardFormAPI.d.ts +4 -17
- package/mobile/bundle/components/CreditForm/CreditFormStep.d.ts +3 -3
- package/mobile/bundle/components/CreditForm/getInitialFormState.d.ts +1 -1
- package/mobile/bundle/components/CreditForm/useCreditFormAPI.d.ts +4 -17
- package/mobile/bundle/hooks/useRetailFormStore.d.ts +33 -0
- package/mobile/bundle/services/retail/adaptors/getAdditionalInfoData.d.ts +3 -0
- package/mobile/bundle/services/retail/adaptors/getCalculatorData.d.ts +3 -0
- package/mobile/bundle/services/retail/adaptors/getCardOptionsData.d.ts +3 -0
- package/mobile/bundle/{components/CreditForm → services/retail/adaptors}/getCreditFormTaskData.d.ts +2 -2
- package/mobile/bundle/services/retail/adaptors/getDeliveryCreditData.d.ts +3 -0
- package/mobile/bundle/services/retail/adaptors/getEmploymentData.d.ts +3 -0
- package/mobile/bundle/services/retail/adaptors/getFamilyStatusAndIncomeData.d.ts +3 -0
- package/mobile/bundle/services/retail/adaptors/getPersonalInfoData.d.ts +3 -0
- package/mobile/bundle/services/retail/content.d.ts +6 -0
- package/mobile/bundle/ui-kit/FormField/updateOrganizationFields.d.ts +2 -2
- package/mobile/dist/components/ApplicationLeadForm/useSaveUserData.d.ts +1 -1
- package/mobile/dist/components/ApplicationLeadForm/useSaveUserData.js +2 -4
- package/mobile/dist/components/ApplicationLeadForm/useSaveUserData.js.map +1 -1
- package/mobile/dist/components/CreditCardForm/CreditCardForm.js +3 -2
- package/mobile/dist/components/CreditCardForm/CreditCardForm.js.map +1 -1
- package/mobile/dist/components/CreditCardForm/CreditCardFormStatusTracker.js +2 -2
- package/mobile/dist/components/CreditCardForm/CreditCardFormStatusTracker.js.map +1 -1
- package/mobile/dist/components/CreditCardForm/CreditCardFormStep.d.ts +2 -2
- package/mobile/dist/components/CreditCardForm/CreditCardFormStep.js +7 -13
- package/mobile/dist/components/CreditCardForm/CreditCardFormStep.js.map +1 -1
- package/mobile/dist/components/CreditCardForm/PendingStatusContent.js +2 -2
- package/mobile/dist/components/CreditCardForm/PendingStatusContent.js.map +1 -1
- package/mobile/dist/components/CreditCardForm/ReworkStatusContent.js +2 -2
- package/mobile/dist/components/CreditCardForm/ReworkStatusContent.js.map +1 -1
- package/mobile/dist/components/CreditCardForm/SuccessStatusContent.js +2 -2
- package/mobile/dist/components/CreditCardForm/SuccessStatusContent.js.map +1 -1
- package/mobile/dist/components/CreditCardForm/creditCardFormStepsData.js +4 -346
- package/mobile/dist/components/CreditCardForm/creditCardFormStepsData.js.map +1 -1
- package/mobile/dist/components/CreditCardForm/formStateMap.js +1 -4
- package/mobile/dist/components/CreditCardForm/formStateMap.js.map +1 -1
- package/mobile/dist/components/CreditCardForm/getCreditCardFormTaskData.js +14 -14
- package/mobile/dist/components/CreditCardForm/getCreditCardFormTaskData.js.map +1 -1
- package/mobile/dist/components/CreditCardForm/getDeliveryCreditCardData.d.ts +24 -0
- package/{dist/components/CreditCardForm/getSixthStepData.js → mobile/dist/components/CreditCardForm/getDeliveryCreditCardData.js} +4 -4
- package/mobile/dist/components/CreditCardForm/getDeliveryCreditCardData.js.map +1 -0
- package/mobile/dist/components/CreditCardForm/getInitialFormState.d.ts +1 -1
- package/mobile/dist/components/CreditCardForm/getInitialFormState.js +8 -11
- package/mobile/dist/components/CreditCardForm/getInitialFormState.js.map +1 -1
- package/mobile/dist/components/CreditCardForm/useCreditCardFormAPI.d.ts +4 -17
- package/mobile/dist/components/CreditCardForm/useCreditCardFormAPI.js +32 -34
- package/mobile/dist/components/CreditCardForm/useCreditCardFormAPI.js.map +1 -1
- package/mobile/dist/components/CreditForm/CreditForm.js +3 -2
- package/mobile/dist/components/CreditForm/CreditForm.js.map +1 -1
- package/mobile/dist/components/CreditForm/CreditFormStatusTracker.js +2 -2
- package/mobile/dist/components/CreditForm/CreditFormStatusTracker.js.map +1 -1
- package/mobile/dist/components/CreditForm/CreditFormStep.d.ts +3 -3
- package/mobile/dist/components/CreditForm/CreditFormStep.js +9 -14
- package/mobile/dist/components/CreditForm/CreditFormStep.js.map +1 -1
- package/mobile/dist/components/CreditForm/PendingStatusContent.js +2 -2
- package/mobile/dist/components/CreditForm/PendingStatusContent.js.map +1 -1
- package/mobile/dist/components/CreditForm/ReworkStatusContent.js +2 -2
- package/mobile/dist/components/CreditForm/ReworkStatusContent.js.map +1 -1
- package/mobile/dist/components/CreditForm/SuccessStatusContent.js +2 -2
- package/mobile/dist/components/CreditForm/SuccessStatusContent.js.map +1 -1
- package/mobile/dist/components/CreditForm/creditFormStepsData.js +4 -279
- package/mobile/dist/components/CreditForm/creditFormStepsData.js.map +1 -1
- package/mobile/dist/components/CreditForm/getInitialFormState.d.ts +1 -1
- package/mobile/dist/components/CreditForm/getInitialFormState.js +8 -11
- package/mobile/dist/components/CreditForm/getInitialFormState.js.map +1 -1
- package/mobile/dist/components/CreditForm/useCreditFormAPI.d.ts +4 -17
- package/mobile/dist/components/CreditForm/useCreditFormAPI.js +33 -40
- package/mobile/dist/components/CreditForm/useCreditFormAPI.js.map +1 -1
- package/mobile/dist/hooks/useRetailFormStore.d.ts +33 -0
- package/mobile/dist/hooks/{useCreditFormStore.js → useRetailFormStore.js} +4 -4
- package/mobile/dist/hooks/useRetailFormStore.js.map +1 -0
- package/mobile/dist/services/retail/adaptors/getAdditionalInfoData.d.ts +3 -0
- package/{dist/components/CreditForm/getFourthStepData.js → mobile/dist/services/retail/adaptors/getAdditionalInfoData.js} +4 -4
- package/mobile/dist/services/retail/adaptors/getAdditionalInfoData.js.map +1 -0
- package/mobile/dist/services/retail/adaptors/getCalculatorData.d.ts +3 -0
- package/{dist/components/CreditForm/getZeroStepData.js → mobile/dist/services/retail/adaptors/getCalculatorData.js} +4 -4
- package/mobile/dist/services/retail/adaptors/getCalculatorData.js.map +1 -0
- package/mobile/dist/services/retail/adaptors/getCardOptionsData.d.ts +3 -0
- package/{dist/components/CreditCardForm/getCardData.js → mobile/dist/services/retail/adaptors/getCardOptionsData.js} +4 -4
- package/mobile/dist/services/retail/adaptors/getCardOptionsData.js.map +1 -0
- package/mobile/dist/services/retail/adaptors/getCreditFormTaskData.d.ts +11 -0
- package/{dist/components/CreditForm → mobile/dist/services/retail/adaptors}/getCreditFormTaskData.js +14 -14
- package/mobile/dist/services/retail/adaptors/getCreditFormTaskData.js.map +1 -0
- package/mobile/dist/services/retail/adaptors/getDeliveryCreditData.d.ts +3 -0
- package/mobile/dist/{components/CreditForm/getFifthStepData.js → services/retail/adaptors/getDeliveryCreditData.js} +4 -4
- package/mobile/dist/services/retail/adaptors/getDeliveryCreditData.js.map +1 -0
- package/mobile/dist/services/retail/adaptors/getEmploymentData.d.ts +3 -0
- package/mobile/dist/{components/CreditCardForm/getThirdStepData.js → services/retail/adaptors/getEmploymentData.js} +7 -7
- package/mobile/dist/services/retail/adaptors/getEmploymentData.js.map +1 -0
- package/mobile/dist/services/retail/adaptors/getFamilyStatusAndIncomeData.d.ts +3 -0
- package/{dist/components/CreditCardForm/getFourthStepData.js → mobile/dist/services/retail/adaptors/getFamilyStatusAndIncomeData.js} +5 -5
- package/mobile/dist/services/retail/adaptors/getFamilyStatusAndIncomeData.js.map +1 -0
- package/mobile/dist/services/retail/adaptors/getPersonalInfoData.d.ts +3 -0
- package/{dist/components/CreditCardForm/getSecondStepData.js → mobile/dist/services/retail/adaptors/getPersonalInfoData.js} +7 -7
- package/mobile/dist/services/retail/adaptors/getPersonalInfoData.js.map +1 -0
- package/mobile/dist/services/retail/content.d.ts +6 -0
- package/mobile/dist/services/retail/content.js +389 -0
- package/mobile/dist/services/retail/content.js.map +1 -0
- package/mobile/dist/ui-kit/DraftDialog/DraftDialog.js +7 -9
- package/mobile/dist/ui-kit/DraftDialog/DraftDialog.js.map +1 -1
- package/mobile/dist/ui-kit/EsiaLoginDialog/EsiaLoginDialog.js +6 -6
- package/mobile/dist/ui-kit/EsiaLoginDialog/EsiaLoginDialog.js.map +1 -1
- package/mobile/dist/ui-kit/FormField/Fields/AmountWorkersField.js +2 -2
- package/mobile/dist/ui-kit/FormField/Fields/AmountWorkersField.js.map +1 -1
- package/mobile/dist/ui-kit/FormField/Fields/EmployerActivitiesField.js +2 -2
- package/mobile/dist/ui-kit/FormField/Fields/EmployerActivitiesField.js.map +1 -1
- package/mobile/dist/ui-kit/FormField/Fields/EmployerOrganizationField.js +2 -2
- package/mobile/dist/ui-kit/FormField/Fields/EmployerOrganizationField.js.map +1 -1
- package/mobile/dist/ui-kit/FormField/Fields/InnField.js +2 -2
- package/mobile/dist/ui-kit/FormField/Fields/OrganizationField.js +2 -2
- package/mobile/dist/ui-kit/FormField/Fields/OrganizationField.js.map +1 -1
- package/mobile/dist/ui-kit/FormField/Fields/OrganizationNameField.js +2 -2
- package/mobile/dist/ui-kit/FormField/updateOrganizationFields.d.ts +2 -2
- package/mobile/dist/ui-kit/FormField/updateOrganizationFields.js.map +1 -1
- package/mobile/lib/components/ApplicationLeadForm/useSaveUserData.d.ts +1 -1
- package/mobile/lib/components/ApplicationLeadForm/useSaveUserData.js +2 -4
- package/mobile/lib/components/ApplicationLeadForm/useSaveUserData.js.map +1 -1
- package/mobile/lib/components/CreditCardForm/CreditCardForm.js +3 -2
- package/mobile/lib/components/CreditCardForm/CreditCardForm.js.map +1 -1
- package/mobile/lib/components/CreditCardForm/CreditCardFormStatusTracker.js +2 -2
- package/mobile/lib/components/CreditCardForm/CreditCardFormStatusTracker.js.map +1 -1
- package/mobile/lib/components/CreditCardForm/CreditCardFormStep.d.ts +2 -2
- package/mobile/lib/components/CreditCardForm/CreditCardFormStep.js +7 -13
- package/mobile/lib/components/CreditCardForm/CreditCardFormStep.js.map +1 -1
- package/mobile/lib/components/CreditCardForm/PendingStatusContent.js +2 -2
- package/mobile/lib/components/CreditCardForm/PendingStatusContent.js.map +1 -1
- package/mobile/lib/components/CreditCardForm/ReworkStatusContent.js +2 -2
- package/mobile/lib/components/CreditCardForm/ReworkStatusContent.js.map +1 -1
- package/mobile/lib/components/CreditCardForm/SuccessStatusContent.js +2 -2
- package/mobile/lib/components/CreditCardForm/SuccessStatusContent.js.map +1 -1
- package/mobile/lib/components/CreditCardForm/creditCardFormStepsData.js +4 -346
- package/mobile/lib/components/CreditCardForm/creditCardFormStepsData.js.map +1 -1
- package/mobile/lib/components/CreditCardForm/formStateMap.js +1 -4
- package/mobile/lib/components/CreditCardForm/formStateMap.js.map +1 -1
- package/mobile/lib/components/CreditCardForm/getCreditCardFormTaskData.js +12 -12
- package/mobile/lib/components/CreditCardForm/getCreditCardFormTaskData.js.map +1 -1
- package/mobile/lib/components/CreditCardForm/getDeliveryCreditCardData.d.ts +24 -0
- package/mobile/lib/components/CreditCardForm/{getSixthStepData.js → getDeliveryCreditCardData.js} +2 -2
- package/mobile/lib/components/CreditCardForm/getDeliveryCreditCardData.js.map +1 -0
- package/mobile/lib/components/CreditCardForm/getInitialFormState.d.ts +1 -1
- package/mobile/lib/components/CreditCardForm/getInitialFormState.js +8 -11
- package/mobile/lib/components/CreditCardForm/getInitialFormState.js.map +1 -1
- package/mobile/lib/components/CreditCardForm/useCreditCardFormAPI.d.ts +4 -17
- package/mobile/lib/components/CreditCardForm/useCreditCardFormAPI.js +33 -35
- package/mobile/lib/components/CreditCardForm/useCreditCardFormAPI.js.map +1 -1
- package/mobile/lib/components/CreditForm/CreditForm.js +3 -2
- package/mobile/lib/components/CreditForm/CreditForm.js.map +1 -1
- package/mobile/lib/components/CreditForm/CreditFormStatusTracker.js +2 -2
- package/mobile/lib/components/CreditForm/CreditFormStatusTracker.js.map +1 -1
- package/mobile/lib/components/CreditForm/CreditFormStep.d.ts +3 -3
- package/mobile/lib/components/CreditForm/CreditFormStep.js +9 -14
- package/mobile/lib/components/CreditForm/CreditFormStep.js.map +1 -1
- package/mobile/lib/components/CreditForm/PendingStatusContent.js +2 -2
- package/mobile/lib/components/CreditForm/PendingStatusContent.js.map +1 -1
- package/mobile/lib/components/CreditForm/ReworkStatusContent.js +2 -2
- package/mobile/lib/components/CreditForm/ReworkStatusContent.js.map +1 -1
- package/mobile/lib/components/CreditForm/SuccessStatusContent.js +2 -2
- package/mobile/lib/components/CreditForm/SuccessStatusContent.js.map +1 -1
- package/mobile/lib/components/CreditForm/creditFormStepsData.js +4 -279
- package/mobile/lib/components/CreditForm/creditFormStepsData.js.map +1 -1
- package/mobile/lib/components/CreditForm/getInitialFormState.d.ts +1 -1
- package/mobile/lib/components/CreditForm/getInitialFormState.js +8 -11
- package/mobile/lib/components/CreditForm/getInitialFormState.js.map +1 -1
- package/mobile/lib/components/CreditForm/useCreditFormAPI.d.ts +4 -17
- package/mobile/lib/components/CreditForm/useCreditFormAPI.js +34 -41
- package/mobile/lib/components/CreditForm/useCreditFormAPI.js.map +1 -1
- package/mobile/lib/hooks/useRetailFormStore.d.ts +33 -0
- package/mobile/lib/hooks/{useCreditFormStore.js → useRetailFormStore.js} +2 -2
- package/mobile/lib/hooks/useRetailFormStore.js.map +1 -0
- package/mobile/lib/services/retail/adaptors/getAdditionalInfoData.d.ts +3 -0
- package/mobile/lib/{components/CreditCardForm/getFifthStepData.js → services/retail/adaptors/getAdditionalInfoData.js} +2 -2
- package/mobile/lib/services/retail/adaptors/getAdditionalInfoData.js.map +1 -0
- package/mobile/lib/services/retail/adaptors/getCalculatorData.d.ts +3 -0
- package/{lib/components/CreditForm/getZeroStepData.js → mobile/lib/services/retail/adaptors/getCalculatorData.js} +2 -2
- package/mobile/lib/services/retail/adaptors/getCalculatorData.js.map +1 -0
- package/mobile/lib/services/retail/adaptors/getCardOptionsData.d.ts +3 -0
- package/{lib/components/CreditCardForm/getCardData.js → mobile/lib/services/retail/adaptors/getCardOptionsData.js} +2 -2
- package/mobile/lib/services/retail/adaptors/getCardOptionsData.js.map +1 -0
- package/mobile/lib/services/retail/adaptors/getCreditFormTaskData.d.ts +11 -0
- package/mobile/lib/{components/CreditForm → services/retail/adaptors}/getCreditFormTaskData.js +14 -14
- package/mobile/lib/services/retail/adaptors/getCreditFormTaskData.js.map +1 -0
- package/mobile/lib/services/retail/adaptors/getDeliveryCreditData.d.ts +3 -0
- package/mobile/lib/{components/CreditForm/getFifthStepData.js → services/retail/adaptors/getDeliveryCreditData.js} +2 -2
- package/mobile/lib/services/retail/adaptors/getDeliveryCreditData.js.map +1 -0
- package/mobile/lib/services/retail/adaptors/getEmploymentData.d.ts +3 -0
- package/mobile/lib/{components/CreditCardForm/getThirdStepData.js → services/retail/adaptors/getEmploymentData.js} +5 -5
- package/mobile/lib/services/retail/adaptors/getEmploymentData.js.map +1 -0
- package/mobile/lib/services/retail/adaptors/getFamilyStatusAndIncomeData.d.ts +3 -0
- package/mobile/lib/{components/CreditForm/getThirdStepData.js → services/retail/adaptors/getFamilyStatusAndIncomeData.js} +3 -3
- package/mobile/lib/services/retail/adaptors/getFamilyStatusAndIncomeData.js.map +1 -0
- package/mobile/lib/services/retail/adaptors/getPersonalInfoData.d.ts +3 -0
- package/mobile/lib/{components/CreditCardForm/getSecondStepData.js → services/retail/adaptors/getPersonalInfoData.js} +5 -5
- package/mobile/lib/services/retail/adaptors/getPersonalInfoData.js.map +1 -0
- package/mobile/lib/services/retail/content.d.ts +6 -0
- package/mobile/lib/services/retail/content.js +387 -0
- package/mobile/lib/services/retail/content.js.map +1 -0
- package/mobile/lib/ui-kit/DraftDialog/DraftDialog.js +7 -9
- package/mobile/lib/ui-kit/DraftDialog/DraftDialog.js.map +1 -1
- package/mobile/lib/ui-kit/EsiaLoginDialog/EsiaLoginDialog.js +6 -6
- package/mobile/lib/ui-kit/EsiaLoginDialog/EsiaLoginDialog.js.map +1 -1
- package/mobile/lib/ui-kit/FormField/Fields/AmountWorkersField.js +2 -2
- package/mobile/lib/ui-kit/FormField/Fields/AmountWorkersField.js.map +1 -1
- package/mobile/lib/ui-kit/FormField/Fields/EmployerActivitiesField.js +2 -2
- package/mobile/lib/ui-kit/FormField/Fields/EmployerActivitiesField.js.map +1 -1
- package/mobile/lib/ui-kit/FormField/Fields/EmployerOrganizationField.js +2 -2
- package/mobile/lib/ui-kit/FormField/Fields/EmployerOrganizationField.js.map +1 -1
- package/mobile/lib/ui-kit/FormField/Fields/InnField.js +2 -2
- package/mobile/lib/ui-kit/FormField/Fields/OrganizationField.js +2 -2
- package/mobile/lib/ui-kit/FormField/Fields/OrganizationField.js.map +1 -1
- package/mobile/lib/ui-kit/FormField/Fields/OrganizationNameField.js +2 -2
- package/mobile/lib/ui-kit/FormField/updateOrganizationFields.d.ts +2 -2
- package/mobile/lib/ui-kit/FormField/updateOrganizationFields.js.map +1 -1
- package/mobile/src/components/ApplicationLeadForm/useSaveUserData.ts +2 -4
- package/mobile/src/components/CreditCardForm/CreditCardForm.tsx +4 -3
- package/mobile/src/components/CreditCardForm/CreditCardFormStatusTracker.tsx +2 -2
- package/mobile/src/components/CreditCardForm/CreditCardFormStep.tsx +12 -16
- package/mobile/src/components/CreditCardForm/PendingStatusContent.tsx +2 -3
- package/mobile/src/components/CreditCardForm/ReworkStatusContent.tsx +2 -3
- package/mobile/src/components/CreditCardForm/SuccessStatusContent.tsx +2 -3
- package/mobile/src/components/CreditCardForm/creditCardFormStepsData.tsx +8 -347
- package/mobile/src/components/CreditCardForm/formStateMap.tsx +1 -4
- package/mobile/src/components/CreditCardForm/getCreditCardFormTaskData.ts +16 -12
- package/mobile/src/components/CreditCardForm/{getSixthStepData.ts → getDeliveryCreditCardData.ts} +1 -1
- package/mobile/src/components/CreditCardForm/getInitialFormState.tsx +8 -12
- package/mobile/src/components/CreditCardForm/useCreditCardFormAPI.tsx +65 -84
- package/mobile/src/components/CreditForm/CreditForm.tsx +5 -4
- package/mobile/src/components/CreditForm/CreditFormStatusTracker.tsx +2 -2
- package/mobile/src/components/CreditForm/CreditFormStep.tsx +15 -19
- package/mobile/src/components/CreditForm/PendingStatusContent.tsx +2 -3
- package/mobile/src/components/CreditForm/ReworkStatusContent.tsx +2 -3
- package/mobile/src/components/CreditForm/SuccessStatusContent.tsx +2 -3
- package/mobile/src/components/CreditForm/creditFormStepsData.tsx +8 -280
- package/mobile/src/components/CreditForm/getInitialFormState.tsx +8 -12
- package/mobile/src/components/CreditForm/useCreditFormAPI.tsx +66 -89
- package/mobile/src/hooks/useRetailFormStore.tsx +29 -0
- package/mobile/src/services/retail/adaptors/getAdditionalInfoData.ts +13 -0
- package/mobile/src/{components/CreditForm/getZeroStepData.ts → services/retail/adaptors/getCalculatorData.ts} +3 -3
- package/mobile/src/services/retail/adaptors/getCardOptionsData.tsx +13 -0
- package/{src/components/CreditForm → mobile/src/services/retail/adaptors}/getCreditFormTaskData.ts +16 -16
- package/mobile/src/services/retail/adaptors/getDeliveryCreditData.ts +12 -0
- package/mobile/src/{components/CreditForm/getSecondStepData.tsx → services/retail/adaptors/getEmploymentData.tsx} +9 -6
- package/mobile/src/{components/CreditCardForm/getFourthStepData.ts → services/retail/adaptors/getFamilyStatusAndIncomeData.ts} +4 -4
- package/{src/components/CreditCardForm/getSecondStepData.tsx → mobile/src/services/retail/adaptors/getPersonalInfoData.tsx} +9 -6
- package/mobile/src/services/retail/content.tsx +391 -0
- package/mobile/src/ui-kit/DraftDialog/DraftDialog.tsx +7 -9
- package/mobile/src/ui-kit/EsiaLoginDialog/EsiaLoginDialog.tsx +7 -7
- package/mobile/src/ui-kit/FormField/Fields/AmountWorkersField.tsx +2 -2
- package/mobile/src/ui-kit/FormField/Fields/EmployerActivitiesField.tsx +2 -2
- package/mobile/src/ui-kit/FormField/Fields/EmployerOrganizationField.tsx +2 -2
- package/mobile/src/ui-kit/FormField/Fields/InnField.tsx +2 -2
- package/mobile/src/ui-kit/FormField/Fields/OrganizationField.tsx +2 -2
- package/mobile/src/ui-kit/FormField/Fields/OrganizationNameField.tsx +2 -2
- package/mobile/src/ui-kit/FormField/updateOrganizationFields.ts +2 -2
- package/package.json +1 -1
- package/src/components/ApplicationLeadForm/useSaveUserData.ts +2 -4
- package/src/components/CreditCardForm/CreditCardForm.tsx +4 -3
- package/src/components/CreditCardForm/CreditCardFormStatusTracker.tsx +2 -2
- package/src/components/CreditCardForm/CreditCardFormStep.tsx +12 -16
- package/src/components/CreditCardForm/PendingStatusContent.tsx +2 -3
- package/src/components/CreditCardForm/ReworkStatusContent.tsx +2 -3
- package/src/components/CreditCardForm/SuccessStatusContent.tsx +2 -3
- package/src/components/CreditCardForm/creditCardFormStepsData.tsx +8 -347
- package/src/components/CreditCardForm/formStateMap.tsx +1 -4
- package/src/components/CreditCardForm/getCreditCardFormTaskData.ts +16 -12
- package/src/components/CreditCardForm/{getSixthStepData.ts → getDeliveryCreditCardData.ts} +1 -1
- package/src/components/CreditCardForm/getInitialFormState.tsx +8 -12
- package/src/components/CreditCardForm/useCreditCardFormAPI.tsx +65 -84
- package/src/components/CreditForm/CreditForm.tsx +5 -4
- package/src/components/CreditForm/CreditFormStatusTracker.tsx +2 -2
- package/src/components/CreditForm/CreditFormStep.tsx +15 -19
- package/src/components/CreditForm/PendingStatusContent.tsx +2 -3
- package/src/components/CreditForm/ReworkStatusContent.tsx +2 -3
- package/src/components/CreditForm/SuccessStatusContent.tsx +2 -3
- package/src/components/CreditForm/creditFormStepsData.tsx +8 -280
- package/src/components/CreditForm/getInitialFormState.tsx +8 -12
- package/src/components/CreditForm/useCreditFormAPI.tsx +66 -89
- package/src/hooks/useRetailFormStore.tsx +29 -0
- package/src/icons/IconName.ts +4 -4
- package/src/services/retail/adaptors/getAdditionalInfoData.ts +13 -0
- package/src/{components/CreditForm/getZeroStepData.ts → services/retail/adaptors/getCalculatorData.ts} +3 -3
- package/src/services/retail/adaptors/getCardOptionsData.tsx +13 -0
- package/{mobile/src/components/CreditForm → src/services/retail/adaptors}/getCreditFormTaskData.ts +16 -16
- package/src/services/retail/adaptors/getDeliveryCreditData.ts +12 -0
- package/src/{components/CreditForm/getSecondStepData.tsx → services/retail/adaptors/getEmploymentData.tsx} +9 -6
- package/src/{components/CreditCardForm/getFourthStepData.ts → services/retail/adaptors/getFamilyStatusAndIncomeData.ts} +4 -4
- package/{mobile/src/components/CreditCardForm/getSecondStepData.tsx → src/services/retail/adaptors/getPersonalInfoData.tsx} +9 -6
- package/src/services/retail/content.tsx +391 -0
- package/src/ui-kit/DraftDialog/DraftDialog.tsx +7 -9
- package/src/ui-kit/EsiaLoginDialog/EsiaLoginDialog.tsx +7 -7
- package/src/ui-kit/FormField/Fields/AmountWorkersField.tsx +2 -2
- package/src/ui-kit/FormField/Fields/EmployerActivitiesField.tsx +2 -2
- package/src/ui-kit/FormField/Fields/EmployerOrganizationField.tsx +2 -2
- package/src/ui-kit/FormField/Fields/InnField.tsx +2 -2
- package/src/ui-kit/FormField/Fields/OrganizationField.tsx +2 -2
- package/src/ui-kit/FormField/Fields/OrganizationNameField.tsx +2 -2
- package/src/ui-kit/FormField/updateOrganizationFields.ts +2 -2
- package/bundle/components/CreditCardForm/getCardData.d.ts +0 -3
- package/bundle/components/CreditCardForm/getFifthStepData.d.ts +0 -3
- package/bundle/components/CreditCardForm/getFourthStepData.d.ts +0 -3
- package/bundle/components/CreditCardForm/getSecondStepData.d.ts +0 -3
- package/bundle/components/CreditCardForm/getThirdStepData.d.ts +0 -3
- package/bundle/components/CreditForm/getFifthStepData.d.ts +0 -3
- package/bundle/components/CreditForm/getFirstStepData.d.ts +0 -3
- package/bundle/components/CreditForm/getFourthStepData.d.ts +0 -3
- package/bundle/components/CreditForm/getSecondStepData.d.ts +0 -3
- package/bundle/components/CreditForm/getThirdStepData.d.ts +0 -3
- package/bundle/components/CreditForm/getZeroStepData.d.ts +0 -3
- package/bundle/hooks/useCreditFormStore.d.ts +0 -13
- package/dist/components/CreditCardForm/getCardData.d.ts +0 -3
- package/dist/components/CreditCardForm/getCardData.js.map +0 -1
- package/dist/components/CreditCardForm/getFifthStepData.d.ts +0 -3
- package/dist/components/CreditCardForm/getFifthStepData.js +0 -13
- package/dist/components/CreditCardForm/getFifthStepData.js.map +0 -1
- package/dist/components/CreditCardForm/getFourthStepData.d.ts +0 -3
- package/dist/components/CreditCardForm/getFourthStepData.js.map +0 -1
- package/dist/components/CreditCardForm/getSecondStepData.d.ts +0 -3
- package/dist/components/CreditCardForm/getSecondStepData.js.map +0 -1
- package/dist/components/CreditCardForm/getSixthStepData.js.map +0 -1
- package/dist/components/CreditCardForm/getThirdStepData.d.ts +0 -3
- package/dist/components/CreditCardForm/getThirdStepData.js +0 -30
- package/dist/components/CreditCardForm/getThirdStepData.js.map +0 -1
- package/dist/components/CreditForm/getCreditFormTaskData.js.map +0 -1
- package/dist/components/CreditForm/getFifthStepData.d.ts +0 -3
- package/dist/components/CreditForm/getFifthStepData.js.map +0 -1
- package/dist/components/CreditForm/getFirstStepData.d.ts +0 -3
- package/dist/components/CreditForm/getFirstStepData.js +0 -35
- package/dist/components/CreditForm/getFirstStepData.js.map +0 -1
- package/dist/components/CreditForm/getFourthStepData.d.ts +0 -3
- package/dist/components/CreditForm/getFourthStepData.js.map +0 -1
- package/dist/components/CreditForm/getSecondStepData.d.ts +0 -3
- package/dist/components/CreditForm/getSecondStepData.js.map +0 -1
- package/dist/components/CreditForm/getThirdStepData.d.ts +0 -3
- package/dist/components/CreditForm/getThirdStepData.js +0 -28
- package/dist/components/CreditForm/getThirdStepData.js.map +0 -1
- package/dist/components/CreditForm/getZeroStepData.d.ts +0 -3
- package/dist/components/CreditForm/getZeroStepData.js.map +0 -1
- package/dist/hooks/useCreditFormStore.d.ts +0 -13
- package/dist/hooks/useCreditFormStore.js.map +0 -1
- package/lib/components/CreditCardForm/getCardData.d.ts +0 -3
- package/lib/components/CreditCardForm/getCardData.js.map +0 -1
- package/lib/components/CreditCardForm/getFifthStepData.d.ts +0 -3
- package/lib/components/CreditCardForm/getFifthStepData.js.map +0 -1
- package/lib/components/CreditCardForm/getFourthStepData.d.ts +0 -3
- package/lib/components/CreditCardForm/getFourthStepData.js +0 -25
- package/lib/components/CreditCardForm/getFourthStepData.js.map +0 -1
- package/lib/components/CreditCardForm/getSecondStepData.d.ts +0 -3
- package/lib/components/CreditCardForm/getSecondStepData.js.map +0 -1
- package/lib/components/CreditCardForm/getSixthStepData.js.map +0 -1
- package/lib/components/CreditCardForm/getThirdStepData.d.ts +0 -3
- package/lib/components/CreditCardForm/getThirdStepData.js +0 -27
- package/lib/components/CreditCardForm/getThirdStepData.js.map +0 -1
- package/lib/components/CreditForm/getCreditFormTaskData.js.map +0 -1
- package/lib/components/CreditForm/getFifthStepData.d.ts +0 -3
- package/lib/components/CreditForm/getFifthStepData.js.map +0 -1
- package/lib/components/CreditForm/getFirstStepData.d.ts +0 -3
- package/lib/components/CreditForm/getFirstStepData.js +0 -32
- package/lib/components/CreditForm/getFirstStepData.js.map +0 -1
- package/lib/components/CreditForm/getFourthStepData.d.ts +0 -3
- package/lib/components/CreditForm/getFourthStepData.js +0 -10
- package/lib/components/CreditForm/getFourthStepData.js.map +0 -1
- package/lib/components/CreditForm/getSecondStepData.d.ts +0 -3
- package/lib/components/CreditForm/getSecondStepData.js.map +0 -1
- package/lib/components/CreditForm/getThirdStepData.d.ts +0 -3
- package/lib/components/CreditForm/getThirdStepData.js +0 -25
- package/lib/components/CreditForm/getThirdStepData.js.map +0 -1
- package/lib/components/CreditForm/getZeroStepData.d.ts +0 -3
- package/lib/components/CreditForm/getZeroStepData.js.map +0 -1
- package/lib/hooks/useCreditFormStore.d.ts +0 -13
- package/lib/hooks/useCreditFormStore.js.map +0 -1
- package/mobile/bundle/components/CreditCardForm/getCardData.d.ts +0 -3
- package/mobile/bundle/components/CreditCardForm/getFifthStepData.d.ts +0 -3
- package/mobile/bundle/components/CreditCardForm/getFourthStepData.d.ts +0 -3
- package/mobile/bundle/components/CreditCardForm/getSecondStepData.d.ts +0 -3
- package/mobile/bundle/components/CreditCardForm/getThirdStepData.d.ts +0 -3
- package/mobile/bundle/components/CreditForm/getFifthStepData.d.ts +0 -3
- package/mobile/bundle/components/CreditForm/getFirstStepData.d.ts +0 -3
- package/mobile/bundle/components/CreditForm/getFourthStepData.d.ts +0 -3
- package/mobile/bundle/components/CreditForm/getSecondStepData.d.ts +0 -3
- package/mobile/bundle/components/CreditForm/getThirdStepData.d.ts +0 -3
- package/mobile/bundle/components/CreditForm/getZeroStepData.d.ts +0 -3
- package/mobile/bundle/hooks/useCreditFormStore.d.ts +0 -13
- package/mobile/dist/components/CreditCardForm/getCardData.d.ts +0 -3
- package/mobile/dist/components/CreditCardForm/getCardData.js.map +0 -1
- package/mobile/dist/components/CreditCardForm/getFifthStepData.d.ts +0 -3
- package/mobile/dist/components/CreditCardForm/getFifthStepData.js.map +0 -1
- package/mobile/dist/components/CreditCardForm/getFourthStepData.d.ts +0 -3
- package/mobile/dist/components/CreditCardForm/getFourthStepData.js.map +0 -1
- package/mobile/dist/components/CreditCardForm/getSecondStepData.d.ts +0 -3
- package/mobile/dist/components/CreditCardForm/getSecondStepData.js.map +0 -1
- package/mobile/dist/components/CreditCardForm/getSixthStepData.d.ts +0 -24
- package/mobile/dist/components/CreditCardForm/getSixthStepData.js.map +0 -1
- package/mobile/dist/components/CreditCardForm/getThirdStepData.d.ts +0 -3
- package/mobile/dist/components/CreditCardForm/getThirdStepData.js.map +0 -1
- package/mobile/dist/components/CreditForm/getCreditFormTaskData.d.ts +0 -11
- package/mobile/dist/components/CreditForm/getCreditFormTaskData.js.map +0 -1
- package/mobile/dist/components/CreditForm/getFifthStepData.d.ts +0 -3
- package/mobile/dist/components/CreditForm/getFifthStepData.js.map +0 -1
- package/mobile/dist/components/CreditForm/getFirstStepData.d.ts +0 -3
- package/mobile/dist/components/CreditForm/getFirstStepData.js +0 -35
- package/mobile/dist/components/CreditForm/getFirstStepData.js.map +0 -1
- package/mobile/dist/components/CreditForm/getFourthStepData.d.ts +0 -3
- package/mobile/dist/components/CreditForm/getFourthStepData.js +0 -13
- package/mobile/dist/components/CreditForm/getFourthStepData.js.map +0 -1
- package/mobile/dist/components/CreditForm/getSecondStepData.d.ts +0 -3
- package/mobile/dist/components/CreditForm/getSecondStepData.js +0 -30
- package/mobile/dist/components/CreditForm/getSecondStepData.js.map +0 -1
- package/mobile/dist/components/CreditForm/getThirdStepData.d.ts +0 -3
- package/mobile/dist/components/CreditForm/getThirdStepData.js +0 -28
- package/mobile/dist/components/CreditForm/getThirdStepData.js.map +0 -1
- package/mobile/dist/components/CreditForm/getZeroStepData.d.ts +0 -3
- package/mobile/dist/components/CreditForm/getZeroStepData.js.map +0 -1
- package/mobile/dist/hooks/useCreditFormStore.d.ts +0 -13
- package/mobile/dist/hooks/useCreditFormStore.js.map +0 -1
- package/mobile/lib/components/CreditCardForm/getCardData.d.ts +0 -3
- package/mobile/lib/components/CreditCardForm/getCardData.js.map +0 -1
- package/mobile/lib/components/CreditCardForm/getFifthStepData.d.ts +0 -3
- package/mobile/lib/components/CreditCardForm/getFifthStepData.js.map +0 -1
- package/mobile/lib/components/CreditCardForm/getFourthStepData.d.ts +0 -3
- package/mobile/lib/components/CreditCardForm/getFourthStepData.js.map +0 -1
- package/mobile/lib/components/CreditCardForm/getSecondStepData.d.ts +0 -3
- package/mobile/lib/components/CreditCardForm/getSecondStepData.js.map +0 -1
- package/mobile/lib/components/CreditCardForm/getSixthStepData.d.ts +0 -24
- package/mobile/lib/components/CreditCardForm/getSixthStepData.js.map +0 -1
- package/mobile/lib/components/CreditCardForm/getThirdStepData.d.ts +0 -3
- package/mobile/lib/components/CreditCardForm/getThirdStepData.js.map +0 -1
- package/mobile/lib/components/CreditForm/getCreditFormTaskData.d.ts +0 -11
- package/mobile/lib/components/CreditForm/getCreditFormTaskData.js.map +0 -1
- package/mobile/lib/components/CreditForm/getFifthStepData.d.ts +0 -3
- package/mobile/lib/components/CreditForm/getFifthStepData.js.map +0 -1
- package/mobile/lib/components/CreditForm/getFirstStepData.d.ts +0 -3
- package/mobile/lib/components/CreditForm/getFirstStepData.js +0 -32
- package/mobile/lib/components/CreditForm/getFirstStepData.js.map +0 -1
- package/mobile/lib/components/CreditForm/getFourthStepData.d.ts +0 -3
- package/mobile/lib/components/CreditForm/getFourthStepData.js +0 -10
- package/mobile/lib/components/CreditForm/getFourthStepData.js.map +0 -1
- package/mobile/lib/components/CreditForm/getSecondStepData.d.ts +0 -3
- package/mobile/lib/components/CreditForm/getSecondStepData.js +0 -27
- package/mobile/lib/components/CreditForm/getSecondStepData.js.map +0 -1
- package/mobile/lib/components/CreditForm/getThirdStepData.d.ts +0 -3
- package/mobile/lib/components/CreditForm/getThirdStepData.js.map +0 -1
- package/mobile/lib/components/CreditForm/getZeroStepData.d.ts +0 -3
- package/mobile/lib/components/CreditForm/getZeroStepData.js.map +0 -1
- package/mobile/lib/hooks/useCreditFormStore.d.ts +0 -13
- package/mobile/lib/hooks/useCreditFormStore.js.map +0 -1
- package/mobile/src/components/CreditCardForm/getCardData.tsx +0 -13
- package/mobile/src/components/CreditCardForm/getFifthStepData.ts +0 -13
- package/mobile/src/components/CreditCardForm/getThirdStepData.tsx +0 -47
- package/mobile/src/components/CreditForm/getFifthStepData.ts +0 -10
- package/mobile/src/components/CreditForm/getFirstStepData.tsx +0 -54
- package/mobile/src/components/CreditForm/getFourthStepData.ts +0 -13
- package/mobile/src/components/CreditForm/getThirdStepData.ts +0 -45
- package/mobile/src/hooks/useCreditFormStore.tsx +0 -13
- package/src/components/CreditCardForm/getCardData.tsx +0 -13
- package/src/components/CreditCardForm/getFifthStepData.ts +0 -13
- package/src/components/CreditCardForm/getThirdStepData.tsx +0 -47
- package/src/components/CreditForm/getFifthStepData.ts +0 -10
- package/src/components/CreditForm/getFirstStepData.tsx +0 -54
- package/src/components/CreditForm/getFourthStepData.ts +0 -13
- package/src/components/CreditForm/getThirdStepData.ts +0 -45
- package/src/hooks/useCreditFormStore.tsx +0 -13
package/bundle/bundle.umd.js
CHANGED
|
@@ -2807,7 +2807,7 @@
|
|
|
2807
2807
|
return useStore(localStore, methods);
|
|
2808
2808
|
}
|
|
2809
2809
|
|
|
2810
|
-
const
|
|
2810
|
+
const useRetailFormStore = () => {
|
|
2811
2811
|
return useLocalStore();
|
|
2812
2812
|
};
|
|
2813
2813
|
|
|
@@ -2823,7 +2823,7 @@
|
|
|
2823
2823
|
|
|
2824
2824
|
const AmountWorkersField = JSX(({ field, input }) => {
|
|
2825
2825
|
const { data } = useLeadFormData('EMPLOYEES_NUMBER');
|
|
2826
|
-
const store =
|
|
2826
|
+
const store = useRetailFormStore();
|
|
2827
2827
|
useEffect(() => {
|
|
2828
2828
|
if (data) {
|
|
2829
2829
|
store.amountWorkers = data;
|
|
@@ -3659,7 +3659,7 @@
|
|
|
3659
3659
|
|
|
3660
3660
|
const EmployerActivitiesField = JSX(({ field, input }) => {
|
|
3661
3661
|
const { data } = useLeadFormData('ORGANIZATION_ACTIVITY_TYPE');
|
|
3662
|
-
const store =
|
|
3662
|
+
const store = useRetailFormStore();
|
|
3663
3663
|
useEffect(() => {
|
|
3664
3664
|
if (data) {
|
|
3665
3665
|
store.employerActivities = data;
|
|
@@ -3670,7 +3670,7 @@
|
|
|
3670
3670
|
|
|
3671
3671
|
const EmployerOrganizationField = JSX(({ field, input }) => {
|
|
3672
3672
|
const { data } = useLeadFormData('ORGANIZATION_KIND');
|
|
3673
|
-
const store =
|
|
3673
|
+
const store = useRetailFormStore();
|
|
3674
3674
|
useEffect(() => {
|
|
3675
3675
|
if (data) {
|
|
3676
3676
|
store.employerOrganization = data;
|
|
@@ -3851,7 +3851,7 @@
|
|
|
3851
3851
|
});
|
|
3852
3852
|
|
|
3853
3853
|
const InnField = JSX(({ field, input }) => {
|
|
3854
|
-
const store =
|
|
3854
|
+
const store = useRetailFormStore();
|
|
3855
3855
|
const onDaDataChange = useCallback((item) => {
|
|
3856
3856
|
field?.('organizationName')?.onChange?.(item.data?.name?.short_with_opf);
|
|
3857
3857
|
updateOrganizationFields(store, field, item);
|
|
@@ -3915,7 +3915,7 @@
|
|
|
3915
3915
|
|
|
3916
3916
|
const OrganizationField = JSX(({ field, input }) => {
|
|
3917
3917
|
const { data } = useLeadFormData('ORGANIZATION_TYPE');
|
|
3918
|
-
const store =
|
|
3918
|
+
const store = useRetailFormStore();
|
|
3919
3919
|
useEffect(() => {
|
|
3920
3920
|
if (data) {
|
|
3921
3921
|
store.organization = data;
|
|
@@ -3925,7 +3925,7 @@
|
|
|
3925
3925
|
});
|
|
3926
3926
|
|
|
3927
3927
|
const OrganizationNameField = JSX(({ field, input }) => {
|
|
3928
|
-
const store =
|
|
3928
|
+
const store = useRetailFormStore();
|
|
3929
3929
|
const onDaDataChange = useCallback((item) => {
|
|
3930
3930
|
field?.('inn')?.onChange?.(item.data?.inn);
|
|
3931
3931
|
updateOrganizationFields(store, field, item);
|
|
@@ -4785,18 +4785,6 @@
|
|
|
4785
4785
|
};
|
|
4786
4786
|
};
|
|
4787
4787
|
|
|
4788
|
-
const useLeadFormStore = () => useLocalStore();
|
|
4789
|
-
|
|
4790
|
-
const useSetter = (target, key) => useCallback((value) => {
|
|
4791
|
-
const newValue = value instanceof Function ? value(target[key]) : value;
|
|
4792
|
-
if (newValue !== null && newValue !== undefined) {
|
|
4793
|
-
target[key] = newValue;
|
|
4794
|
-
}
|
|
4795
|
-
else {
|
|
4796
|
-
delete target[key];
|
|
4797
|
-
}
|
|
4798
|
-
}, [target, key]);
|
|
4799
|
-
|
|
4800
4788
|
const DraftActionButton = JSX(({ title, icon, description, onClick = noop }) => (jsxs("button", { className: "flex gap-lg items-center border border-gray rounded-md cursor-pointer p-4 hover:border-green", type: "button", onClick: onClick, children: [jsx(Img, { image: { icon: icon, iconVersion: 'black' }, width: "78", height: "78" }), jsxs("div", { children: [jsx(Heading, { className: "text-left", title: title, headingType: "h5" }), description ? (jsx(Paragraph, { color: "text-secondary-text", size: "text-m", children: description })) : null] })] })));
|
|
4801
4789
|
|
|
4802
4790
|
const creditCodesToProgrammIdMap = {
|
|
@@ -4939,8 +4927,7 @@
|
|
|
4939
4927
|
};
|
|
4940
4928
|
|
|
4941
4929
|
const DraftDialog = JSX(function ({ task, isFromLead = false, onClose = noop, }) {
|
|
4942
|
-
const
|
|
4943
|
-
const saveForm = useSetter(leadFormStore, 'leadForm');
|
|
4930
|
+
const retailFormStore = useRetailFormStore();
|
|
4944
4931
|
const navigator = locationNavigator();
|
|
4945
4932
|
const { participants, creditProgram, id: taskId } = task;
|
|
4946
4933
|
const programmId = creditProgramCodeToProductIdMap[creditProgram.code];
|
|
@@ -4949,11 +4936,11 @@
|
|
|
4949
4936
|
const { name, midname, id: participantId, profile } = participants[0];
|
|
4950
4937
|
const handleGoToDraft = useCallback(() => {
|
|
4951
4938
|
const taskFromDraft = parseDraftTask(task);
|
|
4952
|
-
|
|
4953
|
-
|
|
4954
|
-
|
|
4955
|
-
|
|
4956
|
-
|
|
4939
|
+
retailFormStore.participantId = participantId;
|
|
4940
|
+
retailFormStore.taskId = taskId;
|
|
4941
|
+
retailFormStore.profileId = profile?.id;
|
|
4942
|
+
retailFormStore.programId = programmId;
|
|
4943
|
+
retailFormStore.leadForm = taskFromDraft;
|
|
4957
4944
|
navigator.assign(nextStepLink);
|
|
4958
4945
|
}, []);
|
|
4959
4946
|
const handleGoToNewTask = useCallback(() => {
|
|
@@ -4991,7 +4978,7 @@
|
|
|
4991
4978
|
|
|
4992
4979
|
const EsiaLoginDialog = JSX(({ onClose }) => {
|
|
4993
4980
|
const navigator = locationNavigator();
|
|
4994
|
-
const
|
|
4981
|
+
const retailFormStore = useRetailFormStore();
|
|
4995
4982
|
const handleAuth = useCallback(async () => {
|
|
4996
4983
|
const resp = await getLink({
|
|
4997
4984
|
redirectUri: navigator.href,
|
|
@@ -5001,10 +4988,10 @@
|
|
|
5001
4988
|
}
|
|
5002
4989
|
}, []);
|
|
5003
4990
|
const handleClose = useCallback(() => {
|
|
5004
|
-
if (leadForm
|
|
5005
|
-
const
|
|
5006
|
-
|
|
5007
|
-
|
|
4991
|
+
if (retailFormStore.leadForm) {
|
|
4992
|
+
const leadForm = { ...retailFormStore.leadForm };
|
|
4993
|
+
delete leadForm.esiaAccountTypeCd;
|
|
4994
|
+
retailFormStore.leadForm = leadForm;
|
|
5008
4995
|
}
|
|
5009
4996
|
onClose?.();
|
|
5010
4997
|
}, []);
|
|
@@ -5118,15 +5105,16 @@
|
|
|
5118
5105
|
};
|
|
5119
5106
|
};
|
|
5120
5107
|
|
|
5108
|
+
const useLeadFormStore = () => useLocalStore();
|
|
5109
|
+
|
|
5121
5110
|
const useSaveUserData = () => {
|
|
5122
5111
|
const leadFormStore = useLeadFormStore();
|
|
5123
|
-
const
|
|
5124
|
-
const saveUserData = useCallback(({ participantId, taskId, profileId, formData, programId: programNumber }) => {
|
|
5112
|
+
const saveUserData = useCallback(({ participantId, taskId, profileId, programId: programNumber, formData }) => {
|
|
5125
5113
|
leadFormStore.participantId = participantId;
|
|
5126
5114
|
leadFormStore.taskId = taskId;
|
|
5127
5115
|
leadFormStore.profileId = profileId;
|
|
5128
5116
|
leadFormStore.programId = programNumber;
|
|
5129
|
-
|
|
5117
|
+
leadFormStore.leadForm = formData;
|
|
5130
5118
|
}, []);
|
|
5131
5119
|
return saveUserData;
|
|
5132
5120
|
};
|
|
@@ -5232,6 +5220,16 @@
|
|
|
5232
5220
|
|
|
5233
5221
|
const updateProfileEsia = (body) => fetchRetailJSON('/esia/updateProfileEsia', 'POST', body);
|
|
5234
5222
|
|
|
5223
|
+
const useSetter = (target, key) => useCallback((value) => {
|
|
5224
|
+
const newValue = value instanceof Function ? value(target[key]) : value;
|
|
5225
|
+
if (newValue !== null && newValue !== undefined) {
|
|
5226
|
+
target[key] = newValue;
|
|
5227
|
+
}
|
|
5228
|
+
else {
|
|
5229
|
+
delete target[key];
|
|
5230
|
+
}
|
|
5231
|
+
}, [target, key]);
|
|
5232
|
+
|
|
5235
5233
|
const initialFormState = {
|
|
5236
5234
|
typeForm: '',
|
|
5237
5235
|
region: { key: '', text: '' },
|
|
@@ -6831,7 +6829,7 @@
|
|
|
6831
6829
|
const FailedStatusContent$1 = JSX(() => (jsx(CreditCardFormStatus, { title: "\u0411\u043B\u0430\u0433\u043E\u0434\u0430\u0440\u0438\u043C \u0412\u0430\u0441 \u0437\u0430 \u043E\u0436\u0438\u0434\u0430\u043D\u0438\u0435", description: "\u0412 \u043D\u0430\u0441\u0442\u043E\u044F\u0449\u0438\u0439 \u043C\u043E\u043C\u0435\u043D\u0442 \u0411\u0430\u043D\u043A \u043D\u0435 \u043C\u043E\u0436\u0435\u0442 \u043E\u0434\u043E\u0431\u0440\u0438\u0442\u044C \u0412\u0430\u0448\u0443 \u0437\u0430\u044F\u0432\u043A\u0443 \u043D\u0430 \u043A\u0440\u0435\u0434\u0438\u0442. \u041F\u043E\u043F\u0440\u043E\u0431\u0443\u0439\u0442\u0435 \u043F\u043E\u0434\u0430\u0442\u044C \u0437\u0430\u044F\u0432\u043A\u0443 \u043F\u043E\u0437\u0436\u0435. \u0421\u043F\u0430\u0441\u0438\u0431\u043E \u0437\u0430 \u043E\u0431\u0440\u0430\u0449\u0435\u043D\u0438\u0435 \u0432 \u0410\u041E \u00AB\u0420\u043E\u0441\u0441\u0435\u043B\u044C\u0445\u043E\u0437\u0431\u0430\u043D\u043A\u00BB.", buttonText: "\u0412\u0435\u0440\u043D\u0443\u0442\u044C\u0441\u044F \u043D\u0430 \u0433\u043B\u0430\u0432\u043D\u0443\u044E" })));
|
|
6832
6830
|
|
|
6833
6831
|
const PendingStatusContent$1 = JSX(({ handleExpireTimer }) => {
|
|
6834
|
-
const
|
|
6832
|
+
const { statusInfo } = useRetailFormStore();
|
|
6835
6833
|
return (jsx(CreditCardFormStatus, { interval: 300, intervalExpireAction: handleExpireTimer, title: "\u0417\u0430\u044F\u0432\u043A\u0430 \u0443\u0441\u043F\u0435\u0448\u043D\u043E \u043E\u0442\u043F\u0440\u0430\u0432\u043B\u0435\u043D\u0430", description: "\u041D\u0435 \u0437\u0430\u043A\u0440\u044B\u0432\u0430\u0439\u0442\u0435 \u043E\u043A\u043D\u043E, \u0441\u043A\u043E\u0440\u043E \u0441\u043E\u043E\u0431\u0449\u0438\u043C \u0440\u0435\u0437\u0443\u043B\u044C\u0442\u0430\u0442", sectionInfoTitle: "\u0417\u0430\u044F\u0432\u043B\u0435\u043D\u043D\u044B\u0435 \u0443\u0441\u043B\u043E\u0432\u0438\u044F \u043F\u043E \u043A\u0440\u0435\u0434\u0438\u0442\u0443", sectionInfo: [
|
|
6836
6834
|
{
|
|
6837
6835
|
label: 'Название продукта',
|
|
@@ -6845,7 +6843,7 @@
|
|
|
6845
6843
|
});
|
|
6846
6844
|
|
|
6847
6845
|
const ReworkStatusContent$1 = JSX(() => {
|
|
6848
|
-
const
|
|
6846
|
+
const { statusInfo } = useRetailFormStore();
|
|
6849
6847
|
return (jsx(CreditCardFormStatus, { title: "\u0411\u043B\u0430\u0433\u043E\u0434\u0430\u0440\u0438\u043C \u0432\u0430\u0441 \u0437\u0430 \u043E\u0436\u0438\u0434\u0430\u043D\u0438\u0435, \u043D\u043E \u043D\u0430\u043C \u0442\u0440\u0435\u0431\u0443\u0435\u0442\u0441\u044F \u0431\u043E\u043B\u044C\u0448\u0435 \u0432\u0440\u0435\u043C\u0435\u043D\u0438 \u0434\u043B\u044F \u043F\u0440\u0438\u043D\u044F\u0442\u0438\u044F \u0440\u0435\u0448\u0435\u043D\u0438\u044F", description: "\u041F\u043E\u0441\u0435\u0442\u0438\u0442\u0435 \u0432\u044B\u0431\u0440\u0430\u043D\u043D\u043E\u0435 \u043E\u0442\u0434\u0435\u043B\u0435\u043D\u0438\u0435 \u0431\u0430\u043D\u043A\u0430 \u0441 \u043D\u0435\u043E\u0431\u0445\u043E\u0434\u0438\u043C\u044B\u043C\u0438 \u0434\u043E\u043A\u0443\u043C\u0435\u043D\u0442\u0430\u043C\u0438 \u0438 \u0442\u0430\u043A \u0437\u0430\u0432\u0435\u0440\u0448\u0438\u0442\u0435 \u043E\u0444\u043E\u0440\u043C\u043B\u0435\u043D\u0438\u0435 \u043A\u0440\u0435\u0434\u0438\u0442\u0430.", sectionAdditionalTitle: "\u0412 \u043E\u0442\u0434\u0435\u043B\u0435\u043D\u0438\u0438 \u0411\u0430\u043D\u043A\u0430", sectionInfoAdditional: [
|
|
6850
6848
|
{
|
|
6851
6849
|
label: 'Регион',
|
|
@@ -6864,7 +6862,7 @@
|
|
|
6864
6862
|
});
|
|
6865
6863
|
|
|
6866
6864
|
const SuccessStatusContent$1 = JSX(() => {
|
|
6867
|
-
const
|
|
6865
|
+
const { statusInfo } = useRetailFormStore();
|
|
6868
6866
|
return (jsx(CreditCardFormStatus, { title: "\u0411\u0430\u043D\u043A \u043E\u0434\u043E\u0431\u0440\u0438\u043B \u0432\u0430\u043C \u043A\u0440\u0435\u0434\u0438\u0442", description: "\u041E\u0431\u0440\u0430\u0442\u0438\u0442\u0435\u0441\u044C \u0432 \u043E\u0442\u0434\u0435\u043B\u0435\u043D\u0438\u0435 \u0431\u0430\u043D\u043A\u0430, \u0447\u0442\u043E\u0431\u044B \u0437\u0430\u0432\u0435\u0440\u0448\u0438\u0442\u044C \u043E\u0444\u043E\u0440\u043C\u043B\u0435\u043D\u0438\u0435 \u0438 \u043F\u043E\u043B\u0443\u0447\u0438\u0442 \u0432\u0430\u0448 \u043A\u0440\u0435\u0434\u0438\u0442", sectionInfo: [
|
|
6869
6867
|
{
|
|
6870
6868
|
label: 'Название продукта',
|
|
@@ -6895,7 +6893,7 @@
|
|
|
6895
6893
|
];
|
|
6896
6894
|
const CreditCardFormStatusTracker = JSX(() => {
|
|
6897
6895
|
const [status, setStatus] = useState(STATUS_TYPE.process);
|
|
6898
|
-
const
|
|
6896
|
+
const { taskId } = useRetailFormStore();
|
|
6899
6897
|
useEffect(() => {
|
|
6900
6898
|
(async () => {
|
|
6901
6899
|
for (const signalType of SIGNAL_TYPES$1) {
|
|
@@ -6924,117 +6922,6 @@
|
|
|
6924
6922
|
return statusesMap[status] || jsx(ReworkStatusContent$1, {});
|
|
6925
6923
|
};
|
|
6926
6924
|
|
|
6927
|
-
const formStateMap$1 = [
|
|
6928
|
-
{
|
|
6929
|
-
paymentSystem: { name: '', type: '' },
|
|
6930
|
-
currency: '810',
|
|
6931
|
-
codeWord: '',
|
|
6932
|
-
},
|
|
6933
|
-
{
|
|
6934
|
-
surname: '',
|
|
6935
|
-
name: '',
|
|
6936
|
-
middleName: '',
|
|
6937
|
-
sex: '',
|
|
6938
|
-
limitedBirthday: undefined,
|
|
6939
|
-
birthPlace: '',
|
|
6940
|
-
phone: '',
|
|
6941
|
-
email: '',
|
|
6942
|
-
dulSerie: undefined,
|
|
6943
|
-
dulNumber: undefined,
|
|
6944
|
-
dulIssueDateField: undefined,
|
|
6945
|
-
dulSubdivisionCode: '',
|
|
6946
|
-
dulIssuedBy: '',
|
|
6947
|
-
addressRegistration: {
|
|
6948
|
-
fullAddress: '',
|
|
6949
|
-
fiasCode: '',
|
|
6950
|
-
},
|
|
6951
|
-
participantDateRegistration: undefined,
|
|
6952
|
-
addressFact: {
|
|
6953
|
-
fullAddress: '',
|
|
6954
|
-
fiasCode: '',
|
|
6955
|
-
},
|
|
6956
|
-
housing: undefined,
|
|
6957
|
-
methodObtain: 'office',
|
|
6958
|
-
addressCourier: {
|
|
6959
|
-
fullAddress: '',
|
|
6960
|
-
fiasCode: '',
|
|
6961
|
-
},
|
|
6962
|
-
},
|
|
6963
|
-
{
|
|
6964
|
-
amountWorkers: { key: '', text: '' },
|
|
6965
|
-
beginDate: undefined,
|
|
6966
|
-
employerActivities: { key: '', text: '' },
|
|
6967
|
-
employerOrganization: { key: '', text: '' },
|
|
6968
|
-
employment: { key: '', text: '' },
|
|
6969
|
-
experience5Years: undefined,
|
|
6970
|
-
inn: undefined,
|
|
6971
|
-
jobsNumber: undefined,
|
|
6972
|
-
lastJobExperience: undefined,
|
|
6973
|
-
legalForm: '',
|
|
6974
|
-
organization: { key: '', text: '' },
|
|
6975
|
-
organizationAddress: {
|
|
6976
|
-
fullAddress: '',
|
|
6977
|
-
fiasCode: '',
|
|
6978
|
-
},
|
|
6979
|
-
organizationName: '',
|
|
6980
|
-
organizationPhone: '',
|
|
6981
|
-
partInBusiness: undefined,
|
|
6982
|
-
positionOrganization: { key: '', text: '' },
|
|
6983
|
-
},
|
|
6984
|
-
{
|
|
6985
|
-
familyStatus: { key: '', text: '' },
|
|
6986
|
-
dependents: undefined,
|
|
6987
|
-
familyMembers: undefined,
|
|
6988
|
-
confirmationIncome: { key: '', text: '' },
|
|
6989
|
-
wages: undefined,
|
|
6990
|
-
mandatoryPayments: undefined,
|
|
6991
|
-
snils: '',
|
|
6992
|
-
armyIdFlg: false,
|
|
6993
|
-
},
|
|
6994
|
-
{
|
|
6995
|
-
disablePeopleFlg: false,
|
|
6996
|
-
bankruptcyFlg: false,
|
|
6997
|
-
shareholderFlg: false,
|
|
6998
|
-
legalEntityName: '',
|
|
6999
|
-
creditInRshbCd: undefined,
|
|
7000
|
-
},
|
|
7001
|
-
{
|
|
7002
|
-
regionRetail: { key: '', text: '' },
|
|
7003
|
-
addressRetail: {
|
|
7004
|
-
key: '',
|
|
7005
|
-
text: '',
|
|
7006
|
-
},
|
|
7007
|
-
bankEmployeeCode: undefined,
|
|
7008
|
-
addressCourier: {
|
|
7009
|
-
fullAddress: '',
|
|
7010
|
-
fiasCode: '',
|
|
7011
|
-
},
|
|
7012
|
-
methodObtain: 'office',
|
|
7013
|
-
deliveryDate: undefined,
|
|
7014
|
-
},
|
|
7015
|
-
];
|
|
7016
|
-
|
|
7017
|
-
const getInitialFormState$1 = (step, localStorageData) => ({
|
|
7018
|
-
...formStateMap$1[step],
|
|
7019
|
-
...localStorageData,
|
|
7020
|
-
limitedBirthday: transformStringToData$1(localStorageData?.limitedBirthday),
|
|
7021
|
-
dulIssueDateField: transformStringToData$1(localStorageData?.dulIssueDateField),
|
|
7022
|
-
participantDateRegistration: transformStringToData$1(localStorageData?.participantDateRegistration),
|
|
7023
|
-
beginDate: transformStringToData$1(localStorageData?.beginDate),
|
|
7024
|
-
deliveryDate: transformStringToData$1(localStorageData?.deliveryDate),
|
|
7025
|
-
});
|
|
7026
|
-
const transformStringToData$1 = (text) => {
|
|
7027
|
-
if (!text) {
|
|
7028
|
-
return undefined;
|
|
7029
|
-
}
|
|
7030
|
-
try {
|
|
7031
|
-
return new Date(text);
|
|
7032
|
-
}
|
|
7033
|
-
catch (_) {
|
|
7034
|
-
return undefined;
|
|
7035
|
-
}
|
|
7036
|
-
};
|
|
7037
|
-
|
|
7038
6925
|
const calculateInputs$1 = (getValue) => (inputs, step) => inputs
|
|
7039
6926
|
.filter((_) => _)
|
|
7040
6927
|
.map((_) => {
|
|
@@ -7084,7 +6971,17 @@
|
|
|
7084
6971
|
return (jsxs("div", { className: "flex justify-between gap-m", children: [jsx(Button, { onClick: onPrevStep, type: "button", version: "secondary", disabled: isFirstStep, children: "\u041D\u0430\u0437\u0430\u0434" }), jsx(Button, { type: "submit", children: isFinalStep ? 'Отправить заявку' : 'Далее' })] }));
|
|
7085
6972
|
});
|
|
7086
6973
|
|
|
7087
|
-
const
|
|
6974
|
+
const getAdditionalInfoData = (formData) => {
|
|
6975
|
+
const { bankruptcyFlg, shareholderFlg, legalEntityName, creditInRshbCd } = formData;
|
|
6976
|
+
return {
|
|
6977
|
+
bankruptcyFlg,
|
|
6978
|
+
shareholderFlg,
|
|
6979
|
+
nameLegalEntity: legalEntityName,
|
|
6980
|
+
creditInRshbCd,
|
|
6981
|
+
};
|
|
6982
|
+
};
|
|
6983
|
+
|
|
6984
|
+
const getCardOptionsData = (formData) => {
|
|
7088
6985
|
const { currency, paymentSystem, cardCategory, codeWord } = formData;
|
|
7089
6986
|
return {
|
|
7090
6987
|
currencyCode: currency ? { key: currency } : undefined,
|
|
@@ -7094,17 +6991,31 @@
|
|
|
7094
6991
|
};
|
|
7095
6992
|
};
|
|
7096
6993
|
|
|
7097
|
-
const
|
|
7098
|
-
const {
|
|
6994
|
+
const getEmploymentData = (formData) => {
|
|
6995
|
+
const { beginDate, employment, organizationName, inn, legalForm, organization, amountWorkers, employerActivities, employerOrganization, generalSeniority, lastJobExperience, experience5Years, jobsNumber, organizationPhone, organizationAddress, positionOrganization, } = formData;
|
|
7099
6996
|
return {
|
|
7100
|
-
|
|
7101
|
-
|
|
7102
|
-
|
|
7103
|
-
|
|
6997
|
+
employmentContractDate: formatDate(beginDate || '', true),
|
|
6998
|
+
employmentTypeCd: employment,
|
|
6999
|
+
organizationName,
|
|
7000
|
+
organizationInn: inn,
|
|
7001
|
+
organizationActivityTypeCd: employerActivities,
|
|
7002
|
+
organizationTypeCd: organization,
|
|
7003
|
+
organizationKindCd: employerOrganization,
|
|
7004
|
+
employeesNumberCd: amountWorkers,
|
|
7005
|
+
opf: legalForm,
|
|
7006
|
+
seniority: generalSeniority,
|
|
7007
|
+
generalSeniority: experience5Years,
|
|
7008
|
+
jobsNumber,
|
|
7009
|
+
lastWorkDuration: lastJobExperience,
|
|
7010
|
+
positionCd: positionOrganization,
|
|
7011
|
+
participantContacts: getParticipantContacts({
|
|
7012
|
+
organizationPhone: organizationPhone && formatPhone(organizationPhone),
|
|
7013
|
+
}),
|
|
7014
|
+
participantAddresses: getParticipantAddresses({ organizationAddress }),
|
|
7104
7015
|
};
|
|
7105
7016
|
};
|
|
7106
7017
|
|
|
7107
|
-
const
|
|
7018
|
+
const getFamilyStatusAndIncomeData = (formData) => {
|
|
7108
7019
|
const { familyStatus, dependents, familyMembers, children, confirmationIncome, wages, mandatoryPayments, incomeAverage, additionalIncome, otherIncome, otherPayments, rentalIncome, retirementIncome, snils, armyIdFlg, conscription, } = formData;
|
|
7109
7020
|
return {
|
|
7110
7021
|
maritalStatusCd: familyStatus,
|
|
@@ -7128,7 +7039,7 @@
|
|
|
7128
7039
|
};
|
|
7129
7040
|
};
|
|
7130
7041
|
|
|
7131
|
-
const
|
|
7042
|
+
const getPersonalInfoData = (formData) => {
|
|
7132
7043
|
const { name, surname, middleName, limitedBirthday = '', phone = '', email, sex, birthPlace, dulIssueDateField = '', dulIssuedBy, dulNumber, dulSerie, dulSubdivisionCode, education, participantDateRegistration = '', housing, addressRegistration, addressFact, } = formData;
|
|
7133
7044
|
return {
|
|
7134
7045
|
birthDate: formatDate(limitedBirthday, true),
|
|
@@ -7184,7 +7095,7 @@
|
|
|
7184
7095
|
}
|
|
7185
7096
|
: {};
|
|
7186
7097
|
};
|
|
7187
|
-
const
|
|
7098
|
+
const getDeliveryCreditCardData = (formData) => {
|
|
7188
7099
|
const { addressCourier, methodObtain } = formData;
|
|
7189
7100
|
const isCourierDelivery = methodObtain === 'courier';
|
|
7190
7101
|
return isCourierDelivery
|
|
@@ -7194,30 +7105,6 @@
|
|
|
7194
7105
|
: {};
|
|
7195
7106
|
};
|
|
7196
7107
|
|
|
7197
|
-
const getThirdStepData$1 = (formData) => {
|
|
7198
|
-
const { beginDate, employment, organizationName, inn, legalForm, organization, amountWorkers, employerActivities, employerOrganization, generalSeniority, lastJobExperience, experience5Years, jobsNumber, organizationPhone, organizationAddress, positionOrganization, } = formData;
|
|
7199
|
-
return {
|
|
7200
|
-
employmentContractDate: formatDate(beginDate || '', true),
|
|
7201
|
-
employmentTypeCd: employment,
|
|
7202
|
-
organizationName,
|
|
7203
|
-
organizationInn: inn,
|
|
7204
|
-
organizationActivityTypeCd: employerActivities,
|
|
7205
|
-
organizationTypeCd: organization,
|
|
7206
|
-
organizationKindCd: employerOrganization,
|
|
7207
|
-
employeesNumberCd: amountWorkers,
|
|
7208
|
-
opf: legalForm,
|
|
7209
|
-
seniority: generalSeniority,
|
|
7210
|
-
generalSeniority: experience5Years,
|
|
7211
|
-
jobsNumber,
|
|
7212
|
-
lastWorkDuration: lastJobExperience,
|
|
7213
|
-
positionCd: positionOrganization,
|
|
7214
|
-
participantContacts: getParticipantContacts({
|
|
7215
|
-
organizationPhone: organizationPhone && formatPhone(organizationPhone),
|
|
7216
|
-
}),
|
|
7217
|
-
participantAddresses: getParticipantAddresses({ organizationAddress }),
|
|
7218
|
-
};
|
|
7219
|
-
};
|
|
7220
|
-
|
|
7221
7108
|
const getCreditCardFormTaskData = ({ participantId, taskId, profileId, formData, step = 0, }) => {
|
|
7222
7109
|
const navigator = locationNavigator();
|
|
7223
7110
|
return {
|
|
@@ -7241,7 +7128,7 @@
|
|
|
7241
7128
|
...getCurrentStepData$1(step, formData),
|
|
7242
7129
|
},
|
|
7243
7130
|
],
|
|
7244
|
-
...
|
|
7131
|
+
...getCardOptionsData(formData),
|
|
7245
7132
|
...getDeliveryData(formData),
|
|
7246
7133
|
},
|
|
7247
7134
|
};
|
|
@@ -7251,438 +7138,579 @@
|
|
|
7251
7138
|
case 0:
|
|
7252
7139
|
return {};
|
|
7253
7140
|
case 1:
|
|
7254
|
-
return
|
|
7141
|
+
return getPersonalInfoData(formData);
|
|
7255
7142
|
case 2:
|
|
7256
|
-
return
|
|
7143
|
+
return getEmploymentData(formData);
|
|
7257
7144
|
case 3:
|
|
7258
|
-
return
|
|
7145
|
+
return getFamilyStatusAndIncomeData(formData);
|
|
7259
7146
|
case 4:
|
|
7260
|
-
return
|
|
7147
|
+
return getAdditionalInfoData(formData);
|
|
7261
7148
|
case 5:
|
|
7262
|
-
return
|
|
7149
|
+
return getDeliveryCreditCardData(formData);
|
|
7263
7150
|
default:
|
|
7264
7151
|
return {};
|
|
7265
7152
|
}
|
|
7266
7153
|
};
|
|
7267
7154
|
|
|
7268
|
-
const
|
|
7269
|
-
|
|
7270
|
-
|
|
7271
|
-
|
|
7272
|
-
|
|
7273
|
-
|
|
7274
|
-
|
|
7275
|
-
|
|
7276
|
-
|
|
7277
|
-
|
|
7278
|
-
|
|
7279
|
-
|
|
7280
|
-
|
|
7281
|
-
|
|
7282
|
-
|
|
7283
|
-
|
|
7284
|
-
|
|
7285
|
-
|
|
7286
|
-
|
|
7287
|
-
|
|
7288
|
-
|
|
7289
|
-
|
|
7290
|
-
|
|
7291
|
-
}
|
|
7292
|
-
}
|
|
7293
|
-
catch (ex) {
|
|
7294
|
-
return 'Fail';
|
|
7295
|
-
}
|
|
7296
|
-
onNextStep();
|
|
7297
|
-
if (isFinalStep) {
|
|
7298
|
-
finishForm?.(true);
|
|
7299
|
-
}
|
|
7300
|
-
return 'OK';
|
|
7301
|
-
}, []);
|
|
7302
|
-
return {
|
|
7303
|
-
handleSubmit,
|
|
7304
|
-
};
|
|
7305
|
-
};
|
|
7306
|
-
const resetForm$1 = ({ isFinalStep, response, leadForm, setStatusInfo, }) => {
|
|
7307
|
-
if (isFinalStep && response.ok && leadForm) {
|
|
7308
|
-
const regionRetail = leadForm?.regionRetail?.text;
|
|
7309
|
-
const addressRetail = leadForm?.addressRetail?.text;
|
|
7310
|
-
const cardCategory = leadForm?.cardCategory?.text;
|
|
7311
|
-
const calculator = {
|
|
7312
|
-
monthsValue: leadForm?.calculator?.monthsValue,
|
|
7313
|
-
moneyValue: leadForm?.calculator?.moneyValue,
|
|
7314
|
-
isAnnuity: leadForm?.calculator?.isAnnuity,
|
|
7315
|
-
};
|
|
7316
|
-
setStatusInfo({ regionRetail, addressRetail, cardCategory, calculator });
|
|
7317
|
-
globalThis.localStorage.removeItem('leadForm');
|
|
7318
|
-
}
|
|
7319
|
-
};
|
|
7320
|
-
const getValue$2 = (formData) => (name) => formData[name];
|
|
7321
|
-
|
|
7322
|
-
const CreditCardFormStep = JSX(({ step, sections, onPrevStep, onNextStep, isFormFinished, finishForm }) => {
|
|
7323
|
-
const [localStorageData, saveStep] = useLocalStorage('leadForm');
|
|
7324
|
-
const initialState = getInitialFormState$1(step, localStorageData);
|
|
7325
|
-
const inputs = (sections?.flatMap((_) => _?.inputs) || []);
|
|
7326
|
-
const { handleSubmit } = useCreditCardFormAPI({
|
|
7327
|
-
step,
|
|
7328
|
-
inputs,
|
|
7329
|
-
onNextStep,
|
|
7330
|
-
saveStep,
|
|
7331
|
-
finishForm,
|
|
7332
|
-
});
|
|
7333
|
-
const [, { field, onSubmit }] = useForm(initialState, {
|
|
7334
|
-
onSubmit: handleSubmit,
|
|
7335
|
-
});
|
|
7336
|
-
return isFormFinished ? (jsx(CreditCardFormStatusTracker, {})) : (jsxs("form", { onSubmit: onSubmit, className: "space-y-m", children: [renderStep$2({ sections, field, step }), jsx(StepsNavigationButtons$1, { step: step, onPrevStep: onPrevStep })] }));
|
|
7337
|
-
});
|
|
7338
|
-
|
|
7339
|
-
/* eslint-disable max-lines */
|
|
7340
|
-
/* eslint-disable max-len */
|
|
7341
|
-
const stepsSectionsMap$1 = [
|
|
7342
|
-
[
|
|
7343
|
-
{
|
|
7344
|
-
title: 'Параметры карты',
|
|
7345
|
-
inputs: [],
|
|
7155
|
+
const formStateMap$1 = [
|
|
7156
|
+
{
|
|
7157
|
+
paymentSystem: { name: '', type: '' },
|
|
7158
|
+
currency: '810',
|
|
7159
|
+
codeWord: '',
|
|
7160
|
+
},
|
|
7161
|
+
{
|
|
7162
|
+
surname: '',
|
|
7163
|
+
name: '',
|
|
7164
|
+
middleName: '',
|
|
7165
|
+
sex: '',
|
|
7166
|
+
limitedBirthday: undefined,
|
|
7167
|
+
birthPlace: '',
|
|
7168
|
+
phone: '',
|
|
7169
|
+
email: '',
|
|
7170
|
+
dulSerie: undefined,
|
|
7171
|
+
dulNumber: undefined,
|
|
7172
|
+
dulIssueDateField: undefined,
|
|
7173
|
+
dulSubdivisionCode: '',
|
|
7174
|
+
dulIssuedBy: '',
|
|
7175
|
+
addressRegistration: {
|
|
7176
|
+
fullAddress: '',
|
|
7177
|
+
fiasCode: '',
|
|
7346
7178
|
},
|
|
7347
|
-
|
|
7348
|
-
|
|
7349
|
-
|
|
7350
|
-
|
|
7351
|
-
{ fieldType: 'common', name: 'cardCategory', required: true },
|
|
7352
|
-
{ fieldType: 'common', name: 'codeWord', required: true },
|
|
7353
|
-
],
|
|
7179
|
+
participantDateRegistration: undefined,
|
|
7180
|
+
addressFact: {
|
|
7181
|
+
fullAddress: '',
|
|
7182
|
+
fiasCode: '',
|
|
7354
7183
|
},
|
|
7355
|
-
|
|
7356
|
-
|
|
7357
|
-
{
|
|
7358
|
-
|
|
7359
|
-
|
|
7360
|
-
inputs: [
|
|
7361
|
-
{
|
|
7362
|
-
fieldType: 'common',
|
|
7363
|
-
name: 'surname',
|
|
7364
|
-
required: true,
|
|
7365
|
-
dadata: true,
|
|
7366
|
-
filledByEsia: true,
|
|
7367
|
-
},
|
|
7368
|
-
{ fieldType: 'common', name: 'name', required: true, dadata: true, filledByEsia: true },
|
|
7369
|
-
{ fieldType: 'common', name: 'middleName', dadata: true, filledByEsia: true },
|
|
7370
|
-
{ fieldType: 'common', name: 'sex', required: true },
|
|
7371
|
-
{ fieldType: 'common', name: 'limitedBirthday', required: true, filledByEsia: true },
|
|
7372
|
-
{ fieldType: 'common', name: 'birthPlace', required: true, filledByEsia: true },
|
|
7373
|
-
{ fieldType: 'common', name: 'phone', required: true, filledByEsia: true },
|
|
7374
|
-
{ fieldType: 'common', name: 'email', required: true, dadata: true },
|
|
7375
|
-
],
|
|
7376
|
-
},
|
|
7377
|
-
{
|
|
7378
|
-
title: 'Паспортные данные',
|
|
7379
|
-
columns: 2,
|
|
7380
|
-
inputs: [
|
|
7381
|
-
{ fieldType: 'common', name: 'dulSerie', required: true, filledByEsia: true },
|
|
7382
|
-
{ fieldType: 'common', name: 'dulNumber', required: true, filledByEsia: true },
|
|
7383
|
-
{ fieldType: 'common', name: 'dulIssueDateField', required: true, filledByEsia: true },
|
|
7384
|
-
{
|
|
7385
|
-
fieldType: 'common',
|
|
7386
|
-
name: 'dulSubdivisionCode',
|
|
7387
|
-
required: true,
|
|
7388
|
-
dadata: true,
|
|
7389
|
-
filledByEsia: true,
|
|
7390
|
-
},
|
|
7391
|
-
],
|
|
7392
|
-
},
|
|
7393
|
-
{
|
|
7394
|
-
inputs: [
|
|
7395
|
-
{
|
|
7396
|
-
fieldType: 'common',
|
|
7397
|
-
name: 'dulIssuedBy',
|
|
7398
|
-
required: true,
|
|
7399
|
-
dadata: true,
|
|
7400
|
-
filledByEsia: true,
|
|
7401
|
-
},
|
|
7402
|
-
{
|
|
7403
|
-
fieldType: 'common',
|
|
7404
|
-
name: 'education',
|
|
7405
|
-
required: true,
|
|
7406
|
-
},
|
|
7407
|
-
],
|
|
7408
|
-
},
|
|
7409
|
-
{
|
|
7410
|
-
title: 'Адрес регистрации по месту жительства',
|
|
7411
|
-
columns: 1,
|
|
7412
|
-
inputs: [],
|
|
7413
|
-
},
|
|
7414
|
-
{
|
|
7415
|
-
inputs: [
|
|
7416
|
-
{
|
|
7417
|
-
fieldType: 'common',
|
|
7418
|
-
name: 'addressRegistration',
|
|
7419
|
-
required: true,
|
|
7420
|
-
dadata: true,
|
|
7421
|
-
filledByEsia: true,
|
|
7422
|
-
},
|
|
7423
|
-
{ fieldType: 'common', name: 'addressMatch' },
|
|
7424
|
-
],
|
|
7425
|
-
},
|
|
7426
|
-
{
|
|
7427
|
-
columns: 2,
|
|
7428
|
-
inputs: [{ fieldType: 'common', name: 'participantDateRegistration', required: true }],
|
|
7429
|
-
},
|
|
7430
|
-
{
|
|
7431
|
-
title: 'Адрес фактического проживания (место пребывания РФ)',
|
|
7432
|
-
inputs: [],
|
|
7433
|
-
},
|
|
7434
|
-
{
|
|
7435
|
-
columns: 2,
|
|
7436
|
-
inputs: [{ fieldType: 'common', name: 'housing', required: true }],
|
|
7437
|
-
},
|
|
7438
|
-
{
|
|
7439
|
-
inputs: [{ fieldType: 'common', name: 'addressFact', required: true, dadata: true }],
|
|
7440
|
-
},
|
|
7441
|
-
],
|
|
7442
|
-
[
|
|
7443
|
-
{
|
|
7444
|
-
title: 'Данные о трудоустройстве',
|
|
7445
|
-
inputs: [],
|
|
7446
|
-
},
|
|
7447
|
-
{
|
|
7448
|
-
inputs: [
|
|
7449
|
-
{
|
|
7450
|
-
fieldType: 'info',
|
|
7451
|
-
text: 'Клиент на момент оформления заявки на кредит должен быть: официально трудоустроен более 6 месяцев, если Клиент получает з/п на счет РСХБ, то трудоустроен более 3 месяцев, не должен находиться в декретном отпуске',
|
|
7452
|
-
},
|
|
7453
|
-
],
|
|
7454
|
-
},
|
|
7455
|
-
{
|
|
7456
|
-
inputs: [
|
|
7457
|
-
{ fieldType: 'common', name: 'employment', required: true },
|
|
7458
|
-
{ fieldType: 'common', name: 'organizationName', required: true, dadata: true },
|
|
7459
|
-
],
|
|
7460
|
-
},
|
|
7461
|
-
{
|
|
7462
|
-
columns: 2,
|
|
7463
|
-
inputs: [
|
|
7464
|
-
{ fieldType: 'common', name: 'inn', required: true, dadata: true },
|
|
7465
|
-
{ fieldType: 'common', name: 'legalForm', required: true },
|
|
7466
|
-
],
|
|
7467
|
-
},
|
|
7468
|
-
{
|
|
7469
|
-
inputs: [
|
|
7470
|
-
{ fieldType: 'common', name: 'organization', required: true },
|
|
7471
|
-
{ fieldType: 'common', name: 'amountWorkers', required: true },
|
|
7472
|
-
],
|
|
7473
|
-
},
|
|
7474
|
-
{
|
|
7475
|
-
columns: 2,
|
|
7476
|
-
inputs: [
|
|
7477
|
-
{ fieldType: 'common', name: 'employerActivities', required: true },
|
|
7478
|
-
{ fieldType: 'common', name: 'employerOrganization', required: true },
|
|
7479
|
-
{ fieldType: 'common', name: 'generalSeniority', required: true },
|
|
7480
|
-
{ fieldType: 'common', name: 'lastJobExperience', required: true },
|
|
7481
|
-
{ fieldType: 'common', name: 'experience5Years', required: true },
|
|
7482
|
-
{ fieldType: 'common', name: 'jobsNumber', required: true },
|
|
7483
|
-
],
|
|
7484
|
-
},
|
|
7485
|
-
{
|
|
7486
|
-
inputs: [
|
|
7487
|
-
{
|
|
7488
|
-
fieldType: 'common',
|
|
7489
|
-
name: 'organizationPhone',
|
|
7490
|
-
label: 'Телефон работодателя',
|
|
7491
|
-
required: true,
|
|
7492
|
-
},
|
|
7493
|
-
{ fieldType: 'common', name: 'beginDate', required: true },
|
|
7494
|
-
],
|
|
7495
|
-
},
|
|
7496
|
-
{
|
|
7497
|
-
columns: 2,
|
|
7498
|
-
inputs: [
|
|
7499
|
-
{ fieldType: 'common', name: 'positionOrganization', required: true },
|
|
7500
|
-
{
|
|
7501
|
-
fieldType: 'common',
|
|
7502
|
-
name: 'partInBusiness',
|
|
7503
|
-
required: true,
|
|
7504
|
-
condition: { name: 'positionOrganization', values: ['BUSINESS_OWNER'] },
|
|
7505
|
-
},
|
|
7506
|
-
],
|
|
7507
|
-
},
|
|
7508
|
-
{
|
|
7509
|
-
title: 'Адрес работодателя',
|
|
7510
|
-
inputs: [],
|
|
7511
|
-
},
|
|
7512
|
-
{
|
|
7513
|
-
inputs: [{ fieldType: 'common', name: 'organizationAddress', required: true, dadata: true }],
|
|
7514
|
-
},
|
|
7515
|
-
],
|
|
7516
|
-
[
|
|
7517
|
-
{
|
|
7518
|
-
title: 'Семейное положение',
|
|
7519
|
-
},
|
|
7520
|
-
{
|
|
7521
|
-
columns: 1,
|
|
7522
|
-
inputs: [{ fieldType: 'common', name: 'familyStatus', required: true }],
|
|
7523
|
-
},
|
|
7524
|
-
{
|
|
7525
|
-
columns: 1,
|
|
7526
|
-
inputs: [{ fieldType: 'common', name: 'dependents', required: true }],
|
|
7527
|
-
},
|
|
7528
|
-
{
|
|
7529
|
-
columns: 2,
|
|
7530
|
-
inputs: [
|
|
7531
|
-
{ fieldType: 'common', name: 'familyMembers' },
|
|
7532
|
-
{ fieldType: 'common', name: 'children', required: true },
|
|
7533
|
-
],
|
|
7534
|
-
},
|
|
7535
|
-
{
|
|
7536
|
-
title: 'Совокупный доход',
|
|
7537
|
-
},
|
|
7538
|
-
{
|
|
7539
|
-
inputs: [
|
|
7540
|
-
{
|
|
7541
|
-
fieldType: 'info',
|
|
7542
|
-
text: 'Сумма основного и дополнительных доходов после вычета налога',
|
|
7543
|
-
},
|
|
7544
|
-
],
|
|
7545
|
-
},
|
|
7546
|
-
{
|
|
7547
|
-
columns: 1,
|
|
7548
|
-
inputs: [{ fieldType: 'common', name: 'confirmationIncome', required: true }],
|
|
7549
|
-
},
|
|
7550
|
-
{
|
|
7551
|
-
columns: 1,
|
|
7552
|
-
inputs: [{ fieldType: 'common', name: 'wages', required: true }],
|
|
7553
|
-
},
|
|
7554
|
-
{
|
|
7555
|
-
columns: 1,
|
|
7556
|
-
inputs: [{ fieldType: 'common', name: 'mandatoryPayments', required: true }],
|
|
7557
|
-
},
|
|
7558
|
-
{
|
|
7559
|
-
columns: 1,
|
|
7560
|
-
inputs: [{ fieldType: 'common', name: 'snils', required: true }],
|
|
7561
|
-
},
|
|
7562
|
-
{
|
|
7563
|
-
columns: 1,
|
|
7564
|
-
inputs: [{ fieldType: 'common', name: 'conscription', required: true }],
|
|
7565
|
-
},
|
|
7566
|
-
{
|
|
7567
|
-
columns: 2,
|
|
7568
|
-
inputs: [{ fieldType: 'common', name: 'armyIdFlg' }],
|
|
7569
|
-
},
|
|
7570
|
-
],
|
|
7571
|
-
[
|
|
7572
|
-
{
|
|
7573
|
-
title: 'Дополнительные сведения',
|
|
7574
|
-
columns: 1,
|
|
7575
|
-
inputs: [],
|
|
7576
|
-
},
|
|
7577
|
-
{
|
|
7578
|
-
inputs: [{ fieldType: 'common', name: 'disablePeopleFlg' }],
|
|
7184
|
+
housing: undefined,
|
|
7185
|
+
methodObtain: 'office',
|
|
7186
|
+
addressCourier: {
|
|
7187
|
+
fullAddress: '',
|
|
7188
|
+
fiasCode: '',
|
|
7579
7189
|
},
|
|
7580
|
-
|
|
7581
|
-
|
|
7190
|
+
},
|
|
7191
|
+
{
|
|
7192
|
+
amountWorkers: { key: '', text: '' },
|
|
7193
|
+
beginDate: undefined,
|
|
7194
|
+
employerActivities: { key: '', text: '' },
|
|
7195
|
+
employerOrganization: { key: '', text: '' },
|
|
7196
|
+
employment: { key: '', text: '' },
|
|
7197
|
+
experience5Years: undefined,
|
|
7198
|
+
inn: undefined,
|
|
7199
|
+
jobsNumber: undefined,
|
|
7200
|
+
lastJobExperience: undefined,
|
|
7201
|
+
legalForm: '',
|
|
7202
|
+
organization: { key: '', text: '' },
|
|
7203
|
+
organizationAddress: {
|
|
7204
|
+
fullAddress: '',
|
|
7205
|
+
fiasCode: '',
|
|
7582
7206
|
},
|
|
7583
|
-
|
|
7584
|
-
|
|
7207
|
+
organizationName: '',
|
|
7208
|
+
organizationPhone: '',
|
|
7209
|
+
partInBusiness: undefined,
|
|
7210
|
+
positionOrganization: { key: '', text: '' },
|
|
7211
|
+
},
|
|
7212
|
+
{
|
|
7213
|
+
familyStatus: { key: '', text: '' },
|
|
7214
|
+
dependents: undefined,
|
|
7215
|
+
familyMembers: undefined,
|
|
7216
|
+
confirmationIncome: { key: '', text: '' },
|
|
7217
|
+
wages: undefined,
|
|
7218
|
+
mandatoryPayments: undefined,
|
|
7219
|
+
snils: '',
|
|
7220
|
+
armyIdFlg: false,
|
|
7221
|
+
},
|
|
7222
|
+
{
|
|
7223
|
+
disablePeopleFlg: false,
|
|
7224
|
+
bankruptcyFlg: false,
|
|
7225
|
+
shareholderFlg: false,
|
|
7226
|
+
legalEntityName: '',
|
|
7227
|
+
creditInRshbCd: undefined,
|
|
7228
|
+
},
|
|
7229
|
+
{
|
|
7230
|
+
regionRetail: { key: '', text: '' },
|
|
7231
|
+
addressRetail: { key: '', text: '' },
|
|
7232
|
+
bankEmployeeCode: undefined,
|
|
7233
|
+
addressCourier: {
|
|
7234
|
+
fullAddress: '',
|
|
7235
|
+
fiasCode: '',
|
|
7585
7236
|
},
|
|
7586
|
-
|
|
7587
|
-
|
|
7588
|
-
|
|
7589
|
-
|
|
7590
|
-
|
|
7237
|
+
methodObtain: 'office',
|
|
7238
|
+
deliveryDate: undefined,
|
|
7239
|
+
},
|
|
7240
|
+
];
|
|
7241
|
+
|
|
7242
|
+
const getInitialFormState$1 = (step, formState) => ({
|
|
7243
|
+
...formStateMap$1[step],
|
|
7244
|
+
...formState,
|
|
7245
|
+
limitedBirthday: transformStringToData$1(formState?.limitedBirthday),
|
|
7246
|
+
dulIssueDateField: transformStringToData$1(formState?.dulIssueDateField),
|
|
7247
|
+
participantDateRegistration: transformStringToData$1(formState?.participantDateRegistration),
|
|
7248
|
+
beginDate: transformStringToData$1(formState?.beginDate),
|
|
7249
|
+
deliveryDate: transformStringToData$1(formState?.deliveryDate),
|
|
7250
|
+
});
|
|
7251
|
+
const transformStringToData$1 = (text) => {
|
|
7252
|
+
try {
|
|
7253
|
+
return text ? new Date(text) : undefined;
|
|
7254
|
+
}
|
|
7255
|
+
catch (_) {
|
|
7256
|
+
return undefined;
|
|
7257
|
+
}
|
|
7258
|
+
};
|
|
7259
|
+
|
|
7260
|
+
const useCreditCardFormAPI = ({ step, inputs, onNextStep, onFinish, }) => {
|
|
7261
|
+
const isFinalStep = step === 5;
|
|
7262
|
+
const retailFormStore = useRetailFormStore();
|
|
7263
|
+
const initialState = useMemo(() => getInitialFormState$1(step, retailFormStore.leadForm), [step, retailFormStore.leadForm]);
|
|
7264
|
+
const resetForm = useCallback((response) => {
|
|
7265
|
+
const { leadForm } = retailFormStore;
|
|
7266
|
+
if (isFinalStep && response.ok && leadForm) {
|
|
7267
|
+
retailFormStore.statusInfo = {
|
|
7268
|
+
regionRetail: leadForm?.regionRetail?.text,
|
|
7269
|
+
addressRetail: leadForm?.addressRetail?.text,
|
|
7270
|
+
cardCategory: leadForm?.cardCategory?.text,
|
|
7271
|
+
calculator: {
|
|
7272
|
+
monthsValue: leadForm?.calculator?.monthsValue,
|
|
7273
|
+
moneyValue: leadForm?.calculator?.moneyValue,
|
|
7274
|
+
isAnnuity: leadForm?.calculator?.isAnnuity,
|
|
7591
7275
|
},
|
|
7592
|
-
|
|
7593
|
-
|
|
7594
|
-
|
|
7595
|
-
|
|
7596
|
-
|
|
7597
|
-
|
|
7598
|
-
|
|
7599
|
-
|
|
7600
|
-
|
|
7601
|
-
|
|
7602
|
-
|
|
7603
|
-
|
|
7604
|
-
|
|
7605
|
-
|
|
7606
|
-
|
|
7607
|
-
|
|
7608
|
-
|
|
7609
|
-
|
|
7610
|
-
|
|
7611
|
-
|
|
7612
|
-
|
|
7613
|
-
|
|
7614
|
-
|
|
7615
|
-
|
|
7616
|
-
|
|
7617
|
-
|
|
7618
|
-
|
|
7619
|
-
|
|
7620
|
-
|
|
7621
|
-
|
|
7622
|
-
|
|
7276
|
+
};
|
|
7277
|
+
retailFormStore.leadForm = initialState;
|
|
7278
|
+
}
|
|
7279
|
+
}, [isFinalStep, initialState]);
|
|
7280
|
+
const handleSubmit = useCallback(async (formData) => {
|
|
7281
|
+
const feedbackValidator = objectValidator(getObjectValidator(calculateInputs$1(getValue$2(formData))(inputs, step)));
|
|
7282
|
+
if (!isValidationSuccess(feedbackValidator(formData))) {
|
|
7283
|
+
return;
|
|
7284
|
+
}
|
|
7285
|
+
retailFormStore.leadForm = formData;
|
|
7286
|
+
try {
|
|
7287
|
+
const { taskId, profileId, participantId } = retailFormStore;
|
|
7288
|
+
if (taskId && profileId && participantId) {
|
|
7289
|
+
const response = await updateUserTask(getCreditCardFormTaskData({
|
|
7290
|
+
participantId,
|
|
7291
|
+
taskId,
|
|
7292
|
+
profileId,
|
|
7293
|
+
step,
|
|
7294
|
+
formData: formData,
|
|
7295
|
+
}));
|
|
7296
|
+
resetForm(response);
|
|
7297
|
+
}
|
|
7298
|
+
onNextStep();
|
|
7299
|
+
if (isFinalStep) {
|
|
7300
|
+
onFinish?.();
|
|
7301
|
+
}
|
|
7302
|
+
}
|
|
7303
|
+
catch (ex) {
|
|
7304
|
+
// Do nothing
|
|
7305
|
+
}
|
|
7306
|
+
}, [isFinalStep, resetForm]);
|
|
7307
|
+
return [initialState, handleSubmit];
|
|
7308
|
+
};
|
|
7309
|
+
const getValue$2 = (formData) => (name) => formData[name];
|
|
7310
|
+
|
|
7311
|
+
const CreditCardFormStep = JSX(({ step, sections, isFormFinished, onPrevStep, onNextStep, onFinish }) => {
|
|
7312
|
+
const inputs = useMemo(() => (sections?.flatMap((_) => _?.inputs) || []), [sections]);
|
|
7313
|
+
const [initialState, onSubmit] = useCreditCardFormAPI({
|
|
7314
|
+
step,
|
|
7315
|
+
inputs,
|
|
7316
|
+
onNextStep,
|
|
7317
|
+
onFinish,
|
|
7318
|
+
});
|
|
7319
|
+
const [, { field, onSubmit: handleSubmit }] = useForm(initialState, { onSubmit });
|
|
7320
|
+
return isFormFinished ? (jsx(CreditCardFormStatusTracker, {})) : (jsxs("form", { onSubmit: handleSubmit, className: "space-y-m", children: [renderStep$2({ sections, field, step }), jsx(StepsNavigationButtons$1, { step: step, onPrevStep: onPrevStep })] }));
|
|
7321
|
+
});
|
|
7322
|
+
|
|
7323
|
+
const PERSONAL_INFO_CONTENT = [
|
|
7324
|
+
{
|
|
7325
|
+
title: 'Персональные данные',
|
|
7326
|
+
columns: 2,
|
|
7327
|
+
inputs: [
|
|
7328
|
+
{
|
|
7329
|
+
fieldType: 'common',
|
|
7330
|
+
name: 'surname',
|
|
7331
|
+
required: true,
|
|
7332
|
+
dadata: true,
|
|
7333
|
+
filledByEsia: true,
|
|
7334
|
+
},
|
|
7335
|
+
{ fieldType: 'common', name: 'name', required: true, dadata: true, filledByEsia: true },
|
|
7336
|
+
{ fieldType: 'common', name: 'middleName', dadata: true, filledByEsia: true },
|
|
7337
|
+
{ fieldType: 'common', name: 'sex', required: true },
|
|
7338
|
+
{ fieldType: 'common', name: 'limitedBirthday', required: true, filledByEsia: true },
|
|
7339
|
+
{ fieldType: 'common', name: 'birthPlace', required: true, filledByEsia: true },
|
|
7340
|
+
{ fieldType: 'common', name: 'phone', required: true, filledByEsia: true },
|
|
7341
|
+
{ fieldType: 'common', name: 'email', required: true, dadata: true },
|
|
7342
|
+
],
|
|
7343
|
+
},
|
|
7344
|
+
{
|
|
7345
|
+
title: 'Паспортные данные',
|
|
7346
|
+
columns: 2,
|
|
7347
|
+
inputs: [
|
|
7348
|
+
{ fieldType: 'common', name: 'dulSerie', required: true, filledByEsia: true },
|
|
7349
|
+
{ fieldType: 'common', name: 'dulNumber', required: true, filledByEsia: true },
|
|
7350
|
+
{ fieldType: 'common', name: 'dulIssueDateField', required: true, filledByEsia: true },
|
|
7351
|
+
{
|
|
7352
|
+
fieldType: 'common',
|
|
7353
|
+
name: 'dulSubdivisionCode',
|
|
7354
|
+
required: true,
|
|
7355
|
+
dadata: true,
|
|
7356
|
+
filledByEsia: true,
|
|
7357
|
+
},
|
|
7358
|
+
],
|
|
7359
|
+
},
|
|
7360
|
+
{
|
|
7361
|
+
inputs: [
|
|
7362
|
+
{
|
|
7363
|
+
fieldType: 'common',
|
|
7364
|
+
name: 'dulIssuedBy',
|
|
7365
|
+
required: true,
|
|
7366
|
+
dadata: true,
|
|
7367
|
+
filledByEsia: true,
|
|
7368
|
+
},
|
|
7369
|
+
{
|
|
7370
|
+
fieldType: 'common',
|
|
7371
|
+
name: 'education',
|
|
7372
|
+
required: true,
|
|
7373
|
+
},
|
|
7374
|
+
],
|
|
7375
|
+
},
|
|
7376
|
+
{
|
|
7377
|
+
title: 'Адрес регистрации по месту жительства',
|
|
7378
|
+
columns: 1,
|
|
7379
|
+
inputs: [],
|
|
7380
|
+
},
|
|
7381
|
+
{
|
|
7382
|
+
inputs: [
|
|
7383
|
+
{
|
|
7384
|
+
fieldType: 'common',
|
|
7385
|
+
name: 'addressRegistration',
|
|
7386
|
+
required: true,
|
|
7387
|
+
dadata: true,
|
|
7388
|
+
filledByEsia: true,
|
|
7389
|
+
},
|
|
7390
|
+
{ fieldType: 'common', name: 'addressMatch' },
|
|
7391
|
+
],
|
|
7392
|
+
},
|
|
7393
|
+
{
|
|
7394
|
+
columns: 2,
|
|
7395
|
+
inputs: [{ fieldType: 'common', name: 'participantDateRegistration', required: true }],
|
|
7396
|
+
},
|
|
7397
|
+
{
|
|
7398
|
+
title: 'Адрес фактического проживания (место пребывания РФ)',
|
|
7399
|
+
inputs: [],
|
|
7400
|
+
},
|
|
7401
|
+
{
|
|
7402
|
+
columns: 2,
|
|
7403
|
+
inputs: [{ fieldType: 'common', name: 'housing', required: true }],
|
|
7404
|
+
},
|
|
7405
|
+
{
|
|
7406
|
+
inputs: [{ fieldType: 'common', name: 'addressFact', required: true, dadata: true }],
|
|
7407
|
+
},
|
|
7408
|
+
];
|
|
7409
|
+
const EMPLOYMENT_CONTENT = [
|
|
7410
|
+
{
|
|
7411
|
+
title: 'Данные о трудоустройстве',
|
|
7412
|
+
inputs: [],
|
|
7413
|
+
},
|
|
7414
|
+
{
|
|
7415
|
+
inputs: [
|
|
7416
|
+
{
|
|
7417
|
+
fieldType: 'info',
|
|
7418
|
+
text: 'Клиент на момент оформления заявки на кредит должен быть: официально трудоустроен более 6 месяцев, ' +
|
|
7419
|
+
'если Клиент получает з/п на счет РСХБ, то трудоустроен более 3 месяцев, не должен находиться в декретном отпуске',
|
|
7420
|
+
},
|
|
7421
|
+
],
|
|
7422
|
+
},
|
|
7423
|
+
{
|
|
7424
|
+
inputs: [
|
|
7425
|
+
{ fieldType: 'common', name: 'employment', required: true },
|
|
7426
|
+
{ fieldType: 'common', name: 'organizationName', required: true, dadata: true },
|
|
7427
|
+
],
|
|
7428
|
+
},
|
|
7429
|
+
{
|
|
7430
|
+
columns: 2,
|
|
7431
|
+
inputs: [
|
|
7432
|
+
{ fieldType: 'common', name: 'inn', required: true, dadata: true },
|
|
7433
|
+
{ fieldType: 'common', name: 'legalForm', required: true },
|
|
7434
|
+
],
|
|
7435
|
+
},
|
|
7436
|
+
{
|
|
7437
|
+
inputs: [
|
|
7438
|
+
{ fieldType: 'common', name: 'organization', required: true },
|
|
7439
|
+
{ fieldType: 'common', name: 'amountWorkers', required: true },
|
|
7440
|
+
],
|
|
7441
|
+
},
|
|
7442
|
+
{
|
|
7443
|
+
columns: 2,
|
|
7444
|
+
inputs: [
|
|
7445
|
+
{ fieldType: 'common', name: 'employerActivities', required: true },
|
|
7446
|
+
{ fieldType: 'common', name: 'employerOrganization', required: true },
|
|
7447
|
+
{ fieldType: 'common', name: 'generalSeniority', required: true },
|
|
7448
|
+
{ fieldType: 'common', name: 'lastJobExperience', required: true },
|
|
7449
|
+
{ fieldType: 'common', name: 'experience5Years', required: true },
|
|
7450
|
+
{ fieldType: 'common', name: 'jobsNumber', required: true },
|
|
7451
|
+
],
|
|
7452
|
+
},
|
|
7453
|
+
{
|
|
7454
|
+
inputs: [
|
|
7455
|
+
{
|
|
7456
|
+
fieldType: 'common',
|
|
7457
|
+
name: 'organizationPhone',
|
|
7458
|
+
label: 'Телефон работодателя',
|
|
7459
|
+
required: true,
|
|
7460
|
+
},
|
|
7461
|
+
{ fieldType: 'common', name: 'beginDate', required: true },
|
|
7462
|
+
],
|
|
7463
|
+
},
|
|
7464
|
+
{
|
|
7465
|
+
columns: 2,
|
|
7466
|
+
inputs: [
|
|
7467
|
+
{ fieldType: 'common', name: 'positionOrganization', required: true },
|
|
7468
|
+
{
|
|
7469
|
+
fieldType: 'common',
|
|
7470
|
+
name: 'partInBusiness',
|
|
7471
|
+
required: true,
|
|
7472
|
+
condition: { name: 'positionOrganization', values: ['BUSINESS_OWNER'] },
|
|
7473
|
+
},
|
|
7474
|
+
],
|
|
7475
|
+
},
|
|
7476
|
+
{
|
|
7477
|
+
title: 'Адрес работодателя',
|
|
7478
|
+
inputs: [],
|
|
7479
|
+
},
|
|
7480
|
+
{
|
|
7481
|
+
inputs: [{ fieldType: 'common', name: 'organizationAddress', required: true, dadata: true }],
|
|
7482
|
+
},
|
|
7483
|
+
];
|
|
7484
|
+
const FAMILY_STATUS_AND_INCOME_CONTENT = [
|
|
7485
|
+
{
|
|
7486
|
+
title: 'Семейное положение',
|
|
7487
|
+
},
|
|
7488
|
+
{
|
|
7489
|
+
columns: 1,
|
|
7490
|
+
inputs: [{ fieldType: 'common', name: 'familyStatus', required: true }],
|
|
7491
|
+
},
|
|
7492
|
+
{
|
|
7493
|
+
columns: 1,
|
|
7494
|
+
inputs: [{ fieldType: 'common', name: 'dependents', required: true }],
|
|
7495
|
+
},
|
|
7496
|
+
{
|
|
7497
|
+
columns: 2,
|
|
7498
|
+
inputs: [
|
|
7499
|
+
{ fieldType: 'common', name: 'familyMembers' },
|
|
7500
|
+
{ fieldType: 'common', name: 'children', required: true },
|
|
7501
|
+
],
|
|
7502
|
+
},
|
|
7503
|
+
{
|
|
7504
|
+
title: 'Совокупный доход',
|
|
7505
|
+
},
|
|
7506
|
+
{
|
|
7507
|
+
inputs: [
|
|
7508
|
+
{
|
|
7509
|
+
fieldType: 'info',
|
|
7510
|
+
text: 'Сумма основного и дополнительных доходов после вычета налога',
|
|
7511
|
+
},
|
|
7512
|
+
],
|
|
7513
|
+
},
|
|
7514
|
+
{
|
|
7515
|
+
columns: 1,
|
|
7516
|
+
inputs: [{ fieldType: 'common', name: 'confirmationIncome', required: true }],
|
|
7517
|
+
},
|
|
7518
|
+
{
|
|
7519
|
+
columns: 1,
|
|
7520
|
+
inputs: [{ fieldType: 'common', name: 'wages', required: true }],
|
|
7521
|
+
},
|
|
7522
|
+
{
|
|
7523
|
+
columns: 1,
|
|
7524
|
+
inputs: [{ fieldType: 'common', name: 'mandatoryPayments', required: true }],
|
|
7525
|
+
},
|
|
7526
|
+
{
|
|
7527
|
+
columns: 1,
|
|
7528
|
+
inputs: [{ fieldType: 'common', name: 'snils', required: true }],
|
|
7529
|
+
},
|
|
7530
|
+
{
|
|
7531
|
+
columns: 1,
|
|
7532
|
+
inputs: [{ fieldType: 'common', name: 'conscription', required: true }],
|
|
7533
|
+
},
|
|
7534
|
+
{
|
|
7535
|
+
columns: 2,
|
|
7536
|
+
inputs: [{ fieldType: 'common', name: 'armyIdFlg' }],
|
|
7537
|
+
},
|
|
7538
|
+
];
|
|
7539
|
+
const ADDITIONAL_CONTENT = [
|
|
7540
|
+
{
|
|
7541
|
+
title: 'Дополнительные сведения',
|
|
7542
|
+
columns: 1,
|
|
7543
|
+
inputs: [],
|
|
7544
|
+
},
|
|
7545
|
+
{
|
|
7546
|
+
inputs: [{ fieldType: 'common', name: 'disablePeopleFlg' }],
|
|
7547
|
+
},
|
|
7548
|
+
{
|
|
7549
|
+
inputs: [{ fieldType: 'common', name: 'bankruptcyFlg' }],
|
|
7550
|
+
},
|
|
7551
|
+
{
|
|
7552
|
+
inputs: [{ fieldType: 'common', name: 'shareholderFlg' }],
|
|
7553
|
+
},
|
|
7554
|
+
{
|
|
7555
|
+
inputs: [{ fieldType: 'common', name: 'legalEntityName' }],
|
|
7556
|
+
},
|
|
7557
|
+
{
|
|
7558
|
+
inputs: [{ fieldType: 'common', name: 'creditInRshbCd' }],
|
|
7559
|
+
},
|
|
7560
|
+
];
|
|
7561
|
+
const COMMON_RETAIL_CONTENT = [
|
|
7562
|
+
PERSONAL_INFO_CONTENT,
|
|
7563
|
+
EMPLOYMENT_CONTENT,
|
|
7564
|
+
FAMILY_STATUS_AND_INCOME_CONTENT,
|
|
7565
|
+
ADDITIONAL_CONTENT,
|
|
7566
|
+
];
|
|
7567
|
+
const DELIVERY_CREDIT_CONTENT = [
|
|
7568
|
+
{
|
|
7569
|
+
title: 'Отделение Банка',
|
|
7570
|
+
columns: 1,
|
|
7571
|
+
inputs: [],
|
|
7572
|
+
},
|
|
7573
|
+
{
|
|
7574
|
+
inputs: [{ fieldType: 'common', name: 'regionRetail', required: true }],
|
|
7575
|
+
},
|
|
7576
|
+
{
|
|
7577
|
+
inputs: [{ fieldType: 'common', name: 'addressRetail', required: true }],
|
|
7578
|
+
},
|
|
7579
|
+
{
|
|
7580
|
+
title: 'Код представителя Банка',
|
|
7581
|
+
columns: 1,
|
|
7582
|
+
inputs: [],
|
|
7583
|
+
},
|
|
7584
|
+
{
|
|
7585
|
+
inputs: [
|
|
7586
|
+
{
|
|
7587
|
+
fieldType: 'info',
|
|
7588
|
+
text: 'Если представитель Банка помогал Вам в заведении заявки, введите здесь его код',
|
|
7589
|
+
},
|
|
7590
|
+
],
|
|
7591
|
+
},
|
|
7592
|
+
{
|
|
7593
|
+
inputs: [{ fieldType: 'common', name: 'bankEmployeeCode' }],
|
|
7594
|
+
},
|
|
7595
|
+
];
|
|
7596
|
+
const DELIVERY_CREDIT_CARD_CONTENT = [
|
|
7597
|
+
{
|
|
7598
|
+
title: 'Способ получения',
|
|
7599
|
+
columns: 1,
|
|
7600
|
+
inputs: [],
|
|
7601
|
+
},
|
|
7602
|
+
{
|
|
7603
|
+
inputs: [{ fieldType: 'common', name: 'methodObtain' }],
|
|
7604
|
+
},
|
|
7605
|
+
{
|
|
7606
|
+
title: 'Адрес',
|
|
7607
|
+
columns: 1,
|
|
7608
|
+
inputs: [],
|
|
7609
|
+
},
|
|
7610
|
+
{
|
|
7611
|
+
inputs: [
|
|
7612
|
+
{
|
|
7613
|
+
fieldType: 'common',
|
|
7614
|
+
name: 'addressCourier',
|
|
7615
|
+
dadata: true,
|
|
7616
|
+
condition: {
|
|
7617
|
+
name: 'methodObtain',
|
|
7618
|
+
values: ['courier'],
|
|
7623
7619
|
},
|
|
7624
|
-
|
|
7625
|
-
|
|
7626
|
-
|
|
7627
|
-
|
|
7628
|
-
|
|
7629
|
-
|
|
7630
|
-
|
|
7631
|
-
|
|
7620
|
+
required: true,
|
|
7621
|
+
},
|
|
7622
|
+
{
|
|
7623
|
+
fieldType: 'common',
|
|
7624
|
+
name: 'deliveryDate',
|
|
7625
|
+
condition: {
|
|
7626
|
+
name: 'methodObtain',
|
|
7627
|
+
values: ['courier'],
|
|
7632
7628
|
},
|
|
7633
|
-
|
|
7634
|
-
|
|
7635
|
-
|
|
7636
|
-
|
|
7637
|
-
|
|
7638
|
-
|
|
7639
|
-
|
|
7629
|
+
required: true,
|
|
7630
|
+
},
|
|
7631
|
+
{
|
|
7632
|
+
fieldType: 'common',
|
|
7633
|
+
name: 'comment',
|
|
7634
|
+
condition: {
|
|
7635
|
+
name: 'methodObtain',
|
|
7636
|
+
values: ['courier'],
|
|
7640
7637
|
},
|
|
7641
|
-
|
|
7642
|
-
|
|
7643
|
-
|
|
7644
|
-
|
|
7645
|
-
|
|
7646
|
-
|
|
7647
|
-
|
|
7648
|
-
|
|
7649
|
-
|
|
7650
|
-
|
|
7651
|
-
|
|
7652
|
-
|
|
7638
|
+
},
|
|
7639
|
+
],
|
|
7640
|
+
},
|
|
7641
|
+
{
|
|
7642
|
+
inputs: [
|
|
7643
|
+
{
|
|
7644
|
+
fieldType: 'common',
|
|
7645
|
+
name: 'regionRetail',
|
|
7646
|
+
required: true,
|
|
7647
|
+
condition: {
|
|
7648
|
+
name: 'methodObtain',
|
|
7649
|
+
values: ['office'],
|
|
7653
7650
|
},
|
|
7654
|
-
|
|
7655
|
-
|
|
7656
|
-
|
|
7657
|
-
|
|
7658
|
-
|
|
7659
|
-
|
|
7660
|
-
|
|
7661
|
-
|
|
7651
|
+
},
|
|
7652
|
+
{
|
|
7653
|
+
fieldType: 'common',
|
|
7654
|
+
name: 'addressRetail',
|
|
7655
|
+
required: true,
|
|
7656
|
+
condition: {
|
|
7657
|
+
name: 'methodObtain',
|
|
7658
|
+
values: ['office'],
|
|
7662
7659
|
},
|
|
7663
|
-
|
|
7664
|
-
|
|
7665
|
-
|
|
7666
|
-
|
|
7667
|
-
|
|
7668
|
-
|
|
7669
|
-
|
|
7670
|
-
|
|
7671
|
-
|
|
7672
|
-
|
|
7673
|
-
|
|
7660
|
+
},
|
|
7661
|
+
],
|
|
7662
|
+
},
|
|
7663
|
+
{
|
|
7664
|
+
inputs: [
|
|
7665
|
+
{
|
|
7666
|
+
fieldType: 'info',
|
|
7667
|
+
text: 'Если представитель Банка помогал Вам в заведении заявки, введите здесь его код',
|
|
7668
|
+
condition: {
|
|
7669
|
+
name: 'methodObtain',
|
|
7670
|
+
values: ['office'],
|
|
7674
7671
|
},
|
|
7675
|
-
|
|
7676
|
-
|
|
7677
|
-
|
|
7678
|
-
|
|
7679
|
-
|
|
7680
|
-
|
|
7681
|
-
|
|
7672
|
+
},
|
|
7673
|
+
{
|
|
7674
|
+
fieldType: 'common',
|
|
7675
|
+
name: 'bankEmployeeCode',
|
|
7676
|
+
condition: {
|
|
7677
|
+
name: 'methodObtain',
|
|
7678
|
+
values: ['office'],
|
|
7682
7679
|
},
|
|
7683
|
-
|
|
7684
|
-
|
|
7685
|
-
|
|
7680
|
+
},
|
|
7681
|
+
],
|
|
7682
|
+
},
|
|
7683
|
+
];
|
|
7684
|
+
const CREDIT_CARD_CONTENT = [
|
|
7685
|
+
{
|
|
7686
|
+
title: 'Параметры карты',
|
|
7687
|
+
inputs: [],
|
|
7688
|
+
},
|
|
7689
|
+
{
|
|
7690
|
+
inputs: [
|
|
7691
|
+
{ fieldType: 'common', name: 'currency', required: true },
|
|
7692
|
+
{ fieldType: 'common', name: 'paymentSystem', required: true },
|
|
7693
|
+
{ fieldType: 'common', name: 'cardCategory', required: true },
|
|
7694
|
+
{ fieldType: 'common', name: 'codeWord', required: true },
|
|
7695
|
+
],
|
|
7696
|
+
},
|
|
7697
|
+
];
|
|
7698
|
+
const CALCULATOR_CONTENT = [
|
|
7699
|
+
{
|
|
7700
|
+
columns: 1,
|
|
7701
|
+
inputs: [
|
|
7702
|
+
{
|
|
7703
|
+
fieldType: 'common',
|
|
7704
|
+
name: 'calculator',
|
|
7705
|
+
},
|
|
7706
|
+
],
|
|
7707
|
+
},
|
|
7708
|
+
];
|
|
7709
|
+
|
|
7710
|
+
const stepsSectionsMap$1 = [
|
|
7711
|
+
CREDIT_CARD_CONTENT,
|
|
7712
|
+
...COMMON_RETAIL_CONTENT,
|
|
7713
|
+
DELIVERY_CREDIT_CARD_CONTENT,
|
|
7686
7714
|
];
|
|
7687
7715
|
|
|
7688
7716
|
const STEPS$1 = 6;
|
|
@@ -7709,8 +7737,8 @@
|
|
|
7709
7737
|
scrollToTop();
|
|
7710
7738
|
}, []);
|
|
7711
7739
|
const sections = useMemo(() => stepsSectionsMap$1[step], [step]);
|
|
7712
|
-
const [isFormFinished,
|
|
7713
|
-
return (jsx(BlockWrapper, { className: className, ...rest, children: jsxs("div", { ref: formContainerRef, className: "container grid grid-cols-12", children: [isFormFinished ? null : (jsx(CreditCardFormProgress, { stepsTitles: TITLES, step: step, totalSteps: STEPS$1 })), jsx("div", { className: "py-lg px-5xl mt-2xs bg-white col-span-12", children: jsx(CreditCardFormStep, { step: step, sections: sections, onNextStep: handleNextStep, onPrevStep: handlePrevStep,
|
|
7740
|
+
const [isFormFinished, { setTrue: handleFinish }] = useBool(false);
|
|
7741
|
+
return (jsx(BlockWrapper, { className: className, ...rest, children: jsxs("div", { ref: formContainerRef, className: "container grid grid-cols-12", children: [isFormFinished ? null : (jsx(CreditCardFormProgress, { stepsTitles: TITLES, step: step, totalSteps: STEPS$1 })), jsx("div", { className: "py-lg px-5xl mt-2xs bg-white col-span-12", children: jsx(CreditCardFormStep, { step: step, sections: sections, isFormFinished: isFormFinished, onNextStep: handleNextStep, onPrevStep: handlePrevStep, onFinish: handleFinish }, String(step)) })] }) }));
|
|
7714
7742
|
});
|
|
7715
7743
|
|
|
7716
7744
|
const CreditFormProgress = JSX(({ step = 1, totalSteps = 5, stepsTitles = [] }) => {
|
|
@@ -7737,7 +7765,7 @@
|
|
|
7737
7765
|
const FailedStatusContent = JSX(() => (jsx(CreditFormStatus, { title: "\u0411\u043B\u0430\u0433\u043E\u0434\u0430\u0440\u0438\u043C \u0412\u0430\u0441 \u0437\u0430 \u043E\u0436\u0438\u0434\u0430\u043D\u0438\u0435", description: "\u0412 \u043D\u0430\u0441\u0442\u043E\u044F\u0449\u0438\u0439 \u043C\u043E\u043C\u0435\u043D\u0442 \u0411\u0430\u043D\u043A \u043D\u0435 \u043C\u043E\u0436\u0435\u0442 \u043E\u0434\u043E\u0431\u0440\u0438\u0442\u044C \u0412\u0430\u0448\u0443 \u0437\u0430\u044F\u0432\u043A\u0443 \u043D\u0430 \u043A\u0440\u0435\u0434\u0438\u0442. \u041F\u043E\u043F\u0440\u043E\u0431\u0443\u0439\u0442\u0435 \u043F\u043E\u0434\u0430\u0442\u044C \u0437\u0430\u044F\u0432\u043A\u0443 \u043F\u043E\u0437\u0436\u0435. \u0421\u043F\u0430\u0441\u0438\u0431\u043E \u0437\u0430 \u043E\u0431\u0440\u0430\u0449\u0435\u043D\u0438\u0435 \u0432 \u0410\u041E \u00AB\u0420\u043E\u0441\u0441\u0435\u043B\u044C\u0445\u043E\u0437\u0431\u0430\u043D\u043A\u00BB.", buttonText: "\u0412\u0435\u0440\u043D\u0443\u0442\u044C\u0441\u044F \u043D\u0430 \u0433\u043B\u0430\u0432\u043D\u0443\u044E" })));
|
|
7738
7766
|
|
|
7739
7767
|
const PendingStatusContent = JSX(({ handleExpireTimer }) => {
|
|
7740
|
-
const
|
|
7768
|
+
const { statusInfo } = useRetailFormStore();
|
|
7741
7769
|
return (jsx(CreditFormStatus, { interval: 300, intervalExpireAction: handleExpireTimer, title: "\u0417\u0430\u044F\u0432\u043A\u0430 \u0443\u0441\u043F\u0435\u0448\u043D\u043E \u043E\u0442\u043F\u0440\u0430\u0432\u043B\u0435\u043D\u0430", description: "\u041D\u0435 \u0437\u0430\u043A\u0440\u044B\u0432\u0430\u0439\u0442\u0435 \u043E\u043A\u043D\u043E, \u0441\u043A\u043E\u0440\u043E \u0441\u043E\u043E\u0431\u0449\u0438\u043C \u0440\u0435\u0437\u0443\u043B\u044C\u0442\u0430\u0442", sectionInfoTitle: "\u0417\u0430\u044F\u0432\u043B\u0435\u043D\u043D\u044B\u0435 \u0443\u0441\u043B\u043E\u0432\u0438\u044F \u043F\u043E \u043A\u0440\u0435\u0434\u0438\u0442\u0443", sectionInfo: [
|
|
7742
7770
|
{
|
|
7743
7771
|
label: 'Название продукта',
|
|
@@ -7763,7 +7791,7 @@
|
|
|
7763
7791
|
});
|
|
7764
7792
|
|
|
7765
7793
|
const ReworkStatusContent = JSX(() => {
|
|
7766
|
-
const
|
|
7794
|
+
const { statusInfo } = useRetailFormStore();
|
|
7767
7795
|
return (jsx(CreditFormStatus, { title: "\u0411\u043B\u0430\u0433\u043E\u0434\u0430\u0440\u0438\u043C \u0432\u0430\u0441 \u0437\u0430 \u043E\u0436\u0438\u0434\u0430\u043D\u0438\u0435, \u043D\u043E \u043D\u0430\u043C \u0442\u0440\u0435\u0431\u0443\u0435\u0442\u0441\u044F \u0431\u043E\u043B\u044C\u0448\u0435 \u0432\u0440\u0435\u043C\u0435\u043D\u0438 \u0434\u043B\u044F \u043F\u0440\u0438\u043D\u044F\u0442\u0438\u044F \u0440\u0435\u0448\u0435\u043D\u0438\u044F", description: "\u041F\u043E\u0441\u0435\u0442\u0438\u0442\u0435 \u0432\u044B\u0431\u0440\u0430\u043D\u043D\u043E\u0435 \u043E\u0442\u0434\u0435\u043B\u0435\u043D\u0438\u0435 \u0431\u0430\u043D\u043A\u0430 \u0441 \u043D\u0435\u043E\u0431\u0445\u043E\u0434\u0438\u043C\u044B\u043C\u0438 \u0434\u043E\u043A\u0443\u043C\u0435\u043D\u0442\u0430\u043C\u0438 \u0438 \u0442\u0430\u043A \u0437\u0430\u0432\u0435\u0440\u0448\u0438\u0442\u0435 \u043E\u0444\u043E\u0440\u043C\u043B\u0435\u043D\u0438\u0435 \u043A\u0440\u0435\u0434\u0438\u0442\u0430.", sectionAdditionalTitle: "\u0412 \u043E\u0442\u0434\u0435\u043B\u0435\u043D\u0438\u0438 \u0411\u0430\u043D\u043A\u0430", sectionInfoAdditional: [
|
|
7768
7796
|
{
|
|
7769
7797
|
label: 'Регион',
|
|
@@ -7782,7 +7810,7 @@
|
|
|
7782
7810
|
});
|
|
7783
7811
|
|
|
7784
7812
|
const SuccessStatusContent = JSX(() => {
|
|
7785
|
-
const
|
|
7813
|
+
const { statusInfo } = useRetailFormStore();
|
|
7786
7814
|
return (jsx(CreditFormStatus, { title: "\u0411\u0430\u043D\u043A \u043E\u0434\u043E\u0431\u0440\u0438\u043B \u0432\u0430\u043C \u043A\u0440\u0435\u0434\u0438\u0442", description: "\u041E\u0431\u0440\u0430\u0442\u0438\u0442\u0435\u0441\u044C \u0432 \u043E\u0442\u0434\u0435\u043B\u0435\u043D\u0438\u0435 \u0431\u0430\u043D\u043A\u0430, \u0447\u0442\u043E\u0431\u044B \u0437\u0430\u0432\u0435\u0440\u0448\u0438\u0442\u044C \u043E\u0444\u043E\u0440\u043C\u043B\u0435\u043D\u0438\u0435 \u0438 \u043F\u043E\u043B\u0443\u0447\u0438\u0442 \u0432\u0430\u0448 \u043A\u0440\u0435\u0434\u0438\u0442", sectionInfo: [
|
|
7787
7815
|
{
|
|
7788
7816
|
label: 'Название продукта',
|
|
@@ -7813,7 +7841,7 @@
|
|
|
7813
7841
|
];
|
|
7814
7842
|
const CreditFormStatusTracker = JSX(() => {
|
|
7815
7843
|
const [status, setStatus] = useState(STATUS_TYPE.process);
|
|
7816
|
-
const
|
|
7844
|
+
const { taskId } = useRetailFormStore();
|
|
7817
7845
|
useEffect(() => {
|
|
7818
7846
|
(async () => {
|
|
7819
7847
|
for (const signalType of SIGNAL_TYPES) {
|
|
@@ -7842,109 +7870,6 @@
|
|
|
7842
7870
|
return statusesMap[status] || jsx(ReworkStatusContent, {});
|
|
7843
7871
|
};
|
|
7844
7872
|
|
|
7845
|
-
const formStateMap = [
|
|
7846
|
-
{
|
|
7847
|
-
calculator: {
|
|
7848
|
-
moneyValue: 0,
|
|
7849
|
-
monthsValue: 0,
|
|
7850
|
-
isAnnuity: false,
|
|
7851
|
-
isInsurance: false,
|
|
7852
|
-
isSalaryClient: false,
|
|
7853
|
-
isPensionClient: false,
|
|
7854
|
-
isStateEmployee: false,
|
|
7855
|
-
},
|
|
7856
|
-
},
|
|
7857
|
-
{
|
|
7858
|
-
surname: '',
|
|
7859
|
-
name: '',
|
|
7860
|
-
middleName: '',
|
|
7861
|
-
sex: '',
|
|
7862
|
-
limitedBirthday: undefined,
|
|
7863
|
-
birthPlace: '',
|
|
7864
|
-
phone: '',
|
|
7865
|
-
email: '',
|
|
7866
|
-
dulSerie: undefined,
|
|
7867
|
-
dulNumber: undefined,
|
|
7868
|
-
dulIssueDateField: undefined,
|
|
7869
|
-
dulSubdivisionCode: '',
|
|
7870
|
-
dulIssuedBy: '',
|
|
7871
|
-
addressRegistration: {
|
|
7872
|
-
fullAddress: '',
|
|
7873
|
-
fiasCode: '',
|
|
7874
|
-
},
|
|
7875
|
-
participantDateRegistration: undefined,
|
|
7876
|
-
addressFact: {
|
|
7877
|
-
fullAddress: '',
|
|
7878
|
-
fiasCode: '',
|
|
7879
|
-
},
|
|
7880
|
-
housing: undefined,
|
|
7881
|
-
},
|
|
7882
|
-
{
|
|
7883
|
-
amountWorkers: { key: '', text: '' },
|
|
7884
|
-
beginDate: undefined,
|
|
7885
|
-
employerActivities: { key: '', text: '' },
|
|
7886
|
-
employerOrganization: { key: '', text: '' },
|
|
7887
|
-
employment: { key: '', text: '' },
|
|
7888
|
-
experience5Years: undefined,
|
|
7889
|
-
inn: undefined,
|
|
7890
|
-
jobsNumber: undefined,
|
|
7891
|
-
lastJobExperience: undefined,
|
|
7892
|
-
legalForm: '',
|
|
7893
|
-
organization: { key: '', text: '' },
|
|
7894
|
-
organizationAddress: {
|
|
7895
|
-
fullAddress: '',
|
|
7896
|
-
fiasCode: '',
|
|
7897
|
-
},
|
|
7898
|
-
organizationName: '',
|
|
7899
|
-
organizationPhone: '',
|
|
7900
|
-
partInBusiness: undefined,
|
|
7901
|
-
positionOrganization: { key: '', text: '' },
|
|
7902
|
-
},
|
|
7903
|
-
{
|
|
7904
|
-
familyStatus: { key: '', text: '' },
|
|
7905
|
-
dependents: undefined,
|
|
7906
|
-
familyMembers: undefined,
|
|
7907
|
-
confirmationIncome: { key: '', text: '' },
|
|
7908
|
-
wages: undefined,
|
|
7909
|
-
mandatoryPayments: undefined,
|
|
7910
|
-
snils: '',
|
|
7911
|
-
armyIdFlg: false,
|
|
7912
|
-
},
|
|
7913
|
-
{
|
|
7914
|
-
disablePeopleFlg: false,
|
|
7915
|
-
bankruptcyFlg: false,
|
|
7916
|
-
shareholderFlg: false,
|
|
7917
|
-
legalEntityName: '',
|
|
7918
|
-
creditInRshbCd: undefined,
|
|
7919
|
-
},
|
|
7920
|
-
{
|
|
7921
|
-
regionRetail: { key: '', text: '' },
|
|
7922
|
-
addressRetail: undefined,
|
|
7923
|
-
bankEmployeeCode: undefined,
|
|
7924
|
-
},
|
|
7925
|
-
];
|
|
7926
|
-
|
|
7927
|
-
const getInitialFormState = (step, localStorageData) => ({
|
|
7928
|
-
...formStateMap[step],
|
|
7929
|
-
...localStorageData,
|
|
7930
|
-
limitedBirthday: transformStringToData(localStorageData?.limitedBirthday),
|
|
7931
|
-
dulIssueDateField: transformStringToData(localStorageData?.dulIssueDateField),
|
|
7932
|
-
participantDateRegistration: transformStringToData(localStorageData?.participantDateRegistration),
|
|
7933
|
-
beginDate: transformStringToData(localStorageData?.beginDate),
|
|
7934
|
-
deliveryDate: transformStringToData(localStorageData?.deliveryDate),
|
|
7935
|
-
});
|
|
7936
|
-
const transformStringToData = (text) => {
|
|
7937
|
-
if (!text) {
|
|
7938
|
-
return undefined;
|
|
7939
|
-
}
|
|
7940
|
-
try {
|
|
7941
|
-
return new Date(text);
|
|
7942
|
-
}
|
|
7943
|
-
catch (_) {
|
|
7944
|
-
return undefined;
|
|
7945
|
-
}
|
|
7946
|
-
};
|
|
7947
|
-
|
|
7948
7873
|
const calculateInputs = (getValue) => (inputs, step) => inputs
|
|
7949
7874
|
.filter((_) => _)
|
|
7950
7875
|
.map((_) => {
|
|
@@ -7999,108 +7924,14 @@
|
|
|
7999
7924
|
};
|
|
8000
7925
|
const getCalcData = (formData) => {
|
|
8001
7926
|
const { moneyValue, monthsValue, isAnnuity } = formData?.calculator ?? {};
|
|
8002
|
-
return {
|
|
8003
|
-
loanAmount: moneyValue,
|
|
8004
|
-
creditPeriod: monthsValue,
|
|
8005
|
-
paymentTypeCd: PAYMENT_TYPE_DATA[isAnnuity ? 'annuity' : 'differential'],
|
|
8006
|
-
};
|
|
8007
|
-
};
|
|
8008
|
-
|
|
8009
|
-
const getFifthStepData = (formData) => {
|
|
8010
|
-
const { addressRetail } = formData;
|
|
8011
|
-
return {
|
|
8012
|
-
office: addressRetail?.key ? { id: addressRetail.key } : undefined,
|
|
8013
|
-
};
|
|
8014
|
-
};
|
|
8015
|
-
|
|
8016
|
-
const getFirstStepData = (formData) => {
|
|
8017
|
-
const { name, surname, middleName, limitedBirthday = '', phone = '', email, sex, birthPlace, dulIssueDateField = '', dulIssuedBy, dulNumber, dulSerie, dulSubdivisionCode, education, participantDateRegistration = '', housing, addressRegistration, addressFact, } = formData;
|
|
8018
|
-
return {
|
|
8019
|
-
birthDate: formatDate(limitedBirthday, true),
|
|
8020
|
-
midname: middleName,
|
|
8021
|
-
name,
|
|
8022
|
-
surname,
|
|
8023
|
-
birthPlace,
|
|
8024
|
-
dulIssueDate: formatDate(dulIssueDateField, true),
|
|
8025
|
-
dulIssuedBy,
|
|
8026
|
-
dulNumber,
|
|
8027
|
-
dulSerie,
|
|
8028
|
-
dulSubdivisionCode,
|
|
8029
|
-
educationLevelCd: education,
|
|
8030
|
-
registrationDate: formatDate(participantDateRegistration, true),
|
|
8031
|
-
houseTypeCd: housing,
|
|
8032
|
-
participantContacts: getParticipantContacts({
|
|
8033
|
-
phone: formatPhone(phone),
|
|
8034
|
-
email,
|
|
8035
|
-
}),
|
|
8036
|
-
participantAddresses: getParticipantAddresses({ addressRegistration, addressFact }),
|
|
8037
|
-
genderCd: sex
|
|
8038
|
-
? {
|
|
8039
|
-
key: sex === 'male' ? 'MAN' : 'WOMAN',
|
|
8040
|
-
}
|
|
8041
|
-
: undefined,
|
|
8042
|
-
};
|
|
8043
|
-
};
|
|
8044
|
-
|
|
8045
|
-
const getFourthStepData = (formData) => {
|
|
8046
|
-
const { bankruptcyFlg, shareholderFlg, legalEntityName, creditInRshbCd } = formData;
|
|
8047
|
-
return {
|
|
8048
|
-
bankruptcyFlg,
|
|
8049
|
-
shareholderFlg,
|
|
8050
|
-
nameLegalEntity: legalEntityName,
|
|
8051
|
-
creditInRshbCd,
|
|
8052
|
-
};
|
|
8053
|
-
};
|
|
8054
|
-
|
|
8055
|
-
const getSecondStepData = (formData) => {
|
|
8056
|
-
const { beginDate, employment, organizationName, inn, legalForm, organization, amountWorkers, employerActivities, employerOrganization, generalSeniority, lastJobExperience, experience5Years, jobsNumber, organizationPhone, organizationAddress, positionOrganization, } = formData;
|
|
8057
|
-
return {
|
|
8058
|
-
employmentContractDate: formatDate(beginDate || '', true),
|
|
8059
|
-
employmentTypeCd: employment,
|
|
8060
|
-
organizationName,
|
|
8061
|
-
organizationInn: inn,
|
|
8062
|
-
organizationActivityTypeCd: employerActivities,
|
|
8063
|
-
organizationTypeCd: organization,
|
|
8064
|
-
organizationKindCd: employerOrganization,
|
|
8065
|
-
employeesNumberCd: amountWorkers,
|
|
8066
|
-
opf: legalForm,
|
|
8067
|
-
seniority: generalSeniority,
|
|
8068
|
-
generalSeniority: experience5Years,
|
|
8069
|
-
jobsNumber,
|
|
8070
|
-
lastWorkDuration: lastJobExperience,
|
|
8071
|
-
positionCd: positionOrganization,
|
|
8072
|
-
participantContacts: getParticipantContacts({
|
|
8073
|
-
organizationPhone: organizationPhone && formatPhone(organizationPhone),
|
|
8074
|
-
}),
|
|
8075
|
-
participantAddresses: getParticipantAddresses({ organizationAddress }),
|
|
8076
|
-
};
|
|
8077
|
-
};
|
|
8078
|
-
|
|
8079
|
-
const getThirdStepData = (formData) => {
|
|
8080
|
-
const { familyStatus, dependents, familyMembers, children, confirmationIncome, wages, mandatoryPayments, incomeAverage, additionalIncome, otherIncome, otherPayments, rentalIncome, retirementIncome, snils, armyIdFlg, conscription, } = formData;
|
|
8081
|
-
return {
|
|
8082
|
-
maritalStatusCd: familyStatus,
|
|
8083
|
-
totalDependents: familyMembers,
|
|
8084
|
-
incomeCertificateCd: confirmationIncome,
|
|
8085
|
-
otherDependents: dependents,
|
|
8086
|
-
childrenDependents: children,
|
|
8087
|
-
militaryStatusCd: conscription,
|
|
8088
|
-
participantIncomes: getParticipantIncomes({
|
|
8089
|
-
wages,
|
|
8090
|
-
mandatoryPayments,
|
|
8091
|
-
incomeAverage,
|
|
8092
|
-
additionalIncome,
|
|
8093
|
-
otherIncome,
|
|
8094
|
-
otherPayments,
|
|
8095
|
-
rentalIncome,
|
|
8096
|
-
retirementIncome,
|
|
8097
|
-
}),
|
|
8098
|
-
snils: snils?.replaceAll(' ', '').replaceAll('-', ''),
|
|
8099
|
-
armyIdFlg,
|
|
7927
|
+
return {
|
|
7928
|
+
loanAmount: moneyValue,
|
|
7929
|
+
creditPeriod: monthsValue,
|
|
7930
|
+
paymentTypeCd: PAYMENT_TYPE_DATA[isAnnuity ? 'annuity' : 'differential'],
|
|
8100
7931
|
};
|
|
8101
7932
|
};
|
|
8102
7933
|
|
|
8103
|
-
const
|
|
7934
|
+
const getCalculatorData = (formData) => {
|
|
8104
7935
|
const { isInsurance, isSalaryClient } = formData?.calculator ?? {};
|
|
8105
7936
|
return {
|
|
8106
7937
|
payrollCardRshbFlg: isInsurance,
|
|
@@ -8108,6 +7939,13 @@
|
|
|
8108
7939
|
};
|
|
8109
7940
|
};
|
|
8110
7941
|
|
|
7942
|
+
const getDeliveryCreditData = (formData) => {
|
|
7943
|
+
const { addressRetail } = formData;
|
|
7944
|
+
return {
|
|
7945
|
+
office: addressRetail?.key ? { id: addressRetail.key } : undefined,
|
|
7946
|
+
};
|
|
7947
|
+
};
|
|
7948
|
+
|
|
8111
7949
|
const getCreditFormTaskData = ({ participantId, taskId, profileId, formData, step = 0, }) => {
|
|
8112
7950
|
const navigator = locationNavigator();
|
|
8113
7951
|
return {
|
|
@@ -8131,7 +7969,7 @@
|
|
|
8131
7969
|
},
|
|
8132
7970
|
],
|
|
8133
7971
|
...getCalcData(formData),
|
|
8134
|
-
...
|
|
7972
|
+
...getDeliveryCreditData(formData),
|
|
8135
7973
|
esiaAccountTypeCd: {
|
|
8136
7974
|
key: formData?.esiaAccountTypeCd?.key,
|
|
8137
7975
|
},
|
|
@@ -8141,34 +7979,148 @@
|
|
|
8141
7979
|
const getCurrentStepData = (step, formData) => {
|
|
8142
7980
|
switch (step) {
|
|
8143
7981
|
case 0:
|
|
8144
|
-
return
|
|
7982
|
+
return getCalculatorData(formData);
|
|
8145
7983
|
case 1:
|
|
8146
|
-
return
|
|
7984
|
+
return getPersonalInfoData(formData);
|
|
8147
7985
|
case 2:
|
|
8148
|
-
return
|
|
7986
|
+
return getEmploymentData(formData);
|
|
8149
7987
|
case 3:
|
|
8150
|
-
return
|
|
7988
|
+
return getFamilyStatusAndIncomeData(formData);
|
|
8151
7989
|
case 4:
|
|
8152
|
-
return
|
|
7990
|
+
return getAdditionalInfoData(formData);
|
|
8153
7991
|
default:
|
|
8154
7992
|
return {};
|
|
8155
7993
|
}
|
|
8156
7994
|
};
|
|
8157
7995
|
|
|
8158
|
-
const
|
|
7996
|
+
const formStateMap = [
|
|
7997
|
+
{
|
|
7998
|
+
calculator: {
|
|
7999
|
+
moneyValue: 0,
|
|
8000
|
+
monthsValue: 0,
|
|
8001
|
+
isAnnuity: false,
|
|
8002
|
+
isInsurance: false,
|
|
8003
|
+
isSalaryClient: false,
|
|
8004
|
+
isPensionClient: false,
|
|
8005
|
+
isStateEmployee: false,
|
|
8006
|
+
},
|
|
8007
|
+
},
|
|
8008
|
+
{
|
|
8009
|
+
surname: '',
|
|
8010
|
+
name: '',
|
|
8011
|
+
middleName: '',
|
|
8012
|
+
sex: '',
|
|
8013
|
+
limitedBirthday: undefined,
|
|
8014
|
+
birthPlace: '',
|
|
8015
|
+
phone: '',
|
|
8016
|
+
email: '',
|
|
8017
|
+
dulSerie: undefined,
|
|
8018
|
+
dulNumber: undefined,
|
|
8019
|
+
dulIssueDateField: undefined,
|
|
8020
|
+
dulSubdivisionCode: '',
|
|
8021
|
+
dulIssuedBy: '',
|
|
8022
|
+
addressRegistration: {
|
|
8023
|
+
fullAddress: '',
|
|
8024
|
+
fiasCode: '',
|
|
8025
|
+
},
|
|
8026
|
+
participantDateRegistration: undefined,
|
|
8027
|
+
addressFact: {
|
|
8028
|
+
fullAddress: '',
|
|
8029
|
+
fiasCode: '',
|
|
8030
|
+
},
|
|
8031
|
+
housing: undefined,
|
|
8032
|
+
},
|
|
8033
|
+
{
|
|
8034
|
+
amountWorkers: { key: '', text: '' },
|
|
8035
|
+
beginDate: undefined,
|
|
8036
|
+
employerActivities: { key: '', text: '' },
|
|
8037
|
+
employerOrganization: { key: '', text: '' },
|
|
8038
|
+
employment: { key: '', text: '' },
|
|
8039
|
+
experience5Years: undefined,
|
|
8040
|
+
inn: undefined,
|
|
8041
|
+
jobsNumber: undefined,
|
|
8042
|
+
lastJobExperience: undefined,
|
|
8043
|
+
legalForm: '',
|
|
8044
|
+
organization: { key: '', text: '' },
|
|
8045
|
+
organizationAddress: {
|
|
8046
|
+
fullAddress: '',
|
|
8047
|
+
fiasCode: '',
|
|
8048
|
+
},
|
|
8049
|
+
organizationName: '',
|
|
8050
|
+
organizationPhone: '',
|
|
8051
|
+
partInBusiness: undefined,
|
|
8052
|
+
positionOrganization: { key: '', text: '' },
|
|
8053
|
+
},
|
|
8054
|
+
{
|
|
8055
|
+
familyStatus: { key: '', text: '' },
|
|
8056
|
+
dependents: undefined,
|
|
8057
|
+
familyMembers: undefined,
|
|
8058
|
+
confirmationIncome: { key: '', text: '' },
|
|
8059
|
+
wages: undefined,
|
|
8060
|
+
mandatoryPayments: undefined,
|
|
8061
|
+
snils: '',
|
|
8062
|
+
armyIdFlg: false,
|
|
8063
|
+
},
|
|
8064
|
+
{
|
|
8065
|
+
disablePeopleFlg: false,
|
|
8066
|
+
bankruptcyFlg: false,
|
|
8067
|
+
shareholderFlg: false,
|
|
8068
|
+
legalEntityName: '',
|
|
8069
|
+
creditInRshbCd: undefined,
|
|
8070
|
+
},
|
|
8071
|
+
{
|
|
8072
|
+
regionRetail: { key: '', text: '' },
|
|
8073
|
+
addressRetail: undefined,
|
|
8074
|
+
bankEmployeeCode: undefined,
|
|
8075
|
+
},
|
|
8076
|
+
];
|
|
8077
|
+
|
|
8078
|
+
const getInitialFormState = (step, formState) => ({
|
|
8079
|
+
...formStateMap[step],
|
|
8080
|
+
...formState,
|
|
8081
|
+
limitedBirthday: transformStringToData(formState?.limitedBirthday),
|
|
8082
|
+
dulIssueDateField: transformStringToData(formState?.dulIssueDateField),
|
|
8083
|
+
participantDateRegistration: transformStringToData(formState?.participantDateRegistration),
|
|
8084
|
+
beginDate: transformStringToData(formState?.beginDate),
|
|
8085
|
+
deliveryDate: transformStringToData(formState?.deliveryDate),
|
|
8086
|
+
});
|
|
8087
|
+
const transformStringToData = (text) => {
|
|
8088
|
+
try {
|
|
8089
|
+
return text ? new Date(text) : undefined;
|
|
8090
|
+
}
|
|
8091
|
+
catch (_) {
|
|
8092
|
+
return undefined;
|
|
8093
|
+
}
|
|
8094
|
+
};
|
|
8095
|
+
|
|
8096
|
+
const useCreditFormAPI = ({ step, inputs, onNextStep, onFinish, }) => {
|
|
8159
8097
|
const isFinalStep = step === 5;
|
|
8160
|
-
const
|
|
8161
|
-
const
|
|
8162
|
-
const
|
|
8163
|
-
|
|
8164
|
-
|
|
8098
|
+
const retailFormStore = useRetailFormStore();
|
|
8099
|
+
const initialState = useMemo(() => getInitialFormState(step, retailFormStore.leadForm), [step, retailFormStore.leadForm]);
|
|
8100
|
+
const resetForm = useCallback((response) => {
|
|
8101
|
+
const { leadForm } = retailFormStore;
|
|
8102
|
+
if (isFinalStep && response.ok && leadForm) {
|
|
8103
|
+
retailFormStore.statusInfo = {
|
|
8104
|
+
regionRetail: leadForm?.regionRetail?.text,
|
|
8105
|
+
addressRetail: leadForm?.addressRetail?.text,
|
|
8106
|
+
cardCategory: leadForm?.cardCategory?.text,
|
|
8107
|
+
calculator: {
|
|
8108
|
+
monthsValue: leadForm?.calculator?.monthsValue,
|
|
8109
|
+
moneyValue: leadForm?.calculator?.moneyValue,
|
|
8110
|
+
isAnnuity: leadForm?.calculator?.isAnnuity,
|
|
8111
|
+
},
|
|
8112
|
+
};
|
|
8113
|
+
retailFormStore.leadForm = initialState;
|
|
8114
|
+
}
|
|
8115
|
+
}, [isFinalStep, initialState]);
|
|
8165
8116
|
const handleSubmit = useCallback(async (formData) => {
|
|
8166
8117
|
const feedbackValidator = objectValidator(getObjectValidator(calculateInputs(getValue(formData))(inputs, step)));
|
|
8167
8118
|
if (!isValidationSuccess(feedbackValidator(formData))) {
|
|
8168
|
-
return
|
|
8119
|
+
return;
|
|
8169
8120
|
}
|
|
8170
|
-
|
|
8121
|
+
retailFormStore.leadForm = formData;
|
|
8171
8122
|
try {
|
|
8123
|
+
const { taskId, profileId, participantId } = retailFormStore;
|
|
8172
8124
|
if (taskId && profileId && participantId) {
|
|
8173
8125
|
const response = await updateUserTask(getCreditFormTaskData({
|
|
8174
8126
|
participantId,
|
|
@@ -8177,342 +8129,39 @@
|
|
|
8177
8129
|
step,
|
|
8178
8130
|
formData: formData,
|
|
8179
8131
|
}));
|
|
8180
|
-
resetForm(
|
|
8132
|
+
resetForm(response);
|
|
8133
|
+
}
|
|
8134
|
+
onNextStep();
|
|
8135
|
+
if (isFinalStep) {
|
|
8136
|
+
onFinish?.();
|
|
8181
8137
|
}
|
|
8182
8138
|
}
|
|
8183
8139
|
catch (ex) {
|
|
8184
|
-
|
|
8185
|
-
}
|
|
8186
|
-
onNextStep();
|
|
8187
|
-
if (isFinalStep) {
|
|
8188
|
-
finishForm?.(true);
|
|
8140
|
+
// Do nothing
|
|
8189
8141
|
}
|
|
8190
|
-
|
|
8191
|
-
|
|
8192
|
-
return {
|
|
8193
|
-
handleSubmit,
|
|
8194
|
-
};
|
|
8195
|
-
};
|
|
8196
|
-
const resetForm = ({ isFinalStep, response, leadForm, setStatusInfo, }) => {
|
|
8197
|
-
if (isFinalStep && response.ok && leadForm !== null) {
|
|
8198
|
-
const regionRetail = leadForm?.regionRetail?.text;
|
|
8199
|
-
const addressRetail = leadForm?.addressRetail?.text;
|
|
8200
|
-
const cardCategory = leadForm?.cardCategory?.text;
|
|
8201
|
-
const calculator = {
|
|
8202
|
-
monthsValue: leadForm?.calculator?.monthsValue,
|
|
8203
|
-
moneyValue: leadForm?.calculator?.moneyValue,
|
|
8204
|
-
isAnnuity: leadForm?.calculator?.isAnnuity,
|
|
8205
|
-
};
|
|
8206
|
-
setStatusInfo({
|
|
8207
|
-
regionRetail,
|
|
8208
|
-
addressRetail,
|
|
8209
|
-
cardCategory,
|
|
8210
|
-
calculator,
|
|
8211
|
-
});
|
|
8212
|
-
globalThis.localStorage.removeItem('leadForm');
|
|
8213
|
-
}
|
|
8142
|
+
}, [isFinalStep, resetForm]);
|
|
8143
|
+
return [initialState, handleSubmit];
|
|
8214
8144
|
};
|
|
8215
8145
|
const getValue = (formData) => (name) => formData[name];
|
|
8216
8146
|
|
|
8217
|
-
const CreditFormStep = JSX(({ step, sections,
|
|
8218
|
-
const
|
|
8219
|
-
const [programId] = useLocalStorage('programId');
|
|
8147
|
+
const CreditFormStep = JSX(({ step, sections, isFormFinished, programsSource, onPrevStep, onNextStep, onFinish }) => {
|
|
8148
|
+
const { programId } = useRetailFormStore();
|
|
8220
8149
|
const calcData = programsSource?.[programId ?? '']; // Need normalizator useForm, to be save defaultParams
|
|
8221
|
-
const
|
|
8222
|
-
const
|
|
8223
|
-
const { handleSubmit } = useCreditFormAPI({
|
|
8150
|
+
const inputs = useMemo(() => (sections?.flatMap((_) => _?.inputs) || []), [sections]);
|
|
8151
|
+
const [initialState, onSubmit] = useCreditFormAPI({
|
|
8224
8152
|
step,
|
|
8225
8153
|
inputs,
|
|
8226
8154
|
onNextStep,
|
|
8227
|
-
|
|
8228
|
-
finishForm,
|
|
8155
|
+
onFinish,
|
|
8229
8156
|
});
|
|
8230
|
-
const [, { field, onSubmit }] = useForm(initialState, {
|
|
8231
|
-
|
|
8232
|
-
});
|
|
8233
|
-
return isFormFinished ? (jsx(CreditFormStatusTracker, {})) : (jsxs("form", { onSubmit: onSubmit, className: "space-y-m", children: [renderStep$1({ sections, field, step, params: { calcData } }), jsx(StepsNavigationButtons, { step: step, onPrevStep: onPrevStep })] }));
|
|
8157
|
+
const [, { field, onSubmit: handleSubmit }] = useForm(initialState, { onSubmit });
|
|
8158
|
+
return isFormFinished ? (jsx(CreditFormStatusTracker, {})) : (jsxs("form", { onSubmit: handleSubmit, className: "space-y-m", children: [renderStep$1({ sections, field, step, params: { calcData } }), jsx(StepsNavigationButtons, { step: step, onPrevStep: onPrevStep })] }));
|
|
8234
8159
|
});
|
|
8235
8160
|
|
|
8236
|
-
/* eslint-disable max-lines */
|
|
8237
|
-
/* eslint-disable max-len */
|
|
8238
8161
|
const stepsSectionsMap = [
|
|
8239
|
-
|
|
8240
|
-
|
|
8241
|
-
|
|
8242
|
-
inputs: [
|
|
8243
|
-
{
|
|
8244
|
-
fieldType: 'common',
|
|
8245
|
-
name: 'calculator',
|
|
8246
|
-
},
|
|
8247
|
-
],
|
|
8248
|
-
},
|
|
8249
|
-
],
|
|
8250
|
-
[
|
|
8251
|
-
{
|
|
8252
|
-
title: 'Персональные данные',
|
|
8253
|
-
columns: 2,
|
|
8254
|
-
inputs: [
|
|
8255
|
-
{
|
|
8256
|
-
fieldType: 'common',
|
|
8257
|
-
name: 'surname',
|
|
8258
|
-
required: true,
|
|
8259
|
-
dadata: true,
|
|
8260
|
-
filledByEsia: true,
|
|
8261
|
-
},
|
|
8262
|
-
{ fieldType: 'common', name: 'name', required: true, dadata: true, filledByEsia: true },
|
|
8263
|
-
{ fieldType: 'common', name: 'middleName', dadata: true, filledByEsia: true },
|
|
8264
|
-
{ fieldType: 'common', name: 'sex', required: true },
|
|
8265
|
-
{ fieldType: 'common', name: 'limitedBirthday', required: true, filledByEsia: true },
|
|
8266
|
-
{ fieldType: 'common', name: 'birthPlace', required: true, filledByEsia: true },
|
|
8267
|
-
{ fieldType: 'common', name: 'phone', required: true, filledByEsia: true },
|
|
8268
|
-
{ fieldType: 'common', name: 'email', required: true, dadata: true },
|
|
8269
|
-
],
|
|
8270
|
-
},
|
|
8271
|
-
{
|
|
8272
|
-
title: 'Паспортные данные',
|
|
8273
|
-
columns: 2,
|
|
8274
|
-
inputs: [
|
|
8275
|
-
{ fieldType: 'common', name: 'dulSerie', required: true, filledByEsia: true },
|
|
8276
|
-
{ fieldType: 'common', name: 'dulNumber', required: true, filledByEsia: true },
|
|
8277
|
-
{ fieldType: 'common', name: 'dulIssueDateField', required: true, filledByEsia: true },
|
|
8278
|
-
{
|
|
8279
|
-
fieldType: 'common',
|
|
8280
|
-
name: 'dulSubdivisionCode',
|
|
8281
|
-
required: true,
|
|
8282
|
-
dadata: true,
|
|
8283
|
-
filledByEsia: true,
|
|
8284
|
-
},
|
|
8285
|
-
],
|
|
8286
|
-
},
|
|
8287
|
-
{
|
|
8288
|
-
inputs: [
|
|
8289
|
-
{
|
|
8290
|
-
fieldType: 'common',
|
|
8291
|
-
name: 'dulIssuedBy',
|
|
8292
|
-
required: true,
|
|
8293
|
-
dadata: true,
|
|
8294
|
-
filledByEsia: true,
|
|
8295
|
-
},
|
|
8296
|
-
{
|
|
8297
|
-
fieldType: 'common',
|
|
8298
|
-
name: 'education',
|
|
8299
|
-
required: true,
|
|
8300
|
-
},
|
|
8301
|
-
],
|
|
8302
|
-
},
|
|
8303
|
-
{
|
|
8304
|
-
title: 'Адрес регистрации по месту жительства',
|
|
8305
|
-
columns: 1,
|
|
8306
|
-
inputs: [],
|
|
8307
|
-
},
|
|
8308
|
-
{
|
|
8309
|
-
inputs: [
|
|
8310
|
-
{
|
|
8311
|
-
fieldType: 'common',
|
|
8312
|
-
name: 'addressRegistration',
|
|
8313
|
-
required: true,
|
|
8314
|
-
dadata: true,
|
|
8315
|
-
filledByEsia: true,
|
|
8316
|
-
},
|
|
8317
|
-
{ fieldType: 'common', name: 'addressMatch' },
|
|
8318
|
-
],
|
|
8319
|
-
},
|
|
8320
|
-
{
|
|
8321
|
-
columns: 2,
|
|
8322
|
-
inputs: [{ fieldType: 'common', name: 'participantDateRegistration', required: true }],
|
|
8323
|
-
},
|
|
8324
|
-
{
|
|
8325
|
-
title: 'Адрес фактического проживания (место пребывания РФ)',
|
|
8326
|
-
inputs: [],
|
|
8327
|
-
},
|
|
8328
|
-
{
|
|
8329
|
-
columns: 2,
|
|
8330
|
-
inputs: [{ fieldType: 'common', name: 'housing', required: true }],
|
|
8331
|
-
},
|
|
8332
|
-
{
|
|
8333
|
-
inputs: [{ fieldType: 'common', name: 'addressFact', required: true, dadata: true }],
|
|
8334
|
-
},
|
|
8335
|
-
],
|
|
8336
|
-
[
|
|
8337
|
-
{
|
|
8338
|
-
title: 'Данные о трудоустройстве',
|
|
8339
|
-
inputs: [],
|
|
8340
|
-
},
|
|
8341
|
-
{
|
|
8342
|
-
inputs: [
|
|
8343
|
-
{
|
|
8344
|
-
fieldType: 'info',
|
|
8345
|
-
text: 'Клиент на момент оформления заявки на кредит должен быть: официально трудоустроен более 6 месяцев, если Клиент получает з/п на счет РСХБ, то трудоустроен более 3 месяцев, не должен находиться в декретном отпуске',
|
|
8346
|
-
},
|
|
8347
|
-
],
|
|
8348
|
-
},
|
|
8349
|
-
{
|
|
8350
|
-
inputs: [
|
|
8351
|
-
{ fieldType: 'common', name: 'employment', required: true },
|
|
8352
|
-
{ fieldType: 'common', name: 'organizationName', required: true, dadata: true },
|
|
8353
|
-
],
|
|
8354
|
-
},
|
|
8355
|
-
{
|
|
8356
|
-
columns: 2,
|
|
8357
|
-
inputs: [
|
|
8358
|
-
{ fieldType: 'common', name: 'inn', required: true, dadata: true },
|
|
8359
|
-
{ fieldType: 'common', name: 'legalForm', required: true },
|
|
8360
|
-
],
|
|
8361
|
-
},
|
|
8362
|
-
{
|
|
8363
|
-
inputs: [
|
|
8364
|
-
{ fieldType: 'common', name: 'organization', required: true },
|
|
8365
|
-
{ fieldType: 'common', name: 'amountWorkers', required: true },
|
|
8366
|
-
],
|
|
8367
|
-
},
|
|
8368
|
-
{
|
|
8369
|
-
columns: 2,
|
|
8370
|
-
inputs: [
|
|
8371
|
-
{ fieldType: 'common', name: 'employerActivities', required: true },
|
|
8372
|
-
{ fieldType: 'common', name: 'employerOrganization', required: true },
|
|
8373
|
-
{ fieldType: 'common', name: 'generalSeniority', required: true },
|
|
8374
|
-
{ fieldType: 'common', name: 'lastJobExperience', required: true },
|
|
8375
|
-
{ fieldType: 'common', name: 'experience5Years', required: true },
|
|
8376
|
-
{ fieldType: 'common', name: 'jobsNumber', required: true },
|
|
8377
|
-
],
|
|
8378
|
-
},
|
|
8379
|
-
{
|
|
8380
|
-
inputs: [
|
|
8381
|
-
{
|
|
8382
|
-
fieldType: 'common',
|
|
8383
|
-
name: 'organizationPhone',
|
|
8384
|
-
label: 'Телефон работодателя',
|
|
8385
|
-
required: true,
|
|
8386
|
-
},
|
|
8387
|
-
{ fieldType: 'common', name: 'beginDate', required: true },
|
|
8388
|
-
],
|
|
8389
|
-
},
|
|
8390
|
-
{
|
|
8391
|
-
columns: 2,
|
|
8392
|
-
inputs: [
|
|
8393
|
-
{ fieldType: 'common', name: 'positionOrganization', required: true },
|
|
8394
|
-
{
|
|
8395
|
-
fieldType: 'common',
|
|
8396
|
-
name: 'partInBusiness',
|
|
8397
|
-
required: true,
|
|
8398
|
-
condition: { name: 'positionOrganization', values: ['BUSINESS_OWNER'] },
|
|
8399
|
-
},
|
|
8400
|
-
],
|
|
8401
|
-
},
|
|
8402
|
-
{
|
|
8403
|
-
title: 'Адрес работодателя',
|
|
8404
|
-
inputs: [],
|
|
8405
|
-
},
|
|
8406
|
-
{
|
|
8407
|
-
inputs: [{ fieldType: 'common', name: 'organizationAddress', required: true, dadata: true }],
|
|
8408
|
-
},
|
|
8409
|
-
],
|
|
8410
|
-
[
|
|
8411
|
-
{
|
|
8412
|
-
title: 'Семейное положение',
|
|
8413
|
-
},
|
|
8414
|
-
{
|
|
8415
|
-
columns: 1,
|
|
8416
|
-
inputs: [{ fieldType: 'common', name: 'familyStatus', required: true }],
|
|
8417
|
-
},
|
|
8418
|
-
{
|
|
8419
|
-
columns: 1,
|
|
8420
|
-
inputs: [{ fieldType: 'common', name: 'dependents', required: true }],
|
|
8421
|
-
},
|
|
8422
|
-
{
|
|
8423
|
-
columns: 2,
|
|
8424
|
-
inputs: [
|
|
8425
|
-
{ fieldType: 'common', name: 'familyMembers' },
|
|
8426
|
-
{ fieldType: 'common', name: 'children', required: true },
|
|
8427
|
-
],
|
|
8428
|
-
},
|
|
8429
|
-
{
|
|
8430
|
-
title: 'Совокупный доход',
|
|
8431
|
-
},
|
|
8432
|
-
{
|
|
8433
|
-
inputs: [
|
|
8434
|
-
{
|
|
8435
|
-
fieldType: 'info',
|
|
8436
|
-
text: 'Сумма основного и дополнительных доходов после вычета налога',
|
|
8437
|
-
},
|
|
8438
|
-
],
|
|
8439
|
-
},
|
|
8440
|
-
{
|
|
8441
|
-
columns: 1,
|
|
8442
|
-
inputs: [{ fieldType: 'common', name: 'confirmationIncome', required: true }],
|
|
8443
|
-
},
|
|
8444
|
-
{
|
|
8445
|
-
columns: 1,
|
|
8446
|
-
inputs: [{ fieldType: 'common', name: 'wages', required: true }],
|
|
8447
|
-
},
|
|
8448
|
-
{
|
|
8449
|
-
columns: 1,
|
|
8450
|
-
inputs: [{ fieldType: 'common', name: 'mandatoryPayments', required: true }],
|
|
8451
|
-
},
|
|
8452
|
-
{
|
|
8453
|
-
columns: 1,
|
|
8454
|
-
inputs: [{ fieldType: 'common', name: 'snils', required: true }],
|
|
8455
|
-
},
|
|
8456
|
-
{
|
|
8457
|
-
columns: 1,
|
|
8458
|
-
inputs: [{ fieldType: 'common', name: 'conscription', required: true }],
|
|
8459
|
-
},
|
|
8460
|
-
{
|
|
8461
|
-
columns: 2,
|
|
8462
|
-
inputs: [{ fieldType: 'common', name: 'armyIdFlg' }],
|
|
8463
|
-
},
|
|
8464
|
-
],
|
|
8465
|
-
[
|
|
8466
|
-
{
|
|
8467
|
-
title: 'Дополнительные сведения',
|
|
8468
|
-
columns: 1,
|
|
8469
|
-
inputs: [],
|
|
8470
|
-
},
|
|
8471
|
-
{
|
|
8472
|
-
inputs: [{ fieldType: 'common', name: 'disablePeopleFlg' }],
|
|
8473
|
-
},
|
|
8474
|
-
{
|
|
8475
|
-
inputs: [{ fieldType: 'common', name: 'bankruptcyFlg' }],
|
|
8476
|
-
},
|
|
8477
|
-
{
|
|
8478
|
-
inputs: [{ fieldType: 'common', name: 'shareholderFlg' }],
|
|
8479
|
-
},
|
|
8480
|
-
{
|
|
8481
|
-
inputs: [{ fieldType: 'common', name: 'legalEntityName' }],
|
|
8482
|
-
},
|
|
8483
|
-
{
|
|
8484
|
-
inputs: [{ fieldType: 'common', name: 'creditInRshbCd' }],
|
|
8485
|
-
},
|
|
8486
|
-
],
|
|
8487
|
-
[
|
|
8488
|
-
{
|
|
8489
|
-
title: 'Отделение Банка',
|
|
8490
|
-
columns: 1,
|
|
8491
|
-
inputs: [],
|
|
8492
|
-
},
|
|
8493
|
-
{
|
|
8494
|
-
inputs: [{ fieldType: 'common', name: 'regionRetail', required: true }],
|
|
8495
|
-
},
|
|
8496
|
-
{
|
|
8497
|
-
inputs: [{ fieldType: 'common', name: 'addressRetail', required: true }],
|
|
8498
|
-
},
|
|
8499
|
-
{
|
|
8500
|
-
title: 'Код представителя Банка',
|
|
8501
|
-
columns: 1,
|
|
8502
|
-
inputs: [],
|
|
8503
|
-
},
|
|
8504
|
-
{
|
|
8505
|
-
inputs: [
|
|
8506
|
-
{
|
|
8507
|
-
fieldType: 'info',
|
|
8508
|
-
text: 'Если представитель Банка помогал Вам в заведении заявки, введите здесь его код',
|
|
8509
|
-
},
|
|
8510
|
-
],
|
|
8511
|
-
},
|
|
8512
|
-
{
|
|
8513
|
-
inputs: [{ fieldType: 'common', name: 'bankEmployeeCode' }],
|
|
8514
|
-
},
|
|
8515
|
-
],
|
|
8162
|
+
CALCULATOR_CONTENT,
|
|
8163
|
+
...COMMON_RETAIL_CONTENT,
|
|
8164
|
+
DELIVERY_CREDIT_CONTENT,
|
|
8516
8165
|
];
|
|
8517
8166
|
|
|
8518
8167
|
const STEPS = 5;
|
|
@@ -8540,8 +8189,8 @@
|
|
|
8540
8189
|
}, []);
|
|
8541
8190
|
const sections = useMemo(() => stepsSectionsMap[step], [step]);
|
|
8542
8191
|
const isStartStep = step === 0;
|
|
8543
|
-
const [isFormFinished,
|
|
8544
|
-
return (jsx(BlockWrapper, { className: className, ...rest, children: jsxs("div", { ref: formContainerRef, className: "container grid grid-cols-12", children: [isStartStep || isFormFinished ? null : (jsx(CreditFormProgress, { stepsTitles: STEP_TITLES, step: step, totalSteps: STEPS })), jsx("div", { className: "py-lg px-5xl mt-2xs bg-white col-span-12", children: jsx(CreditFormStep, { step: step, sections: sections,
|
|
8192
|
+
const [isFormFinished, { setTrue: handleFinish }] = useBool(false);
|
|
8193
|
+
return (jsx(BlockWrapper, { className: className, ...rest, children: jsxs("div", { ref: formContainerRef, className: "container grid grid-cols-12", children: [isStartStep || isFormFinished ? null : (jsx(CreditFormProgress, { stepsTitles: STEP_TITLES, step: step, totalSteps: STEPS })), jsx("div", { className: "py-lg px-5xl mt-2xs bg-white col-span-12", children: jsx(CreditFormStep, { step: step, sections: sections, isFormFinished: isFormFinished, programsSource: programsSource, onNextStep: handleNextStep, onPrevStep: handlePrevStep, onFinish: handleFinish }, String(step)) })] }) }));
|
|
8545
8194
|
});
|
|
8546
8195
|
|
|
8547
8196
|
const isRateRow = (rateRow) => typeof rateRow?.minMonths === 'number' && typeof rateRow?.maxMonths === 'number';
|
|
@@ -10818,7 +10467,7 @@
|
|
|
10818
10467
|
slots: () => [HEADER_SLOT, FOOTER_SLOT, STICKY_FOOTER_SLOT],
|
|
10819
10468
|
});
|
|
10820
10469
|
|
|
10821
|
-
const packageVersion = "0.14.
|
|
10470
|
+
const packageVersion = "0.14.710";
|
|
10822
10471
|
|
|
10823
10472
|
exports.Blocks = Blocks;
|
|
10824
10473
|
exports.ContentPage = ContentPage;
|