@tap-payments/auth-jsconnect 2.0.71-test → 2.0.75-test

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.
@@ -90,8 +90,11 @@ export interface License {
90
90
  type: string;
91
91
  }
92
92
  export interface Activity {
93
- ar: string;
94
- en: string;
93
+ id: string;
94
+ name: {
95
+ ar: string;
96
+ en: string;
97
+ };
95
98
  }
96
99
  export interface SalesChannel {
97
100
  id: string;
@@ -32,6 +32,10 @@ export declare type BrandFormValues = {
32
32
  website: string;
33
33
  twitter: string;
34
34
  instagram: string;
35
+ apple_store: string;
36
+ play_store: string;
37
+ call_center: string;
38
+ physical_store: string;
35
39
  };
36
40
  termAndConditionChecked: boolean;
37
41
  selectedBrandItem: BrandInfo;
@@ -43,7 +47,6 @@ export declare type BusinessTypeFormValues = {
43
47
  };
44
48
  export declare type ActivitiesFormValues = {
45
49
  activities: Array<Activity> | undefined;
46
- salesChannels: Array<SalesChannel>;
47
50
  operationStartDate: string;
48
51
  };
49
52
  export declare type CustomersFormValues = {
@@ -1,7 +1,8 @@
1
- import { BrandListBody, UpdateBrandBody } from '../api/individual';
1
+ import { BrandListBody, UpdateBrandBody, UpdateSalesChannels } from '../api/individual';
2
2
  declare const brandService: {
3
3
  retrieveBrand: (id: string) => Promise<any>;
4
4
  getBrandList: (data: BrandListBody) => Promise<any>;
5
5
  updateBrandInfo: ({ id, ...data }: UpdateBrandBody) => Promise<any>;
6
+ updateBrandSales: ({ id, ...data }: UpdateSalesChannels) => void;
6
7
  };
7
8
  export { brandService };
@@ -32,9 +32,18 @@ var updateBrandInfo = function (_a) {
32
32
  data: data
33
33
  });
34
34
  };
35
+ var updateBrandSales = function (_a) {
36
+ var id = _a.id, data = __rest(_a, ["id"]);
37
+ httpClient({
38
+ method: 'put',
39
+ url: "".concat(ENDPOINT_PATHS.BRAND_SALES_CHANNELS, "/").concat(id),
40
+ data: data
41
+ });
42
+ };
35
43
  var brandService = {
36
44
  retrieveBrand: retrieveBrand,
37
45
  getBrandList: getBrandList,
38
- updateBrandInfo: updateBrandInfo
46
+ updateBrandInfo: updateBrandInfo,
47
+ updateBrandSales: updateBrandSales
39
48
  };
40
49
  export { brandService };
@@ -1,3 +1,4 @@
1
+ import { AxiosRequestConfig } from 'axios';
1
2
  declare type GetOccupationBody = {
2
3
  page: number;
3
4
  };
@@ -32,5 +33,6 @@ declare const dataService: {
32
33
  getSourceOfIncome: (data: GetSourceOfIncomeBody) => Promise<any>;
33
34
  getMonthlyIncome: (data: GetMonthlyIncomeBody) => Promise<any>;
34
35
  getOccupation: (data: GetOccupationBody) => Promise<any>;
36
+ getActivities: (config?: AxiosRequestConfig) => Promise<any>;
35
37
  };
36
38
  export { dataService };
package/build/api/data.js CHANGED
@@ -1,3 +1,14 @@
1
+ var __assign = (this && this.__assign) || function () {
2
+ __assign = Object.assign || function(t) {
3
+ for (var s, i = 1, n = arguments.length; i < n; i++) {
4
+ s = arguments[i];
5
+ for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p))
6
+ t[p] = s[p];
7
+ }
8
+ return t;
9
+ };
10
+ return __assign.apply(this, arguments);
11
+ };
1
12
  import { httpClient } from './axios';
2
13
  import { ENDPOINT_PATHS } from '../constants';
3
14
  var getChannelsOfServices = function (data) {
@@ -49,6 +60,9 @@ var getOccupation = function (data) {
49
60
  data: data
50
61
  });
51
62
  };
63
+ var getActivities = function (config) {
64
+ return httpClient(__assign({ method: 'post', url: "".concat(ENDPOINT_PATHS.RETRIEVE_ACTIVITIES_LIST_PATH) }, config));
65
+ };
52
66
  var dataService = {
53
67
  getChannelsOfServices: getChannelsOfServices,
54
68
  getCustomerBases: getCustomerBases,
@@ -56,6 +70,7 @@ var dataService = {
56
70
  getExpectedCustomerSales: getExpectedCustomerSales,
57
71
  getSourceOfIncome: getSourceOfIncome,
58
72
  getMonthlyIncome: getMonthlyIncome,
59
- getOccupation: getOccupation
73
+ getOccupation: getOccupation,
74
+ getActivities: getActivities
60
75
  };
61
76
  export { dataService };
@@ -2,7 +2,9 @@ import { AxiosRequestConfig } from 'axios';
2
2
  export declare type EntityInfoBody = {
3
3
  id: string;
4
4
  lead_id?: string;
5
- activities?: Array<string>;
5
+ activities?: Array<{
6
+ id: string;
7
+ }>;
6
8
  license_name?: string;
7
9
  license_number?: string;
8
10
  business_operation_start_at?: string;
@@ -77,6 +77,7 @@ declare const API: {
77
77
  getOccupation: (data: {
78
78
  page: number;
79
79
  }) => Promise<any>;
80
+ getActivities: (config?: import("axios").AxiosRequestConfig<any> | undefined) => Promise<any>;
80
81
  };
81
82
  individualService: {
82
83
  retrieveIndividualInfo: (id: string) => Promise<any>;
@@ -95,6 +96,7 @@ declare const API: {
95
96
  retrieveBrand: (id: string) => Promise<any>;
96
97
  getBrandList: (data: BrandListBody) => Promise<any>;
97
98
  updateBrandInfo: ({ id, ...data }: UpdateBrandBody) => Promise<any>;
99
+ updateBrandSales: ({ id, ...data }: import("./individual").UpdateSalesChannels) => void;
98
100
  };
99
101
  };
100
102
  export type { ValidateOperatorBody, CreateAuthBody, VerifyAuthBody, CreateLeadBody, UpdateLeadBody, LeadVerifyBody, LeadOTPVerifyBody, CheckEmailBody, CheckBrandBody, LeadIdentityUpdateBody, EntityInfoBody, CreateAccountBody, EntityBankUpdateBody, CreatePasswordBody, BrandListBody, VerifyOperationAuthBody, ResetPasswordVerifyAuthBody, UpdateBoardBody, UpdateBrandBody, DataElementBody };
@@ -3,29 +3,58 @@ export declare type BrandListBody = {
3
3
  };
4
4
  export declare type UpdateBrandBody = {
5
5
  id: string;
6
- brand: {
7
- activities?: Array<string>;
8
- business_operation_start_at?: string;
9
- channel_services?: Array<string>;
10
- physical_store_available?: boolean;
11
- monthly_sales_range?: string;
12
- customers_served_monthly?: string;
13
- customers_base?: Array<string>;
14
- vat_id?: string;
15
- agree_chargeback?: boolean;
16
- agree_refund?: boolean;
17
- employer_name?: string;
18
- employer_country?: string | null;
19
- source_income?: Array<string | undefined>;
20
- actual_income?: string;
21
- is_relative_PEP?: boolean | null;
22
- is_influencer?: boolean | null;
23
- is_vat_acknowledged?: boolean;
24
- occupation?: string;
6
+ name?: {
7
+ en: string;
8
+ ar: string;
9
+ };
10
+ sectors?: Array<{
11
+ id: string;
12
+ }>;
13
+ website?: string;
14
+ social?: Array<string>;
15
+ logo?: string;
16
+ content?: {
17
+ tag_line?: {
18
+ en: string;
19
+ ar: string;
20
+ zh: string;
21
+ };
22
+ about?: {
23
+ en: string;
24
+ ar: string;
25
+ zh: string;
26
+ };
27
+ };
28
+ activities?: Array<{
29
+ id: string;
30
+ }>;
31
+ channel_services?: Array<{
32
+ id: string;
33
+ address: string;
34
+ }>;
35
+ operations?: {
36
+ start_date?: string;
37
+ sales?: {
38
+ id: string;
39
+ period: string;
40
+ currency: string;
41
+ };
42
+ customer_base?: {
43
+ id: string;
44
+ period: string;
45
+ locations: Array<string>;
46
+ };
25
47
  };
26
48
  step_name: string;
27
49
  encryption_contract?: Array<string>;
28
50
  };
51
+ export declare type UpdateSalesChannels = {
52
+ id?: string;
53
+ channel_services: Array<{
54
+ id: string;
55
+ address: string;
56
+ }>;
57
+ };
29
58
  declare const individualService: {
30
59
  retrieveIndividualInfo: (id: string) => Promise<any>;
31
60
  };
@@ -31,5 +31,7 @@ export declare const ENDPOINT_PATHS: {
31
31
  BOARD: string;
32
32
  TOKEN_VERIFY: string;
33
33
  BRAND: string;
34
+ BRAND_SALES_CHANNELS: string;
34
35
  VERIFY_AUTH_OTP: string;
36
+ RETRIEVE_ACTIVITIES_LIST_PATH: string;
35
37
  };
@@ -8,6 +8,7 @@ var OPERATOR_PATH = '/operator';
8
8
  var AUTH_PATH = '/auth';
9
9
  var LEAD_PATH = '/lead';
10
10
  var RETRIEVE_ENTITY_LIST_PATH = '/lead/entity/list';
11
+ var RETRIEVE_ACTIVITIES_LIST_PATH = '/entity/activities/list';
11
12
  var ENTITY_PATH = '/entity';
12
13
  var INDIVIDUAL_PATH = '/individual';
13
14
  var BANK_PATH = '/bankaccount';
@@ -25,6 +26,7 @@ var MONTHLY_INCOME_PATH = '/v2/monthlyIncome';
25
26
  var OCCUPATION_PATH = '/v2/occupation';
26
27
  var BRAND_PATH = '/brand';
27
28
  var BRAND_LIST_PATH = "".concat(BRAND_PATH, "/list");
29
+ var BRAND_SALES_CHANNELS = "".concat(BRAND_PATH, "/channel/services");
28
30
  var FIREBASE_URL = 'https://goconnect-195cd-default-rtdb.asia-southeast1.firebasedatabase.app/locale.json';
29
31
  var FILES = '/files';
30
32
  var TOKEN_VERIFY_PATH = '/token/verify';
@@ -65,5 +67,7 @@ export var ENDPOINT_PATHS = {
65
67
  BOARD: BOARD_PATH,
66
68
  TOKEN_VERIFY: TOKEN_VERIFY_PATH,
67
69
  BRAND: BRAND_PATH,
68
- VERIFY_AUTH_OTP: VERIFY_AUTH_OTP_PATH
70
+ BRAND_SALES_CHANNELS: BRAND_SALES_CHANNELS,
71
+ VERIFY_AUTH_OTP: VERIFY_AUTH_OTP_PATH,
72
+ RETRIEVE_ACTIVITIES_LIST_PATH: RETRIEVE_ACTIVITIES_LIST_PATH
69
73
  };
@@ -1,5 +1,5 @@
1
1
  import { RootState } from '../../../app/store';
2
- import { ActivitiesFormValues, CustomersFormValues, BusinessTypeFormValues, NIDFormValues, OTPFormValues, ResponseData, SharedState, FlowsTypes, Activity, SalesChannel, CivilFormValues } from '../../../@types';
2
+ import { ActivitiesFormValues, CustomersFormValues, BusinessTypeFormValues, NIDFormValues, OTPFormValues, ResponseData, SharedState, FlowsTypes, Activity, CivilFormValues } from '../../../@types';
3
3
  export declare const verifyLeadToken: import("@reduxjs/toolkit").AsyncThunk<{
4
4
  data: any;
5
5
  leadData: any;
@@ -37,7 +37,6 @@ export declare const updateLeadIdentity: import("@reduxjs/toolkit").AsyncThunk<{
37
37
  };
38
38
  }, NIDFormValues, {}>;
39
39
  export declare const resendOTPLeadIdentity: import("@reduxjs/toolkit").AsyncThunk<any, void, {}>;
40
- export declare const retrieveChannels: import("@reduxjs/toolkit").AsyncThunk<any, void, {}>;
41
40
  export declare const retrieveEntityList: import("@reduxjs/toolkit").AsyncThunk<any, {
42
41
  leadId: string;
43
42
  }, {}>;
@@ -53,7 +52,6 @@ export declare const updateActivitiesInfo: import("@reduxjs/toolkit").AsyncThunk
53
52
  data: any;
54
53
  formData: {
55
54
  activities: Activity[] | undefined;
56
- salesChannels: SalesChannel[];
57
55
  operationStartDate: string;
58
56
  };
59
57
  }, ActivitiesFormValues, {}>;