@tap-payments/auth-jsconnect 2.0.48 → 2.0.49
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/build/@types/app.d.ts +8 -6
- package/build/@types/form.d.ts +23 -22
- package/build/@types/theme.d.ts +1 -1
- package/build/api/account.d.ts +2 -2
- package/build/api/auth.d.ts +11 -11
- package/build/api/availabilityServices.d.ts +3 -3
- package/build/api/axios.js +1 -1
- package/build/api/board.d.ts +3 -3
- package/build/api/country.d.ts +1 -1
- package/build/api/data.d.ts +10 -10
- package/build/api/document.d.ts +25 -0
- package/build/api/document.js +38 -0
- package/build/api/entity.d.ts +10 -20
- package/build/api/entity.js +6 -5
- package/build/api/file.d.ts +2 -1
- package/build/api/file.js +14 -1
- package/build/api/index.d.ts +10 -3
- package/build/api/index.js +3 -1
- package/build/api/individual.d.ts +8 -8
- package/build/api/lead.d.ts +10 -10
- package/build/api/operator.d.ts +1 -1
- package/build/api/operator.js +1 -1
- package/build/api/user.d.ts +2 -2
- package/build/app/settings.d.ts +11 -2
- package/build/app/settings.js +1 -1
- package/build/app/store.d.ts +4 -4
- package/build/assets/locales/ar.json +3 -1
- package/build/assets/locales/en.json +3 -1
- package/build/components/Lottie/Lottie.d.ts +1 -2
- package/build/components/Lottie/Lottie.js +1 -1
- package/build/components/Lottie/index.d.ts +2 -2
- package/build/components/Lottie/index.js +2 -2
- package/build/components/Slide/Slide.d.ts +1 -1
- package/build/constants/app.d.ts +31 -0
- package/build/constants/app.js +43 -1
- package/build/features/app/bank/bankStore.d.ts +73 -10
- package/build/features/app/bank/bankStore.js +29 -15
- package/build/features/app/brand/brandStore.d.ts +104 -12
- package/build/features/app/brand/brandStore.js +65 -66
- package/build/features/app/business/businessStore.d.ts +163 -19
- package/build/features/app/business/businessStore.js +3 -3
- package/build/features/app/connect/connectStore.d.ts +121 -13
- package/build/features/app/connect/connectStore.js +1 -1
- package/build/features/app/connectExpress/connectExpressStore.d.ts +181 -19
- package/build/features/app/connectExpress/connectExpressStore.js +1 -1
- package/build/features/app/entity/entityStore.d.ts +76 -20
- package/build/features/app/entity/entityStore.js +67 -93
- package/build/features/app/individual/individualStore.d.ts +182 -20
- package/build/features/app/individual/individualStore.js +278 -135
- package/build/features/app/password/passwordStore.d.ts +102 -12
- package/build/features/app/password/passwordStore.js +1 -1
- package/build/features/app/signIn/signInStore.d.ts +61 -7
- package/build/features/app/signIn/signInStore.js +1 -1
- package/build/features/app/tax/taxStore.d.ts +62 -8
- package/build/features/app/tax/taxStore.js +25 -12
- package/build/features/bank/screens/BankDetails/BankStatement.d.ts +1 -1
- package/build/features/bank/screens/BankDetails/BankStatement.js +4 -3
- package/build/features/bank/screens/BankDetails/IBAN.js +1 -1
- package/build/features/bank/screens/ResetPasswordSuccess/ResetPasswordSuccess.js +1 -1
- package/build/features/brand/screens/BrandActivities/ActivitiesList.d.ts +13 -13
- package/build/features/brand/screens/BrandActivities/ActivitiesList.js +6 -7
- package/build/features/brand/screens/BrandActivities/CustomerBase.d.ts +11 -11
- package/build/features/brand/screens/BrandActivities/CustomerBase.js +5 -7
- package/build/features/brand/screens/BrandActivities/ExpectedSalesRange.js +5 -7
- package/build/features/brand/screens/BrandActivities/OperationStartDate.d.ts +2 -2
- package/build/features/brand/screens/BrandActivities/RefundPolicy.d.ts +5 -5
- package/build/features/brand/screens/BrandInfo/BrandName.js +1 -1
- package/build/features/brand/screens/ResetPasswordSuccess/ResetPasswordSuccess.js +1 -1
- package/build/features/business/screens/Activities/ActivitiesList.d.ts +13 -13
- package/build/features/business/screens/Activities/OperationStartDate.d.ts +2 -2
- package/build/features/business/screens/BusinessType/Article.d.ts +1 -1
- package/build/features/business/screens/BusinessType/Article.js +1 -1
- package/build/features/business/screens/BusinessType/LicenseCertificate.js +2 -1
- package/build/features/business/screens/BusinessType/LicenseType.d.ts +5 -5
- package/build/features/business/screens/Customers/CustomerLocations.d.ts +11 -11
- package/build/features/business/screens/Customers/RefundPolicy.d.ts +5 -5
- package/build/features/business/screens/ResetPasswordSuccess/ResetPasswordSuccess.js +1 -1
- package/build/features/connect/screens/Individual/Email.js +1 -1
- package/build/features/connect/screens/Merchant/BrandName.js +1 -1
- package/build/features/connectExpress/screens/CollectBusinessInfo/BrandName.js +1 -1
- package/build/features/connectExpress/screens/CollectBusinessInfo/LicenseType.d.ts +5 -5
- package/build/features/connectExpress/screens/CollectIndividualInfo/Email.js +1 -1
- package/build/features/entity/screens/EntityCapital/ActivityList.d.ts +13 -13
- package/build/features/entity/screens/EntityCapital/ActivityList.js +7 -7
- package/build/features/entity/screens/EntityCapital/CapitalPaid.js +3 -4
- package/build/features/entity/screens/EntityCapital/CapitalShareCount.js +3 -4
- package/build/features/entity/screens/EntityCapital/CapitalShareValue.js +3 -4
- package/build/features/entity/screens/EntityName/Article.d.ts +1 -1
- package/build/features/entity/screens/EntityName/Article.js +16 -53
- package/build/features/entity/screens/EntityName/EntityName.js +2 -3
- package/build/features/entity/screens/EntityName/EntityTypeList.d.ts +13 -13
- package/build/features/entity/screens/EntityName/EntityTypeList.js +4 -6
- package/build/features/entity/screens/EntityName/ExpiryDate.d.ts +2 -2
- package/build/features/entity/screens/EntityName/ExpiryDate.js +6 -6
- package/build/features/entity/screens/EntityName/IssuingDate.d.ts +2 -2
- package/build/features/entity/screens/EntityName/IssuingDate.js +4 -5
- package/build/features/entity/screens/EntityName/LegalName.js +2 -4
- package/build/features/entity/screens/EntityName/LicenseCertificate.js +4 -3
- package/build/features/entity/screens/EntityName/LicenseNumber.js +4 -4
- package/build/features/entity/screens/EntityName/UnifiedNumber.js +3 -4
- package/build/features/entity/screens/ResetPasswordSuccess/ResetPasswordSuccess.js +1 -1
- package/build/features/featuresScreens.js +5 -0
- package/build/features/individual/screens/AdditionalIndividualInfo/AdditionalIndividualInfo.d.ts +2 -2
- package/build/features/individual/screens/AdditionalIndividualInfo/CivilIDFile.js +4 -3
- package/build/features/individual/screens/AdditionalIndividualInfo/InfluencerSwitch.js +2 -4
- package/build/features/individual/screens/AdditionalIndividualInfo/MonthlyIncome.js +5 -6
- package/build/features/individual/screens/AdditionalIndividualInfo/Occupation.js +5 -6
- package/build/features/individual/screens/AdditionalIndividualInfo/PEPSwitch.d.ts +4 -4
- package/build/features/individual/screens/AdditionalIndividualInfo/PEPSwitch.js +2 -4
- package/build/features/individual/screens/AdditionalIndividualInfo/SignatureFile.js +4 -3
- package/build/features/individual/screens/AdditionalIndividualInfo/SourceOfIncome.js +5 -6
- package/build/features/individual/screens/IndividualList/CollectPhoneEmail.d.ts +2 -0
- package/build/features/individual/screens/IndividualList/CollectPhoneEmail.js +3 -2
- package/build/features/individual/screens/IndividualList/Email.d.ts +5 -1
- package/build/features/individual/screens/IndividualList/Email.js +73 -8
- package/build/features/individual/screens/IndividualList/IndividualList.d.ts +4 -4
- package/build/features/individual/screens/IndividualList/UserList.js +36 -19
- package/build/features/individual/screens/IndividualList/validation.js +2 -1
- package/build/features/individual/screens/IndividualPersonalInfo/Email.js +2 -3
- package/build/features/individual/screens/IndividualPersonalInfo/ExpiryDate.js +3 -4
- package/build/features/individual/screens/IndividualPersonalInfo/Gender.d.ts +5 -5
- package/build/features/individual/screens/IndividualPersonalInfo/ID.js +2 -3
- package/build/features/individual/screens/IndividualPersonalInfo/IndividualPersonalInfo.d.ts +2 -2
- package/build/features/individual/screens/IndividualPersonalInfo/IssuedCountry.js +6 -7
- package/build/features/individual/screens/IndividualPersonalInfo/MobileNumber.js +5 -6
- package/build/features/individual/screens/IndividualPersonalInfo/Name.js +2 -3
- package/build/features/individual/screens/IndividualPersonalInfo/Nationality.js +6 -7
- package/build/features/individual/screens/IndividualPhoneInfo/MobileNumber.d.ts +12 -0
- package/build/features/individual/screens/IndividualPhoneInfo/MobileNumber.js +143 -0
- package/build/features/individual/screens/IndividualPhoneInfo/PhoneInfo.d.ts +5 -0
- package/build/features/individual/screens/IndividualPhoneInfo/PhoneInfo.js +60 -0
- package/build/features/individual/screens/IndividualPhoneInfo/index.d.ts +3 -0
- package/build/features/individual/screens/IndividualPhoneInfo/index.js +2 -0
- package/build/features/individual/screens/IndividualPhoneInfo/validation.d.ts +8 -0
- package/build/features/individual/screens/IndividualPhoneInfo/validation.js +31 -0
- package/build/features/individual/screens/ResetPasswordSuccess/ResetPasswordSuccess.js +1 -1
- package/build/features/password/screens/ResetPasswordSuccess/ResetPasswordSuccess.js +1 -1
- package/build/features/shared/Address/CountryList.d.ts +9 -9
- package/build/features/shared/Address/InputSelect.d.ts +9 -9
- package/build/features/shared/Address/InputSelect.js +1 -1
- package/build/features/shared/Button/Button.js +1 -1
- package/build/features/shared/Button/EmailProvidersButtons.d.ts +1 -1
- package/build/features/shared/Button/FlowsButtons.d.ts +1 -1
- package/build/features/shared/Button/FlowsButtons.js +1 -1
- package/build/features/shared/Button/{ListButton.d.ts → IndividualActionButtons.d.ts} +5 -4
- package/build/features/shared/Button/IndividualActionButtons.js +132 -0
- package/build/features/shared/Button/index.d.ts +1 -1
- package/build/features/shared/Button/index.js +1 -1
- package/build/features/shared/Containers/FeatureContainer.d.ts +1 -1
- package/build/features/shared/Containers/ScreenContainer.d.ts +1 -1
- package/build/features/shared/Input/Input.d.ts +3 -3
- package/build/features/shared/SuccessFlowButtons/SuccessFlowButtons.js +11 -1
- package/build/features/shared/UploadFile/FileUpload.d.ts +29 -0
- package/build/features/shared/UploadFile/FileUpload.js +263 -0
- package/build/features/shared/UploadFile/UploadFile.d.ts +2 -2
- package/build/features/shared/UploadFile/UploadWrapper.d.ts +33 -0
- package/build/features/shared/UploadFile/UploadWrapper.js +114 -0
- package/build/features/shared/UploadFile/index.d.ts +2 -1
- package/build/features/shared/UploadFile/index.js +2 -1
- package/build/features/shared/UploadMultipleFile/UploadFile.d.ts +9 -20
- package/build/features/shared/UploadMultipleFile/UploadFile.js +109 -24
- package/build/features/shared/UploadMultipleFile/UploadMultipleFile.d.ts +6 -4
- package/build/features/shared/UploadMultipleFile/UploadMultipleFile.js +26 -19
- package/build/features/tax/screens/ResetPasswordSuccess/ResetPasswordSuccess.js +1 -1
- package/build/features/tax/screens/TaxDetails/TaxDocument.js +4 -3
- package/build/features/tax/screens/TaxDetails/VATId.js +3 -4
- package/build/index.d.ts +2 -2
- package/build/index.js +4 -3
- package/build/utils/array.d.ts +3 -1
- package/build/utils/array.js +35 -6
- package/package.json +1 -1
- package/build/features/shared/Button/ListButton.js +0 -125
package/build/api/index.js
CHANGED
|
@@ -14,6 +14,7 @@ import { boardService } from './board';
|
|
|
14
14
|
import { userService } from './user';
|
|
15
15
|
import { brandService } from './brand';
|
|
16
16
|
import { fileService } from './file';
|
|
17
|
+
import { documentService } from './document';
|
|
17
18
|
var API = {
|
|
18
19
|
locationService: locationService,
|
|
19
20
|
operatorService: operatorService,
|
|
@@ -29,7 +30,8 @@ var API = {
|
|
|
29
30
|
boardService: boardService,
|
|
30
31
|
userService: userService,
|
|
31
32
|
brandService: brandService,
|
|
32
|
-
fileService: fileService
|
|
33
|
+
fileService: fileService,
|
|
34
|
+
documentService: documentService
|
|
33
35
|
};
|
|
34
36
|
export { setAxiosGlobalHeaders, removeAxiosGlobalHeaders, axiosInstance, getAxiosHeaders };
|
|
35
37
|
export default API;
|
|
@@ -1,8 +1,8 @@
|
|
|
1
|
-
import { DocumentInfo } from './
|
|
2
|
-
export
|
|
1
|
+
import { DocumentInfo } from './document';
|
|
2
|
+
export type BrandListBody = {
|
|
3
3
|
individual_id: string;
|
|
4
4
|
};
|
|
5
|
-
export
|
|
5
|
+
export type UpdateBrandBody = {
|
|
6
6
|
id: string;
|
|
7
7
|
name?: {
|
|
8
8
|
en: string;
|
|
@@ -45,8 +45,8 @@ export declare type UpdateBrandBody = {
|
|
|
45
45
|
currency?: string;
|
|
46
46
|
};
|
|
47
47
|
customer_base?: {
|
|
48
|
-
id
|
|
49
|
-
period
|
|
48
|
+
id?: string;
|
|
49
|
+
period?: string;
|
|
50
50
|
locations?: Array<{
|
|
51
51
|
id: string;
|
|
52
52
|
}>;
|
|
@@ -64,14 +64,14 @@ export declare type UpdateBrandBody = {
|
|
|
64
64
|
step_name?: string;
|
|
65
65
|
encryption_contract?: Array<string>;
|
|
66
66
|
};
|
|
67
|
-
export
|
|
67
|
+
export type UpdateSalesChannels = {
|
|
68
68
|
id?: string;
|
|
69
69
|
channel_services: Array<{
|
|
70
70
|
id: string;
|
|
71
71
|
address: string;
|
|
72
72
|
}>;
|
|
73
73
|
};
|
|
74
|
-
export
|
|
74
|
+
export type UpdateIndividualBody = {
|
|
75
75
|
id: string;
|
|
76
76
|
type: string;
|
|
77
77
|
names?: {
|
|
@@ -131,7 +131,7 @@ export declare type UpdateIndividualBody = {
|
|
|
131
131
|
step_name?: string;
|
|
132
132
|
encryption_contract?: Array<string>;
|
|
133
133
|
};
|
|
134
|
-
export
|
|
134
|
+
export type GetIndividualListBody = {
|
|
135
135
|
page: number;
|
|
136
136
|
limit: number;
|
|
137
137
|
business_id: string;
|
package/build/api/lead.d.ts
CHANGED
|
@@ -1,32 +1,32 @@
|
|
|
1
1
|
import { AxiosRequestConfig } from 'axios';
|
|
2
2
|
import { LanguageMode } from '../@types';
|
|
3
|
-
|
|
3
|
+
type Name = {
|
|
4
4
|
title?: string;
|
|
5
5
|
first?: string;
|
|
6
6
|
middle?: string;
|
|
7
7
|
last?: string;
|
|
8
8
|
};
|
|
9
|
-
|
|
9
|
+
type Contact = {
|
|
10
10
|
email?: string;
|
|
11
11
|
phone?: {
|
|
12
12
|
country_code?: string;
|
|
13
13
|
number?: string;
|
|
14
14
|
};
|
|
15
15
|
};
|
|
16
|
-
|
|
16
|
+
type BusinessName = {
|
|
17
17
|
en?: string;
|
|
18
18
|
ar?: string;
|
|
19
19
|
};
|
|
20
|
-
|
|
20
|
+
type BrandTitle = {
|
|
21
21
|
en?: string;
|
|
22
22
|
ar?: string;
|
|
23
23
|
zh?: string;
|
|
24
24
|
};
|
|
25
|
-
|
|
25
|
+
type BrandContent = {
|
|
26
26
|
tag_line?: BrandTitle;
|
|
27
27
|
about?: BrandTitle;
|
|
28
28
|
};
|
|
29
|
-
|
|
29
|
+
type BrandInfo = {
|
|
30
30
|
id?: string;
|
|
31
31
|
name?: BrandTitle;
|
|
32
32
|
sector?: Array<string>;
|
|
@@ -35,7 +35,7 @@ declare type BrandInfo = {
|
|
|
35
35
|
logo?: string;
|
|
36
36
|
content?: BrandContent;
|
|
37
37
|
};
|
|
38
|
-
export
|
|
38
|
+
export type UpdateLeadBody = {
|
|
39
39
|
step_name?: string;
|
|
40
40
|
id: string;
|
|
41
41
|
encryption_contract?: Array<string>;
|
|
@@ -64,7 +64,7 @@ export declare type UpdateLeadBody = {
|
|
|
64
64
|
team: string;
|
|
65
65
|
};
|
|
66
66
|
};
|
|
67
|
-
export
|
|
67
|
+
export type LeadVerifyBody = {
|
|
68
68
|
verify_token: string;
|
|
69
69
|
service_name: string;
|
|
70
70
|
};
|
|
@@ -73,11 +73,11 @@ export interface LeadOTPVerifyBody extends LeadVerifyBody {
|
|
|
73
73
|
step_name: string;
|
|
74
74
|
encryption_contract: Array<string>;
|
|
75
75
|
}
|
|
76
|
-
export
|
|
76
|
+
export type CreateLeadBody = {
|
|
77
77
|
individual_id: string;
|
|
78
78
|
country_code: string;
|
|
79
79
|
};
|
|
80
|
-
export
|
|
80
|
+
export type LeadIdentityUpdateBody = {
|
|
81
81
|
id: string;
|
|
82
82
|
identification: {
|
|
83
83
|
id: string;
|
package/build/api/operator.d.ts
CHANGED
package/build/api/operator.js
CHANGED
|
@@ -13,7 +13,7 @@ var __generator = (this && this.__generator) || function (thisArg, body) {
|
|
|
13
13
|
function verb(n) { return function (v) { return step([n, v]); }; }
|
|
14
14
|
function step(op) {
|
|
15
15
|
if (f) throw new TypeError("Generator is already executing.");
|
|
16
|
-
while (_) try {
|
|
16
|
+
while (g && (g = 0, op[0] && (_ = 0)), _) try {
|
|
17
17
|
if (f = 1, y && (t = op[0] & 2 ? y["return"] : op[0] ? y["throw"] || ((t = y["return"]) && t.call(y), 0) : y.next) && !(t = t.call(y, op[1])).done) return t;
|
|
18
18
|
if (y = 0, t) op = [op[0] & 2, t.value];
|
|
19
19
|
switch (op[0]) {
|
package/build/api/user.d.ts
CHANGED
package/build/app/settings.d.ts
CHANGED
|
@@ -12,7 +12,16 @@ export declare const fetchAppSettingsSync: import("@reduxjs/toolkit").AsyncThunk
|
|
|
12
12
|
locale: any;
|
|
13
13
|
deviceInfo: DeviceInfo;
|
|
14
14
|
isValidOperator: boolean;
|
|
15
|
-
}, SettingParams, {
|
|
15
|
+
}, SettingParams, {
|
|
16
|
+
state?: unknown;
|
|
17
|
+
dispatch?: import("redux").Dispatch<import("redux").AnyAction> | undefined;
|
|
18
|
+
extra?: unknown;
|
|
19
|
+
rejectValue?: unknown;
|
|
20
|
+
serializedErrorType?: unknown;
|
|
21
|
+
pendingMeta?: unknown;
|
|
22
|
+
fulfilledMeta?: unknown;
|
|
23
|
+
rejectedMeta?: unknown;
|
|
24
|
+
}>;
|
|
16
25
|
export interface SettingsData {
|
|
17
26
|
skin: ThemeMode;
|
|
18
27
|
language: LanguageMode;
|
|
@@ -40,7 +49,7 @@ export declare const settingsSlice: import("@reduxjs/toolkit").Slice<SettingsSta
|
|
|
40
49
|
handleSetAppConfig: (state: SettingsState, action: ActionState<LibConfig>) => void;
|
|
41
50
|
handleSetCountryByIso2: (state: SettingsState, action: ActionState<string>) => void;
|
|
42
51
|
}, "settings">;
|
|
43
|
-
export declare const handleSkin: import("@reduxjs/toolkit").ActionCreatorWithPayload<ThemeMode,
|
|
52
|
+
export declare const handleSkin: import("@reduxjs/toolkit").ActionCreatorWithPayload<ThemeMode, "settings/handleSkin">, handleLanguage: import("@reduxjs/toolkit").ActionCreatorWithPayload<LanguageMode, "settings/handleLanguage">, handleActiveFlowScreens: import("@reduxjs/toolkit").ActionCreatorWithPayload<ScreenStepNavigation[], "settings/handleActiveFlowScreens">, handleNextScreenStep: import("@reduxjs/toolkit").ActionCreatorWithOptionalPayload<string | undefined, "settings/handleNextScreenStep">, handlePrevScreenStep: import("@reduxjs/toolkit").ActionCreatorWithOptionalPayload<string | undefined, "settings/handlePrevScreenStep">, handleCurrentActiveScreen: import("@reduxjs/toolkit").ActionCreatorWithPayload<string, "settings/handleCurrentActiveScreen">, handleSetAppConfig: import("@reduxjs/toolkit").ActionCreatorWithPayload<LibConfig, "settings/handleSetAppConfig">, handleOpen: import("@reduxjs/toolkit").ActionCreatorWithPayload<boolean, "settings/handleOpen">, handleSetCountryByIso2: import("@reduxjs/toolkit").ActionCreatorWithPayload<string, "settings/handleSetCountryByIso2">, handleIsTapOrigin: import("@reduxjs/toolkit").ActionCreatorWithPayload<boolean, "settings/handleIsTapOrigin">;
|
|
44
53
|
declare const _default: import("redux").Reducer<SettingsState, import("redux").AnyAction>;
|
|
45
54
|
export default _default;
|
|
46
55
|
export declare const settingsSelector: (state: RootState) => SettingsState;
|
package/build/app/settings.js
CHANGED
|
@@ -24,7 +24,7 @@ var __generator = (this && this.__generator) || function (thisArg, body) {
|
|
|
24
24
|
function verb(n) { return function (v) { return step([n, v]); }; }
|
|
25
25
|
function step(op) {
|
|
26
26
|
if (f) throw new TypeError("Generator is already executing.");
|
|
27
|
-
while (_) try {
|
|
27
|
+
while (g && (g = 0, op[0] && (_ = 0)), _) try {
|
|
28
28
|
if (f = 1, y && (t = op[0] & 2 ? y["return"] : op[0] ? y["throw"] || ((t = y["return"]) && t.call(y), 0) : y.next) && !(t = t.call(y, op[1])).done) return t;
|
|
29
29
|
if (y = 0, t) op = [op[0] & 2, t.value];
|
|
30
30
|
switch (op[0]) {
|
package/build/app/store.d.ts
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { ThunkAction, Action } from '@reduxjs/toolkit';
|
|
2
|
-
export declare const store: import("@reduxjs/toolkit").
|
|
2
|
+
export declare const store: import("@reduxjs/toolkit/dist/configureStore").ToolkitStore<{
|
|
3
3
|
settings: import("./settings").SettingsState;
|
|
4
4
|
connect: import("../features/app/connect/connectStore").ConnectState;
|
|
5
5
|
business: import("../features/app/business/businessStore").BusinessState;
|
|
@@ -24,6 +24,6 @@ export declare const store: import("@reduxjs/toolkit").EnhancedStore<{
|
|
|
24
24
|
brand: import("../features/app/brand/brandStore").BrandState;
|
|
25
25
|
connectExpress: import("../features/app/connectExpress/connectExpressStore").ConnectExpressState;
|
|
26
26
|
}, import("redux").AnyAction, undefined>]>>;
|
|
27
|
-
export
|
|
28
|
-
export
|
|
29
|
-
export
|
|
27
|
+
export type AppDispatch = typeof store.dispatch;
|
|
28
|
+
export type RootState = ReturnType<typeof store.getState>;
|
|
29
|
+
export type AppThunk<ReturnType = void> = ThunkAction<ReturnType, RootState, unknown, Action<string>>;
|
|
@@ -388,5 +388,7 @@
|
|
|
388
388
|
"share_value_label": "قيمة السهم ({{currency}})",
|
|
389
389
|
"share_value_hint": "0000",
|
|
390
390
|
"brand": "الاسم التجاري",
|
|
391
|
-
"try_again": "حاول مرة أخرى"
|
|
391
|
+
"try_again": "حاول مرة أخرى",
|
|
392
|
+
"file_delete_error": "حدث خطأ ما في حذف الملف. حاول مرة اخرى",
|
|
393
|
+
"file_download_error": "حدث خطأ ما في تحميل الملف. حاول مرة اخرى"
|
|
392
394
|
}
|
|
@@ -418,5 +418,7 @@
|
|
|
418
418
|
"share_value_label": "Share Value ({{currency}})",
|
|
419
419
|
"share_value_hint": "0000",
|
|
420
420
|
"brand": "Brand",
|
|
421
|
-
"try_again": "Try again"
|
|
421
|
+
"try_again": "Try again",
|
|
422
|
+
"file_delete_error": "Something went wrong with deleting file. Please try again",
|
|
423
|
+
"file_download_error": "Something went wrong with downloading file. Please try again"
|
|
422
424
|
}
|
|
@@ -4193,9 +4193,8 @@ export declare const LottieAnimationFiles: {
|
|
|
4193
4193
|
markers: never[];
|
|
4194
4194
|
};
|
|
4195
4195
|
};
|
|
4196
|
-
export declare type LottieAnimationFiles = (typeof LottieAnimationFiles)[keyof typeof LottieAnimationFiles];
|
|
4197
4196
|
interface LottieFileProps extends DetailedHTMLProps<HTMLAttributes<HTMLDivElement>, HTMLDivElement> {
|
|
4198
|
-
file: LottieAnimationFiles;
|
|
4197
|
+
file: (typeof LottieAnimationFiles)[keyof typeof LottieAnimationFiles];
|
|
4199
4198
|
width?: number | string;
|
|
4200
4199
|
height?: number | string;
|
|
4201
4200
|
loop?: boolean;
|
|
@@ -58,7 +58,7 @@ var LottieFile = function (_a) {
|
|
|
58
58
|
return (_jsx(_Fragment, { children: _jsx("div", __assign({ ref: lottieContainer, style: {
|
|
59
59
|
width: width || '100%',
|
|
60
60
|
height: height || '100%'
|
|
61
|
-
}, className: "".concat(props.className
|
|
61
|
+
}, className: "".concat(props.className || '') }, props)) }));
|
|
62
62
|
};
|
|
63
63
|
LottieFile.defaultProps = {
|
|
64
64
|
file: LottieAnimationFiles.start_loading
|
|
@@ -2,5 +2,5 @@ import React from 'react';
|
|
|
2
2
|
import { SlideProps as MUISlideProps } from '@mui/material/Slide';
|
|
3
3
|
export interface SlideProps extends MUISlideProps {
|
|
4
4
|
}
|
|
5
|
-
declare const _default: React.MemoExoticComponent<React.ForwardRefExoticComponent<Pick<SlideProps, "
|
|
5
|
+
declare const _default: React.MemoExoticComponent<React.ForwardRefExoticComponent<Pick<SlideProps, "color" | "direction" | "translate" | "slot" | "style" | "title" | "defaultChecked" | "defaultValue" | "suppressContentEditableWarning" | "suppressHydrationWarning" | "accessKey" | "className" | "contentEditable" | "contextMenu" | "dir" | "draggable" | "hidden" | "id" | "lang" | "nonce" | "placeholder" | "spellCheck" | "tabIndex" | "radioGroup" | "role" | "about" | "datatype" | "inlist" | "prefix" | "property" | "resource" | "typeof" | "vocab" | "autoCapitalize" | "autoCorrect" | "autoSave" | "itemProp" | "itemScope" | "itemType" | "itemID" | "itemRef" | "results" | "security" | "unselectable" | "inputMode" | "is" | "children" | "aria-activedescendant" | "aria-atomic" | "aria-autocomplete" | "aria-busy" | "aria-checked" | "aria-colcount" | "aria-colindex" | "aria-colspan" | "aria-controls" | "aria-current" | "aria-describedby" | "aria-details" | "aria-disabled" | "aria-dropeffect" | "aria-errormessage" | "aria-expanded" | "aria-flowto" | "aria-grabbed" | "aria-haspopup" | "aria-hidden" | "aria-invalid" | "aria-keyshortcuts" | "aria-label" | "aria-labelledby" | "aria-level" | "aria-live" | "aria-modal" | "aria-multiline" | "aria-multiselectable" | "aria-orientation" | "aria-owns" | "aria-placeholder" | "aria-posinset" | "aria-pressed" | "aria-readonly" | "aria-relevant" | "aria-required" | "aria-roledescription" | "aria-rowcount" | "aria-rowindex" | "aria-rowspan" | "aria-selected" | "aria-setsize" | "aria-sort" | "aria-valuemax" | "aria-valuemin" | "aria-valuenow" | "aria-valuetext" | "dangerouslySetInnerHTML" | "onCopy" | "onCopyCapture" | "onCut" | "onCutCapture" | "onPaste" | "onPasteCapture" | "onCompositionEnd" | "onCompositionEndCapture" | "onCompositionStart" | "onCompositionStartCapture" | "onCompositionUpdate" | "onCompositionUpdateCapture" | "onFocus" | "onFocusCapture" | "onBlur" | "onBlurCapture" | "onChange" | "onChangeCapture" | "onBeforeInput" | "onBeforeInputCapture" | "onInput" | "onInputCapture" | "onReset" | "onResetCapture" | "onSubmit" | "onSubmitCapture" | "onInvalid" | "onInvalidCapture" | "onLoad" | "onLoadCapture" | "onError" | "onErrorCapture" | "onKeyDown" | "onKeyDownCapture" | "onKeyPress" | "onKeyPressCapture" | "onKeyUp" | "onKeyUpCapture" | "onAbort" | "onAbortCapture" | "onCanPlay" | "onCanPlayCapture" | "onCanPlayThrough" | "onCanPlayThroughCapture" | "onDurationChange" | "onDurationChangeCapture" | "onEmptied" | "onEmptiedCapture" | "onEncrypted" | "onEncryptedCapture" | "onEnded" | "onEndedCapture" | "onLoadedData" | "onLoadedDataCapture" | "onLoadedMetadata" | "onLoadedMetadataCapture" | "onLoadStart" | "onLoadStartCapture" | "onPause" | "onPauseCapture" | "onPlay" | "onPlayCapture" | "onPlaying" | "onPlayingCapture" | "onProgress" | "onProgressCapture" | "onRateChange" | "onRateChangeCapture" | "onResize" | "onResizeCapture" | "onSeeked" | "onSeekedCapture" | "onSeeking" | "onSeekingCapture" | "onStalled" | "onStalledCapture" | "onSuspend" | "onSuspendCapture" | "onTimeUpdate" | "onTimeUpdateCapture" | "onVolumeChange" | "onVolumeChangeCapture" | "onWaiting" | "onWaitingCapture" | "onAuxClick" | "onAuxClickCapture" | "onClick" | "onClickCapture" | "onContextMenu" | "onContextMenuCapture" | "onDoubleClick" | "onDoubleClickCapture" | "onDrag" | "onDragCapture" | "onDragEnd" | "onDragEndCapture" | "onDragEnter" | "onDragEnterCapture" | "onDragExit" | "onDragExitCapture" | "onDragLeave" | "onDragLeaveCapture" | "onDragOver" | "onDragOverCapture" | "onDragStart" | "onDragStartCapture" | "onDrop" | "onDropCapture" | "onMouseDown" | "onMouseDownCapture" | "onMouseEnter" | "onMouseLeave" | "onMouseMove" | "onMouseMoveCapture" | "onMouseOut" | "onMouseOutCapture" | "onMouseOver" | "onMouseOverCapture" | "onMouseUp" | "onMouseUpCapture" | "onSelect" | "onSelectCapture" | "onTouchCancel" | "onTouchCancelCapture" | "onTouchEnd" | "onTouchEndCapture" | "onTouchMove" | "onTouchMoveCapture" | "onTouchStart" | "onTouchStartCapture" | "onPointerDown" | "onPointerDownCapture" | "onPointerMove" | "onPointerMoveCapture" | "onPointerUp" | "onPointerUpCapture" | "onPointerCancel" | "onPointerCancelCapture" | "onPointerEnter" | "onPointerEnterCapture" | "onPointerLeave" | "onPointerLeaveCapture" | "onPointerOver" | "onPointerOverCapture" | "onPointerOut" | "onPointerOutCapture" | "onGotPointerCapture" | "onGotPointerCaptureCapture" | "onLostPointerCapture" | "onLostPointerCaptureCapture" | "onScroll" | "onScrollCapture" | "onWheel" | "onWheelCapture" | "onAnimationStart" | "onAnimationStartCapture" | "onAnimationEnd" | "onAnimationEndCapture" | "onAnimationIteration" | "onAnimationIterationCapture" | "onTransitionEnd" | "onTransitionEndCapture" | "timeout" | "in" | "mountOnEnter" | "unmountOnExit" | "easing" | "addEndListener" | "onEnter" | "onEntering" | "onEntered" | "onExit" | "onExiting" | "onExited" | "appear" | "enter" | "exit" | "container"> & React.RefAttributes<unknown>>>;
|
|
6
6
|
export default _default;
|
package/build/constants/app.d.ts
CHANGED
|
@@ -135,6 +135,7 @@ export declare const TAX_STEP_NAMES: {
|
|
|
135
135
|
TAX_SUCCESS: string;
|
|
136
136
|
};
|
|
137
137
|
export declare const INDIVIDUAl_STEP_NAMES: {
|
|
138
|
+
PHONE_INFO: string;
|
|
138
139
|
PHONE_AUTH: string;
|
|
139
140
|
INDIVIDUAl_PERSONAL_INFO: string;
|
|
140
141
|
INDIVIDUAl_INFO: string;
|
|
@@ -192,3 +193,33 @@ export declare const BUSINESS_FLOW_SUCCESS: {
|
|
|
192
193
|
status: string;
|
|
193
194
|
url: string;
|
|
194
195
|
}[];
|
|
196
|
+
export declare enum FileRemoveType {
|
|
197
|
+
AOA_FILE_ID = "AOA_file_id"
|
|
198
|
+
}
|
|
199
|
+
export declare enum FileType {
|
|
200
|
+
IMAGES = "images",
|
|
201
|
+
FILES = "files"
|
|
202
|
+
}
|
|
203
|
+
export declare enum FileStatus {
|
|
204
|
+
INIT = "init",
|
|
205
|
+
UPLOADING = "uploading",
|
|
206
|
+
DOWNLOADING = "downloading",
|
|
207
|
+
SUCCESS = "success",
|
|
208
|
+
ERROR = "error",
|
|
209
|
+
ALREADY_UPLOADED = "already_uploaded"
|
|
210
|
+
}
|
|
211
|
+
export declare enum DeleteFileStatus {
|
|
212
|
+
NONE = "none",
|
|
213
|
+
DELETING = "deleting",
|
|
214
|
+
ERROR = "error",
|
|
215
|
+
SUCCESS = "success"
|
|
216
|
+
}
|
|
217
|
+
export type FileInfo = {
|
|
218
|
+
fileId: string;
|
|
219
|
+
docId: string;
|
|
220
|
+
name: string;
|
|
221
|
+
status: FileStatus;
|
|
222
|
+
progress: number;
|
|
223
|
+
error: string;
|
|
224
|
+
deleteStatus: DeleteFileStatus;
|
|
225
|
+
};
|
package/build/constants/app.js
CHANGED
|
@@ -241,7 +241,23 @@ export var BUSINESS_SCREENS_NAVIGATION = [
|
|
|
241
241
|
export var INDIVIDUAL_SCREENS_NAVIGATION = [
|
|
242
242
|
{
|
|
243
243
|
name: 'INDIVIDUAL_VERIFY_STEP',
|
|
244
|
-
next: [
|
|
244
|
+
next: [
|
|
245
|
+
'INDIVIDUAL_PERSONAL_INDIVIDUAL_INFO_STEP',
|
|
246
|
+
'INDIVIDUAL_SUCCESS_FOUR_FLOWS_BUTTONS_STEP',
|
|
247
|
+
'INDIVIDUAL_LIST_STEP',
|
|
248
|
+
'INDIVIDUAL_PHONE_INFO_STEP'
|
|
249
|
+
],
|
|
250
|
+
prev: '',
|
|
251
|
+
order: 1
|
|
252
|
+
},
|
|
253
|
+
{
|
|
254
|
+
name: 'INDIVIDUAL_PHONE_INFO_STEP',
|
|
255
|
+
next: [
|
|
256
|
+
'INDIVIDUAL_PERSONAL_INDIVIDUAL_INFO_STEP',
|
|
257
|
+
'INDIVIDUAL_SUCCESS_FOUR_FLOWS_BUTTONS_STEP',
|
|
258
|
+
'INDIVIDUAL_LIST_STEP',
|
|
259
|
+
'INDIVIDUAL_VERIFY_STEP'
|
|
260
|
+
],
|
|
245
261
|
prev: '',
|
|
246
262
|
order: 1
|
|
247
263
|
},
|
|
@@ -626,6 +642,7 @@ export var TAX_STEP_NAMES = {
|
|
|
626
642
|
TAX_SUCCESS: 'tax_completed'
|
|
627
643
|
};
|
|
628
644
|
export var INDIVIDUAl_STEP_NAMES = {
|
|
645
|
+
PHONE_INFO: 'phone_info',
|
|
629
646
|
PHONE_AUTH: 'individual_phone_auth',
|
|
630
647
|
INDIVIDUAl_PERSONAL_INFO: 'individual_personal_info',
|
|
631
648
|
INDIVIDUAl_INFO: 'individual_info',
|
|
@@ -679,3 +696,28 @@ export var PASSWORD_OPERATION_TYPE = {
|
|
|
679
696
|
RESET_PASSWORD: 'reset_password'
|
|
680
697
|
};
|
|
681
698
|
export var BUSINESS_FLOW_SUCCESS = [{ name: 'business', status: 'completed', url: '' }];
|
|
699
|
+
export var FileRemoveType;
|
|
700
|
+
(function (FileRemoveType) {
|
|
701
|
+
FileRemoveType["AOA_FILE_ID"] = "AOA_file_id";
|
|
702
|
+
})(FileRemoveType || (FileRemoveType = {}));
|
|
703
|
+
export var FileType;
|
|
704
|
+
(function (FileType) {
|
|
705
|
+
FileType["IMAGES"] = "images";
|
|
706
|
+
FileType["FILES"] = "files";
|
|
707
|
+
})(FileType || (FileType = {}));
|
|
708
|
+
export var FileStatus;
|
|
709
|
+
(function (FileStatus) {
|
|
710
|
+
FileStatus["INIT"] = "init";
|
|
711
|
+
FileStatus["UPLOADING"] = "uploading";
|
|
712
|
+
FileStatus["DOWNLOADING"] = "downloading";
|
|
713
|
+
FileStatus["SUCCESS"] = "success";
|
|
714
|
+
FileStatus["ERROR"] = "error";
|
|
715
|
+
FileStatus["ALREADY_UPLOADED"] = "already_uploaded";
|
|
716
|
+
})(FileStatus || (FileStatus = {}));
|
|
717
|
+
export var DeleteFileStatus;
|
|
718
|
+
(function (DeleteFileStatus) {
|
|
719
|
+
DeleteFileStatus["NONE"] = "none";
|
|
720
|
+
DeleteFileStatus["DELETING"] = "deleting";
|
|
721
|
+
DeleteFileStatus["ERROR"] = "error";
|
|
722
|
+
DeleteFileStatus["SUCCESS"] = "success";
|
|
723
|
+
})(DeleteFileStatus || (DeleteFileStatus = {}));
|
|
@@ -1,6 +1,6 @@
|
|
|
1
|
+
import { CancelToken } from 'axios';
|
|
1
2
|
import { RootState } from '../../../app/store';
|
|
2
3
|
import { ActionState, BankFormValues, FlowsTypes, OTPFormValues, ResponseData, SharedState } from '../../../@types';
|
|
3
|
-
import { CancelToken } from 'axios';
|
|
4
4
|
interface VerifyLeadTokenProps {
|
|
5
5
|
token: string;
|
|
6
6
|
isInternally?: boolean;
|
|
@@ -20,33 +20,96 @@ export declare const verifyLeadToken: import("@reduxjs/toolkit").AsyncThunk<{
|
|
|
20
20
|
flows: any;
|
|
21
21
|
};
|
|
22
22
|
token: string;
|
|
23
|
-
}, VerifyLeadTokenProps, {
|
|
23
|
+
}, VerifyLeadTokenProps, {
|
|
24
|
+
state?: unknown;
|
|
25
|
+
dispatch?: import("redux").Dispatch<import("redux").AnyAction> | undefined;
|
|
26
|
+
extra?: unknown;
|
|
27
|
+
rejectValue?: unknown;
|
|
28
|
+
serializedErrorType?: unknown;
|
|
29
|
+
pendingMeta?: unknown;
|
|
30
|
+
fulfilledMeta?: unknown;
|
|
31
|
+
rejectedMeta?: unknown;
|
|
32
|
+
}>;
|
|
24
33
|
export declare const resendOTP: import("@reduxjs/toolkit").AsyncThunk<{
|
|
25
34
|
data: any;
|
|
26
|
-
}, void, {
|
|
35
|
+
}, void, {
|
|
36
|
+
state?: unknown;
|
|
37
|
+
dispatch?: import("redux").Dispatch<import("redux").AnyAction> | undefined;
|
|
38
|
+
extra?: unknown;
|
|
39
|
+
rejectValue?: unknown;
|
|
40
|
+
serializedErrorType?: unknown;
|
|
41
|
+
pendingMeta?: unknown;
|
|
42
|
+
fulfilledMeta?: unknown;
|
|
43
|
+
rejectedMeta?: unknown;
|
|
44
|
+
}>;
|
|
27
45
|
export declare const verifyBankLeadOTP: import("@reduxjs/toolkit").AsyncThunk<{
|
|
28
46
|
data: any;
|
|
29
47
|
formData: OTPFormValues;
|
|
30
|
-
}, OTPFormValues, {
|
|
48
|
+
}, OTPFormValues, {
|
|
49
|
+
state?: unknown;
|
|
50
|
+
dispatch?: import("redux").Dispatch<import("redux").AnyAction> | undefined;
|
|
51
|
+
extra?: unknown;
|
|
52
|
+
rejectValue?: unknown;
|
|
53
|
+
serializedErrorType?: unknown;
|
|
54
|
+
pendingMeta?: unknown;
|
|
55
|
+
fulfilledMeta?: unknown;
|
|
56
|
+
rejectedMeta?: unknown;
|
|
57
|
+
}>;
|
|
31
58
|
export declare const retrieveBoardDetails: import("@reduxjs/toolkit").AsyncThunk<{
|
|
32
59
|
data: any;
|
|
33
|
-
}, string, {
|
|
60
|
+
}, string, {
|
|
61
|
+
state?: unknown;
|
|
62
|
+
dispatch?: import("redux").Dispatch<import("redux").AnyAction> | undefined;
|
|
63
|
+
extra?: unknown;
|
|
64
|
+
rejectValue?: unknown;
|
|
65
|
+
serializedErrorType?: unknown;
|
|
66
|
+
pendingMeta?: unknown;
|
|
67
|
+
fulfilledMeta?: unknown;
|
|
68
|
+
rejectedMeta?: unknown;
|
|
69
|
+
}>;
|
|
34
70
|
export declare const createBankAccount: import("@reduxjs/toolkit").AsyncThunk<{
|
|
35
71
|
data: any;
|
|
36
72
|
formData: BankFormValues;
|
|
37
|
-
}, BankFormValues, {
|
|
73
|
+
}, BankFormValues, {
|
|
74
|
+
state?: unknown;
|
|
75
|
+
dispatch?: import("redux").Dispatch<import("redux").AnyAction> | undefined;
|
|
76
|
+
extra?: unknown;
|
|
77
|
+
rejectValue?: unknown;
|
|
78
|
+
serializedErrorType?: unknown;
|
|
79
|
+
pendingMeta?: unknown;
|
|
80
|
+
fulfilledMeta?: unknown;
|
|
81
|
+
rejectedMeta?: unknown;
|
|
82
|
+
}>;
|
|
38
83
|
export declare const checkIbanBank: import("@reduxjs/toolkit").AsyncThunk<{
|
|
39
84
|
data: any;
|
|
40
85
|
}, {
|
|
41
86
|
iban: string;
|
|
42
87
|
cancelToken: CancelToken;
|
|
43
88
|
onSuccess?: (() => void) | undefined;
|
|
44
|
-
}, {
|
|
89
|
+
}, {
|
|
90
|
+
state?: unknown;
|
|
91
|
+
dispatch?: import("redux").Dispatch<import("redux").AnyAction> | undefined;
|
|
92
|
+
extra?: unknown;
|
|
93
|
+
rejectValue?: unknown;
|
|
94
|
+
serializedErrorType?: unknown;
|
|
95
|
+
pendingMeta?: unknown;
|
|
96
|
+
fulfilledMeta?: unknown;
|
|
97
|
+
rejectedMeta?: unknown;
|
|
98
|
+
}>;
|
|
45
99
|
export declare const updateBoardSuccess: import("@reduxjs/toolkit").AsyncThunk<{
|
|
46
100
|
response: any;
|
|
47
101
|
formData: void;
|
|
48
|
-
} | undefined, void, {
|
|
49
|
-
|
|
102
|
+
} | undefined, void, {
|
|
103
|
+
state?: unknown;
|
|
104
|
+
dispatch?: import("redux").Dispatch<import("redux").AnyAction> | undefined;
|
|
105
|
+
extra?: unknown;
|
|
106
|
+
rejectValue?: unknown;
|
|
107
|
+
serializedErrorType?: unknown;
|
|
108
|
+
pendingMeta?: unknown;
|
|
109
|
+
fulfilledMeta?: unknown;
|
|
110
|
+
rejectedMeta?: unknown;
|
|
111
|
+
}>;
|
|
112
|
+
type VerifyData = {
|
|
50
113
|
token: string;
|
|
51
114
|
};
|
|
52
115
|
export interface BankData {
|
|
@@ -64,7 +127,7 @@ export declare const bankSlice: import("@reduxjs/toolkit").Slice<BankState, {
|
|
|
64
127
|
resetOTPScreen: (state: BankState) => void;
|
|
65
128
|
bankStatementUploadingStatus: (state: BankState, action: ActionState<boolean>) => void;
|
|
66
129
|
}, "bank/store">;
|
|
67
|
-
export declare const clearError: import("@reduxjs/toolkit").ActionCreatorWithoutPayload<
|
|
130
|
+
export declare const clearError: import("@reduxjs/toolkit").ActionCreatorWithoutPayload<"bank/store/clearError">, stopLoader: import("@reduxjs/toolkit").ActionCreatorWithoutPayload<"bank/store/stopLoader">, resetOTPScreen: import("@reduxjs/toolkit").ActionCreatorWithoutPayload<"bank/store/resetOTPScreen">, bankStatementUploadingStatus: import("@reduxjs/toolkit").ActionCreatorWithPayload<boolean, "bank/store/bankStatementUploadingStatus">;
|
|
68
131
|
declare const _default: import("redux").Reducer<BankState, import("redux").AnyAction>;
|
|
69
132
|
export default _default;
|
|
70
133
|
export declare const bankSelector: (state: RootState) => BankState;
|
|
@@ -24,7 +24,7 @@ var __generator = (this && this.__generator) || function (thisArg, body) {
|
|
|
24
24
|
function verb(n) { return function (v) { return step([n, v]); }; }
|
|
25
25
|
function step(op) {
|
|
26
26
|
if (f) throw new TypeError("Generator is already executing.");
|
|
27
|
-
while (_) try {
|
|
27
|
+
while (g && (g = 0, op[0] && (_ = 0)), _) try {
|
|
28
28
|
if (f = 1, y && (t = op[0] & 2 ? y["return"] : op[0] ? y["throw"] || ((t = y["return"]) && t.call(y), 0) : y.next) && !(t = t.call(y, op[1])).done) return t;
|
|
29
29
|
if (y = 0, t) op = [op[0] & 2, t.value];
|
|
30
30
|
switch (op[0]) {
|
|
@@ -48,7 +48,7 @@ var __generator = (this && this.__generator) || function (thisArg, body) {
|
|
|
48
48
|
var _a;
|
|
49
49
|
import { createAsyncThunk, createSlice } from '@reduxjs/toolkit';
|
|
50
50
|
import API from '../../../api';
|
|
51
|
-
import {
|
|
51
|
+
import { FlowsTypes } from '../../../@types';
|
|
52
52
|
import { handleCurrentActiveScreen, handleNextScreenStep, handleSetCountryByIso2 } from '../../../app/settings';
|
|
53
53
|
import { BANK_STEP_NAMES } from '../../../constants';
|
|
54
54
|
export var verifyLeadToken = createAsyncThunk('bankVerifyLeadToken', function (_a, thunkApi) {
|
|
@@ -180,26 +180,39 @@ export var retrieveBoardDetails = createAsyncThunk('retrieveBankEntityInfo', fun
|
|
|
180
180
|
});
|
|
181
181
|
}); });
|
|
182
182
|
export var createBankAccount = createAsyncThunk('createBankAccount', function (params, thunkApi) { return __awaiter(void 0, void 0, void 0, function () {
|
|
183
|
-
var _a, settings, bank, iban, beneficiaryName, bankName, bankStatementId, confirmPolicy, bank_account, isIBANEditable, isBeneficiaryNameEditable, isBankNameEditable, isBankStatementIdEditable, requestBody, data;
|
|
184
|
-
var _b, _c, _d, _e, _f, _g, _h, _j
|
|
185
|
-
return __generator(this, function (
|
|
186
|
-
switch (
|
|
183
|
+
var _a, settings, bank, iban, beneficiaryName, bankName, bankStatementId, confirmPolicy, bank_account, isIBANEditable, isBeneficiaryNameEditable, isBankNameEditable, isBankStatementIdEditable, documentResponse, hasDocument, documentId, documentBody, requestBody, data;
|
|
184
|
+
var _b, _c, _d, _e, _f, _g, _h, _j;
|
|
185
|
+
return __generator(this, function (_k) {
|
|
186
|
+
switch (_k.label) {
|
|
187
187
|
case 0:
|
|
188
188
|
_a = thunkApi.getState(), settings = _a.settings, bank = _a.bank;
|
|
189
189
|
iban = params.iban, beneficiaryName = params.beneficiaryName, bankName = params.bankName, bankStatementId = params.bankStatementId, confirmPolicy = params.confirmPolicy;
|
|
190
190
|
bank_account = (bank.data.verify.responseBody || {}).bank_account;
|
|
191
|
-
isIBANEditable =
|
|
192
|
-
isBeneficiaryNameEditable =
|
|
193
|
-
isBankNameEditable =
|
|
194
|
-
isBankStatementIdEditable =
|
|
191
|
+
isIBANEditable = true;
|
|
192
|
+
isBeneficiaryNameEditable = true;
|
|
193
|
+
isBankNameEditable = true;
|
|
194
|
+
isBankStatementIdEditable = true;
|
|
195
|
+
documentResponse = undefined;
|
|
196
|
+
hasDocument = isBankStatementIdEditable && (bankStatementId || []).length > 0;
|
|
197
|
+
documentId = (_b = bank_account === null || bank_account === void 0 ? void 0 : bank_account.document) === null || _b === void 0 ? void 0 : _b.id;
|
|
198
|
+
if (!(documentId && hasDocument)) return [3, 2];
|
|
199
|
+
documentBody = {
|
|
200
|
+
id: documentId,
|
|
201
|
+
files: bankStatementId || []
|
|
202
|
+
};
|
|
203
|
+
return [4, API.documentService.addFilesToExistingDocument(documentBody)];
|
|
204
|
+
case 1:
|
|
205
|
+
documentResponse = _k.sent();
|
|
206
|
+
_k.label = 2;
|
|
207
|
+
case 2:
|
|
195
208
|
requestBody = {
|
|
196
|
-
wallet_id: (
|
|
209
|
+
wallet_id: (_g = (_f = (_e = (_d = (_c = bank.data.verify.responseBody) === null || _c === void 0 ? void 0 : _c.business) === null || _d === void 0 ? void 0 : _d.entity) === null || _e === void 0 ? void 0 : _e.merchant) === null || _f === void 0 ? void 0 : _f.wallet) === null || _g === void 0 ? void 0 : _g.id,
|
|
197
210
|
bank_account: {
|
|
198
211
|
iban: isIBANEditable ? iban : undefined,
|
|
199
212
|
beneficiary_name: isBeneficiaryNameEditable ? beneficiaryName : undefined,
|
|
200
213
|
bank_name: isBankNameEditable ? bankName : undefined,
|
|
201
214
|
is_acknowledged: confirmPolicy,
|
|
202
|
-
document:
|
|
215
|
+
document: !documentId && hasDocument
|
|
203
216
|
? {
|
|
204
217
|
type: 'bank_statement',
|
|
205
218
|
files: bankStatementId || []
|
|
@@ -210,11 +223,12 @@ export var createBankAccount = createAsyncThunk('createBankAccount', function (p
|
|
|
210
223
|
encryption_contract: ['bank_account.iban', 'bank_account.beneficiary_name', 'bank_account.bank_name']
|
|
211
224
|
};
|
|
212
225
|
return [4, API.entityService.createBankAccount(requestBody)];
|
|
213
|
-
case
|
|
214
|
-
data = (
|
|
226
|
+
case 3:
|
|
227
|
+
data = (_k.sent()).data;
|
|
215
228
|
if (!data.errors) {
|
|
229
|
+
data.documentData = documentResponse;
|
|
216
230
|
thunkApi.dispatch(handleNextScreenStep());
|
|
217
|
-
(
|
|
231
|
+
(_j = (_h = settings.data.appConfig).onStepCompleted) === null || _j === void 0 ? void 0 : _j.call(_h, settings.data.activeScreen.name, requestBody);
|
|
218
232
|
}
|
|
219
233
|
return [2, { data: data, formData: params }];
|
|
220
234
|
}
|