@redneckz/wildless-cms-uni-blocks 0.14.681 → 0.14.682
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/bundle/api/RetailAPI/updateUserTask.d.ts +1 -0
- package/bundle/bundle.umd.js +18 -12
- package/bundle/bundle.umd.min.js +1 -1
- package/bundle/components/ApplicationLeadForm/getInitialFormState.d.ts +1 -1
- package/bundle/components/CreditCardForm/getSixthStepData.d.ts +5 -0
- package/dist/api/RetailAPI/updateUserTask.d.ts +1 -0
- package/dist/api/RetailAPI/updateUserTask.js.map +1 -1
- package/dist/components/ApplicationLeadForm/getInitialFormState.d.ts +1 -1
- package/dist/components/CreditCardForm/getCreditCardFormTaskData.js +1 -3
- package/dist/components/CreditCardForm/getCreditCardFormTaskData.js.map +1 -1
- package/dist/components/CreditCardForm/getFourthStepData.js +3 -1
- package/dist/components/CreditCardForm/getFourthStepData.js.map +1 -1
- package/dist/components/CreditCardForm/getSixthStepData.d.ts +5 -0
- package/dist/components/CreditCardForm/getSixthStepData.js +8 -1
- package/dist/components/CreditCardForm/getSixthStepData.js.map +1 -1
- package/dist/components/CreditCardForm/getThirdStepData.js +3 -1
- package/dist/components/CreditCardForm/getThirdStepData.js.map +1 -1
- package/dist/components/CreditCardForm/useCreditCardFormAPI.js +0 -1
- package/dist/components/CreditCardForm/useCreditCardFormAPI.js.map +1 -1
- package/dist/components/CreditForm/getCreditFormTaskData.js +0 -3
- package/dist/components/CreditForm/getCreditFormTaskData.js.map +1 -1
- package/dist/components/CreditForm/getSecondStepData.js +3 -1
- package/dist/components/CreditForm/getSecondStepData.js.map +1 -1
- package/dist/components/CreditForm/getThirdStepData.js +3 -1
- package/dist/components/CreditForm/getThirdStepData.js.map +1 -1
- package/lib/api/RetailAPI/updateUserTask.d.ts +1 -0
- package/lib/api/RetailAPI/updateUserTask.js.map +1 -1
- package/lib/components/ApplicationLeadForm/getInitialFormState.d.ts +1 -1
- package/lib/components/CreditCardForm/getCreditCardFormTaskData.js +2 -4
- package/lib/components/CreditCardForm/getCreditCardFormTaskData.js.map +1 -1
- package/lib/components/CreditCardForm/getFourthStepData.js +3 -1
- package/lib/components/CreditCardForm/getFourthStepData.js.map +1 -1
- package/lib/components/CreditCardForm/getSixthStepData.d.ts +5 -0
- package/lib/components/CreditCardForm/getSixthStepData.js +6 -0
- package/lib/components/CreditCardForm/getSixthStepData.js.map +1 -1
- package/lib/components/CreditCardForm/getThirdStepData.js +3 -1
- package/lib/components/CreditCardForm/getThirdStepData.js.map +1 -1
- package/lib/components/CreditCardForm/useCreditCardFormAPI.js +0 -1
- package/lib/components/CreditCardForm/useCreditCardFormAPI.js.map +1 -1
- package/lib/components/CreditForm/getCreditFormTaskData.js +0 -3
- package/lib/components/CreditForm/getCreditFormTaskData.js.map +1 -1
- package/lib/components/CreditForm/getSecondStepData.js +3 -1
- package/lib/components/CreditForm/getSecondStepData.js.map +1 -1
- package/lib/components/CreditForm/getThirdStepData.js +3 -1
- package/lib/components/CreditForm/getThirdStepData.js.map +1 -1
- package/mobile/bundle/api/RetailAPI/updateUserTask.d.ts +1 -0
- package/mobile/bundle/bundle.umd.js +18 -12
- package/mobile/bundle/bundle.umd.min.js +1 -1
- package/mobile/bundle/components/ApplicationLeadForm/getInitialFormState.d.ts +1 -1
- package/mobile/bundle/components/CreditCardForm/getSixthStepData.d.ts +5 -0
- package/mobile/dist/api/RetailAPI/updateUserTask.d.ts +1 -0
- package/mobile/dist/api/RetailAPI/updateUserTask.js.map +1 -1
- package/mobile/dist/components/ApplicationLeadForm/getInitialFormState.d.ts +1 -1
- package/mobile/dist/components/CreditCardForm/getCreditCardFormTaskData.js +1 -3
- package/mobile/dist/components/CreditCardForm/getCreditCardFormTaskData.js.map +1 -1
- package/mobile/dist/components/CreditCardForm/getFourthStepData.js +3 -1
- package/mobile/dist/components/CreditCardForm/getFourthStepData.js.map +1 -1
- package/mobile/dist/components/CreditCardForm/getSixthStepData.d.ts +5 -0
- package/mobile/dist/components/CreditCardForm/getSixthStepData.js +8 -1
- package/mobile/dist/components/CreditCardForm/getSixthStepData.js.map +1 -1
- package/mobile/dist/components/CreditCardForm/getThirdStepData.js +3 -1
- package/mobile/dist/components/CreditCardForm/getThirdStepData.js.map +1 -1
- package/mobile/dist/components/CreditCardForm/useCreditCardFormAPI.js +0 -1
- package/mobile/dist/components/CreditCardForm/useCreditCardFormAPI.js.map +1 -1
- package/mobile/dist/components/CreditForm/getCreditFormTaskData.js +0 -3
- package/mobile/dist/components/CreditForm/getCreditFormTaskData.js.map +1 -1
- package/mobile/dist/components/CreditForm/getSecondStepData.js +3 -1
- package/mobile/dist/components/CreditForm/getSecondStepData.js.map +1 -1
- package/mobile/dist/components/CreditForm/getThirdStepData.js +3 -1
- package/mobile/dist/components/CreditForm/getThirdStepData.js.map +1 -1
- package/mobile/lib/api/RetailAPI/updateUserTask.d.ts +1 -0
- package/mobile/lib/api/RetailAPI/updateUserTask.js.map +1 -1
- package/mobile/lib/components/ApplicationLeadForm/getInitialFormState.d.ts +1 -1
- package/mobile/lib/components/CreditCardForm/getCreditCardFormTaskData.js +2 -4
- package/mobile/lib/components/CreditCardForm/getCreditCardFormTaskData.js.map +1 -1
- package/mobile/lib/components/CreditCardForm/getFourthStepData.js +3 -1
- package/mobile/lib/components/CreditCardForm/getFourthStepData.js.map +1 -1
- package/mobile/lib/components/CreditCardForm/getSixthStepData.d.ts +5 -0
- package/mobile/lib/components/CreditCardForm/getSixthStepData.js +6 -0
- package/mobile/lib/components/CreditCardForm/getSixthStepData.js.map +1 -1
- package/mobile/lib/components/CreditCardForm/getThirdStepData.js +3 -1
- package/mobile/lib/components/CreditCardForm/getThirdStepData.js.map +1 -1
- package/mobile/lib/components/CreditCardForm/useCreditCardFormAPI.js +0 -1
- package/mobile/lib/components/CreditCardForm/useCreditCardFormAPI.js.map +1 -1
- package/mobile/lib/components/CreditForm/getCreditFormTaskData.js +0 -3
- package/mobile/lib/components/CreditForm/getCreditFormTaskData.js.map +1 -1
- package/mobile/lib/components/CreditForm/getSecondStepData.js +3 -1
- package/mobile/lib/components/CreditForm/getSecondStepData.js.map +1 -1
- package/mobile/lib/components/CreditForm/getThirdStepData.js +3 -1
- package/mobile/lib/components/CreditForm/getThirdStepData.js.map +1 -1
- package/mobile/src/api/RetailAPI/updateUserTask.ts +1 -0
- package/mobile/src/components/ApplicationLeadForm/getInitialFormState.tsx +1 -1
- package/mobile/src/components/CreditCardForm/getCreditCardFormTaskData.ts +2 -4
- package/mobile/src/components/CreditCardForm/getFourthStepData.ts +4 -0
- package/mobile/src/components/CreditCardForm/getSixthStepData.ts +8 -0
- package/mobile/src/components/CreditCardForm/getThirdStepData.tsx +3 -0
- package/mobile/src/components/CreditCardForm/useCreditCardFormAPI.tsx +1 -1
- package/mobile/src/components/CreditForm/getCreditFormTaskData.ts +0 -3
- package/mobile/src/components/CreditForm/getSecondStepData.tsx +3 -0
- package/mobile/src/components/CreditForm/getThirdStepData.ts +4 -0
- package/package.json +1 -1
- package/src/api/RetailAPI/updateUserTask.ts +1 -0
- package/src/components/ApplicationLeadForm/getInitialFormState.tsx +1 -1
- package/src/components/CreditCardForm/getCreditCardFormTaskData.ts +2 -4
- package/src/components/CreditCardForm/getFourthStepData.ts +4 -0
- package/src/components/CreditCardForm/getSixthStepData.ts +8 -0
- package/src/components/CreditCardForm/getThirdStepData.tsx +3 -0
- package/src/components/CreditCardForm/useCreditCardFormAPI.tsx +1 -1
- package/src/components/CreditForm/getCreditFormTaskData.ts +0 -3
- package/src/components/CreditForm/getSecondStepData.tsx +3 -0
- package/src/components/CreditForm/getThirdStepData.ts +4 -0
|
@@ -1,10 +1,12 @@
|
|
|
1
1
|
import { type Participant } from '../../api/RetailAPI/updateUserTask';
|
|
2
|
+
import { formatDate } from '../../utils/formatDate';
|
|
2
3
|
import { formatPhone } from '../../utils/formatPhone';
|
|
3
4
|
import { type FormState } from '../ApplicationLeadForm/getInitialFormState';
|
|
4
5
|
import { getParticipantAddresses, getParticipantContacts } from './utils';
|
|
5
6
|
|
|
6
7
|
export const getSecondStepData = (formData: FormState): Partial<Participant> => {
|
|
7
8
|
const {
|
|
9
|
+
beginDate,
|
|
8
10
|
employment,
|
|
9
11
|
organizationName,
|
|
10
12
|
inn,
|
|
@@ -23,6 +25,7 @@ export const getSecondStepData = (formData: FormState): Partial<Participant> =>
|
|
|
23
25
|
} = formData;
|
|
24
26
|
|
|
25
27
|
return {
|
|
28
|
+
employmentContractDate: formatDate(beginDate || '', true),
|
|
26
29
|
employmentTypeCd: employment,
|
|
27
30
|
organizationName,
|
|
28
31
|
organizationInn: inn,
|
|
@@ -7,6 +7,7 @@ export const getThirdStepData = (formData: FormState): Partial<Participant> => {
|
|
|
7
7
|
familyStatus,
|
|
8
8
|
dependents,
|
|
9
9
|
familyMembers,
|
|
10
|
+
children,
|
|
10
11
|
confirmationIncome,
|
|
11
12
|
wages,
|
|
12
13
|
mandatoryPayments,
|
|
@@ -18,6 +19,7 @@ export const getThirdStepData = (formData: FormState): Partial<Participant> => {
|
|
|
18
19
|
retirementIncome,
|
|
19
20
|
snils,
|
|
20
21
|
armyIdFlg,
|
|
22
|
+
conscription,
|
|
21
23
|
} = formData;
|
|
22
24
|
|
|
23
25
|
return {
|
|
@@ -25,6 +27,8 @@ export const getThirdStepData = (formData: FormState): Partial<Participant> => {
|
|
|
25
27
|
totalDependents: familyMembers,
|
|
26
28
|
incomeCertificateCd: confirmationIncome,
|
|
27
29
|
otherDependents: dependents,
|
|
30
|
+
childrenDependents: children,
|
|
31
|
+
militaryStatusCd: conscription,
|
|
28
32
|
participantIncomes: getParticipantIncomes({
|
|
29
33
|
wages,
|
|
30
34
|
mandatoryPayments,
|
package/package.json
CHANGED
|
@@ -118,7 +118,7 @@ export interface FormState extends FormConsents, FormStateDeliveryType {
|
|
|
118
118
|
totalIncome?: number;
|
|
119
119
|
expenses?: number;
|
|
120
120
|
snils?: string;
|
|
121
|
-
conscription?:
|
|
121
|
+
conscription?: Option;
|
|
122
122
|
armyIdFlg?: boolean;
|
|
123
123
|
addressRegistration?: Address;
|
|
124
124
|
participantDateRegistration?: Date | string;
|
|
@@ -5,7 +5,7 @@ import { getFifthStepData } from './getFifthStepData';
|
|
|
5
5
|
import { getFirstStepData } from './getFirstStepData';
|
|
6
6
|
import { getFourthStepData } from './getFourthStepData';
|
|
7
7
|
import { getSecondStepData } from './getSecondStepData';
|
|
8
|
-
import { getDeliveryData, getSixthStepData } from './getSixthStepData';
|
|
8
|
+
import { getDeliveryData, getOfficeCode, getSixthStepData } from './getSixthStepData';
|
|
9
9
|
import { getThirdStepData } from './getThirdStepData';
|
|
10
10
|
|
|
11
11
|
type getCreditCardFormTaskDataProps = {
|
|
@@ -31,9 +31,7 @@ export const getCreditCardFormTaskData = ({
|
|
|
31
31
|
task: {
|
|
32
32
|
taskSource: navigator.origin,
|
|
33
33
|
id: taskId,
|
|
34
|
-
|
|
35
|
-
id: '650', // TODO: Remove hardcode
|
|
36
|
-
},
|
|
34
|
+
...getOfficeCode(formData),
|
|
37
35
|
authorizedAgentId: formData?.bankEmployeeCode,
|
|
38
36
|
participants: [
|
|
39
37
|
{
|
|
@@ -7,6 +7,7 @@ export const getFourthStepData = (formData: FormState): Partial<Participant> =>
|
|
|
7
7
|
familyStatus,
|
|
8
8
|
dependents,
|
|
9
9
|
familyMembers,
|
|
10
|
+
children,
|
|
10
11
|
wages,
|
|
11
12
|
mandatoryPayments,
|
|
12
13
|
incomeAverage,
|
|
@@ -17,12 +18,15 @@ export const getFourthStepData = (formData: FormState): Partial<Participant> =>
|
|
|
17
18
|
retirementIncome,
|
|
18
19
|
snils,
|
|
19
20
|
armyIdFlg,
|
|
21
|
+
conscription,
|
|
20
22
|
} = formData;
|
|
21
23
|
|
|
22
24
|
return {
|
|
23
25
|
maritalStatusCd: familyStatus,
|
|
26
|
+
childrenDependents: children,
|
|
24
27
|
totalDependents: familyMembers,
|
|
25
28
|
otherDependents: dependents,
|
|
29
|
+
militaryStatusCd: conscription,
|
|
26
30
|
participantIncomes: getParticipantIncomes({
|
|
27
31
|
wages,
|
|
28
32
|
mandatoryPayments,
|
|
@@ -12,6 +12,14 @@ export const getDeliveryData = (formData: FormState) => {
|
|
|
12
12
|
};
|
|
13
13
|
};
|
|
14
14
|
|
|
15
|
+
export const getOfficeCode = (formData: FormState) => {
|
|
16
|
+
const { addressRetail } = formData;
|
|
17
|
+
|
|
18
|
+
return {
|
|
19
|
+
office: addressRetail?.key ? { id: addressRetail.key } : undefined,
|
|
20
|
+
};
|
|
21
|
+
};
|
|
22
|
+
|
|
15
23
|
export const getSixthStepData = (formData: FormState) => {
|
|
16
24
|
const { addressCourier } = formData;
|
|
17
25
|
|
|
@@ -1,10 +1,12 @@
|
|
|
1
1
|
import { type Participant } from '../../api/RetailAPI/updateUserTask';
|
|
2
|
+
import { formatDate } from '../../utils/formatDate';
|
|
2
3
|
import { formatPhone } from '../../utils/formatPhone';
|
|
3
4
|
import { type FormState } from '../ApplicationLeadForm/getInitialFormState';
|
|
4
5
|
import { getParticipantAddresses, getParticipantContacts } from '../CreditForm/utils';
|
|
5
6
|
|
|
6
7
|
export const getThirdStepData = (formData: FormState): Partial<Participant> => {
|
|
7
8
|
const {
|
|
9
|
+
beginDate,
|
|
8
10
|
employment,
|
|
9
11
|
organizationName,
|
|
10
12
|
inn,
|
|
@@ -23,6 +25,7 @@ export const getThirdStepData = (formData: FormState): Partial<Participant> => {
|
|
|
23
25
|
} = formData;
|
|
24
26
|
|
|
25
27
|
return {
|
|
28
|
+
employmentContractDate: formatDate(beginDate || '', true),
|
|
26
29
|
employmentTypeCd: employment,
|
|
27
30
|
organizationName,
|
|
28
31
|
organizationInn: inn,
|
|
@@ -32,7 +32,7 @@ export const useCreditCardFormAPI = ({
|
|
|
32
32
|
const feedbackValidator = objectValidator(
|
|
33
33
|
getObjectValidator(calculateInputs(getValue(formData))(inputs, step)),
|
|
34
34
|
);
|
|
35
|
-
|
|
35
|
+
|
|
36
36
|
if (!isValidationSuccess(feedbackValidator(formData))) {
|
|
37
37
|
return console.warn('validation fail');
|
|
38
38
|
}
|
|
@@ -1,10 +1,12 @@
|
|
|
1
1
|
import { type Participant } from '../../api/RetailAPI/updateUserTask';
|
|
2
|
+
import { formatDate } from '../../utils/formatDate';
|
|
2
3
|
import { formatPhone } from '../../utils/formatPhone';
|
|
3
4
|
import { type FormState } from '../ApplicationLeadForm/getInitialFormState';
|
|
4
5
|
import { getParticipantAddresses, getParticipantContacts } from './utils';
|
|
5
6
|
|
|
6
7
|
export const getSecondStepData = (formData: FormState): Partial<Participant> => {
|
|
7
8
|
const {
|
|
9
|
+
beginDate,
|
|
8
10
|
employment,
|
|
9
11
|
organizationName,
|
|
10
12
|
inn,
|
|
@@ -23,6 +25,7 @@ export const getSecondStepData = (formData: FormState): Partial<Participant> =>
|
|
|
23
25
|
} = formData;
|
|
24
26
|
|
|
25
27
|
return {
|
|
28
|
+
employmentContractDate: formatDate(beginDate || '', true),
|
|
26
29
|
employmentTypeCd: employment,
|
|
27
30
|
organizationName,
|
|
28
31
|
organizationInn: inn,
|
|
@@ -7,6 +7,7 @@ export const getThirdStepData = (formData: FormState): Partial<Participant> => {
|
|
|
7
7
|
familyStatus,
|
|
8
8
|
dependents,
|
|
9
9
|
familyMembers,
|
|
10
|
+
children,
|
|
10
11
|
confirmationIncome,
|
|
11
12
|
wages,
|
|
12
13
|
mandatoryPayments,
|
|
@@ -18,6 +19,7 @@ export const getThirdStepData = (formData: FormState): Partial<Participant> => {
|
|
|
18
19
|
retirementIncome,
|
|
19
20
|
snils,
|
|
20
21
|
armyIdFlg,
|
|
22
|
+
conscription,
|
|
21
23
|
} = formData;
|
|
22
24
|
|
|
23
25
|
return {
|
|
@@ -25,6 +27,8 @@ export const getThirdStepData = (formData: FormState): Partial<Participant> => {
|
|
|
25
27
|
totalDependents: familyMembers,
|
|
26
28
|
incomeCertificateCd: confirmationIncome,
|
|
27
29
|
otherDependents: dependents,
|
|
30
|
+
childrenDependents: children,
|
|
31
|
+
militaryStatusCd: conscription,
|
|
28
32
|
participantIncomes: getParticipantIncomes({
|
|
29
33
|
wages,
|
|
30
34
|
mandatoryPayments,
|