@redneckz/wildless-cms-uni-blocks 0.14.711 → 0.14.712
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/draftTasksKZO.d.ts +7 -0
- package/bundle/api/RetailAPI/getPaymentSystems.d.ts +2 -2
- package/bundle/api/RetailAPI/updateUserTask.d.ts +1 -5
- package/bundle/bundle.umd.js +15 -9
- package/bundle/bundle.umd.min.js +1 -1
- package/bundle/components/ApplicationLeadForm/LeadFormState.d.ts +2 -2
- package/dist/api/RetailAPI/draftTasksKZO.d.ts +7 -0
- package/dist/api/RetailAPI/draftTasksKZO.js.map +1 -1
- package/dist/api/RetailAPI/getPaymentSystems.d.ts +2 -2
- package/dist/api/RetailAPI/getPaymentSystems.js +5 -1
- package/dist/api/RetailAPI/getPaymentSystems.js.map +1 -1
- package/dist/api/RetailAPI/updateUserTask.d.ts +1 -5
- package/dist/api/RetailAPI/updateUserTask.js.map +1 -1
- package/dist/components/ApplicationLeadForm/LeadFormState.d.ts +2 -2
- package/dist/components/CreditCardForm/formStateMap.js +1 -1
- package/dist/components/CreditCardForm/formStateMap.js.map +1 -1
- package/dist/ui-kit/DraftDialog/parseDraftTask.js +4 -2
- package/dist/ui-kit/DraftDialog/parseDraftTask.js.map +1 -1
- package/dist/ui-kit/FormField/Fields/CardCategoryField.js +1 -1
- package/dist/ui-kit/FormField/Fields/CardCategoryField.js.map +1 -1
- package/dist/ui-kit/FormField/Fields/PaymentSystemField.js +3 -3
- package/dist/ui-kit/FormField/Fields/PaymentSystemField.js.map +1 -1
- package/lib/api/RetailAPI/draftTasksKZO.d.ts +7 -0
- package/lib/api/RetailAPI/draftTasksKZO.js.map +1 -1
- package/lib/api/RetailAPI/getPaymentSystems.d.ts +2 -2
- package/lib/api/RetailAPI/getPaymentSystems.js +5 -1
- package/lib/api/RetailAPI/getPaymentSystems.js.map +1 -1
- package/lib/api/RetailAPI/updateUserTask.d.ts +1 -5
- package/lib/api/RetailAPI/updateUserTask.js.map +1 -1
- package/lib/components/ApplicationLeadForm/LeadFormState.d.ts +2 -2
- package/lib/components/CreditCardForm/formStateMap.js +1 -1
- package/lib/components/CreditCardForm/formStateMap.js.map +1 -1
- package/lib/ui-kit/DraftDialog/parseDraftTask.js +4 -2
- package/lib/ui-kit/DraftDialog/parseDraftTask.js.map +1 -1
- package/lib/ui-kit/FormField/Fields/CardCategoryField.js +1 -1
- package/lib/ui-kit/FormField/Fields/CardCategoryField.js.map +1 -1
- package/lib/ui-kit/FormField/Fields/PaymentSystemField.js +3 -3
- package/lib/ui-kit/FormField/Fields/PaymentSystemField.js.map +1 -1
- package/mobile/bundle/api/RetailAPI/draftTasksKZO.d.ts +7 -0
- package/mobile/bundle/api/RetailAPI/getPaymentSystems.d.ts +2 -2
- package/mobile/bundle/api/RetailAPI/updateUserTask.d.ts +1 -5
- package/mobile/bundle/bundle.umd.js +15 -9
- package/mobile/bundle/bundle.umd.min.js +1 -1
- package/mobile/bundle/components/ApplicationLeadForm/LeadFormState.d.ts +2 -2
- package/mobile/dist/api/RetailAPI/draftTasksKZO.d.ts +7 -0
- package/mobile/dist/api/RetailAPI/draftTasksKZO.js.map +1 -1
- package/mobile/dist/api/RetailAPI/getPaymentSystems.d.ts +2 -2
- package/mobile/dist/api/RetailAPI/getPaymentSystems.js +5 -1
- package/mobile/dist/api/RetailAPI/getPaymentSystems.js.map +1 -1
- package/mobile/dist/api/RetailAPI/updateUserTask.d.ts +1 -5
- package/mobile/dist/api/RetailAPI/updateUserTask.js.map +1 -1
- package/mobile/dist/components/ApplicationLeadForm/LeadFormState.d.ts +2 -2
- package/mobile/dist/components/CreditCardForm/formStateMap.js +1 -1
- package/mobile/dist/components/CreditCardForm/formStateMap.js.map +1 -1
- package/mobile/dist/ui-kit/DraftDialog/parseDraftTask.js +4 -2
- package/mobile/dist/ui-kit/DraftDialog/parseDraftTask.js.map +1 -1
- package/mobile/dist/ui-kit/FormField/Fields/CardCategoryField.js +1 -1
- package/mobile/dist/ui-kit/FormField/Fields/CardCategoryField.js.map +1 -1
- package/mobile/dist/ui-kit/FormField/Fields/PaymentSystemField.js +3 -3
- package/mobile/dist/ui-kit/FormField/Fields/PaymentSystemField.js.map +1 -1
- package/mobile/lib/api/RetailAPI/draftTasksKZO.d.ts +7 -0
- package/mobile/lib/api/RetailAPI/draftTasksKZO.js.map +1 -1
- package/mobile/lib/api/RetailAPI/getPaymentSystems.d.ts +2 -2
- package/mobile/lib/api/RetailAPI/getPaymentSystems.js +5 -1
- package/mobile/lib/api/RetailAPI/getPaymentSystems.js.map +1 -1
- package/mobile/lib/api/RetailAPI/updateUserTask.d.ts +1 -5
- package/mobile/lib/api/RetailAPI/updateUserTask.js.map +1 -1
- package/mobile/lib/components/ApplicationLeadForm/LeadFormState.d.ts +2 -2
- package/mobile/lib/components/CreditCardForm/formStateMap.js +1 -1
- package/mobile/lib/components/CreditCardForm/formStateMap.js.map +1 -1
- package/mobile/lib/ui-kit/DraftDialog/parseDraftTask.js +4 -2
- package/mobile/lib/ui-kit/DraftDialog/parseDraftTask.js.map +1 -1
- package/mobile/lib/ui-kit/FormField/Fields/CardCategoryField.js +1 -1
- package/mobile/lib/ui-kit/FormField/Fields/CardCategoryField.js.map +1 -1
- package/mobile/lib/ui-kit/FormField/Fields/PaymentSystemField.js +3 -3
- package/mobile/lib/ui-kit/FormField/Fields/PaymentSystemField.js.map +1 -1
- package/mobile/src/api/RetailAPI/draftTasksKZO.ts +5 -0
- package/mobile/src/api/RetailAPI/getPaymentSystems.ts +13 -2
- package/mobile/src/api/RetailAPI/updateUserTask.ts +1 -6
- package/mobile/src/components/ApplicationLeadForm/LeadFormState.ts +2 -2
- package/mobile/src/components/CreditCardForm/formStateMap.tsx +1 -1
- package/mobile/src/ui-kit/DraftDialog/parseDraftTask.ts +9 -5
- package/mobile/src/ui-kit/FormField/Fields/CardCategoryField.tsx +1 -1
- package/mobile/src/ui-kit/FormField/Fields/PaymentSystemField.tsx +6 -6
- package/package.json +1 -1
- package/src/api/RetailAPI/draftTasksKZO.ts +5 -0
- package/src/api/RetailAPI/getPaymentSystems.ts +13 -2
- package/src/api/RetailAPI/updateUserTask.ts +1 -6
- package/src/components/ApplicationLeadForm/LeadFormState.ts +2 -2
- package/src/components/CreditCardForm/formStateMap.tsx +1 -1
- package/src/ui-kit/DraftDialog/parseDraftTask.ts +9 -5
- package/src/ui-kit/FormField/Fields/CardCategoryField.tsx +1 -1
- package/src/ui-kit/FormField/Fields/PaymentSystemField.tsx +6 -6
|
@@ -1,5 +1,12 @@
|
|
|
1
|
+
import { type Option } from '../../ui-kit/Select/Option';
|
|
1
2
|
import { type Participant, type PaymentType } from './updateUserTask';
|
|
2
3
|
export declare type Task = {
|
|
4
|
+
currencyCode?: {
|
|
5
|
+
key: string;
|
|
6
|
+
};
|
|
7
|
+
paymentSystemTypeCd?: Option;
|
|
8
|
+
classCard?: Option;
|
|
9
|
+
codeWord?: string;
|
|
3
10
|
courierDeliveryFlg?: boolean;
|
|
4
11
|
creditPeriod?: number;
|
|
5
12
|
creditProgram: {
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import { type
|
|
2
|
-
export declare const getPaymentSystems: (creditProgramId: string) => Promise<
|
|
1
|
+
import { type Option } from '../../ui-kit/Select/Option';
|
|
2
|
+
export declare const getPaymentSystems: (creditProgramId: string) => Promise<Option[]>;
|
|
@@ -28,10 +28,6 @@ export declare type PaymentType = {
|
|
|
28
28
|
key: 'ANNUITY' | 'DIFFERENTIAL';
|
|
29
29
|
value: string;
|
|
30
30
|
};
|
|
31
|
-
export declare type PaymentSystem = {
|
|
32
|
-
name: string;
|
|
33
|
-
type: string;
|
|
34
|
-
};
|
|
35
31
|
export declare type Participant = {
|
|
36
32
|
birthDate?: string;
|
|
37
33
|
id: number;
|
|
@@ -98,7 +94,7 @@ export declare type Participant = {
|
|
|
98
94
|
currencyCode?: {
|
|
99
95
|
key: string;
|
|
100
96
|
};
|
|
101
|
-
paymentSystemTypeCd?:
|
|
97
|
+
paymentSystemTypeCd?: Option;
|
|
102
98
|
classCard?: Option;
|
|
103
99
|
codeWord?: string;
|
|
104
100
|
};
|
package/bundle/bundle.umd.js
CHANGED
|
@@ -3160,7 +3160,7 @@
|
|
|
3160
3160
|
const [cardTypes, setCardTypes] = useState([]);
|
|
3161
3161
|
const [programId] = useLocalStorage('programId');
|
|
3162
3162
|
const { value: selectedCardCategory, onChange: cardCategoryChange } = field('cardCategory');
|
|
3163
|
-
const selectedPaymentSystem = field('paymentSystem')?.value?.
|
|
3163
|
+
const selectedPaymentSystem = field('paymentSystem')?.value?.key;
|
|
3164
3164
|
useEffect(() => {
|
|
3165
3165
|
if (selectedPaymentSystem && programId) {
|
|
3166
3166
|
(async () => {
|
|
@@ -3955,8 +3955,12 @@
|
|
|
3955
3955
|
const data = await fetchRetailJSON('/public-data/creditProgramConditions', 'POST', {
|
|
3956
3956
|
creditProgramId,
|
|
3957
3957
|
});
|
|
3958
|
-
return data?.paymentSystems || [];
|
|
3958
|
+
return formatData(data?.paymentSystems || []);
|
|
3959
3959
|
};
|
|
3960
|
+
const formatData = (paymentSystems) => paymentSystems.map((_) => ({
|
|
3961
|
+
key: _.type,
|
|
3962
|
+
text: _.name,
|
|
3963
|
+
}));
|
|
3960
3964
|
|
|
3961
3965
|
const PaymentSystemField = JSX(({ field, input }) => {
|
|
3962
3966
|
const { value, onChange } = field('paymentSystem');
|
|
@@ -3970,10 +3974,10 @@
|
|
|
3970
3974
|
})();
|
|
3971
3975
|
}
|
|
3972
3976
|
}, []);
|
|
3973
|
-
const handleChange = useCallback((type) => onChange?.(paymentSystemOptions?.find((_) => _.
|
|
3974
|
-
return (jsx(RadioButtonGroupControl, { label: "\u041F\u043B\u0430\u0442\u0435\u0436\u043D\u0430\u044F \u0441\u0438\u0441\u0442\u0435\u043C\u0430", orientation: "horizontal", items: formatPaymentSystems(paymentSystemOptions), ...getValidation(field('paymentSystem'), validatorObj.paymentSystem, input?.required), value: value?.
|
|
3977
|
+
const handleChange = useCallback((type) => onChange?.(paymentSystemOptions?.find((_) => _.key === type)), [paymentSystemOptions, onChange]);
|
|
3978
|
+
return (jsx(RadioButtonGroupControl, { label: "\u041F\u043B\u0430\u0442\u0435\u0436\u043D\u0430\u044F \u0441\u0438\u0441\u0442\u0435\u043C\u0430", orientation: "horizontal", items: formatPaymentSystems(paymentSystemOptions), ...getValidation(field('paymentSystem'), validatorObj.paymentSystem, input?.required), value: value?.key, onChange: handleChange }));
|
|
3975
3979
|
});
|
|
3976
|
-
const formatPaymentSystems = (paymentSystems) => paymentSystems?.map((_) => ({ id: _.
|
|
3980
|
+
const formatPaymentSystems = (paymentSystems) => paymentSystems?.map((_) => ({ id: _.key, text: _.text })) ?? [];
|
|
3977
3981
|
|
|
3978
3982
|
const isPlaceholder = (_) => _ === '_';
|
|
3979
3983
|
const isDigit = (_) => /\d/.test(_);
|
|
@@ -4867,11 +4871,12 @@
|
|
|
4867
4871
|
|
|
4868
4872
|
const parseDraftTask = (task) => {
|
|
4869
4873
|
const participant = task.participants[0];
|
|
4874
|
+
const { classCard: cardCategory, codeWord, paymentSystemTypeCd: paymentSystem, currencyCode: currency, } = task;
|
|
4870
4875
|
const { loanAmount: moneyValue, creditPeriod: monthsValue, paymentTypeCd } = task;
|
|
4871
|
-
const {
|
|
4876
|
+
const { birthDate: limitedBirthday, midname: middleName, name, surname, birthPlace, dulIssueDate: dulIssueDateField, dulIssuedBy, dulNumber, dulSerie, dulSubdivisionCode, educationLevelCd: education, registrationDate: participantDateRegistration, houseTypeCd: housing, genderCd, participantContacts = [], participantAddresses = [], employmentContractDate: beginDate, employmentTypeCd: employment, organizationName, organizationInn: inn, organizationActivityTypeCd: employerActivities, organizationTypeCd: organization, organizationKindCd: employerOrganization, employeesNumberCd: amountWorkers, opf: legalForm, seniority: generalSeniority, generalSeniority: experience5Years, jobsNumber, lastWorkDuration: lastJobExperience, positionCd: positionOrganization, maritalStatusCd: familyStatus, childrenDependents: children, totalDependents: familyMembers, otherDependents: dependents, militaryStatusCd: conscription, participantIncomes, snils, armyIdFlg, bankruptcyFlg, shareholderFlg, nameLegalEntity: legalEntityName, creditInRshbCd, payrollCardRshbFlg: isInsurance, consentInsuranceFlg: isSalaryClient, incomeCertificateCd, } = participant;
|
|
4872
4877
|
return {
|
|
4873
4878
|
currency: currency?.key,
|
|
4874
|
-
paymentSystem,
|
|
4879
|
+
paymentSystem: getSelectValue(paymentSystem),
|
|
4875
4880
|
cardCategory: getSelectValue(cardCategory),
|
|
4876
4881
|
codeWord,
|
|
4877
4882
|
limitedBirthday,
|
|
@@ -4906,6 +4911,7 @@
|
|
|
4906
4911
|
familyMembers: familyMembers?.toString(),
|
|
4907
4912
|
dependents: dependents?.toString(),
|
|
4908
4913
|
conscription: getSelectValue(conscription),
|
|
4914
|
+
confirmationIncome: getSelectValue(incomeCertificateCd),
|
|
4909
4915
|
snils,
|
|
4910
4916
|
armyIdFlg,
|
|
4911
4917
|
bankruptcyFlg,
|
|
@@ -7154,7 +7160,7 @@
|
|
|
7154
7160
|
|
|
7155
7161
|
const formStateMap$1 = [
|
|
7156
7162
|
{
|
|
7157
|
-
paymentSystem: {
|
|
7163
|
+
paymentSystem: { key: '', text: '' },
|
|
7158
7164
|
currency: '810',
|
|
7159
7165
|
codeWord: '',
|
|
7160
7166
|
},
|
|
@@ -10467,7 +10473,7 @@
|
|
|
10467
10473
|
slots: () => [HEADER_SLOT, FOOTER_SLOT, STICKY_FOOTER_SLOT],
|
|
10468
10474
|
});
|
|
10469
10475
|
|
|
10470
|
-
const packageVersion = "0.14.
|
|
10476
|
+
const packageVersion = "0.14.711";
|
|
10471
10477
|
|
|
10472
10478
|
exports.Blocks = Blocks;
|
|
10473
10479
|
exports.ContentPage = ContentPage;
|