@zeniai/client-epic-state 5.0.48-betaRD5 → 5.0.49-betaML1
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/lib/commonStateTypes/viewAndReport/viewAndReport.d.ts +2 -2
- package/lib/commonStateTypes/viewAndReport/viewAndReport.js +1 -0
- package/lib/entity/account/accountSelector.d.ts +5 -0
- package/lib/entity/account/accountSelector.js +8 -1
- package/lib/entity/account/accountState.d.ts +1 -1
- package/lib/entity/accountGroup/accountGroupState.d.ts +1 -1
- package/lib/entity/class/classReducer.d.ts +4 -4
- package/lib/entity/class/classState.d.ts +1 -1
- package/lib/entity/forecast/forecastState.d.ts +1 -1
- package/lib/entity/project/projectPayload.d.ts +3 -3
- package/lib/entity/project/projectPayload.js +3 -3
- package/lib/entity/project/projectState.d.ts +2 -4
- package/lib/entity/sectionAccountsView/sectionAccountsView.d.ts +1 -1
- package/lib/entity/sectionClassesViewV2/sectionClassesView.d.ts +1 -1
- package/lib/entity/sectionClassesViewV2/sectionClassesViewReducer.d.ts +2 -2
- package/lib/entity/sectionProjectView/sectionProjectView.d.ts +1 -1
- package/lib/entity/sectionProjectView/sectionProjectViewReducer.d.ts +2 -2
- package/lib/entity/snackbar/snackbarTypes.d.ts +1 -1
- package/lib/entity/snackbar/snackbarTypes.js +2 -0
- package/lib/entity/tenant/SessionManager.d.ts +4 -0
- package/lib/entity/tenant/SessionManager.js +6 -0
- package/lib/entity/transaction/payloadTypes/transactionLinePayload.js +1 -1
- package/lib/entity/transaction/payloadTypes/transactionPayload.d.ts +6 -2
- package/lib/entity/transaction/payloadTypes/transactionPayload.js +10 -6
- package/lib/entity/transaction/stateTypes/transaction.d.ts +3 -2
- package/lib/entity/transaction/stateTypes/transactionLine.d.ts +2 -2
- package/lib/epic.d.ts +3 -1
- package/lib/epic.js +3 -1
- package/lib/esm/commonStateTypes/viewAndReport/viewAndReport.js +1 -0
- package/lib/esm/entity/account/accountSelector.js +6 -0
- package/lib/esm/entity/project/projectPayload.js +1 -1
- package/lib/esm/entity/snackbar/snackbarTypes.js +2 -0
- package/lib/esm/entity/tenant/SessionManager.js +6 -0
- package/lib/esm/entity/transaction/payloadTypes/transactionLinePayload.js +2 -2
- package/lib/esm/entity/transaction/payloadTypes/transactionPayload.js +10 -6
- package/lib/esm/epic.js +3 -1
- package/lib/esm/index.js +4 -4
- package/lib/esm/view/expenseAutomationView/epics/transactionCategorization/createTransferEntryEpic.js +81 -0
- package/lib/esm/view/expenseAutomationView/epics/transactionCategorization/fetchTransactionCategorizationViewEpic.js +5 -7
- package/lib/esm/view/expenseAutomationView/epics/transactionCategorization/fetchTransferAccountsEpic.js +25 -0
- package/lib/esm/view/expenseAutomationView/epics/transactionCategorization/updateTransactionCategorizationEpic.js +0 -3
- package/lib/esm/view/expenseAutomationView/helpers/saveTransactionHelper.js +0 -1
- package/lib/esm/view/expenseAutomationView/helpers/transactionCategorizationLocalDataHelper.js +2 -11
- package/lib/esm/view/expenseAutomationView/reducers/transactionsViewReducer.js +70 -14
- package/lib/esm/view/expenseAutomationView/selectors/transactionCategorizationSelector.js +21 -7
- package/lib/esm/view/transactionDetail/epics/transactionDetailEpic.js +6 -0
- package/lib/esm/view/transactionDetail/transactionDetailSelector.js +13 -2
- package/lib/index.d.ts +6 -6
- package/lib/index.js +42 -33
- package/lib/tsconfig.typecheck.tsbuildinfo +1 -1
- package/lib/view/auditReportView/auditReportViewState.d.ts +1 -1
- package/lib/view/billPayCard/billPayCardSelector.d.ts +1 -1
- package/lib/view/cardBalance/cardBalanceSelector.d.ts +1 -1
- package/lib/view/cashBalance/cashBalanceSelector.d.ts +1 -1
- package/lib/view/cashInCashOut/cashInCashOutSelector.d.ts +1 -1
- package/lib/view/cashPosition/cashPositionSelector.d.ts +1 -1
- package/lib/view/dashboard/dashboardReducer.d.ts +2 -2
- package/lib/view/expenseAutomationView/epics/transactionCategorization/createTransferEntryEpic.d.ts +9 -0
- package/lib/view/expenseAutomationView/epics/transactionCategorization/createTransferEntryEpic.js +85 -0
- package/lib/view/expenseAutomationView/epics/transactionCategorization/fetchTransactionCategorizationViewEpic.d.ts +2 -3
- package/lib/view/expenseAutomationView/epics/transactionCategorization/fetchTransactionCategorizationViewEpic.js +4 -6
- package/lib/view/expenseAutomationView/epics/transactionCategorization/fetchTransferAccountsEpic.d.ts +8 -0
- package/lib/view/expenseAutomationView/epics/transactionCategorization/fetchTransferAccountsEpic.js +29 -0
- package/lib/view/expenseAutomationView/epics/transactionCategorization/updateTransactionCategorizationEpic.js +0 -3
- package/lib/view/expenseAutomationView/helpers/saveTransactionHelper.js +0 -1
- package/lib/view/expenseAutomationView/helpers/transactionCategorizationLocalDataHelper.d.ts +2 -3
- package/lib/view/expenseAutomationView/helpers/transactionCategorizationLocalDataHelper.js +2 -11
- package/lib/view/expenseAutomationView/reducers/transactionsViewReducer.d.ts +16 -4
- package/lib/view/expenseAutomationView/reducers/transactionsViewReducer.js +71 -15
- package/lib/view/expenseAutomationView/selectorTypes/transactionsViewSelectorTypes.d.ts +3 -4
- package/lib/view/expenseAutomationView/selectors/transactionCategorizationSelector.d.ts +2 -0
- package/lib/view/expenseAutomationView/selectors/transactionCategorizationSelector.js +21 -6
- package/lib/view/expenseAutomationView/types/transactionsViewState.d.ts +13 -4
- package/lib/view/financeStatement/financeStatementReducer.d.ts +1 -1
- package/lib/view/globalMerchantView/globalMerchantViewReducer.d.ts +2 -2
- package/lib/view/reimbursementCard/reimbursementCardSelector.d.ts +1 -1
- package/lib/view/reportsResync/reportsResyncReducer.d.ts +2 -2
- package/lib/view/tasksCard/tasksCardSelector.d.ts +1 -1
- package/lib/view/topEx/topExSelector.d.ts +1 -1
- package/lib/view/transactionDetail/epics/transactionDetailEpic.d.ts +2 -1
- package/lib/view/transactionDetail/epics/transactionDetailEpic.js +6 -0
- package/lib/view/transactionDetail/transactionDetailPayload.d.ts +1 -1
- package/lib/view/transactionDetail/transactionDetailSelector.d.ts +4 -1
- package/lib/view/transactionDetail/transactionDetailSelector.js +12 -1
- package/lib/view/transactionDetail/transactionDetailState.d.ts +2 -2
- package/lib/view/transactionDetail/transactionDetailTypes.d.ts +2 -2
- package/package.json +1 -1
|
@@ -5,7 +5,7 @@ import { ZeniDate } from '../../zeniDayJS';
|
|
|
5
5
|
import { AuditSummary } from '../reviewCompanyView/reviewCompanyViewState';
|
|
6
6
|
export declare const toAuditRuleEntityType: (v: string) => "dashboard" | "transactions" | "reports";
|
|
7
7
|
export type AuditRuleEntityType = ReturnType<typeof toAuditRuleEntityType>;
|
|
8
|
-
declare const toAuditRuleEntityIdType: (v: string) => "cash_balance" | "card_balance" | "expense_automation_card" | "operating_expenses" | "operating_expenses_by_classes" | "revenue" | "revenue_by_classes" | "net_burn_or_income" | "net_burn_or_income_story_card" | "net_burn_or_income_by_classes" | "cash_position" | "top_expenses" | "profit_and_loss" | "profit_and_loss_by_classes" | "profit_and_loss_by_projects" | "balance_sheet" | "cash_flow" | "dashboard" | "finance_statement" | "transaction_list_of_account" | "transaction_list_missing_receipt" | "transaction_list_of_account_by_class" | "transaction_list_of_account_by_project" | "transaction_detail" | "cash_in_cash_out" | "insights_dashboard" | "company_details" | "class_list" | "account_list" | "account_list_by_type" | "vendor" | "task_card" | "bill_pay" | "reimbursement" | "bill_pay_card" | "reimbursement_card" | "bill_pay_promo_card" | "zeni_accounts" | "zeni_accounts_promo_card" | "zeni_treasury" | "charge_cards" | "other_connection" | "reimbursement_promo_card" | "onboarding" | "operating_expenses_by_vendor" | "operating_expenses_by_vendor_summary" | "vendors_tab" | "accounts_payable_aging" | "accounts_receivable_aging" | "vendor_global_review" | "prepaid_expenses" | "fixed_assets" | "notification" | "rewards_card" | "billing" | "flux_analysis_operating_expense" | "account_reconciliation" | "zeni_credit_promo_card" | "treasury_promo_card" | "excluded_account_reconciliation" | "uncategorized-expense" | "uncategorized-income";
|
|
8
|
+
declare const toAuditRuleEntityIdType: (v: string) => "cash_balance" | "card_balance" | "expense_automation_card" | "operating_expenses" | "operating_expenses_by_classes" | "revenue" | "revenue_by_classes" | "net_burn_or_income" | "net_burn_or_income_story_card" | "net_burn_or_income_by_classes" | "cash_position" | "top_expenses" | "profit_and_loss" | "profit_and_loss_by_classes" | "profit_and_loss_by_projects" | "balance_sheet" | "cash_flow" | "dashboard" | "finance_statement" | "transaction_list_of_account" | "transaction_list_missing_receipt" | "transaction_list_of_account_by_class" | "transaction_list_of_account_by_project" | "transaction_detail" | "cash_in_cash_out" | "insights_dashboard" | "company_details" | "class_list" | "account_list" | "account_list_by_type" | "vendor" | "task_card" | "bill_pay" | "reimbursement" | "bill_pay_card" | "reimbursement_card" | "bill_pay_promo_card" | "zeni_accounts" | "zeni_accounts_promo_card" | "zeni_treasury" | "charge_cards" | "other_connection" | "reimbursement_promo_card" | "onboarding" | "operating_expenses_by_vendor" | "operating_expenses_by_vendor_summary" | "vendors_tab" | "accounts_payable_aging" | "accounts_receivable_aging" | "vendor_global_review" | "prepaid_expenses" | "fixed_assets" | "notification" | "rewards_card" | "billing" | "flux_analysis_operating_expense" | "account_reconciliation" | "zeni_credit_promo_card" | "treasury_promo_card" | "excluded_account_reconciliation" | "transfer_accounts" | "uncategorized-expense" | "uncategorized-income";
|
|
9
9
|
export type AuditRuleEntityIdType = ReturnType<typeof toAuditRuleEntityIdType>;
|
|
10
10
|
export declare const toAuditRuleTypeIdType: (v: string) => "accounting" | "business";
|
|
11
11
|
type AuditRuleTypeIdType = ReturnType<typeof toAuditRuleTypeIdType>;
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { RootState } from '../../reducer';
|
|
2
2
|
export declare const getBillPayCardReport: (state: RootState) => {
|
|
3
|
-
reportId: "cash_balance" | "card_balance" | "expense_automation_card" | "operating_expenses" | "operating_expenses_by_classes" | "revenue" | "revenue_by_classes" | "net_burn_or_income" | "net_burn_or_income_story_card" | "net_burn_or_income_by_classes" | "cash_position" | "top_expenses" | "profit_and_loss" | "profit_and_loss_by_classes" | "profit_and_loss_by_projects" | "balance_sheet" | "cash_flow" | "dashboard" | "finance_statement" | "transaction_list_of_account" | "transaction_list_missing_receipt" | "transaction_list_of_account_by_class" | "transaction_list_of_account_by_project" | "transaction_detail" | "cash_in_cash_out" | "insights_dashboard" | "company_details" | "class_list" | "account_list" | "account_list_by_type" | "vendor" | "task_card" | "bill_pay" | "reimbursement" | "bill_pay_card" | "reimbursement_card" | "bill_pay_promo_card" | "zeni_accounts" | "zeni_accounts_promo_card" | "zeni_treasury" | "charge_cards" | "other_connection" | "reimbursement_promo_card" | "onboarding" | "operating_expenses_by_vendor" | "operating_expenses_by_vendor_summary" | "vendors_tab" | "accounts_payable_aging" | "accounts_receivable_aging" | "vendor_global_review" | "prepaid_expenses" | "fixed_assets" | "notification" | "rewards_card" | "billing" | "flux_analysis_operating_expense" | "account_reconciliation" | "zeni_credit_promo_card" | "treasury_promo_card" | "excluded_account_reconciliation";
|
|
3
|
+
reportId: "cash_balance" | "card_balance" | "expense_automation_card" | "operating_expenses" | "operating_expenses_by_classes" | "revenue" | "revenue_by_classes" | "net_burn_or_income" | "net_burn_or_income_story_card" | "net_burn_or_income_by_classes" | "cash_position" | "top_expenses" | "profit_and_loss" | "profit_and_loss_by_classes" | "profit_and_loss_by_projects" | "balance_sheet" | "cash_flow" | "dashboard" | "finance_statement" | "transaction_list_of_account" | "transaction_list_missing_receipt" | "transaction_list_of_account_by_class" | "transaction_list_of_account_by_project" | "transaction_detail" | "cash_in_cash_out" | "insights_dashboard" | "company_details" | "class_list" | "account_list" | "account_list_by_type" | "vendor" | "task_card" | "bill_pay" | "reimbursement" | "bill_pay_card" | "reimbursement_card" | "bill_pay_promo_card" | "zeni_accounts" | "zeni_accounts_promo_card" | "zeni_treasury" | "charge_cards" | "other_connection" | "reimbursement_promo_card" | "onboarding" | "operating_expenses_by_vendor" | "operating_expenses_by_vendor_summary" | "vendors_tab" | "accounts_payable_aging" | "accounts_receivable_aging" | "vendor_global_review" | "prepaid_expenses" | "fixed_assets" | "notification" | "rewards_card" | "billing" | "flux_analysis_operating_expense" | "account_reconciliation" | "zeni_credit_promo_card" | "treasury_promo_card" | "excluded_account_reconciliation" | "transfer_accounts";
|
|
4
4
|
reportTitle: string;
|
|
5
5
|
version: string | number | undefined;
|
|
6
6
|
fetchState: import("../..").FetchState;
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { RootState } from '../../reducer';
|
|
2
2
|
export declare const getCardBalance: (state: RootState) => {
|
|
3
|
-
reportId: "cash_balance" | "card_balance" | "expense_automation_card" | "operating_expenses" | "operating_expenses_by_classes" | "revenue" | "revenue_by_classes" | "net_burn_or_income" | "net_burn_or_income_story_card" | "net_burn_or_income_by_classes" | "cash_position" | "top_expenses" | "profit_and_loss" | "profit_and_loss_by_classes" | "profit_and_loss_by_projects" | "balance_sheet" | "cash_flow" | "dashboard" | "finance_statement" | "transaction_list_of_account" | "transaction_list_missing_receipt" | "transaction_list_of_account_by_class" | "transaction_list_of_account_by_project" | "transaction_detail" | "cash_in_cash_out" | "insights_dashboard" | "company_details" | "class_list" | "account_list" | "account_list_by_type" | "vendor" | "task_card" | "bill_pay" | "reimbursement" | "bill_pay_card" | "reimbursement_card" | "bill_pay_promo_card" | "zeni_accounts" | "zeni_accounts_promo_card" | "zeni_treasury" | "charge_cards" | "other_connection" | "reimbursement_promo_card" | "onboarding" | "operating_expenses_by_vendor" | "operating_expenses_by_vendor_summary" | "vendors_tab" | "accounts_payable_aging" | "accounts_receivable_aging" | "vendor_global_review" | "prepaid_expenses" | "fixed_assets" | "notification" | "rewards_card" | "billing" | "flux_analysis_operating_expense" | "account_reconciliation" | "zeni_credit_promo_card" | "treasury_promo_card" | "excluded_account_reconciliation";
|
|
3
|
+
reportId: "cash_balance" | "card_balance" | "expense_automation_card" | "operating_expenses" | "operating_expenses_by_classes" | "revenue" | "revenue_by_classes" | "net_burn_or_income" | "net_burn_or_income_story_card" | "net_burn_or_income_by_classes" | "cash_position" | "top_expenses" | "profit_and_loss" | "profit_and_loss_by_classes" | "profit_and_loss_by_projects" | "balance_sheet" | "cash_flow" | "dashboard" | "finance_statement" | "transaction_list_of_account" | "transaction_list_missing_receipt" | "transaction_list_of_account_by_class" | "transaction_list_of_account_by_project" | "transaction_detail" | "cash_in_cash_out" | "insights_dashboard" | "company_details" | "class_list" | "account_list" | "account_list_by_type" | "vendor" | "task_card" | "bill_pay" | "reimbursement" | "bill_pay_card" | "reimbursement_card" | "bill_pay_promo_card" | "zeni_accounts" | "zeni_accounts_promo_card" | "zeni_treasury" | "charge_cards" | "other_connection" | "reimbursement_promo_card" | "onboarding" | "operating_expenses_by_vendor" | "operating_expenses_by_vendor_summary" | "vendors_tab" | "accounts_payable_aging" | "accounts_receivable_aging" | "vendor_global_review" | "prepaid_expenses" | "fixed_assets" | "notification" | "rewards_card" | "billing" | "flux_analysis_operating_expense" | "account_reconciliation" | "zeni_credit_promo_card" | "treasury_promo_card" | "excluded_account_reconciliation" | "transfer_accounts";
|
|
4
4
|
reportTitle: string;
|
|
5
5
|
version: string | number | undefined;
|
|
6
6
|
status: import("../..").Status | undefined;
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { RootState } from '../../reducer';
|
|
2
2
|
export declare const getCashBalance: (state: RootState) => {
|
|
3
|
-
reportId: "cash_balance" | "card_balance" | "expense_automation_card" | "operating_expenses" | "operating_expenses_by_classes" | "revenue" | "revenue_by_classes" | "net_burn_or_income" | "net_burn_or_income_story_card" | "net_burn_or_income_by_classes" | "cash_position" | "top_expenses" | "profit_and_loss" | "profit_and_loss_by_classes" | "profit_and_loss_by_projects" | "balance_sheet" | "cash_flow" | "dashboard" | "finance_statement" | "transaction_list_of_account" | "transaction_list_missing_receipt" | "transaction_list_of_account_by_class" | "transaction_list_of_account_by_project" | "transaction_detail" | "cash_in_cash_out" | "insights_dashboard" | "company_details" | "class_list" | "account_list" | "account_list_by_type" | "vendor" | "task_card" | "bill_pay" | "reimbursement" | "bill_pay_card" | "reimbursement_card" | "bill_pay_promo_card" | "zeni_accounts" | "zeni_accounts_promo_card" | "zeni_treasury" | "charge_cards" | "other_connection" | "reimbursement_promo_card" | "onboarding" | "operating_expenses_by_vendor" | "operating_expenses_by_vendor_summary" | "vendors_tab" | "accounts_payable_aging" | "accounts_receivable_aging" | "vendor_global_review" | "prepaid_expenses" | "fixed_assets" | "notification" | "rewards_card" | "billing" | "flux_analysis_operating_expense" | "account_reconciliation" | "zeni_credit_promo_card" | "treasury_promo_card" | "excluded_account_reconciliation";
|
|
3
|
+
reportId: "cash_balance" | "card_balance" | "expense_automation_card" | "operating_expenses" | "operating_expenses_by_classes" | "revenue" | "revenue_by_classes" | "net_burn_or_income" | "net_burn_or_income_story_card" | "net_burn_or_income_by_classes" | "cash_position" | "top_expenses" | "profit_and_loss" | "profit_and_loss_by_classes" | "profit_and_loss_by_projects" | "balance_sheet" | "cash_flow" | "dashboard" | "finance_statement" | "transaction_list_of_account" | "transaction_list_missing_receipt" | "transaction_list_of_account_by_class" | "transaction_list_of_account_by_project" | "transaction_detail" | "cash_in_cash_out" | "insights_dashboard" | "company_details" | "class_list" | "account_list" | "account_list_by_type" | "vendor" | "task_card" | "bill_pay" | "reimbursement" | "bill_pay_card" | "reimbursement_card" | "bill_pay_promo_card" | "zeni_accounts" | "zeni_accounts_promo_card" | "zeni_treasury" | "charge_cards" | "other_connection" | "reimbursement_promo_card" | "onboarding" | "operating_expenses_by_vendor" | "operating_expenses_by_vendor_summary" | "vendors_tab" | "accounts_payable_aging" | "accounts_receivable_aging" | "vendor_global_review" | "prepaid_expenses" | "fixed_assets" | "notification" | "rewards_card" | "billing" | "flux_analysis_operating_expense" | "account_reconciliation" | "zeni_credit_promo_card" | "treasury_promo_card" | "excluded_account_reconciliation" | "transfer_accounts";
|
|
4
4
|
reportTitle: string;
|
|
5
5
|
version: string | number | undefined;
|
|
6
6
|
status: import("../..").Status | undefined;
|
|
@@ -15,7 +15,7 @@ export declare const getCashInCashOut: (accountState: AccountState, accountGroup
|
|
|
15
15
|
firstMonthOfFY: 1 | 3 | 12 | 2 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | 11;
|
|
16
16
|
dataAvailable: import("../../commonStateTypes/timeframeTick").TimeframeTick | undefined;
|
|
17
17
|
availableNumberOfPeriods: number | undefined;
|
|
18
|
-
reportId: "cash_balance" | "card_balance" | "expense_automation_card" | "operating_expenses" | "operating_expenses_by_classes" | "revenue" | "revenue_by_classes" | "net_burn_or_income" | "net_burn_or_income_story_card" | "net_burn_or_income_by_classes" | "cash_position" | "top_expenses" | "profit_and_loss" | "profit_and_loss_by_classes" | "profit_and_loss_by_projects" | "balance_sheet" | "cash_flow" | "dashboard" | "finance_statement" | "transaction_list_of_account" | "transaction_list_missing_receipt" | "transaction_list_of_account_by_class" | "transaction_list_of_account_by_project" | "transaction_detail" | "cash_in_cash_out" | "insights_dashboard" | "company_details" | "class_list" | "account_list" | "account_list_by_type" | "vendor" | "task_card" | "bill_pay" | "reimbursement" | "bill_pay_card" | "reimbursement_card" | "bill_pay_promo_card" | "zeni_accounts" | "zeni_accounts_promo_card" | "zeni_treasury" | "charge_cards" | "other_connection" | "reimbursement_promo_card" | "onboarding" | "operating_expenses_by_vendor" | "operating_expenses_by_vendor_summary" | "vendors_tab" | "accounts_payable_aging" | "accounts_receivable_aging" | "vendor_global_review" | "prepaid_expenses" | "fixed_assets" | "notification" | "rewards_card" | "billing" | "flux_analysis_operating_expense" | "account_reconciliation" | "zeni_credit_promo_card" | "treasury_promo_card" | "excluded_account_reconciliation";
|
|
18
|
+
reportId: "cash_balance" | "card_balance" | "expense_automation_card" | "operating_expenses" | "operating_expenses_by_classes" | "revenue" | "revenue_by_classes" | "net_burn_or_income" | "net_burn_or_income_story_card" | "net_burn_or_income_by_classes" | "cash_position" | "top_expenses" | "profit_and_loss" | "profit_and_loss_by_classes" | "profit_and_loss_by_projects" | "balance_sheet" | "cash_flow" | "dashboard" | "finance_statement" | "transaction_list_of_account" | "transaction_list_missing_receipt" | "transaction_list_of_account_by_class" | "transaction_list_of_account_by_project" | "transaction_detail" | "cash_in_cash_out" | "insights_dashboard" | "company_details" | "class_list" | "account_list" | "account_list_by_type" | "vendor" | "task_card" | "bill_pay" | "reimbursement" | "bill_pay_card" | "reimbursement_card" | "bill_pay_promo_card" | "zeni_accounts" | "zeni_accounts_promo_card" | "zeni_treasury" | "charge_cards" | "other_connection" | "reimbursement_promo_card" | "onboarding" | "operating_expenses_by_vendor" | "operating_expenses_by_vendor_summary" | "vendors_tab" | "accounts_payable_aging" | "accounts_receivable_aging" | "vendor_global_review" | "prepaid_expenses" | "fixed_assets" | "notification" | "rewards_card" | "billing" | "flux_analysis_operating_expense" | "account_reconciliation" | "zeni_credit_promo_card" | "treasury_promo_card" | "excluded_account_reconciliation" | "transfer_accounts";
|
|
19
19
|
reportTitle: string;
|
|
20
20
|
version: string | number | undefined;
|
|
21
21
|
status: import("../..").Status | undefined;
|
|
@@ -12,7 +12,7 @@ export declare const getCashPosition: (accountState: AccountState, cashPositionS
|
|
|
12
12
|
firstMonthOfFY: 1 | 3 | 12 | 2 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | 11;
|
|
13
13
|
dataAvailable: import("../../commonStateTypes/timeframeTick").TimeframeTick | undefined;
|
|
14
14
|
availableNumberOfPeriods: number | undefined;
|
|
15
|
-
reportId: "cash_balance" | "card_balance" | "expense_automation_card" | "operating_expenses" | "operating_expenses_by_classes" | "revenue" | "revenue_by_classes" | "net_burn_or_income" | "net_burn_or_income_story_card" | "net_burn_or_income_by_classes" | "cash_position" | "top_expenses" | "profit_and_loss" | "profit_and_loss_by_classes" | "profit_and_loss_by_projects" | "balance_sheet" | "cash_flow" | "dashboard" | "finance_statement" | "transaction_list_of_account" | "transaction_list_missing_receipt" | "transaction_list_of_account_by_class" | "transaction_list_of_account_by_project" | "transaction_detail" | "cash_in_cash_out" | "insights_dashboard" | "company_details" | "class_list" | "account_list" | "account_list_by_type" | "vendor" | "task_card" | "bill_pay" | "reimbursement" | "bill_pay_card" | "reimbursement_card" | "bill_pay_promo_card" | "zeni_accounts" | "zeni_accounts_promo_card" | "zeni_treasury" | "charge_cards" | "other_connection" | "reimbursement_promo_card" | "onboarding" | "operating_expenses_by_vendor" | "operating_expenses_by_vendor_summary" | "vendors_tab" | "accounts_payable_aging" | "accounts_receivable_aging" | "vendor_global_review" | "prepaid_expenses" | "fixed_assets" | "notification" | "rewards_card" | "billing" | "flux_analysis_operating_expense" | "account_reconciliation" | "zeni_credit_promo_card" | "treasury_promo_card" | "excluded_account_reconciliation";
|
|
15
|
+
reportId: "cash_balance" | "card_balance" | "expense_automation_card" | "operating_expenses" | "operating_expenses_by_classes" | "revenue" | "revenue_by_classes" | "net_burn_or_income" | "net_burn_or_income_story_card" | "net_burn_or_income_by_classes" | "cash_position" | "top_expenses" | "profit_and_loss" | "profit_and_loss_by_classes" | "profit_and_loss_by_projects" | "balance_sheet" | "cash_flow" | "dashboard" | "finance_statement" | "transaction_list_of_account" | "transaction_list_missing_receipt" | "transaction_list_of_account_by_class" | "transaction_list_of_account_by_project" | "transaction_detail" | "cash_in_cash_out" | "insights_dashboard" | "company_details" | "class_list" | "account_list" | "account_list_by_type" | "vendor" | "task_card" | "bill_pay" | "reimbursement" | "bill_pay_card" | "reimbursement_card" | "bill_pay_promo_card" | "zeni_accounts" | "zeni_accounts_promo_card" | "zeni_treasury" | "charge_cards" | "other_connection" | "reimbursement_promo_card" | "onboarding" | "operating_expenses_by_vendor" | "operating_expenses_by_vendor_summary" | "vendors_tab" | "accounts_payable_aging" | "accounts_receivable_aging" | "vendor_global_review" | "prepaid_expenses" | "fixed_assets" | "notification" | "rewards_card" | "billing" | "flux_analysis_operating_expense" | "account_reconciliation" | "zeni_credit_promo_card" | "treasury_promo_card" | "excluded_account_reconciliation" | "transfer_accounts";
|
|
16
16
|
reportTitle: string;
|
|
17
17
|
version: string | number | undefined;
|
|
18
18
|
status: import("../..").Status | undefined;
|
|
@@ -1,12 +1,12 @@
|
|
|
1
1
|
import { DashboardState } from './dashboardState';
|
|
2
2
|
export declare const initialState: DashboardState;
|
|
3
|
-
export declare const fetchDashboard: import("@reduxjs/toolkit").ActionCreatorWithPreparedPayload<[userId: string, companyId: string, tenantId: string, fetchFullReport?: any, cacheOverride?: any, excludeResources?: ("cash_balance" | "card_balance" | "expense_automation_card" | "operating_expenses" | "operating_expenses_by_classes" | "revenue" | "revenue_by_classes" | "net_burn_or_income" | "net_burn_or_income_story_card" | "net_burn_or_income_by_classes" | "cash_position" | "top_expenses" | "profit_and_loss" | "profit_and_loss_by_classes" | "profit_and_loss_by_projects" | "balance_sheet" | "cash_flow" | "dashboard" | "finance_statement" | "transaction_list_of_account" | "transaction_list_missing_receipt" | "transaction_list_of_account_by_class" | "transaction_list_of_account_by_project" | "transaction_detail" | "cash_in_cash_out" | "insights_dashboard" | "company_details" | "class_list" | "account_list" | "account_list_by_type" | "vendor" | "task_card" | "bill_pay" | "reimbursement" | "bill_pay_card" | "reimbursement_card" | "bill_pay_promo_card" | "zeni_accounts" | "zeni_accounts_promo_card" | "zeni_treasury" | "charge_cards" | "other_connection" | "reimbursement_promo_card" | "onboarding" | "operating_expenses_by_vendor" | "operating_expenses_by_vendor_summary" | "vendors_tab" | "accounts_payable_aging" | "accounts_receivable_aging" | "vendor_global_review" | "prepaid_expenses" | "fixed_assets" | "notification" | "rewards_card" | "billing" | "flux_analysis_operating_expense" | "account_reconciliation" | "zeni_credit_promo_card" | "treasury_promo_card" | "excluded_account_reconciliation")[] | undefined], {
|
|
3
|
+
export declare const fetchDashboard: import("@reduxjs/toolkit").ActionCreatorWithPreparedPayload<[userId: string, companyId: string, tenantId: string, fetchFullReport?: any, cacheOverride?: any, excludeResources?: ("cash_balance" | "card_balance" | "expense_automation_card" | "operating_expenses" | "operating_expenses_by_classes" | "revenue" | "revenue_by_classes" | "net_burn_or_income" | "net_burn_or_income_story_card" | "net_burn_or_income_by_classes" | "cash_position" | "top_expenses" | "profit_and_loss" | "profit_and_loss_by_classes" | "profit_and_loss_by_projects" | "balance_sheet" | "cash_flow" | "dashboard" | "finance_statement" | "transaction_list_of_account" | "transaction_list_missing_receipt" | "transaction_list_of_account_by_class" | "transaction_list_of_account_by_project" | "transaction_detail" | "cash_in_cash_out" | "insights_dashboard" | "company_details" | "class_list" | "account_list" | "account_list_by_type" | "vendor" | "task_card" | "bill_pay" | "reimbursement" | "bill_pay_card" | "reimbursement_card" | "bill_pay_promo_card" | "zeni_accounts" | "zeni_accounts_promo_card" | "zeni_treasury" | "charge_cards" | "other_connection" | "reimbursement_promo_card" | "onboarding" | "operating_expenses_by_vendor" | "operating_expenses_by_vendor_summary" | "vendors_tab" | "accounts_payable_aging" | "accounts_receivable_aging" | "vendor_global_review" | "prepaid_expenses" | "fixed_assets" | "notification" | "rewards_card" | "billing" | "flux_analysis_operating_expense" | "account_reconciliation" | "zeni_credit_promo_card" | "treasury_promo_card" | "excluded_account_reconciliation" | "transfer_accounts")[] | undefined], {
|
|
4
4
|
userId: string;
|
|
5
5
|
companyId: string;
|
|
6
6
|
tenantId: string;
|
|
7
7
|
fetchFullReport: any;
|
|
8
8
|
cacheOverride: any;
|
|
9
|
-
excludeResources: ("cash_balance" | "card_balance" | "expense_automation_card" | "operating_expenses" | "operating_expenses_by_classes" | "revenue" | "revenue_by_classes" | "net_burn_or_income" | "net_burn_or_income_story_card" | "net_burn_or_income_by_classes" | "cash_position" | "top_expenses" | "profit_and_loss" | "profit_and_loss_by_classes" | "profit_and_loss_by_projects" | "balance_sheet" | "cash_flow" | "dashboard" | "finance_statement" | "transaction_list_of_account" | "transaction_list_missing_receipt" | "transaction_list_of_account_by_class" | "transaction_list_of_account_by_project" | "transaction_detail" | "cash_in_cash_out" | "insights_dashboard" | "company_details" | "class_list" | "account_list" | "account_list_by_type" | "vendor" | "task_card" | "bill_pay" | "reimbursement" | "bill_pay_card" | "reimbursement_card" | "bill_pay_promo_card" | "zeni_accounts" | "zeni_accounts_promo_card" | "zeni_treasury" | "charge_cards" | "other_connection" | "reimbursement_promo_card" | "onboarding" | "operating_expenses_by_vendor" | "operating_expenses_by_vendor_summary" | "vendors_tab" | "accounts_payable_aging" | "accounts_receivable_aging" | "vendor_global_review" | "prepaid_expenses" | "fixed_assets" | "notification" | "rewards_card" | "billing" | "flux_analysis_operating_expense" | "account_reconciliation" | "zeni_credit_promo_card" | "treasury_promo_card" | "excluded_account_reconciliation")[];
|
|
9
|
+
excludeResources: ("cash_balance" | "card_balance" | "expense_automation_card" | "operating_expenses" | "operating_expenses_by_classes" | "revenue" | "revenue_by_classes" | "net_burn_or_income" | "net_burn_or_income_story_card" | "net_burn_or_income_by_classes" | "cash_position" | "top_expenses" | "profit_and_loss" | "profit_and_loss_by_classes" | "profit_and_loss_by_projects" | "balance_sheet" | "cash_flow" | "dashboard" | "finance_statement" | "transaction_list_of_account" | "transaction_list_missing_receipt" | "transaction_list_of_account_by_class" | "transaction_list_of_account_by_project" | "transaction_detail" | "cash_in_cash_out" | "insights_dashboard" | "company_details" | "class_list" | "account_list" | "account_list_by_type" | "vendor" | "task_card" | "bill_pay" | "reimbursement" | "bill_pay_card" | "reimbursement_card" | "bill_pay_promo_card" | "zeni_accounts" | "zeni_accounts_promo_card" | "zeni_treasury" | "charge_cards" | "other_connection" | "reimbursement_promo_card" | "onboarding" | "operating_expenses_by_vendor" | "operating_expenses_by_vendor_summary" | "vendors_tab" | "accounts_payable_aging" | "accounts_receivable_aging" | "vendor_global_review" | "prepaid_expenses" | "fixed_assets" | "notification" | "rewards_card" | "billing" | "flux_analysis_operating_expense" | "account_reconciliation" | "zeni_credit_promo_card" | "treasury_promo_card" | "excluded_account_reconciliation" | "transfer_accounts")[];
|
|
10
10
|
}, "dashboard/fetchDashboard", never, never>, updateTreasuryVideoClosed: import("@reduxjs/toolkit").ActionCreatorWithoutPayload<"dashboard/updateTreasuryVideoClosed">, clearDashboard: import("@reduxjs/toolkit").ActionCreatorWithoutPayload<"dashboard/clearDashboard">;
|
|
11
11
|
declare const _default: import("redux").Reducer<DashboardState>;
|
|
12
12
|
export default _default;
|
package/lib/view/expenseAutomationView/epics/transactionCategorization/createTransferEntryEpic.d.ts
ADDED
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
import { ActionsObservable, StateObservable } from 'redux-observable';
|
|
2
|
+
import { openSnackbar } from '../../../../entity/snackbar/snackbarReducer';
|
|
3
|
+
import { removeTransaction, updateTransaction } from '../../../../entity/transaction/transactionReducer';
|
|
4
|
+
import { RootState } from '../../../../reducer';
|
|
5
|
+
import { ZeniAPI } from '../../../../zeniAPI';
|
|
6
|
+
import { initializeTransactionDetailLocalData, removeTransactionDetail } from '../../../transactionDetail/transactionDetailReducer';
|
|
7
|
+
import { acknowledgeTransferEntryRouteReplacement, createTransferEntry, createTransferEntryFailure, createTransferEntryReplacedTransaction, createTransferEntrySuccess, removeTransactionFromAllTabs, resetCreateTransferEntryStatus } from '../../reducers/transactionsViewReducer';
|
|
8
|
+
export type ActionType = ReturnType<typeof openSnackbar> | ReturnType<typeof createTransferEntry> | ReturnType<typeof createTransferEntrySuccess> | ReturnType<typeof createTransferEntryFailure> | ReturnType<typeof removeTransactionFromAllTabs> | ReturnType<typeof resetCreateTransferEntryStatus> | ReturnType<typeof createTransferEntryReplacedTransaction> | ReturnType<typeof acknowledgeTransferEntryRouteReplacement> | ReturnType<typeof updateTransaction> | ReturnType<typeof initializeTransactionDetailLocalData> | ReturnType<typeof removeTransaction> | ReturnType<typeof removeTransactionDetail>;
|
|
9
|
+
export declare const createTransferEntryEpic: (actions$: ActionsObservable<ActionType>, _state$: StateObservable<RootState>, zeniAPI: ZeniAPI) => import("rxjs").Observable<ActionType>;
|
package/lib/view/expenseAutomationView/epics/transactionCategorization/createTransferEntryEpic.js
ADDED
|
@@ -0,0 +1,85 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.createTransferEntryEpic = void 0;
|
|
4
|
+
const rxjs_1 = require("rxjs");
|
|
5
|
+
const operators_1 = require("rxjs/operators");
|
|
6
|
+
const snackbarReducer_1 = require("../../../../entity/snackbar/snackbarReducer");
|
|
7
|
+
const transactionIDPayload_1 = require("../../../../entity/transaction/payloadTypes/transactionIDPayload");
|
|
8
|
+
const transactionType_1 = require("../../../../entity/transaction/stateTypes/transactionType");
|
|
9
|
+
const transactionReducer_1 = require("../../../../entity/transaction/transactionReducer");
|
|
10
|
+
const responsePayload_1 = require("../../../../responsePayload");
|
|
11
|
+
const transactionDetailReducer_1 = require("../../../transactionDetail/transactionDetailReducer");
|
|
12
|
+
const transactionDetailState_1 = require("../../../transactionDetail/transactionDetailState");
|
|
13
|
+
const transactionsViewReducer_1 = require("../../reducers/transactionsViewReducer");
|
|
14
|
+
function transactionIdsAreEqual(a, b) {
|
|
15
|
+
return a.id === b.id && a.type === b.type;
|
|
16
|
+
}
|
|
17
|
+
const createTransferEntryEpic = (actions$, _state$, zeniAPI) => actions$.pipe((0, operators_1.filter)(transactionsViewReducer_1.createTransferEntry.match), (0, operators_1.mergeMap)((action) => {
|
|
18
|
+
const { transactionId, creditAccountIntegrationId, debitAccountIntegrationId, memo, transactionType, sourceTransactionType, } = action.payload;
|
|
19
|
+
const url = `${zeniAPI.apiEndPoints.accountMicroServiceBaseUrl}/1.0/transactions/transaction-type-update`;
|
|
20
|
+
return zeniAPI
|
|
21
|
+
.putAndGetJSON(url, {
|
|
22
|
+
transaction_type: transactionType,
|
|
23
|
+
transaction_id: transactionId,
|
|
24
|
+
to_account_integration_id: creditAccountIntegrationId,
|
|
25
|
+
from_account_integration_id: debitAccountIntegrationId,
|
|
26
|
+
memo,
|
|
27
|
+
})
|
|
28
|
+
.pipe((0, operators_1.mergeMap)((response) => {
|
|
29
|
+
if ((0, responsePayload_1.isSuccessResponse)(response)) {
|
|
30
|
+
const immediate = [];
|
|
31
|
+
const previousTransactionId = {
|
|
32
|
+
id: transactionId,
|
|
33
|
+
type: (0, transactionType_1.toTransactionType)(sourceTransactionType),
|
|
34
|
+
};
|
|
35
|
+
if (response.data?.transaction != null) {
|
|
36
|
+
const newTransactionId = (0, transactionIDPayload_1.toTransactionID)(response.data.transaction);
|
|
37
|
+
const replaced = !transactionIdsAreEqual(previousTransactionId, newTransactionId);
|
|
38
|
+
const newDetailKey = (0, transactionDetailState_1.getTransactionDetailKey)(newTransactionId);
|
|
39
|
+
immediate.push((0, transactionReducer_1.updateTransaction)(newDetailKey, response.data.transaction));
|
|
40
|
+
immediate.push((0, transactionDetailReducer_1.initializeTransactionDetailLocalData)({
|
|
41
|
+
transactionId: newTransactionId,
|
|
42
|
+
vendorId: response.data.vendors?.[0]?.vendor_id,
|
|
43
|
+
}));
|
|
44
|
+
immediate.push((0, transactionsViewReducer_1.createTransferEntrySuccess)(), (0, transactionsViewReducer_1.removeTransactionFromAllTabs)(transactionId), (0, snackbarReducer_1.openSnackbar)({
|
|
45
|
+
messageSection: 'create_transfer_entry',
|
|
46
|
+
messageText: 'success',
|
|
47
|
+
type: 'success',
|
|
48
|
+
}));
|
|
49
|
+
if (replaced) {
|
|
50
|
+
immediate.push((0, transactionsViewReducer_1.createTransferEntryReplacedTransaction)(previousTransactionId, newTransactionId));
|
|
51
|
+
}
|
|
52
|
+
return (0, rxjs_1.concat)((0, rxjs_1.from)(immediate), (0, rxjs_1.timer)(0).pipe((0, operators_1.map)(() => (0, transactionsViewReducer_1.resetCreateTransferEntryStatus)()), (0, operators_1.mergeMap)((resetAction) => replaced
|
|
53
|
+
? (0, rxjs_1.from)([
|
|
54
|
+
resetAction,
|
|
55
|
+
(0, transactionReducer_1.removeTransaction)((0, transactionDetailState_1.getTransactionDetailKey)(previousTransactionId)),
|
|
56
|
+
(0, transactionDetailReducer_1.removeTransactionDetail)(previousTransactionId),
|
|
57
|
+
(0, transactionsViewReducer_1.acknowledgeTransferEntryRouteReplacement)(),
|
|
58
|
+
])
|
|
59
|
+
: (0, rxjs_1.from)([resetAction]))));
|
|
60
|
+
}
|
|
61
|
+
immediate.push((0, transactionsViewReducer_1.createTransferEntrySuccess)(), (0, transactionsViewReducer_1.removeTransactionFromAllTabs)(transactionId), (0, snackbarReducer_1.openSnackbar)({
|
|
62
|
+
messageSection: 'create_transfer_entry',
|
|
63
|
+
messageText: 'success',
|
|
64
|
+
type: 'success',
|
|
65
|
+
}));
|
|
66
|
+
return (0, rxjs_1.concat)((0, rxjs_1.from)(immediate), (0, rxjs_1.timer)(0).pipe((0, operators_1.map)(() => (0, transactionsViewReducer_1.resetCreateTransferEntryStatus)())));
|
|
67
|
+
}
|
|
68
|
+
return (0, rxjs_1.from)([
|
|
69
|
+
(0, transactionsViewReducer_1.createTransferEntryFailure)(),
|
|
70
|
+
(0, snackbarReducer_1.openSnackbar)({
|
|
71
|
+
messageSection: 'create_transfer_entry',
|
|
72
|
+
messageText: 'failed',
|
|
73
|
+
type: 'error',
|
|
74
|
+
}),
|
|
75
|
+
]);
|
|
76
|
+
}), (0, operators_1.catchError)(() => (0, rxjs_1.from)([
|
|
77
|
+
(0, transactionsViewReducer_1.createTransferEntryFailure)(),
|
|
78
|
+
(0, snackbarReducer_1.openSnackbar)({
|
|
79
|
+
messageSection: 'create_transfer_entry',
|
|
80
|
+
messageText: 'failed',
|
|
81
|
+
type: 'error',
|
|
82
|
+
}),
|
|
83
|
+
])));
|
|
84
|
+
}));
|
|
85
|
+
exports.createTransferEntryEpic = createTransferEntryEpic;
|
|
@@ -4,7 +4,6 @@ import { RootState } from '../../../../reducer';
|
|
|
4
4
|
import { fetchAccountList } from '../../../accountList/accountListReducer';
|
|
5
5
|
import { fetchClassList } from '../../../classList/classListReducer';
|
|
6
6
|
import { fetchOwnerList } from '../../../ownerList/ownerListReducer';
|
|
7
|
-
import {
|
|
8
|
-
|
|
9
|
-
export type ActionType = ReturnType<typeof fetchTransactionCategorizationView> | ReturnType<typeof fetchTransactionCategorization> | ReturnType<typeof fetchAccountList> | ReturnType<typeof fetchClassList> | ReturnType<typeof fetchOwnerList> | ReturnType<typeof fetchProjectList>;
|
|
7
|
+
import { fetchTransactionCategorization, fetchTransactionCategorizationView, fetchTransferAccounts } from '../../reducers/transactionsViewReducer';
|
|
8
|
+
export type ActionType = ReturnType<typeof fetchTransactionCategorizationView> | ReturnType<typeof fetchTransactionCategorization> | ReturnType<typeof fetchAccountList> | ReturnType<typeof fetchClassList> | ReturnType<typeof fetchOwnerList> | ReturnType<typeof fetchTransferAccounts>;
|
|
10
9
|
export declare const fetchTransactionCategorizationViewEpic: (actions$: ActionsObservable<ActionType>, state$: StateObservable<RootState>) => Observable<ActionType>;
|
|
@@ -7,7 +7,6 @@ const timePeriod_1 = require("../../../../commonStateTypes/timePeriod");
|
|
|
7
7
|
const accountListReducer_1 = require("../../../accountList/accountListReducer");
|
|
8
8
|
const classListReducer_1 = require("../../../classList/classListReducer");
|
|
9
9
|
const ownerListReducer_1 = require("../../../ownerList/ownerListReducer");
|
|
10
|
-
const projectListReducer_1 = require("../../../projectList/projectListReducer");
|
|
11
10
|
const transactionsViewReducer_1 = require("../../reducers/transactionsViewReducer");
|
|
12
11
|
const fetchTransactionCategorizationViewEpic = (actions$, state$) => actions$.pipe((0, operators_1.filter)(transactionsViewReducer_1.fetchTransactionCategorizationView.match), (0, operators_1.mergeMap)((action) => {
|
|
13
12
|
const { selectedTab, cacheOverride, keepExistingListItems, pageToken, period, refreshViewInBackground, searchString, resetListItems, isUncategorizedExpenseCategoryEnabled, } = action.payload;
|
|
@@ -25,16 +24,15 @@ const fetchTransactionCategorizationViewEpic = (actions$, state$) => actions$.pi
|
|
|
25
24
|
accountList.fetchState === 'Not-Started') {
|
|
26
25
|
updateActions.push((0, accountListReducer_1.fetchAccountList)('accountList', true));
|
|
27
26
|
}
|
|
27
|
+
const { transferAccounts } = state$.value.expenseAutomationTransactionsViewState;
|
|
28
|
+
if (transferAccounts.fetchState === 'Not-Started') {
|
|
29
|
+
updateActions.push((0, transactionsViewReducer_1.fetchTransferAccounts)());
|
|
30
|
+
}
|
|
28
31
|
const classList = state$.value.classListState;
|
|
29
32
|
if (classList.hasValidState() === false &&
|
|
30
33
|
classList.fetchState === 'Not-Started') {
|
|
31
34
|
updateActions.push((0, classListReducer_1.fetchClassList)());
|
|
32
35
|
}
|
|
33
|
-
const projectList = state$.value.projectListState;
|
|
34
|
-
if (projectList.hasValidState() === false &&
|
|
35
|
-
projectList.fetchState === 'Not-Started') {
|
|
36
|
-
updateActions.push((0, projectListReducer_1.fetchProjectList)());
|
|
37
|
-
}
|
|
38
36
|
const vendorOwnerList = state$.value.ownerListState;
|
|
39
37
|
if (vendorOwnerList.hasValidState() === false &&
|
|
40
38
|
vendorOwnerList.fetchState === 'Not-Started') {
|
|
@@ -0,0 +1,8 @@
|
|
|
1
|
+
import { ActionsObservable, StateObservable } from 'redux-observable';
|
|
2
|
+
import { Observable } from 'rxjs';
|
|
3
|
+
import { updateAccounts } from '../../../../entity/account/accountReducer';
|
|
4
|
+
import { RootState } from '../../../../reducer';
|
|
5
|
+
import { ZeniAPI } from '../../../../zeniAPI';
|
|
6
|
+
import { fetchTransferAccounts, updateTransferAccounts, updateTransferAccountsFailure } from '../../reducers/transactionsViewReducer';
|
|
7
|
+
export type ActionType = ReturnType<typeof fetchTransferAccounts> | ReturnType<typeof updateTransferAccounts> | ReturnType<typeof updateTransferAccountsFailure> | ReturnType<typeof updateAccounts>;
|
|
8
|
+
export declare const fetchTransferAccountsEpic: (actions$: ActionsObservable<ActionType>, _state$: StateObservable<RootState>, zeniAPI: ZeniAPI) => Observable<ActionType>;
|
package/lib/view/expenseAutomationView/epics/transactionCategorization/fetchTransferAccountsEpic.js
ADDED
|
@@ -0,0 +1,29 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.fetchTransferAccountsEpic = void 0;
|
|
4
|
+
const rxjs_1 = require("rxjs");
|
|
5
|
+
const operators_1 = require("rxjs/operators");
|
|
6
|
+
const accountReducer_1 = require("../../../../entity/account/accountReducer");
|
|
7
|
+
const responsePayload_1 = require("../../../../responsePayload");
|
|
8
|
+
const transactionsViewReducer_1 = require("../../reducers/transactionsViewReducer");
|
|
9
|
+
const TRANSFER_ACCOUNTS_REPORT_ID = 'transfer_accounts';
|
|
10
|
+
const fetchTransferAccountsEpic = (actions$, _state$, zeniAPI) => actions$.pipe((0, operators_1.filter)(transactionsViewReducer_1.fetchTransferAccounts.match), (0, operators_1.switchMap)(() => {
|
|
11
|
+
const queryValue = { is_only_include_transfer_accounts: true };
|
|
12
|
+
const url = `${zeniAPI.apiEndPoints.accountMicroServiceBaseUrl}/1.0/accounts?query=${encodeURIComponent(JSON.stringify(queryValue))}`;
|
|
13
|
+
return zeniAPI.getJSON(url).pipe((0, operators_1.mergeMap)((response) => {
|
|
14
|
+
if ((0, responsePayload_1.isSuccessResponse)(response) && response.data != null) {
|
|
15
|
+
const accountIds = response.data.accounts.map((account) => account.account_id);
|
|
16
|
+
const actions = [
|
|
17
|
+
(0, accountReducer_1.updateAccounts)(response.data.accounts, TRANSFER_ACCOUNTS_REPORT_ID),
|
|
18
|
+
(0, transactionsViewReducer_1.updateTransferAccounts)({ accountIds }),
|
|
19
|
+
];
|
|
20
|
+
return (0, rxjs_1.of)(...actions);
|
|
21
|
+
}
|
|
22
|
+
else {
|
|
23
|
+
return (0, rxjs_1.of)((0, transactionsViewReducer_1.updateTransferAccountsFailure)());
|
|
24
|
+
}
|
|
25
|
+
}), (0, operators_1.catchError)(() => {
|
|
26
|
+
return (0, rxjs_1.of)((0, transactionsViewReducer_1.updateTransferAccountsFailure)());
|
|
27
|
+
}));
|
|
28
|
+
}));
|
|
29
|
+
exports.fetchTransferAccountsEpic = fetchTransferAccountsEpic;
|
|
@@ -117,9 +117,6 @@ const toTransactionUpdatePayload = (updates, detail, transactionId, cotTrackingB
|
|
|
117
117
|
if (lineUpdates.class != null) {
|
|
118
118
|
lineToBeUpdated.class = lineUpdates.class;
|
|
119
119
|
}
|
|
120
|
-
if (lineUpdates.project != null) {
|
|
121
|
-
lineToBeUpdated.project = lineUpdates.project;
|
|
122
|
-
}
|
|
123
120
|
if (lineUpdates.account != null) {
|
|
124
121
|
lineToBeUpdated.account = lineUpdates.account;
|
|
125
122
|
}
|
|
@@ -44,7 +44,6 @@ const toTransactionUpdatesFromTransactionCategorizationLocalData = (transactionC
|
|
|
44
44
|
lineDescription: lineItem.lineDescription,
|
|
45
45
|
class: lineItem.class,
|
|
46
46
|
account: lineItem.account,
|
|
47
|
-
project: lineItem.project,
|
|
48
47
|
recommendation: (0, transactionHelper_1.convertCOTRecommendationsToRegular)(lineItem.recommendationsWithCOT),
|
|
49
48
|
};
|
|
50
49
|
if (line.type === 'journal_entry_transaction_line' ||
|
package/lib/view/expenseAutomationView/helpers/transactionCategorizationLocalDataHelper.d.ts
CHANGED
|
@@ -2,7 +2,6 @@ import { ID } from '../../../commonStateTypes/common';
|
|
|
2
2
|
import { AccountBase } from '../../../entity/account/accountState';
|
|
3
3
|
import { UncategorizedAccountTypes } from '../../../entity/account/accountState';
|
|
4
4
|
import { ClassBase } from '../../../entity/class/classState';
|
|
5
|
-
import { ProjectBase } from '../../../entity/project/projectState';
|
|
6
5
|
import { Entity } from '../../../entity/genericEntity/entity';
|
|
7
6
|
import { RecommendationWithCOTByLineId } from '../../../entity/transaction/stateTypes/transaction';
|
|
8
7
|
import { SupportedTransactionPayload, SupportedTransactionWithCOT } from '../../../entity/transaction/transactionState';
|
|
@@ -28,7 +27,7 @@ export declare const removeTransactionFromTabView: (tabView: TransactionsTabView
|
|
|
28
27
|
export declare const filterAutoTabLineItems: (tabView: TransactionsTabViewState, transactionId: ID, updatedTransaction: SupportedTransactionWithCOT) => void;
|
|
29
28
|
export declare const MAX_SELECTION_LIMIT = 5;
|
|
30
29
|
export declare const toTransactionDetailLocalData: (transaction: SupportedTransactionWithCOT, selectedTab: TransactionsTab, lineItemsByTransactionIds: string[], uncategorizedIncomeExpense: UncategorizedAccounts, isUncategorizedExpenseCategoryEnabled?: boolean) => TransactionReviewLocalData;
|
|
31
|
-
export declare const toSetAllLineItemsToCategoryClass: (draft: TransactionsTabViewState, transaction: SupportedTransactionWithCOT, transactionId: ID, transactionLineId: ID, transactionDetailLocalData: TransactionReviewLocalData, updatedItem: "category" | "class"
|
|
30
|
+
export declare const toSetAllLineItemsToCategoryClass: (draft: TransactionsTabViewState, transaction: SupportedTransactionWithCOT, transactionId: ID, transactionLineId: ID, transactionDetailLocalData: TransactionReviewLocalData, updatedItem: "category" | "class", uncategorizedAccounts: UncategorizedAccounts, selectedTab: TransactionsTab, vendorId?: ID, customerId?: ID, selectedAccount?: AccountBase, selectedClassBase?: ClassBase, isUncategorizedExpenseCategoryEnabled?: boolean, isAccountingClassesEnabled?: boolean) => {
|
|
32
31
|
localData: TransactionReviewLocalData;
|
|
33
32
|
similarTransactionUpdated: boolean;
|
|
34
33
|
};
|
|
@@ -38,7 +37,7 @@ export declare const getLineItemsByTransactionsIdsFromResponse: (transactions: S
|
|
|
38
37
|
export declare const getLineItemsByTransactionIdsFromLocalData: (transactionLocalData: TransactionReviewLocalDataSelectorView[], selectedTab: TransactionsTab) => Record<ID, string[]>;
|
|
39
38
|
export declare const mergeTabSpecificLineItems: (currentTabSpecificLineItems: TabSpecificLineItems, selectedTab: TransactionsTab, newLineItems: TabSpecificLineItems) => TabSpecificLineItems;
|
|
40
39
|
export declare const getSnackbarMessageForTransactionReview: (updatedCount: number, failedCount: number, categorizedCount: number) => {
|
|
41
|
-
messageSection: "common" | "transactionDetails_updatingPastTransactions" | "transactionDetails_transactionUpdated" | "cockpit_month_end_email_sent" | "cockpit_month_end_email_save" | "cockpit_month_end_email_attachment_upload" | "je_bill_link" | "je_posted" | "audit_score_updated" | "people_invite_people" | "people_invite_multiple_people" | "people_delete_person" | "people_update_person" | "reimbursement_updated" | "reimbursement_deleted" | "reimbursement_cancelled_deleted" | "reimbursement_cancelled" | "reimbursement_approved" | "reimbursement_rejected" | "reimbursement_sent_for_approval" | "account_added" | "business_verification_save" | "business_verification_submit" | "business_verification_from_bills_submit" | "plaid_connection" | "unlink_deposit_account" | "reimbursement_setup" | "reimbursement_approval_create" | "reimbursement_duplicate_approval_create" | "reimbursement_approval_update" | "reimbursement_duplicate_approval_update" | "reimbursement_approval_delete" | "reimbursement_create_mileage" | "reimbursement_update_mileage" | "reimbursement_accept_term" | "reimbursement_accept_employee_term" | "reimbursement_bulk_submit" | "reimbursement_bulk_processed" | "bill_pay_setup" | "zeni_accounts_setup" | "bill_pay_approval_create" | "bill_pay_duplicate_approval_create" | "bill_pay_approval_update" | "bill_pay_duplicate_approval_update" | "bill_pay_approval_delete" | "bill_pay_updated" | "bill_pay_deleted" | "bill_pay_cancelled_deleted" | "bill_pay_cancelled" | "bill_pay_approved" | "real_time_approver_added" | "bill_pay_rejected" | "bill_pay_sent_for_approval" | "bill_pay_accept_term" | "bill_pay_bulk_submit" | "bill_pay_bulk_processed" | "bill_pay_refund" | "bill_pay_retry" | "bill_pay_marked_as_paid" | "zeni_account_accept_term" | "update_vendor" | "data_refresh_update" | "delete_bank_account" | "create_bank_account" | "create_bank_account_ach" | "create_bank_account_wire" | "create_bank_account_international" | "transfer_money" | "update_zeni_account_nickname" | "create_checking_account" | "deposit_check" | "create_vendor" | "onboarding_customer_view" | "onboarding_customer_view_complete" | "onboarding_customer_identity_verification_save" | "onboarding_customer_identity_verification_submit" | "onboarding_customer_business_verification_save" | "onboarding_customer_business_verification_submit" | "retry_bank_account_connection" | "dashboard_invite_sent" | "onboarding_info_saved" | "approve_original_merchant" | "approve_global_merchant" | "reject_global_merchant" | "create_global_merchant" | "fetch_global_merchant_no_recommendation" | "save_vendor_renamed" | "save_vendor_sent_for_review" | "save_vendor_marked_as_employee" | "save_vendor_marked_as_local_contractor" | "charge_card_setup" | "charge_card_accept_term" | "charge_card_receipt_upload" | "charge_card_resend_invite" | "charge_card_revoke_invite" | "charge_card_update_limit" | "charge_cards_update_limit" | "close_charge_card" | "lock_charge_card" | "lock_charge_card_card_user" | "lock_charge_cards" | "unlock_charge_card" | "unlock_charge_card_card_user" | "unlock_charge_cards" | "close_charge_cards" | "revoke_invite_charge_cards" | "charge_card_express_interest" | "create_schedule" | "save_schedule" | "delete_schedule" | "ignore_schedule" | "save_task_detail" | "fetch_task_detail" | "delete_task" | "archive_task" | "snooze_task" | "unsnooze_task" | "create_tag" | "delete_tag" | "update_charge_card" | "update_charge_card_name" | "update_charge_card_name_card_user" | "issue_charge_card" | "issue_charge_cards" | "notification_settings_saved" | "referral_invite_sent" | "notification_mark_as_read" | "mark_as_complete_schedule" | "cancel_journal_entry" | "settings_accounting_accounts_updated" | "create_card_setup" | "confirm_card_setup" | "add_card_payment_source" | "fetch_payment_sources" | "task_assigned_toast_notification" | "task_due_tomorrow_toast_notification" | "task_deleted_toast_notification" | "task_archived_toast_notification" | "task_overdue_toast_notification" | "task_overdue_toast_notification_creator" | "task_notification_count" | "task_activities_toast_notification" | "task_created_toast_notification" | "task_group_creation_success" | "task_group_deletion_success" | "task_group_update_success" | "primary_funding_account_updated" | "task_time_spent_validation" | "missing_receipts_attachment" | "flux_analysis_unreviewed" | "flux_analysis_reviewed" | "receipt_match" | "receipts_upload" | "receipts_bulk_match" | "billing_address_view" | "express_pay_submit" | "exclude_transaction" | "reconcile" | "save_reconcile_for_later" | "recon_transaction_categorize" | "recon_transaction_match" | "update_debit_card_pin_attempt" | "set_debit_card_pin" | "ai_cfo_create_session_and_submit" | "ai_cfo_chat_session_deleted" | "charge_card_auto_pay_enable" | "charge_card_auto_pay_disable" | "treasury_setup" | "treasury_accept_term" | "treasury_transfer_money" | "treasury_transfer_money_failed" | "auto_transfer_rule_create" | "auto_transfer_rule_update" | "auto_transfer_rule_delete" | "auto_transfer_rule_pause" | "auto_transfer_rule_resume" | "treasury_update_portfolio_allocation" | "send_email_magic_link_to_user" | "complete_profile_done" | "reports_resync" | "invalid_phone_number" | "transactions_categorized_updated_failed" | "transaction_categorized_updated_failed" | "transactionsCategorized_transactionsUpdated" | "transactionsCategorized_transactionUpdated" | "transactionCategorized_transactionsUpdated" | "transactionCategorized_transactionUpdated" | "transactionsCategorized_transactionsFailed" | "transactionsCategorized_transactionFailed" | "transactionCategorized_transactionsFailed" | "transactionCategorized_transactionFailed" | "transactionsUpdated_transactionsFailed" | "transactionsUpdated_transactionFailed" | "transactionUpdated_transactionsFailed" | "transactionUpdated_transactionFailed" | "transactionsCategorized_transactionsUpdated_transactionsFailed" | "transactionsCategorized_transactionsUpdated_transactionFailed" | "transactionsCategorized_transactionUpdated_transactionsFailed" | "transactionCategorized_transactionsUpdated_transactionsFailed" | "transactionsCategorized_transactionUpdated_transactionFailed" | "transactionCategorized_transactionsUpdated_transactionFailed" | "transactionCategorized_transactionUpdated_transactionsFailed" | "transactionCategorized_transactionUpdated_transactionFailed" | "accounting_classes_enabled_update" | "account_excluded_from_reconciliation" | "account_included_in_reconciliation" | "ai_accountant_trigger_job" | "oauth_consent_approve" | "oauth_consent_invalid_request" | "credit_agent_update_profile" | "credit_agent_save_macro" | "credit_agent_schedule_cron";
|
|
40
|
+
messageSection: "common" | "transactionDetails_updatingPastTransactions" | "transactionDetails_transactionUpdated" | "cockpit_month_end_email_sent" | "cockpit_month_end_email_save" | "cockpit_month_end_email_attachment_upload" | "je_bill_link" | "je_posted" | "audit_score_updated" | "people_invite_people" | "people_invite_multiple_people" | "people_delete_person" | "people_update_person" | "reimbursement_updated" | "reimbursement_deleted" | "reimbursement_cancelled_deleted" | "reimbursement_cancelled" | "reimbursement_approved" | "reimbursement_rejected" | "reimbursement_sent_for_approval" | "account_added" | "business_verification_save" | "business_verification_submit" | "business_verification_from_bills_submit" | "plaid_connection" | "unlink_deposit_account" | "reimbursement_setup" | "reimbursement_approval_create" | "reimbursement_duplicate_approval_create" | "reimbursement_approval_update" | "reimbursement_duplicate_approval_update" | "reimbursement_approval_delete" | "reimbursement_create_mileage" | "reimbursement_update_mileage" | "reimbursement_accept_term" | "reimbursement_accept_employee_term" | "reimbursement_bulk_submit" | "reimbursement_bulk_processed" | "bill_pay_setup" | "zeni_accounts_setup" | "bill_pay_approval_create" | "bill_pay_duplicate_approval_create" | "bill_pay_approval_update" | "bill_pay_duplicate_approval_update" | "bill_pay_approval_delete" | "bill_pay_updated" | "bill_pay_deleted" | "bill_pay_cancelled_deleted" | "bill_pay_cancelled" | "bill_pay_approved" | "real_time_approver_added" | "bill_pay_rejected" | "bill_pay_sent_for_approval" | "bill_pay_accept_term" | "bill_pay_bulk_submit" | "bill_pay_bulk_processed" | "bill_pay_refund" | "bill_pay_retry" | "bill_pay_marked_as_paid" | "zeni_account_accept_term" | "update_vendor" | "data_refresh_update" | "delete_bank_account" | "create_bank_account" | "create_bank_account_ach" | "create_bank_account_wire" | "create_bank_account_international" | "transfer_money" | "update_zeni_account_nickname" | "create_checking_account" | "deposit_check" | "create_vendor" | "onboarding_customer_view" | "onboarding_customer_view_complete" | "onboarding_customer_identity_verification_save" | "onboarding_customer_identity_verification_submit" | "onboarding_customer_business_verification_save" | "onboarding_customer_business_verification_submit" | "retry_bank_account_connection" | "dashboard_invite_sent" | "onboarding_info_saved" | "approve_original_merchant" | "approve_global_merchant" | "reject_global_merchant" | "create_global_merchant" | "fetch_global_merchant_no_recommendation" | "save_vendor_renamed" | "save_vendor_sent_for_review" | "save_vendor_marked_as_employee" | "save_vendor_marked_as_local_contractor" | "charge_card_setup" | "charge_card_accept_term" | "charge_card_receipt_upload" | "charge_card_resend_invite" | "charge_card_revoke_invite" | "charge_card_update_limit" | "charge_cards_update_limit" | "close_charge_card" | "lock_charge_card" | "lock_charge_card_card_user" | "lock_charge_cards" | "unlock_charge_card" | "unlock_charge_card_card_user" | "unlock_charge_cards" | "close_charge_cards" | "revoke_invite_charge_cards" | "charge_card_express_interest" | "create_schedule" | "save_schedule" | "delete_schedule" | "ignore_schedule" | "save_task_detail" | "fetch_task_detail" | "delete_task" | "archive_task" | "snooze_task" | "unsnooze_task" | "create_tag" | "delete_tag" | "update_charge_card" | "update_charge_card_name" | "update_charge_card_name_card_user" | "issue_charge_card" | "issue_charge_cards" | "notification_settings_saved" | "referral_invite_sent" | "notification_mark_as_read" | "mark_as_complete_schedule" | "cancel_journal_entry" | "settings_accounting_accounts_updated" | "create_card_setup" | "confirm_card_setup" | "add_card_payment_source" | "fetch_payment_sources" | "task_assigned_toast_notification" | "task_due_tomorrow_toast_notification" | "task_deleted_toast_notification" | "task_archived_toast_notification" | "task_overdue_toast_notification" | "task_overdue_toast_notification_creator" | "task_notification_count" | "task_activities_toast_notification" | "task_created_toast_notification" | "task_group_creation_success" | "task_group_deletion_success" | "task_group_update_success" | "primary_funding_account_updated" | "task_time_spent_validation" | "missing_receipts_attachment" | "flux_analysis_unreviewed" | "flux_analysis_reviewed" | "receipt_match" | "receipts_upload" | "receipts_bulk_match" | "billing_address_view" | "express_pay_submit" | "exclude_transaction" | "reconcile" | "save_reconcile_for_later" | "recon_transaction_categorize" | "recon_transaction_match" | "update_debit_card_pin_attempt" | "set_debit_card_pin" | "ai_cfo_create_session_and_submit" | "ai_cfo_chat_session_deleted" | "charge_card_auto_pay_enable" | "charge_card_auto_pay_disable" | "treasury_setup" | "treasury_accept_term" | "treasury_transfer_money" | "treasury_transfer_money_failed" | "auto_transfer_rule_create" | "auto_transfer_rule_update" | "auto_transfer_rule_delete" | "auto_transfer_rule_pause" | "auto_transfer_rule_resume" | "treasury_update_portfolio_allocation" | "send_email_magic_link_to_user" | "complete_profile_done" | "convert_transaction_type" | "create_transfer_entry" | "reports_resync" | "invalid_phone_number" | "transactions_categorized_updated_failed" | "transaction_categorized_updated_failed" | "transactionsCategorized_transactionsUpdated" | "transactionsCategorized_transactionUpdated" | "transactionCategorized_transactionsUpdated" | "transactionCategorized_transactionUpdated" | "transactionsCategorized_transactionsFailed" | "transactionsCategorized_transactionFailed" | "transactionCategorized_transactionsFailed" | "transactionCategorized_transactionFailed" | "transactionsUpdated_transactionsFailed" | "transactionsUpdated_transactionFailed" | "transactionUpdated_transactionsFailed" | "transactionUpdated_transactionFailed" | "transactionsCategorized_transactionsUpdated_transactionsFailed" | "transactionsCategorized_transactionsUpdated_transactionFailed" | "transactionsCategorized_transactionUpdated_transactionsFailed" | "transactionCategorized_transactionsUpdated_transactionsFailed" | "transactionsCategorized_transactionUpdated_transactionFailed" | "transactionCategorized_transactionsUpdated_transactionFailed" | "transactionCategorized_transactionUpdated_transactionsFailed" | "transactionCategorized_transactionUpdated_transactionFailed" | "accounting_classes_enabled_update" | "account_excluded_from_reconciliation" | "account_included_in_reconciliation" | "ai_accountant_trigger_job" | "oauth_consent_approve" | "oauth_consent_invalid_request" | "credit_agent_update_profile" | "credit_agent_save_macro" | "credit_agent_schedule_cron";
|
|
42
41
|
messageText: "notification" | "failed" | "success";
|
|
43
42
|
type: "error" | "success" | "info";
|
|
44
43
|
variables: {
|
|
@@ -190,7 +190,6 @@ const buildLineItemById = (transaction, uncategorizedIncomeExpense, recommendati
|
|
|
190
190
|
const lineId = line.id;
|
|
191
191
|
record.account = accountLine.account;
|
|
192
192
|
record.class = accountLine.class;
|
|
193
|
-
record.project = accountLine.project;
|
|
194
193
|
record.vendor =
|
|
195
194
|
accountLine.vendor != null
|
|
196
195
|
? {
|
|
@@ -313,7 +312,7 @@ const buildLineItemById = (transaction, uncategorizedIncomeExpense, recommendati
|
|
|
313
312
|
});
|
|
314
313
|
return lineItemData;
|
|
315
314
|
};
|
|
316
|
-
const toSetAllLineItemsToCategoryClass = (draft, transaction, transactionId, transactionLineId, transactionDetailLocalData, updatedItem, uncategorizedAccounts, selectedTab, vendorId, customerId, selectedAccount, selectedClassBase,
|
|
315
|
+
const toSetAllLineItemsToCategoryClass = (draft, transaction, transactionId, transactionLineId, transactionDetailLocalData, updatedItem, uncategorizedAccounts, selectedTab, vendorId, customerId, selectedAccount, selectedClassBase, isUncategorizedExpenseCategoryEnabled, isAccountingClassesEnabled) => {
|
|
317
316
|
let newLineItems = {};
|
|
318
317
|
let selectedCheckBoxTransactionIds = draft.selectedCheckBoxTransactionIds;
|
|
319
318
|
let similarTransactionUpdated = false;
|
|
@@ -333,7 +332,7 @@ const toSetAllLineItemsToCategoryClass = (draft, transaction, transactionId, tra
|
|
|
333
332
|
const record = {
|
|
334
333
|
...transactionDetailLocalData.lineItemById[lineId],
|
|
335
334
|
};
|
|
336
|
-
// if the line is the one that is being updated, then set the account
|
|
335
|
+
// if the line is the one that is being updated, then set the account and class
|
|
337
336
|
if (transactionId === record.transactionId &&
|
|
338
337
|
transactionLineId === lineId) {
|
|
339
338
|
if (selectedAccount != null) {
|
|
@@ -342,9 +341,6 @@ const toSetAllLineItemsToCategoryClass = (draft, transaction, transactionId, tra
|
|
|
342
341
|
if (selectedClassBase != null) {
|
|
343
342
|
record.class = selectedClassBase;
|
|
344
343
|
}
|
|
345
|
-
if (selectedProjectBase != null) {
|
|
346
|
-
record.project = selectedProjectBase;
|
|
347
|
-
}
|
|
348
344
|
const isClassSatisfied = isAccountingClassesEnabled === false || record.class != null;
|
|
349
345
|
if (isClassSatisfied && record.account != null) {
|
|
350
346
|
if (selectedCheckBoxTransactionIds.length < exports.MAX_SELECTION_LIMIT &&
|
|
@@ -396,10 +392,6 @@ const toSetAllLineItemsToCategoryClass = (draft, transaction, transactionId, tra
|
|
|
396
392
|
selectedCheckBoxTransactionIds.push(transaction.id);
|
|
397
393
|
}
|
|
398
394
|
}
|
|
399
|
-
// Project intentionally does NOT propagate to other rows of
|
|
400
|
-
// the same vendor: each line can carry a different project,
|
|
401
|
-
// and auto-filling siblings (the way class does) leads to
|
|
402
|
-
// unexpected bulk selection.
|
|
403
395
|
}
|
|
404
396
|
}
|
|
405
397
|
if (line.type === 'transaction_with_product_or_service_line') {
|
|
@@ -530,7 +522,6 @@ const setEntityRecommendationForLineIdInLocalData = (draft, transaction, transac
|
|
|
530
522
|
...newLineItem,
|
|
531
523
|
class: matchingRecord.class,
|
|
532
524
|
account: matchingRecord.account,
|
|
533
|
-
project: matchingRecord.project,
|
|
534
525
|
lineEntity: matchingRecord.lineEntity,
|
|
535
526
|
};
|
|
536
527
|
}
|
|
@@ -4,7 +4,6 @@ import { MonthYearPeriod, TimePeriod } from '../../../commonStateTypes/timePerio
|
|
|
4
4
|
import { PageToken } from '../../../commonStateTypes/viewAndReport/viewAndReport';
|
|
5
5
|
import { AccountBase } from '../../../entity/account/accountState';
|
|
6
6
|
import { ClassBase } from '../../../entity/class/classState';
|
|
7
|
-
import { ProjectBase } from '../../../entity/project/projectState';
|
|
8
7
|
import { CustomerBase } from '../../../entity/customer/customerState';
|
|
9
8
|
import { Entity } from '../../../entity/genericEntity/entity';
|
|
10
9
|
import { RecommendationWithCOTByLineId, TransactionID } from '../../../entity/transaction/stateTypes/transaction';
|
|
@@ -101,7 +100,7 @@ export declare const fetchTransactionCategorization: import("@reduxjs/toolkit").
|
|
|
101
100
|
isUncategorizedExpenseCategoryEnabled?: boolean;
|
|
102
101
|
selectedEntity?: Entity;
|
|
103
102
|
updatedCustomer?: CustomerBase;
|
|
104
|
-
}, "expenseAutomationTransactionsView/updateSelectedCustomerForTransaction">, setAllItemsToCategoryClassInLocalDataForCategorization: import("@reduxjs/toolkit").ActionCreatorWithPreparedPayload<[selectedTab: "review" | "autoCategorized", transactionId: string, lineId: string, transactions: SupportedTransactionWithCOT[], uncategorizedAccounts: UncategorizedAccounts, vendorId?: string | undefined, customerId?: string | undefined, selectedAccount?: AccountBase | undefined, selectedClassBase?: ClassBase | undefined, lineEntity?: Entity | undefined, recommendations?: RecommendationWithCOT[] | undefined, isUncategorizedExpenseCategoryEnabled?: boolean | undefined, isAccountingClassesEnabled?: boolean | undefined
|
|
103
|
+
}, "expenseAutomationTransactionsView/updateSelectedCustomerForTransaction">, setAllItemsToCategoryClassInLocalDataForCategorization: import("@reduxjs/toolkit").ActionCreatorWithPreparedPayload<[selectedTab: "review" | "autoCategorized", transactionId: string, lineId: string, transactions: SupportedTransactionWithCOT[], uncategorizedAccounts: UncategorizedAccounts, vendorId?: string | undefined, customerId?: string | undefined, selectedAccount?: AccountBase | undefined, selectedClassBase?: ClassBase | undefined, lineEntity?: Entity | undefined, recommendations?: RecommendationWithCOT[] | undefined, isUncategorizedExpenseCategoryEnabled?: boolean | undefined, isAccountingClassesEnabled?: boolean | undefined], {
|
|
105
104
|
selectedTab: "review" | "autoCategorized";
|
|
106
105
|
transactionId: string;
|
|
107
106
|
lineId: string;
|
|
@@ -111,7 +110,6 @@ export declare const fetchTransactionCategorization: import("@reduxjs/toolkit").
|
|
|
111
110
|
lineEntity: Entity | undefined;
|
|
112
111
|
selectedAccount: AccountBase | undefined;
|
|
113
112
|
selectedClassBase: ClassBase | undefined;
|
|
114
|
-
selectedProjectBase: ProjectBase | undefined;
|
|
115
113
|
recommendations: RecommendationWithCOT[] | undefined;
|
|
116
114
|
uncategorizedAccounts: UncategorizedAccounts;
|
|
117
115
|
isAccountingClassesEnabled: boolean | undefined;
|
|
@@ -164,7 +162,21 @@ export declare const fetchTransactionCategorization: import("@reduxjs/toolkit").
|
|
|
164
162
|
}, "expenseAutomationTransactionsView/syncTransactionCategorizationFromDetailSave", never, never>, backgroundRefetchReviewTab: import("@reduxjs/toolkit").ActionCreatorWithPreparedPayload<[period: TimePeriod, isUncategorizedExpenseCategoryEnabled?: boolean | undefined], {
|
|
165
163
|
period: TimePeriod;
|
|
166
164
|
isUncategorizedExpenseCategoryEnabled: boolean | undefined;
|
|
167
|
-
}, "expenseAutomationTransactionsView/backgroundRefetchReviewTab", never, never>,
|
|
165
|
+
}, "expenseAutomationTransactionsView/backgroundRefetchReviewTab", never, never>, fetchTransferAccounts: import("@reduxjs/toolkit").ActionCreatorWithoutPayload<"expenseAutomationTransactionsView/fetchTransferAccounts">, updateTransferAccounts: import("@reduxjs/toolkit").ActionCreatorWithPayload<{
|
|
166
|
+
accountIds: ID[];
|
|
167
|
+
}, "expenseAutomationTransactionsView/updateTransferAccounts">, updateTransferAccountsFailure: import("@reduxjs/toolkit").ActionCreatorWithoutPayload<"expenseAutomationTransactionsView/updateTransferAccountsFailure">, createTransferEntry: import("@reduxjs/toolkit").ActionCreatorWithPreparedPayload<[transactionId: string, creditAccountIntegrationId: string, debitAccountIntegrationId: string, memo: string, transactionType: string, sourceTransactionType: string], {
|
|
168
|
+
transactionId: string;
|
|
169
|
+
creditAccountIntegrationId: string;
|
|
170
|
+
debitAccountIntegrationId: string;
|
|
171
|
+
memo: string;
|
|
172
|
+
transactionType: string;
|
|
173
|
+
sourceTransactionType: string;
|
|
174
|
+
}, "expenseAutomationTransactionsView/createTransferEntry", never, never>, createTransferEntrySuccess: import("@reduxjs/toolkit").ActionCreatorWithoutPayload<"expenseAutomationTransactionsView/createTransferEntrySuccess">, createTransferEntryFailure: import("@reduxjs/toolkit").ActionCreatorWithoutPayload<"expenseAutomationTransactionsView/createTransferEntryFailure">, resetCreateTransferEntryStatus: import("@reduxjs/toolkit").ActionCreatorWithoutPayload<"expenseAutomationTransactionsView/resetCreateTransferEntryStatus">, createTransferEntryReplacedTransaction: import("@reduxjs/toolkit").ActionCreatorWithPreparedPayload<[previousTransactionId: TransactionID, newTransactionId: TransactionID], {
|
|
175
|
+
newTransactionId: TransactionID;
|
|
176
|
+
previousTransactionId: TransactionID;
|
|
177
|
+
}, "expenseAutomationTransactionsView/createTransferEntryReplacedTransaction", never, never>, acknowledgeTransferEntryRouteReplacement: import("@reduxjs/toolkit").ActionCreatorWithoutPayload<"expenseAutomationTransactionsView/acknowledgeTransferEntryRouteReplacement">, removeTransactionFromAllTabs: import("@reduxjs/toolkit").ActionCreatorWithPreparedPayload<[transactionId: string], {
|
|
178
|
+
transactionId: string;
|
|
179
|
+
}, "expenseAutomationTransactionsView/removeTransactionFromAllTabs", never, never>, updateTransactionCategorizationUploadReceiptState: import("@reduxjs/toolkit").ActionCreatorWithPreparedPayload<[selectedTab: "review" | "autoCategorized", transactionId: string, fetchStatus: FetchStateAndError], {
|
|
168
180
|
selectedTab: "review" | "autoCategorized";
|
|
169
181
|
transactionId: string;
|
|
170
182
|
fetchStatus: FetchStateAndError;
|