@zeniai/client-epic-state 4.10.7 → 4.10.9

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.
Files changed (98) hide show
  1. package/lib/commonPayloadTypes/agingReportPayloadTypes.d.ts +1 -0
  2. package/lib/commonPayloadTypes/subAccountView/subAccountPayloadHelper.js +2 -2
  3. package/lib/commonStateTypes/accountView/{getNestedAccountIDHeirarchyForReport.d.ts → getNestedAccountIDHierarchyForReport.d.ts} +2 -2
  4. package/lib/commonStateTypes/accountView/nestedAccountID.d.ts +2 -2
  5. package/lib/commonStateTypes/agingBalance/agingBalance.d.ts +4 -0
  6. package/lib/commonStateTypes/agingBalance/agingBalance.js +4 -1
  7. package/lib/commonStateTypes/classesView/getNestedClassIDHierarchyForReport.d.ts +2 -2
  8. package/lib/commonStateTypes/classesView/nestedClassID.d.ts +2 -2
  9. package/lib/commonStateTypes/customerView/getNestedCustomerHierarchy.d.ts +9 -0
  10. package/lib/commonStateTypes/customerView/getNestedCustomerHierarchy.js +46 -0
  11. package/lib/commonStateTypes/customerView/nestedCustomerID.d.ts +42 -0
  12. package/lib/commonStateTypes/customerView/nestedCustomerID.js +9 -0
  13. package/lib/commonStateTypes/selectorTypes/classesViewSelectorReport.d.ts +2 -2
  14. package/lib/commonStateTypes/viewAndReport/agingReportStateTypes.d.ts +4 -7
  15. package/lib/entity/account/subAccountSelector.d.ts +1 -1
  16. package/lib/entity/account/subAccountSelector.js +7 -7
  17. package/lib/entity/accountGroup/accountGroupV2Selector.js +3 -3
  18. package/lib/entity/class/classSelectorV2.d.ts +1 -1
  19. package/lib/entity/class/classSelectorV2.js +10 -10
  20. package/lib/entity/customer/customerPayload.d.ts +1 -1
  21. package/lib/entity/customer/customerPayload.js +1 -1
  22. package/lib/entity/customer/customerReducer.d.ts +1 -1
  23. package/lib/entity/customer/customerSelector.d.ts +1 -1
  24. package/lib/entity/customerIncome/customerIncomeTrend.d.ts +1 -1
  25. package/lib/entity/customerIncome/customerIncomeTrendReducer.d.ts +1 -1
  26. package/lib/entity/sectionAccountsView/getNestedAccountIDHierarchyForSection.js +9 -9
  27. package/lib/entity/sectionAccountsView/sectionAccountsViewEpic.js +2 -2
  28. package/lib/entity/sectionAccountsView/sectionAccountsViewSelector.js +3 -3
  29. package/lib/entity/sectionClassesViewV2/sectionClassesViewEpic.js +2 -2
  30. package/lib/entity/sectionClassesViewV2/sectionClassesViewSelector.js +7 -7
  31. package/lib/entity/sectionClassesViewV2/selectorHelpers/getNestedClassIDHierarchyForSection.js +7 -7
  32. package/lib/entity/transaction/stateTypes/customerTransaction.d.ts +1 -1
  33. package/lib/entity/transaction/stateTypes/transactionLine.d.ts +1 -1
  34. package/lib/index.d.ts +14 -12
  35. package/lib/index.js +7 -6
  36. package/lib/reducer.d.ts +1 -1
  37. package/lib/view/accountList/accountListReducer.js +2 -2
  38. package/lib/view/accountList/accountListSelector.d.ts +3 -3
  39. package/lib/view/accountList/accountListSelector.js +3 -3
  40. package/lib/view/accountList/accountListState.d.ts +2 -2
  41. package/lib/view/accountMappingView/accountMappingPayload.js +25 -0
  42. package/lib/view/accountMappingView/accountMappingReducer.js +19 -19
  43. package/lib/view/accountMappingView/accountMappingState.d.ts +8 -8
  44. package/lib/view/accountMappingView/accountMappingViewSelector.d.ts +8 -8
  45. package/lib/view/accountMappingView/accountMappingViewSelector.js +7 -7
  46. package/lib/view/apAgingView/apAgingReport/apAgingReducer.d.ts +7 -5
  47. package/lib/view/apAgingView/apAgingReport/apAgingReducer.js +34 -15
  48. package/lib/view/apAgingView/apAgingReport/apAgingSelector.d.ts +1 -1
  49. package/lib/view/apAgingView/apAgingReport/apAgingSelector.js +29 -16
  50. package/lib/view/apAgingView/apAgingReport/apAgingState.d.ts +6 -3
  51. package/lib/view/apAgingView/apAgingReport/fetchApAgingEpic.js +11 -7
  52. package/lib/view/arAgingView/arAgingDetail/arAgingDetailSelector.d.ts +1 -1
  53. package/lib/view/arAgingView/arAgingReport/arAgingPayload.js +8 -1
  54. package/lib/view/arAgingView/arAgingReport/arAgingReducer.d.ts +13 -7
  55. package/lib/view/arAgingView/arAgingReport/arAgingReducer.js +49 -15
  56. package/lib/view/arAgingView/arAgingReport/arAgingSelector.d.ts +12 -6
  57. package/lib/view/arAgingView/arAgingReport/arAgingSelector.js +68 -35
  58. package/lib/view/arAgingView/arAgingReport/arAgingState.d.ts +12 -4
  59. package/lib/view/arAgingView/arAgingReport/fetchArAgingEpic.js +10 -7
  60. package/lib/view/classList/classListSelector.d.ts +3 -3
  61. package/lib/view/classList/classListSelector.js +3 -3
  62. package/lib/view/classList/classListState.d.ts +2 -2
  63. package/lib/view/commonVendorView/transactionVendorView/transactionVendorViewSelector.d.ts +4 -4
  64. package/lib/view/commonVendorView/transactionVendorView/transactionVendorViewSelector.js +4 -4
  65. package/lib/view/commonVendorView/vendorView/vendorViewSelector.d.ts +4 -4
  66. package/lib/view/commonVendorView/vendorView/vendorViewSelector.js +4 -4
  67. package/lib/view/commonVendorView/vendorsTabVendorView/vendorsTabVendorViewSelector.d.ts +4 -4
  68. package/lib/view/commonVendorView/vendorsTabVendorView/vendorsTabVendorViewSelector.js +4 -4
  69. package/lib/view/dashboard/dashboardEpic.js +6 -4
  70. package/lib/view/netBurnOrIncomeClassesView/netBurnOrIncomeClassesViewReducer.js +3 -3
  71. package/lib/view/netBurnOrIncomeClassesView/netBurnOrIncomeClassesViewSelector.js +3 -3
  72. package/lib/view/netBurnOrIncomeClassesView/netBurnOrIncomeClassesViewState.d.ts +2 -2
  73. package/lib/view/opExClassesView/opExClassesViewReducer.js +3 -3
  74. package/lib/view/opExClassesView/opExClassesViewSelector.js +3 -3
  75. package/lib/view/opExClassesView/opExClassesViewState.d.ts +2 -2
  76. package/lib/view/profitAndLossClassesView/profitAndLossClassesViewReducer.js +3 -3
  77. package/lib/view/profitAndLossClassesView/profitAndLossClassesViewSelector.js +2 -2
  78. package/lib/view/profitAndLossClassesView/profitAndLossClassesViewState.d.ts +2 -2
  79. package/lib/view/revenueClassesView/revenueClassesViewReducer.js +3 -3
  80. package/lib/view/revenueClassesView/revenueClassesViewSelector.js +3 -3
  81. package/lib/view/revenueClassesView/revenueClassesViewState.d.ts +2 -2
  82. package/lib/view/scheduleView/scheduleDetailView/scheduleDetailSelector.d.ts +5 -5
  83. package/lib/view/scheduleView/scheduleDetailView/scheduleDetailSelector.js +5 -5
  84. package/lib/view/scheduleView/scheduleListView/scheduleListHelper.d.ts +2 -2
  85. package/lib/view/scheduleView/scheduleListView/scheduleListSelector.d.ts +2 -2
  86. package/lib/view/scheduleView/scheduleListView/scheduleListSelector.js +1 -1
  87. package/lib/view/spendManagement/billPay/editBillView/editBillViewSelector.d.ts +4 -4
  88. package/lib/view/spendManagement/billPay/editBillView/editBillViewSelector.js +4 -4
  89. package/lib/view/spendManagement/reimbursement/editRemiView/editRemiViewSelector.d.ts +4 -4
  90. package/lib/view/spendManagement/reimbursement/editRemiView/editRemiViewSelector.js +4 -4
  91. package/lib/view/transactionDetail/transactionDetailSelector.d.ts +4 -4
  92. package/lib/view/transactionDetail/transactionDetailSelector.js +4 -4
  93. package/lib/view/transactionDetail/transactionDetailState.d.ts +1 -1
  94. package/lib/view/transactionDetail/transactionDetailTypes.d.ts +1 -1
  95. package/package.json +1 -1
  96. package/lib/commonStateTypes/accountView/{getNestedAccountIDHeirarchyForReport.js → getNestedAccountIDHierarchyForReport.js} +0 -0
  97. package/lib/entity/customer/{customer.d.ts → customerState.d.ts} +4 -4
  98. /package/lib/entity/customer/{customer.js → customerState.js} +0 -0
@@ -76,7 +76,7 @@ const getScheduleListReport = (state, scheduleType) => {
76
76
  const scheduleState = (0, scheduleListReducer_1.getState)(scheduleListState, scheduleType);
77
77
  const downloadState = scheduleState.downloadState;
78
78
  const allScheduleAccounts = (0, accountListSelector_1.getAccountList)(accountState, accountListState, (0, scheduleListHelper_1.getAccountListKeyForSchedules)());
79
- let allNestedAccounts = (0, accountListSelector_1.getNestedAccountListHeirarchy)(accountListState, (0, scheduleListHelper_1.getAccountListKeyForSchedules)());
79
+ let allNestedAccounts = (0, accountListSelector_1.getNestedAccountListHierarchy)(accountListState, (0, scheduleListHelper_1.getAccountListKeyForSchedules)());
80
80
  let allAccounts = allScheduleAccounts.accounts;
81
81
  const accountTypes = (0, scheduleListHelper_1.getAccountsTypesForScheduleList)(scheduleType);
82
82
  const accountLabel = (0, scheduleListHelper_1.getAccountLabelForScheduleType)(scheduleType);
@@ -17,8 +17,8 @@ import { BillPaySetupApproverView } from '../billPaySetupApproverView/billPaySet
17
17
  import { User } from '../../../../entity/user/userState';
18
18
  import { BillPayConfig, BillPayConfigState, AccountTypeSubConfigCodeKeyType } from '../billPayConfig/billPayConfigState';
19
19
  import { ActivityHistorySelectorView } from '../../commonHistoryView/commonHistorySelector';
20
- import { NestedAccountHeirarchyForReport } from '../../../../commonStateTypes/accountView/nestedAccountID';
21
- import { NestedClassHeirarchyForReport } from '../../../../commonStateTypes/classesView/nestedClassID';
20
+ import { NestedAccountHierarchyForReport } from '../../../../commonStateTypes/accountView/nestedAccountID';
21
+ import { NestedClassHierarchyForReport } from '../../../../commonStateTypes/classesView/nestedClassID';
22
22
  import { DuplicateBillsSelectorView } from '../billPayReview/billPayReviewSelector';
23
23
  import { PiLabel } from '../../../../entity/paymentInstrument/paymentInstrument';
24
24
  import { RecommendationByLineId } from '../../../../entity/transaction/stateTypes/transaction';
@@ -96,8 +96,8 @@ export interface EditBillDetailSelectorView extends SelectorView {
96
96
  toAccountVendorEmail?: string;
97
97
  isCollectToAccountInfoFromVendorContact: boolean;
98
98
  vendorContactSaveStatus?: FetchStateAndError;
99
- accountsHeirarchyList: NestedAccountHeirarchyForReport[];
100
- classHeirarchyList: NestedClassHeirarchyForReport[];
99
+ accountsHierarchyList: NestedAccountHierarchyForReport[];
100
+ classHierarchyList: NestedClassHierarchyForReport[];
101
101
  latestApprovedDate?: ZeniDate;
102
102
  recommendationByLineID?: RecommendationByLineId;
103
103
  vendorDetailLocalData?: VendorDetailLocalData;
@@ -299,8 +299,8 @@ const getEditBillDetail = (state, isVendorRecommendationFeatureEnabled, isZeniAc
299
299
  });
300
300
  }
301
301
  const billHistory = (0, commonHistorySelector_1.getActivityHistory)(commonHistoryState, billId !== null && billId !== void 0 ? billId : '', 'bill_pay');
302
- const accountsHeirarchyList = (0, accountListSelector_1.getNestedAccountListHeirarchy)(accountListState, 'billPayAccountList');
303
- const classHeirarchyList = (0, classListSelector_1.getNestedClassListHeirarchy)(classListState);
302
+ const accountsHierarchyList = (0, accountListSelector_1.getNestedAccountListHierarchy)(accountListState, 'billPayAccountList');
303
+ const classHierarchyList = (0, classListSelector_1.getNestedClassListHierarchy)(classListState);
304
304
  const duplicateBills = (0, billPayReviewSelector_1.getDuplicateBills)(state, billId);
305
305
  return {
306
306
  showVendorGptRecommendationText,
@@ -342,8 +342,8 @@ const getEditBillDetail = (state, isVendorRecommendationFeatureEnabled, isZeniAc
342
342
  toAccountVendorEmail,
343
343
  isCollectToAccountInfoFromVendorContact,
344
344
  vendorContactSaveStatus,
345
- accountsHeirarchyList,
346
- classHeirarchyList,
345
+ accountsHierarchyList,
346
+ classHierarchyList,
347
347
  latestApprovedDate: (0, helpers_1.getLatestApprovalDate)(billActivities),
348
348
  recommendationByLineID: recommendations,
349
349
  isRecurring,
@@ -17,8 +17,8 @@ import { BankAccountSelectorView } from '../../../bankAccountView/bankAccountVie
17
17
  import { BankAccount } from '../../../../entity/bankAccount/bankAccount';
18
18
  import { ActivityHistorySelectorView } from '../../commonHistoryView/commonHistorySelector';
19
19
  import { CountryWithCurrency } from '../../../../entity/currency/currency';
20
- import { NestedAccountHeirarchyForReport } from '../../../../commonStateTypes/accountView/nestedAccountID';
21
- import { NestedClassHeirarchyForReport } from '../../../../commonStateTypes/classesView/nestedClassID';
20
+ import { NestedAccountHierarchyForReport } from '../../../../commonStateTypes/accountView/nestedAccountID';
21
+ import { NestedClassHierarchyForReport } from '../../../../commonStateTypes/classesView/nestedClassID';
22
22
  import { DuplicateLine } from '../remiDetailView/remiDetailViewState';
23
23
  export interface EditRemiDetailSelectorView extends BankAccountSelectorView, SelectorView {
24
24
  remiId: ID | undefined;
@@ -42,8 +42,8 @@ export interface EditRemiDetailSelectorView extends BankAccountSelectorView, Sel
42
42
  uploadStatus: FetchState;
43
43
  editRemiInitialDetails: EditRemiInitialDetails;
44
44
  remiActivities: RemiActivity[];
45
- accountsHeirarchyList: NestedAccountHeirarchyForReport[];
46
- classHeirarchyList: NestedClassHeirarchyForReport[];
45
+ accountsHierarchyList: NestedAccountHierarchyForReport[];
46
+ classHierarchyList: NestedClassHierarchyForReport[];
47
47
  approvalRules: RemiSetupApproverView;
48
48
  createdBy: User | undefined;
49
49
  remiHistory: ActivityHistorySelectorView;
@@ -148,8 +148,8 @@ const getEditRemiDetail = (state, reimbursementId) => {
148
148
  ? (0, bankAccountSelector_1.getBankAccountByBankAccountId)(bankAccountState, paymentTo)
149
149
  : undefined;
150
150
  const bankAccount = (0, bankAccountViewSelector_1.getBankAccount)(state);
151
- const accountsHeirarchyList = (0, accountListSelector_1.getNestedAccountListHeirarchy)(accountListState, 'reimbursementAccountList');
152
- const classHeirarchyList = (0, classListSelector_1.getNestedClassListHeirarchy)(classListState);
151
+ const accountsHierarchyList = (0, accountListSelector_1.getNestedAccountListHierarchy)(accountListState, 'reimbursementAccountList');
152
+ const classHierarchyList = (0, classListSelector_1.getNestedClassListHierarchy)(classListState);
153
153
  const loggedInUserDepartmentId = (_p = (0, tenantSelector_1.getCurrentTenant)(state).accountingClassIDs) === null || _p === void 0 ? void 0 : _p[0];
154
154
  const duplicateReimbursementStatus = remiDetailViewState.duplicateReimbursementFetchStatus;
155
155
  const duplicateLineByLineId = remiDetailViewState.duplicateLineByLineId;
@@ -168,8 +168,8 @@ const getEditRemiDetail = (state, reimbursementId) => {
168
168
  editRemiInitialDetails,
169
169
  createdBy,
170
170
  remiActivities,
171
- accountsHeirarchyList,
172
- classHeirarchyList,
171
+ accountsHierarchyList,
172
+ classHierarchyList,
173
173
  createTime, approvalRules: (0, remiSetupApproverViewSelector_1.getRemiSetupApproverView)(state, false), reimbursementInfo,
174
174
  paymentToBankAccountDetail, remiHistory: (0, commonHistorySelector_1.getActivityHistory)(commonHistoryState, reimbursementId !== null && reimbursementId !== void 0 ? reimbursementId : '', 'reimbursement'), latestApprovedDate: (0, helpers_1.getLatestApprovalDate)(remiActivities), loggedInUserDepartmentId });
175
175
  };
@@ -7,8 +7,8 @@ import { ClassListSelectorView } from '../classList/classListSelector';
7
7
  import { AccountListSelectorView } from '../accountList/accountListSelector';
8
8
  import { ZeniDate } from '../../zeniDayJS';
9
9
  import { TransactionDetailLocalData } from './transactionDetailTypes';
10
- import { NestedAccountHeirarchyForReport } from '../../commonStateTypes/accountView/nestedAccountID';
11
- import { NestedClassHeirarchyForReport } from '../../commonStateTypes/classesView/nestedClassID';
10
+ import { NestedAccountHierarchyForReport } from '../../commonStateTypes/accountView/nestedAccountID';
11
+ import { NestedClassHierarchyForReport } from '../../commonStateTypes/classesView/nestedClassID';
12
12
  import { Vendor } from '../../entity/vendor/vendorState';
13
13
  export interface TransactionDetailReport extends SelectorView {
14
14
  transaction?: SupportedTransaction;
@@ -17,8 +17,8 @@ export interface TransactionDetailReport extends SelectorView {
17
17
  accountList: AccountListSelectorView;
18
18
  classList: ClassListSelectorView;
19
19
  transactionDetailLocalData: TransactionDetailLocalData;
20
- accountsHeirarchyList: NestedAccountHeirarchyForReport[];
21
- classHeirarchyList: NestedClassHeirarchyForReport[];
20
+ accountsHierarchyList: NestedAccountHierarchyForReport[];
21
+ classHierarchyList: NestedClassHierarchyForReport[];
22
22
  isUpdateNotAllowed?: boolean;
23
23
  allVendors: Vendor[];
24
24
  }
@@ -58,8 +58,8 @@ const getTransactionDetail = (state, transactionId, fetchLinkedTransactions = tr
58
58
  }
59
59
  const accountsList = (0, accountListSelector_1.getAccountList)(accountState, accountListState, 'accountList');
60
60
  const classList = (0, classListSelector_1.getClassList)(classState, classListState);
61
- const accountsHeirarchyList = (0, accountListSelector_1.getNestedAccountListHeirarchy)(accountListState, 'accountList');
62
- const classHeirarchyList = (0, classListSelector_1.getNestedClassListHeirarchy)(classListState);
61
+ const accountsHierarchyList = (0, accountListSelector_1.getNestedAccountListHierarchy)(accountListState, 'accountList');
62
+ const classHierarchyList = (0, classListSelector_1.getNestedClassListHierarchy)(classListState);
63
63
  const transactionDetailAnyUpdateStatus = reduceUpdateFetchStates(transactionDetail);
64
64
  const vendors = (0, vendorSelector_1.getVendorsByVendorIds)(vendorState, vendorListState.vendorIds);
65
65
  return {
@@ -73,8 +73,8 @@ const getTransactionDetail = (state, transactionId, fetchLinkedTransactions = tr
73
73
  linkedTransactions,
74
74
  transactionDetailUpdateStatus: transactionDetailAnyUpdateStatus,
75
75
  accountList: accountsList,
76
- classHeirarchyList,
77
- accountsHeirarchyList,
76
+ classHierarchyList,
77
+ accountsHierarchyList,
78
78
  classList: classList,
79
79
  isUpdateNotAllowed: transactionDetail === null || transactionDetail === void 0 ? void 0 : transactionDetail.isUpdateNotAllowed,
80
80
  transactionDetailLocalData: (_b = transactionDetail === null || transactionDetail === void 0 ? void 0 : transactionDetail.transactionDetailLocalData) !== null && _b !== void 0 ? _b : transactionDetailState_1.initialSupportedTransactionDetail.transactionDetailLocalData,
@@ -2,7 +2,7 @@ import { FetchedState, FetchState, FetchStateAndError, ID } from '../../commonSt
2
2
  import { Recommendation } from '../../commonStateTypes/recommendationBase';
3
3
  import { AccountBase } from '../../entity/account/accountState';
4
4
  import { ClassBase } from '../../entity/class/classState';
5
- import { CustomerBase } from '../../entity/customer/customer';
5
+ import { CustomerBase } from '../../entity/customer/customerState';
6
6
  import { EntityType } from '../../entity/genericEntity/entity';
7
7
  import { Transaction, TransactionID } from '../../entity/transaction/stateTypes/transaction';
8
8
  import { VendorBase } from '../../entity/vendor/vendorState';
@@ -4,7 +4,7 @@ import { ClassBase, RecommendedClassBase } from '../../entity/class/classState';
4
4
  import { BillableStatus, PlatformLineDetailType, ProductOrService, TransactionLineBase } from '../../entity/transaction/stateTypes/transactionLine';
5
5
  import { TransactionCategory, TransactionType } from '../../entity/transaction/stateTypes/transactionType';
6
6
  import { TransactionID } from '../../entity/transaction/stateTypes/transaction';
7
- import { CustomerBase } from '../../entity/customer/customer';
7
+ import { CustomerBase } from '../../entity/customer/customerState';
8
8
  import { Entity } from '../../entity/genericEntity/entity';
9
9
  import { VendorBase } from '../../entity/vendor/vendorState';
10
10
  import { Recommendation } from '../../commonStateTypes/recommendationBase';
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@zeniai/client-epic-state",
3
- "version": "4.10.7",
3
+ "version": "4.10.9",
4
4
  "description": "Shared module between Web & Mobile containing required abstractions for state management, async network communication. ",
5
5
  "main": "lib/index.js",
6
6
  "types": "lib/index.d.ts",
@@ -9,6 +9,10 @@ export interface CustomerBase {
9
9
  logo?: Url;
10
10
  }
11
11
  export interface Customer extends CustomerBase {
12
+ isSubCustomer: boolean;
13
+ isTaxable: boolean;
14
+ isDeleted: boolean;
15
+ parentCustomerId?: ID;
12
16
  addressId?: ID;
13
17
  lastName?: string;
14
18
  paymentMethodId?: ID;
@@ -24,7 +28,6 @@ export interface Customer extends CustomerBase {
24
28
  syncToken?: string;
25
29
  email?: string;
26
30
  websiteUrl?: string;
27
- parentCustomerId?: ID;
28
31
  qboParentCustomerId?: ID;
29
32
  isBillWithParent: boolean;
30
33
  updateTime?: ZeniDate;
@@ -32,11 +35,8 @@ export interface Customer extends CustomerBase {
32
35
  phone?: string;
33
36
  bankAccountIds?: ID[];
34
37
  balance?: number;
35
- isDeleted: boolean;
36
38
  tenantId?: ID;
37
39
  title?: string;
38
- isSubCustomer: boolean;
39
- isTaxable: boolean;
40
40
  shippingAddressId?: ID;
41
41
  billingAddressId?: ID;
42
42
  currencySymbol?: string;