@zeniai/client-epic-state 5.2.72 → 5.2.74-betaAK0
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/entity/invoicing/coupon/couponSelector.d.ts +1 -0
- package/lib/entity/invoicing/coupon/couponSelector.js +5 -0
- package/lib/epic.d.ts +2 -1
- package/lib/epic.js +2 -0
- package/lib/esm/entity/invoicing/coupon/couponSelector.js +4 -0
- package/lib/esm/epic.js +2 -0
- package/lib/esm/index.js +1 -1
- package/lib/esm/view/invoicing/editInvoicingSubscriptionDetailView/editInvoicingSubscriptionDetailViewPayload.js +55 -0
- package/lib/esm/view/invoicing/editInvoicingSubscriptionDetailView/editInvoicingSubscriptionDetailViewReducer.js +35 -1
- package/lib/esm/view/invoicing/editInvoicingSubscriptionDetailView/editInvoicingSubscriptionDetailViewSelector.js +80 -2
- package/lib/esm/view/invoicing/editInvoicingSubscriptionDetailView/fetchInvoicingSubscriptionEstimateEpic.js +49 -0
- package/lib/esm/view/invoicing/editInvoicingSubscriptionDetailView/saveInvoicingSubscriptionEpic.js +18 -13
- package/lib/esm/view/onboardingView/customerView/epic/customerDetails/updateOnboardingCustomerViewEpic.js +2 -2
- package/lib/index.d.ts +3 -3
- package/lib/index.js +7 -5
- package/lib/view/invoicing/editInvoicingSubscriptionDetailView/editInvoicingSubscriptionDetailViewPayload.d.ts +46 -1
- package/lib/view/invoicing/editInvoicingSubscriptionDetailView/editInvoicingSubscriptionDetailViewPayload.js +57 -1
- package/lib/view/invoicing/editInvoicingSubscriptionDetailView/editInvoicingSubscriptionDetailViewReducer.d.ts +10 -2
- package/lib/view/invoicing/editInvoicingSubscriptionDetailView/editInvoicingSubscriptionDetailViewReducer.js +36 -2
- package/lib/view/invoicing/editInvoicingSubscriptionDetailView/editInvoicingSubscriptionDetailViewSelector.d.ts +21 -1
- package/lib/view/invoicing/editInvoicingSubscriptionDetailView/editInvoicingSubscriptionDetailViewSelector.js +83 -3
- package/lib/view/invoicing/editInvoicingSubscriptionDetailView/editInvoicingSubscriptionDetailViewState.d.ts +58 -0
- package/lib/view/invoicing/editInvoicingSubscriptionDetailView/fetchInvoicingSubscriptionEstimateEpic.d.ts +7 -0
- package/lib/view/invoicing/editInvoicingSubscriptionDetailView/fetchInvoicingSubscriptionEstimateEpic.js +53 -0
- package/lib/view/invoicing/editInvoicingSubscriptionDetailView/saveInvoicingSubscriptionEpic.d.ts +8 -0
- package/lib/view/invoicing/editInvoicingSubscriptionDetailView/saveInvoicingSubscriptionEpic.js +21 -14
- package/lib/view/onboardingView/customerView/epic/customerDetails/updateOnboardingCustomerViewEpic.js +2 -2
- package/package.json +1 -26
|
@@ -2,3 +2,4 @@ import { ID } from '../../../commonStateTypes/common';
|
|
|
2
2
|
import { InvoicingCoupon, InvoicingCouponState } from './couponState';
|
|
3
3
|
export declare function getInvoicingCouponsByIds(couponState: InvoicingCouponState, ids: ID[]): InvoicingCoupon[];
|
|
4
4
|
export declare function getInvoicingCouponById(couponState: InvoicingCouponState, id: ID): InvoicingCoupon | undefined;
|
|
5
|
+
export declare function getInvoicingCouponByCode(couponState: InvoicingCouponState, couponCode: string): InvoicingCoupon | undefined;
|
|
@@ -5,6 +5,7 @@ var __importDefault = (this && this.__importDefault) || function (mod) {
|
|
|
5
5
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
6
6
|
exports.getInvoicingCouponsByIds = getInvoicingCouponsByIds;
|
|
7
7
|
exports.getInvoicingCouponById = getInvoicingCouponById;
|
|
8
|
+
exports.getInvoicingCouponByCode = getInvoicingCouponByCode;
|
|
8
9
|
const get_1 = __importDefault(require("lodash/get"));
|
|
9
10
|
function getInvoicingCouponsByIds(couponState, ids) {
|
|
10
11
|
return ids
|
|
@@ -14,3 +15,7 @@ function getInvoicingCouponsByIds(couponState, ids) {
|
|
|
14
15
|
function getInvoicingCouponById(couponState, id) {
|
|
15
16
|
return (0, get_1.default)(couponState.couponByID, id);
|
|
16
17
|
}
|
|
18
|
+
// Forms hold a coupon by its code; the store keys coupons by id.
|
|
19
|
+
function getInvoicingCouponByCode(couponState, couponCode) {
|
|
20
|
+
return Object.values(couponState.couponByID).find((coupon) => coupon.couponCode === couponCode);
|
|
21
|
+
}
|
package/lib/epic.d.ts
CHANGED
|
@@ -272,6 +272,7 @@ import { ActionType as EditInvoicingCustomerDetailViewActionType } from './view/
|
|
|
272
272
|
import { ActionType as InvoicingCustomerFormDraftSeedActionType } from './view/invoicing/editInvoicingCustomerDetailView/seedInvoicingCustomerFormDraftEpic';
|
|
273
273
|
import { ActionType as InvoicingSubscriptionDetailFetchActionType } from './view/invoicing/editInvoicingSubscriptionDetailView/fetchInvoicingSubscriptionDetailEpic';
|
|
274
274
|
import { ActionType as InvoicingSubscriptionDetailPageActionType } from './view/invoicing/editInvoicingSubscriptionDetailView/fetchInvoicingSubscriptionDetailPageEpic';
|
|
275
|
+
import { ActionType as InvoicingSubscriptionEstimateActionType } from './view/invoicing/editInvoicingSubscriptionDetailView/fetchInvoicingSubscriptionEstimateEpic';
|
|
275
276
|
import { ActionType as InvoicingSubscriptionFormPageActionType } from './view/invoicing/editInvoicingSubscriptionDetailView/fetchInvoicingSubscriptionFormPageEpic';
|
|
276
277
|
import { ActionType as InvoicingSubscriptionActionActionType } from './view/invoicing/editInvoicingSubscriptionDetailView/runInvoicingSubscriptionActionEpic';
|
|
277
278
|
import { ActionType as EditInvoicingSubscriptionDetailViewActionType } from './view/invoicing/editInvoicingSubscriptionDetailView/saveInvoicingSubscriptionEpic';
|
|
@@ -704,5 +705,5 @@ import { ActionType as FetchDepositAccStatementListActionType } from './view/zen
|
|
|
704
705
|
import { ActionType as FetchZeniAccStatePageActionType } from './view/zeniAccStatementList/fetchZeniAccStatementPageEpic';
|
|
705
706
|
import { ActionType as ApproveOAuthConsentActionType } from './view/zeniOAuthView/epics/approveOAuthConsentEpic';
|
|
706
707
|
/** Root action type is union of all the epic action type */
|
|
707
|
-
export type RootActionType = AcceptBillPayTermsActionType | AcceptBillPayUpdatedTermsActionType | AcceptChargeCardTermsActionType | AcceptEmployeeRemiTermsActionType | AcceptMasterTOSEpicActionType | AcceptRemiTermsActionType | AcceptTreasuryTermsActionType | AcceptZeniAccountTermsActionType | AcknowledgeOnboardingAiActivationViewedActionType | AcknowledgeOnboardingAiFinanceTeamActionType | AddCardPaymentSourceActionType | ApplyBillRecommendationsToLocalStoreActionType | ApplyExtractedPolicyToDraftActionType | ApproveOAuthConsentActionType | ApproveOrRejectBillActionType | ApproveOrRejectBillsBulkActionActionType | ApproveOrRejectRemiActionType | ApproveOrRejectRemisBulkActionActionType | ApproveVendorGlobalReviewActionType | ArchiveCardPolicyActionType | ArchiveTaskActionType | BackgroundRefetchReviewTabActionType | BalanceSheetActionType | BalanceSheetClassesViewActionType | BalanceSheetForTimeframeActionType | BalanceSheetForTimeframeClassesViewActionType | BalanceSheetForTimeframeProjectViewActionType | BalanceSheetProjectViewActionType | BulkUpdateTasksListActionType | BulkUploadMatchResultToastActionType | BulkUploadReceiptsActionType | CancelAiAccountantOnboardingActionType | CancelAndDeleteBillActionType | CancelAndDeleteRemiActionType | CancelOrDeleteBillsBulkActionActionType | CancelOrDeleteRemisBulkActionActionType | CancelScheduleAccruedJournalEntryActionType | CardBalanceActionType | CashBalanceActionType | CashFlowActionType | CashFlowClassesViewActionType | CashFlowForTimeframeActionType | CashFlowForTimeframeClassesViewActionType | CashFlowForTimeframeProjectViewActionType | CashFlowProjectViewActionType | CashInCashOutActionType | CashPositionActionType | ChangeZeniPersonRolesActionType | CheckDepositActionType | CloseChargeCardActionType | CloseChargeCardsActionType | CombinedStatementActionType | CompanyManagementSavePendingUpdatesActionType | CompanyManagementSaveUpdatesActionType | ConfirmBulkUploadMatchActionType | ConfirmCardSetupIntentActionType | ConfirmStatementMappingActionType | CreateAddressActionType | CreateAutoTransferRuleActionType | CreateBankAccountActionType | CreateCardPolicyTemplateActionType | CreateCardSetupIntentActionType | CreateCheckingAccountActionType | CreateCompanyAddressActionType | CreateCompanyOfficersActionType | CreateCompanyUserAddressActionType | CreateGlobalMerchantActionType | CreateInternationalBankAccountActionType | CreateInvoiceActionType | CreateNewSchedulesAccruedActionType | CreateNewSchedulesActionType | CreateNewTaskGroupActionType | CreateOneTimeAccrualActionType | CreatePaymentInstrumentActionType | CreateSessionActionType | CreateSessionAndSubmitActionType | CreateSubTaskActionType | CreateTagActionType | CreateTaskFromTaskGroupTemplateActionType | CreateTransferEntryActionType | CreateUserBankAccountActionType | CurrencyConversionActionType | DeleteAccountStatementActionType | DeleteAutoTransferRuleActionType | DeleteBankAccountActionType | DeleteBillActionType | DeleteBillPayApprovalRuleActionType | DeleteCannedResponseActionType | DeleteChatSessionActionType | DeleteCombinedStatementActionType | DeleteFileActionType | DeleteFileListActionType | DeleteInternationalBankAccountActionType | DeletePaymentInstrumentActionType | DeletePersonActionType | DeleteRemiActionType | DeleteRemiApprovalRuleActionType | DeleteScheduleAccruedDetailActionType | DeleteScheduleDetailActionType | DeleteTagActionType | DeleteTaskActionType | DeleteTaskGroupActionType | DeleteTransactionAttachmentActionType | DeleteUserBankAccountActionType | DepositAccountTransactionListActionType | DisableAccountingProjectsActionType | DismissCapitalizationOnboardingActionType | DoMagicLinkSignInActionType | DownloadAccountingProviderAttachmentActionType | DragNDropTasksActionType | EditInvoicingCatalogItemDetailViewActionType | EditInvoicingCouponDetailViewActionType | EditInvoicingCustomerDetailViewActionType | EditInvoicingSubscriptionDetailViewActionType | EnableAccountingProjectsActionType | EnableChargeCardAutoPayActionType | EnableSetupActionType | EstablishOnboardingPlaidConnectionActionType | EstablishPlaidConnectionActionType | ExcludeAccountFromReconciliationActionType | ExpressInterestChargeCardActionType | ExpressPayActionType | ExtractPolicyDocumentActionType | FetchAccountHistoryActionType | FetchAccountListActionType | FetchAccountListForAccountTypesActionType | FetchAccountSettingsListForAccountTypesActionType | FetchAccruedScheduleListActionType | FetchActiveTenantActionType | FetchAddressActionType | FetchAggregatedReportActionType | FetchAiAccountantCustomersActionType | FetchAiAccountantJobsActionType | FetchAiAgentsActivationStatusActionType | FetchAllCockpitViewsActionType | FetchAllExpenseAutomationTabsActionType | FetchAllPeopleRequiredActionType | FetchAllTagsActionType | FetchAllTaskGroupsActionType | FetchAllTenantsActionType | FetchApAgingActionType | FetchApAgingDetailActionType | FetchArAgingActionType | FetchArAgingDetailActionType | FetchAuditReportGroupViewActionType | FetchAuditRuleGroupViewActionType | FetchAutoTransferReviewDetailActionType | FetchAutoTransferRuleHistoryActionType | FetchAutoTransferRulesActionType | FetchBankAccountsListActionType | FetchBankConnectionsViewActionType | FetchBankCountryNameByIbanActionType | FetchBankNameByRoutingActionType | FetchBankNameBySwiftActionType | FetchBillAndInitializeLocalStoreActionType | FetchBillDetailActionType | FetchBillingAccountsListActionType | FetchBillListActionType | FetchBillListPerTabActionType | FetchBillPayApproversDetailsActionType | FetchBillPayApproversListActionType | FetchBillPayCardActionType | FetchBillPayConfigActionType | FetchBillPaySetupApproverViewActionType | FetchBillPaySetupViewActionType | FetchBillRecommendationsActionType | FetchBulkUploadBatchDetailsActionType | FetchBulkUploadBatchesActionType | FetchCannedResponsesActionType | FetchCardPolicyDetailActionType | FetchCardPolicyListActionType | FetchCardPolicyMccCategoriesActionType | FetchCardPolicyVendorOptionsActionType | FetchCardProfilesActionType | FetchCashbackDetailActionType | FetchChargeCardConfigActionType | FetchChargeCardDetailActionType | FetchChargeCardDetailPageActionType | FetchChargeCardListActionType | FetchChargeCardListPageActionType | FetchChargeCardPaymentHistoryActionType | FetchChargeCardPaymentPageActionType | FetchChargeCardRepaymentDetailActionType | FetchChargeCardSetupViewActionType | FetchChargeCardsRecurringExpensesActionType | FetchChargeCardStatementListActionType | FetchChargeCardTransactionAttachmentsActionType | FetchChargeCardTransactionListActionType | FetchChargeCardTransactionStatisticsActionType | FetchChatHistoryActionType | FetchChatSessionsForUserActionType | FetchClassListActionType | FetchCockpitContextActionType | FetchCollaborationAuthTokenActionType | FetchCompanyBillingAddressActionType | FetchCompanyConfigActionType | FetchCompanyHealthMetricConfigViewEpicActionType | FetchCompanyHealthMetricViewEpicActionType | FetchCompanyManagementActionType | FetchCompanyMetaDataActionType | FetchCompanyMonthEndReportHistoricDataActionType | FetchCompanyMonthEndReportHistoricDatesActionType | FetchCompanyMonthEndReportTemplatesActionType | FetchCompanyMonthEndReportViewActionType | FetchCompanyOnboardingViewActionType | FetchCompanyPassportViewActionType | FetchCompanyPortfolioActionType | FetchCompanyTaskManagerViewActionType | FetchCompletedTransactionsActionType | FetchCreateInvoiceFormPageActionType | FetchCreditAccountActionType | FetchCreditAccountRepaymentActionType | FetchCreditAgentMacroActionType | FetchCurrencyConversionValueActionType | FetchDashboardActionType | FetchDashboardLayoutActionType | FetchDebitCardSummaryActionType | FetchDepositAccountActionType | FetchDepositAccountDetailActionType | FetchDepositAccountLimitActionType | FetchDepositAccountListActionType | FetchDepositAccountListForCardsActionType | FetchDepositAccStatementListActionType | FetchDownloadSchedulesActionType | FetchDuplicateBillActionType | FetchDuplicateReimbursementEpicActionType | FetchEditBillDetailPageActionType | FetchEditRemiDetailPageActionType | FetchEligibleActionsForBillActionType | FetchEntityAutoCompleteActionType | FetchEntityHistoryActionType | FetchEntityRecommendationsByTransactionIdActionType | FetchEntityRecommendationsForLineUpdateActionType | FetchExcludedResourcesActionType | FetchExpenseAutomationActualMatchingActionType | FetchExpenseAutomationActualMatchingMatchActionType | FetchExpenseAutomationActualMatchingPageActionType | FetchExpenseAutomationFailedJePostingsActionType | FetchExpenseAutomationFluxAnalysisActionType | FetchExpenseAutomationInitializeTransactionCategorizationViewLocalDataActionType | FetchExpenseAutomationJEScheduleActionType | FetchExpenseAutomationJESchedulePageActionType | FetchExpenseAutomationMarkTransactionAsNotMiscategorizedActionType | FetchExpenseAutomationMissingReceiptsActionType | FetchExpenseAutomationReconciliationsViewActionType | FetchExpenseAutomationSaveTransactionCategorizationActionType | FetchExpenseAutomationTransactionCategorizationActionType | FetchExpenseAutomationTransactionCategorizationViewActionType | FetchExpenseAutomationUpdateTransactionCategorizationEpicActionType | FetchExpenseTrendActionType | FetchExternalConnectionsActionType | FetchFileActionType | FetchFileListActionType | FetchForecastListActionType | FetchGlobalMerchantAutoCompleteActionType | FetchGlobalMerchantRecommendationActionType | FetchIncomeTrendActionType | FetchInternationalWireDynamicFormActionType | FetchIntlVerificationFormActionType | FetchInvoiceCountsActionType | FetchInvoiceDetailActionType | FetchInvoiceKPIsActionType | FetchInvoiceListActionType | FetchInvoiceListPageActionType | FetchIssueCardPageActionType | FetchMagicLinkBankNameByRoutingActionType | FetchMagicLinkBankNameBySwiftActionType | FetchMagicLinkBillActionType | FetchMagicLinkTenantActionType | FetchManagementActionType | FetchMerchantListActionType | FetchMonthClosePerformanceTrendActionType | FetchMonthEndCloseChecksActionType | FetchMoreBatchDetailsActionType | FetchMultipleBatchDetailsActionType | FetchMyProfileActionType | FetchMyProfileViewActionType | FetchNetBurnOrIncomeStoryCardActionType | FetchNetBurnOrIncomeWithForecastActionType | FetchNotificationSettingsActionType | FetchNotificationSettingsViewActionType | FetchNotificationUnreadCountActionType | FetchNotificationViewActionType | FetchOnboardingActionType | FetchOnboardingCompletedCompaniesActionType | FetchOnboardingCustomerSetupViewActionType | FetchOnboardingCustomerViewActionType | FetchOneTimeAccrualActionType | FetchOpExWithForecastActionType | FetchOwnerListActionType | FetchParentSubsidiaryManagementActionType | FetchPaymentAccountBalanceActionType | FetchPaymentAccountListActionType | FetchPaymentSourcesActionType | FetchPortfolioActionType | FetchPortfolioAllocationActionType | FetchPreviousBillsActionType | FetchProjectListActionType | FetchQBOConnectionPoolActionType | FetchRecommendationByEntityIdActionType | FetchRecommendationByEntityNameActionType | FetchRecommendationsAndUpdateMerchantRecommendationsActionType | FetchRecommendationsAndUpdateVendorRecommendationsActionType | FetchRecommendedBillExpenseActionType | FetchReferralsActionType | FetchRegisteredInterestsActionType | FetchReimbursementCardActionType | FetchReimbursementConfigActionType | FetchRemiAndInitializeLocalStoreActionType | FetchRemiApproversDetailsActionType | FetchRemiApproversListActionType | FetchRemiDetailActionType | FetchRemiListActionType | FetchRemiListPerTabActionType | FetchRemiSetupApproverViewActionType | FetchRemiSetupViewActionType | FetchRevenueWithForecastActionType | FetchReviewCompanyActionType | FetchReviewTransferDetailActionType | FetchRewardsPlanActionType | FetchScheduleAccruedDetailsActionType | FetchScheduleAccruedDetailsPageActionType | FetchScheduleDetailsActionType | FetchScheduleDetailsPageActionType | FetchScheduleListActionType | FetchSchedulesListActionType | FetchSkillsActionType | FetchSubscriptionActionType | FetchSubscriptionAddOnsActionType | FetchSubscriptionCouponsActionType | FetchSubscriptionCreateEstimateActionType | FetchSubscriptionDetailsActionType | FetchSubscriptionListActionType | FetchSubscriptionPlansActionType | FetchSubscriptionSummaryForTenantActionType | FetchSubscriptionUpdateEstimateActionType | FetchSubTasksActionType | FetchSuggestedQuestionsActionType | FetchTaskDetailActionType | FetchTaskDetailPageActionType | FetchTaskGroupTemplatesActionType | FetchTaskHistoryActionType | FetchTaskListActionType | FetchTaskListPageActionType | FetchTaskManagerMetricsActionType | FetchTasksCardActionType | FetchTransactionActivityLogActionType | FetchTransactionDetailActionType | FetchTransactionListByAccountActionType | FetchTransactionListByClassActionType | FetchTransactionListByEntityActionType | FetchTransactionListByProjectActionType | FetchTransactionsForEntityActionType | FetchTransactionsListByCategoryTypeActionType | FetchTransferAccountsActionType | FetchTreasuryDetailActionType | FetchTreasuryFundsActionType | FetchTreasuryHistoryActionType | FetchTreasurySetupViewActionType | FetchTreasuryStatementListActionType | FetchTreasuryTaxLetterListActionType | FetchTreasuryTransactionListActionType | FetchTrendForEntityActionType | FetchUserDetailActionType | FetchUserFinancialAccountActionType | FetchUserListByTypeActionType | FetchUserRoleConfigActionType | FetchVendor1099TypeListActionType | FetchVendorActionType | FetchVendorAndUpdateBillLocalDataActionType | FetchVendorByNameAndParseInvoiceActionType | FetchVendorDetailsActionType | FetchVendorFirstReviewAttachmentsActionType | FetchVendorFirstReviewViewActionType | FetchVendorGlobalReviewViewActionType | FetchVendorsActionType | FetchVendorsFiling1099ActionType | FetchVendorsFiling1099AllActionType | FetchVendorsFiling1099DownloadActionType | FetchVendorTabViewActionType | FetchVendorTypeListActionType | FetchZeniAccountListPageActionType | FetchZeniAccountsConfigActionType | FetchZeniAccountSetupViewActionType | FetchZeniAccStatePageActionType | FetchZeniUsersActionType | GetOnboardingEmailGroupActionType | GetOnboardingPlaidLinkTokenActionType | GetPaymentAccountsActionType | GetPlaidLinkTokenActionType | IgnoreActualMatchingSuggestionActionType | IgnoreExpenseAutomationJEScheduleActionType | ImproveUsingZeniGPTActionType | IncludeAccountInReconciliationActionType | InitialiseExpenseAutomationLocalDataForSelectedAccountIdActionType | InitializeAccountMappingViewActionType | InitializeAccountSettingsViewEpicActionType | InitializeBillPaySetupApproverViewUpdateDataActionType | InitializeBillToLocalStoreActionType | InitializeCardUserOnboardingLocalDataActionType | InitializeCompanyHealthMetricViewLocalDataEpicActionType | InitializeEditPersonActionType | InitializeExpenseAutomationJeScheduleLocalDataActionType | InitializeInternationalWireLocalDataActionType | InitializeIntlVerificationFormEpicActionType | InitializeMyProfileLocalDataActionType | InitializeNewScheduleActionType | InitializeOnboardingCustomerViewUpdateDataActionType | InitializeRemiSetupApproverViewUpdateDataActionType | InitializeRemiToLocalStoreActionType | InitializeScheduleAccruedDetailLocalDataActionType | InitializeScheduleDetailLocalDataActionType | InitializeSubscriptionLocalDataActionType | InitializeTaskToLocalStoreActionType | InitializeTransactionDetailLocalDataActionType | InitializeVendorAddressActionType | InitiateChargeCardRepaymentActionType | InitiateReportsClassViewRefetchingActionType | InitiateReportsProjectViewRefetchingActionType | InsightsCardActionType | InvitePeopleActionType | InviteZeniPeopleActionType | InvoiceDetailPageActionType | InvoicingAuditViewActionType | InvoicingCatalogItemDetailFetchActionType | InvoicingCatalogItemDetailPageActionType | InvoicingCatalogItemFormDraftSeedActionType | InvoicingCatalogListViewActionType | InvoicingCatalogPlanActionActionType | InvoicingCatalogProductActionActionType | InvoicingConfigViewActionType | InvoicingCouponDetailFetchActionType | InvoicingCouponDetailPageActionType | InvoicingCouponFormDraftSeedActionType | InvoicingCouponViewActionType | InvoicingCreditNoteDetailViewActionType | InvoicingCreditNoteListViewActionType | InvoicingCustomerDetailPageActionType | InvoicingCustomerFormDraftSeedActionType | InvoicingCustomerListViewActionType | InvoicingCustomerPaymentMethodActionType | InvoicingCustomerRecordViewActionType | InvoicingDataImportViewActionType | InvoicingDiscountActionActionType | InvoicingDunningActionActionType | InvoicingDunningCaseDetailPageActionType | InvoicingDunningCaseDetailViewActionType | InvoicingDunningCaseListViewActionType | InvoicingInvoiceActionActionType | InvoicingOverviewActionType | InvoicingPaymentActionActionType | InvoicingPaymentLinkEmailPreviewActionType | InvoicingPaymentLinkEmailPreviewPageActionType | InvoicingPromotionalCreditActionActionType | InvoicingQboViewActionType | InvoicingSettingsViewActionType | InvoicingSubscriptionActionActionType | InvoicingSubscriptionDetailFetchActionType | InvoicingSubscriptionDetailPageActionType | InvoicingSubscriptionFormDraftSeedActionType | InvoicingSubscriptionFormPageActionType | InvoicingSubscriptionListViewActionType | InvoicingTransactionDetailViewActionType | InvoicingTransactionListViewActionType | IssueChargeCardActionType | LockChargeCardActionType | LockChargeCardsActionType | MarkAsCompleteScheduleDetailActionType | MarkTransactionAsNotMiscategorizedActionType | MatchAndReverseAccrualsActionType | NetBurnOrIncomeActionType | NetBurnOrIncomeClassesViewActionType | NetBurnOrIncomeForTimeframeActionType | NetBurnOrIncomeForTimeframeClassesViewActionType | NetBurnOrIncomeForTimeframeProjectViewActionType | NetBurnOrIncomeProjectViewActionType | NotifyMeForFeatureActionType | OneTimeAccrualActionsActionType | OpExActionType | OpExByVendorReportActionType | OpExByVendorReportForTimeframeActionType | OpExByVendorReportSummaryActionType | OpExClassesViewActionType | OpExForTimeframeClassesViewActionType | OpExForTimeframeProjectViewActionType | OpExForTimeframeViewActionType | OpExProjectViewActionType | ParallelFetchAccountTransactionListActionType | ParallelFetchClassTransactionListActionType | ParallelFetchEntityTransactionListActionType | ParallelFetchProjectTransactionListActionType | ParallelFetchTransactionListByCategoryTypeActionType | ParseCombinedStatementActionType | ParseInvoiceToBillActionType | ParseReceiptsToRemiActionType | ParseStatementActionType | ParseUploadedKybDocumentActionType | ParseUploadedKycDocumentActionType | PeopleActionType | PeoplePageActionType | PeopleSaveUpdatesActionType | PolicyDocumentExtractionToRecommendationBridgeActionType | PolicyRecommendationFromUploadActionType | PrefetchOtherJeSchedulesTabActionType | ProfitAndLossActionType | ProfitAndLossClassesViewActionType | ProfitAndLossForTimeframeActionType | ProfitAndLossForTimeframeClassesViewActionType | ProfitAndLossForTimeframeProjectViewActionType | ProfitAndLossProjectViewActionType | PushToastNotificationActionType | RecommendationForAccountSettingsActionType | RecommendationForAccountTypeActionType | RecordPaymentActionType | RefetchCompletedTransactionsOnBulkUploadSortActionType | RefreshBatchDetailsForBatchIdActionType | RefreshExpenseAutomationCurrentTabActionType | RefreshIntegrationsDataActionType | RefreshOpExByVendorReportActionType | RejectVendorGlobalReviewActionType | ReorderBillPayApprovalRulesActionType | ReorderRemiApprovalRulesActionType | ReparseStatementActionType | ReportsResyncActionType | ResendCardInviteActionType | ResendInviteActionType | ResendOtpActionType | ResendReferralInviteActionType | ResendVerifyDeviceOTPActionType | ResetKycKybActionType | ResetTransactionVendorLocalDataActionType | ResetVendorDetailLocalDataActionType | RestoreAutomatchingActionType | ResumeEnableAccountingProjectsActionType | RetryBankAccountConnectionActionType | RetryBankAccountConnectionForOnboardingActionType | RetryExpenseAutomationJEScheduleActionType | RetryOrRefundBillActionType | RevenueActionType | RevenueClassesViewActionType | RevenueForTimeframeClassesViewActionType | RevenueForTimeframeProjectViewActionType | RevenueForTimeframeViewActionType | RevenueProjectViewActionType | RevertJeScheduleActionType | ReviewDraftRemisBulkActionActionTye | ReviewExpenseAutomationFluxAnalysisActionType | RevokeCardInviteActionType | RevokeChargeCardsInviteActionType | SaveAccountMappingViewActionType | SaveAccountSettingsViewEpicActionType | SaveAddressActionType | SaveBillDetailActionType | SaveBillPaySetupApproverViewUpdatesActionType | SaveCannedResponseActionType | saveCardOnboardingUserDetailsActionType | SaveCompanyBillingAddressActionType | SaveCompanyHealthMetricByIdEpicActionType | SaveCompanyMonthEndReportActionType | SaveCompanyPassportDetailsActionType | SaveCreditAgentMacroActionType | SaveExpenseAutomationReconciliationDetailActionType | SaveExternalConnectionActionType | SaveMagicLinkBankAccountActionType | SaveNewScheduleActionType | SaveNotificationPreferencesActionType | SaveNotificationSettingsEpicActionType | SaveOnboardingCustomerCompletedStatusActionType | SaveOnboardingCustomerNotesActionType | SaveOnboardingCustomerViewUpdatesActionType | SaveRealTimeApprovalActionType | SaveReasonForAuditRuleActionType | SaveReconciliationReviewActionType | SaveRemiDetailActionType | SaveRemiSetupApproverViewUpdatesActionType | SaveScheduleAccruedDetailsActionType | SaveScheduleDetailsActionType | SaveSubscriptionNotesUpdatesActionType | SaveSubscriptionUpdatesActionType | SaveTaskDetailActionType | SaveTranactionVendorActionType | SaveTransactionDetailActionType | SaveVendorActionType | SaveVendorDetailsViewActionType | SaveVendorFirstReviewViewActionType | ScheduleTenantCreditScoreCronActionType | SearchMatchAccrualsActionType | SearchMatchTransactionsActionType | SearchTransactionsForManualMatchActionType | SearchTransactionsForNewScheduleActionType | SeedAiCardCreationFormDraftActionType | SeedAiCardPolicyFormDraftActionType | SendCompanyMonthEndReportActionType | SendEmailMagicLinkToUserActionType | SendOnboardingCustomerViewInviteActionType | SendOtpActionType | SendReferralInviteActionType | SessionHeartbeatActionType | SignInActionType | SignOutActionType | SnoozeTaskActionType | StatementCloseDayActionType | StopSubmitActionType | StopSubmitQuestionActionType | SubmitDraftBillsBulkActionActionType | SubmitDraftRemisBulkActionActionType | SubmitExpressPayActionType | SubmitFeedbackActionType | SubmitIntlVerificationActionType | SubmitQuestionActionType | SubmitRecommendationFeedbackActionType | SwitchExpenseAutomationJESchedulesTabActionType | SyncInvoicingSubscriptionCouponsActionType | SyncTabsAfterAutomatchActionType | ToggleReportUIOptionForecastModeActionType | TopExActionType | TransferMoneyActionType | TreasuryTransferMoneyActionType | TriggerAiAccountantJobActionType | TriggerReviewTabRefetchActionType | UndoReversalAccrualsActionType | UnlinkPaymentAccountActionType | UnlockChargeCardActionType | UnlockChargeCardsActionType | UnsnoozeTaskActionType | UpdateAccountingClassesEnabledActionType | UpdateAccruedJESchedulesActionType | UpdateAddressActionType | UpdateAmountsInScheduleAccruedDetailActionType | UpdateAmountsInScheduleDetailActionType | UpdateAutoTransferRuleActionType | UpdateBusinessVerificationDetailsActionType | UpdateCapitalizationAccountThresholdActionType | UpdateCardPolicyActionType | UpdateCardProfileActionType | UpdateChargeCardDetailActionType | UpdateChargeCardLimitActionType | UpdateChargeCardNameActionType | UpdateChargeCardsLimitActionType | UpdateCombinedStatementInfoActionType | UpdateCompanyDetailsActionType | UpdateCompanyOfficerActionType | UpdateCompanyPassportLocalStoreDataActionType | UpdateCompanyProductServicesActionType | UpdateCompanyQboRealmIdActionType | UpdateCompanyTaskManagerViewFiltersActionType | UpdateDashboardLayoutActionType | UpdateDebitCardPinAttemptActionType | UpdateDepositAccountActionType | UpdateDynamicFormActionType | UpdateExpenseAutomationReconciliationBalanceLocalDataActionType | UpdateFileNameActionType | UpdateFilesMetadataActionType | UpdateJESchedulesActionType | UpdateMappedCashAccountActionType | UpdateMileageDetailsActionType | UpdateMyProfileActionType | UpdateNetBurnOrIncomeStoryCardSettingsActionType | UpdateNotificationViewAllNotificationsStatusActionType | UpdateNotificationViewNotificationStatusActionType | UpdateOnboardingCustomerViewActionType | UpdateOnboardingCustomerViewCompleteStatusActionType | UpdateOnboardingCustomerViewDashboardLoadedActionType | UpdateOnboardingCustomerViewLocalStoreDataActionType | UpdateOnboardingPaymentAccountLoginStatusActionType | UpdateOnboardingPaymentAccountStatusActionType | UpdatePaymentAccountActionType | UpdatePaymentAccountLoginStatusActionType | UpdatePaymentAccountStatusActionType | UpdatePhysicalChargeCardAttemptActionType | UpdatePortfolioAllocationActionType | UpdatePrimaryContactActionType | UpdatePrimaryFundingAccountActionType | UpdateQBOConnectionPoolExternalConnectionActionType | UpdateReferViewedActionType | UpdateRemiSetupViewLocalStoreDataActionType | UpdateReportUIOptionCOABalancesRangeActionType | UpdateReportUIOptionIsCompareModeActionType | UpdateReportUIOptionIsCompareModeOnActionType | UpdateReportUIOptionThisPeriodActionType | UpdateReportUIOptionTimeFrameActionType | UpdateSectionAccountsViewActionType | UpdateSectionClassesViewV2ActionType | UpdateSectionProjectViewActionType | UpdateSelectedVendorForCreateFlowActionType | UpdateSetupViewLocalStoreDataActionType | UpdateStatementInfoActionType | UpdateTaskFromListViewActionType | UpdateTaskGroupNameActionType | UpdateTransactionDetailActionType | UpdateTransactionOnUploadSuccessActionType | UpdateVendorContactActionType | UploadAccountStatementActionType | UploadMissingReceiptSuccessEpicActionType | UploadTransactionReceiptSuccessEpicActionType | ValidateBillsBulkActionActionType | VendorFiling1099UploadDetailsSaveActionType | VendorsTabFetchVendorActionType | VendorsTabFetchVendorDetailPageViewActionType | VendorsTabFetchVendorDetailsActionType | VendorsTabResetVendorDetailLocalDataActionType | VendorsTabSaveVendorActionType | VerifyDeviceWithTwoFAActionType | VerifyOtpActionType | VerifyUserActionType | WatchBulkUploadBatchStatusActionType | WiseRedirectActionType;
|
|
708
|
+
export type RootActionType = AcceptBillPayTermsActionType | AcceptBillPayUpdatedTermsActionType | AcceptChargeCardTermsActionType | AcceptEmployeeRemiTermsActionType | AcceptMasterTOSEpicActionType | AcceptRemiTermsActionType | AcceptTreasuryTermsActionType | AcceptZeniAccountTermsActionType | AcknowledgeOnboardingAiActivationViewedActionType | AcknowledgeOnboardingAiFinanceTeamActionType | AddCardPaymentSourceActionType | ApplyBillRecommendationsToLocalStoreActionType | ApplyExtractedPolicyToDraftActionType | ApproveOAuthConsentActionType | ApproveOrRejectBillActionType | ApproveOrRejectBillsBulkActionActionType | ApproveOrRejectRemiActionType | ApproveOrRejectRemisBulkActionActionType | ApproveVendorGlobalReviewActionType | ArchiveCardPolicyActionType | ArchiveTaskActionType | BackgroundRefetchReviewTabActionType | BalanceSheetActionType | BalanceSheetClassesViewActionType | BalanceSheetForTimeframeActionType | BalanceSheetForTimeframeClassesViewActionType | BalanceSheetForTimeframeProjectViewActionType | BalanceSheetProjectViewActionType | BulkUpdateTasksListActionType | BulkUploadMatchResultToastActionType | BulkUploadReceiptsActionType | CancelAiAccountantOnboardingActionType | CancelAndDeleteBillActionType | CancelAndDeleteRemiActionType | CancelOrDeleteBillsBulkActionActionType | CancelOrDeleteRemisBulkActionActionType | CancelScheduleAccruedJournalEntryActionType | CardBalanceActionType | CashBalanceActionType | CashFlowActionType | CashFlowClassesViewActionType | CashFlowForTimeframeActionType | CashFlowForTimeframeClassesViewActionType | CashFlowForTimeframeProjectViewActionType | CashFlowProjectViewActionType | CashInCashOutActionType | CashPositionActionType | ChangeZeniPersonRolesActionType | CheckDepositActionType | CloseChargeCardActionType | CloseChargeCardsActionType | CombinedStatementActionType | CompanyManagementSavePendingUpdatesActionType | CompanyManagementSaveUpdatesActionType | ConfirmBulkUploadMatchActionType | ConfirmCardSetupIntentActionType | ConfirmStatementMappingActionType | CreateAddressActionType | CreateAutoTransferRuleActionType | CreateBankAccountActionType | CreateCardPolicyTemplateActionType | CreateCardSetupIntentActionType | CreateCheckingAccountActionType | CreateCompanyAddressActionType | CreateCompanyOfficersActionType | CreateCompanyUserAddressActionType | CreateGlobalMerchantActionType | CreateInternationalBankAccountActionType | CreateInvoiceActionType | CreateNewSchedulesAccruedActionType | CreateNewSchedulesActionType | CreateNewTaskGroupActionType | CreateOneTimeAccrualActionType | CreatePaymentInstrumentActionType | CreateSessionActionType | CreateSessionAndSubmitActionType | CreateSubTaskActionType | CreateTagActionType | CreateTaskFromTaskGroupTemplateActionType | CreateTransferEntryActionType | CreateUserBankAccountActionType | CurrencyConversionActionType | DeleteAccountStatementActionType | DeleteAutoTransferRuleActionType | DeleteBankAccountActionType | DeleteBillActionType | DeleteBillPayApprovalRuleActionType | DeleteCannedResponseActionType | DeleteChatSessionActionType | DeleteCombinedStatementActionType | DeleteFileActionType | DeleteFileListActionType | DeleteInternationalBankAccountActionType | DeletePaymentInstrumentActionType | DeletePersonActionType | DeleteRemiActionType | DeleteRemiApprovalRuleActionType | DeleteScheduleAccruedDetailActionType | DeleteScheduleDetailActionType | DeleteTagActionType | DeleteTaskActionType | DeleteTaskGroupActionType | DeleteTransactionAttachmentActionType | DeleteUserBankAccountActionType | DepositAccountTransactionListActionType | DisableAccountingProjectsActionType | DismissCapitalizationOnboardingActionType | DoMagicLinkSignInActionType | DownloadAccountingProviderAttachmentActionType | DragNDropTasksActionType | EditInvoicingCatalogItemDetailViewActionType | EditInvoicingCouponDetailViewActionType | EditInvoicingCustomerDetailViewActionType | EditInvoicingSubscriptionDetailViewActionType | EnableAccountingProjectsActionType | EnableChargeCardAutoPayActionType | EnableSetupActionType | EstablishOnboardingPlaidConnectionActionType | EstablishPlaidConnectionActionType | ExcludeAccountFromReconciliationActionType | ExpressInterestChargeCardActionType | ExpressPayActionType | ExtractPolicyDocumentActionType | FetchAccountHistoryActionType | FetchAccountListActionType | FetchAccountListForAccountTypesActionType | FetchAccountSettingsListForAccountTypesActionType | FetchAccruedScheduleListActionType | FetchActiveTenantActionType | FetchAddressActionType | FetchAggregatedReportActionType | FetchAiAccountantCustomersActionType | FetchAiAccountantJobsActionType | FetchAiAgentsActivationStatusActionType | FetchAllCockpitViewsActionType | FetchAllExpenseAutomationTabsActionType | FetchAllPeopleRequiredActionType | FetchAllTagsActionType | FetchAllTaskGroupsActionType | FetchAllTenantsActionType | FetchApAgingActionType | FetchApAgingDetailActionType | FetchArAgingActionType | FetchArAgingDetailActionType | FetchAuditReportGroupViewActionType | FetchAuditRuleGroupViewActionType | FetchAutoTransferReviewDetailActionType | FetchAutoTransferRuleHistoryActionType | FetchAutoTransferRulesActionType | FetchBankAccountsListActionType | FetchBankConnectionsViewActionType | FetchBankCountryNameByIbanActionType | FetchBankNameByRoutingActionType | FetchBankNameBySwiftActionType | FetchBillAndInitializeLocalStoreActionType | FetchBillDetailActionType | FetchBillingAccountsListActionType | FetchBillListActionType | FetchBillListPerTabActionType | FetchBillPayApproversDetailsActionType | FetchBillPayApproversListActionType | FetchBillPayCardActionType | FetchBillPayConfigActionType | FetchBillPaySetupApproverViewActionType | FetchBillPaySetupViewActionType | FetchBillRecommendationsActionType | FetchBulkUploadBatchDetailsActionType | FetchBulkUploadBatchesActionType | FetchCannedResponsesActionType | FetchCardPolicyDetailActionType | FetchCardPolicyListActionType | FetchCardPolicyMccCategoriesActionType | FetchCardPolicyVendorOptionsActionType | FetchCardProfilesActionType | FetchCashbackDetailActionType | FetchChargeCardConfigActionType | FetchChargeCardDetailActionType | FetchChargeCardDetailPageActionType | FetchChargeCardListActionType | FetchChargeCardListPageActionType | FetchChargeCardPaymentHistoryActionType | FetchChargeCardPaymentPageActionType | FetchChargeCardRepaymentDetailActionType | FetchChargeCardSetupViewActionType | FetchChargeCardsRecurringExpensesActionType | FetchChargeCardStatementListActionType | FetchChargeCardTransactionAttachmentsActionType | FetchChargeCardTransactionListActionType | FetchChargeCardTransactionStatisticsActionType | FetchChatHistoryActionType | FetchChatSessionsForUserActionType | FetchClassListActionType | FetchCockpitContextActionType | FetchCollaborationAuthTokenActionType | FetchCompanyBillingAddressActionType | FetchCompanyConfigActionType | FetchCompanyHealthMetricConfigViewEpicActionType | FetchCompanyHealthMetricViewEpicActionType | FetchCompanyManagementActionType | FetchCompanyMetaDataActionType | FetchCompanyMonthEndReportHistoricDataActionType | FetchCompanyMonthEndReportHistoricDatesActionType | FetchCompanyMonthEndReportTemplatesActionType | FetchCompanyMonthEndReportViewActionType | FetchCompanyOnboardingViewActionType | FetchCompanyPassportViewActionType | FetchCompanyPortfolioActionType | FetchCompanyTaskManagerViewActionType | FetchCompletedTransactionsActionType | FetchCreateInvoiceFormPageActionType | FetchCreditAccountActionType | FetchCreditAccountRepaymentActionType | FetchCreditAgentMacroActionType | FetchCurrencyConversionValueActionType | FetchDashboardActionType | FetchDashboardLayoutActionType | FetchDebitCardSummaryActionType | FetchDepositAccountActionType | FetchDepositAccountDetailActionType | FetchDepositAccountLimitActionType | FetchDepositAccountListActionType | FetchDepositAccountListForCardsActionType | FetchDepositAccStatementListActionType | FetchDownloadSchedulesActionType | FetchDuplicateBillActionType | FetchDuplicateReimbursementEpicActionType | FetchEditBillDetailPageActionType | FetchEditRemiDetailPageActionType | FetchEligibleActionsForBillActionType | FetchEntityAutoCompleteActionType | FetchEntityHistoryActionType | FetchEntityRecommendationsByTransactionIdActionType | FetchEntityRecommendationsForLineUpdateActionType | FetchExcludedResourcesActionType | FetchExpenseAutomationActualMatchingActionType | FetchExpenseAutomationActualMatchingMatchActionType | FetchExpenseAutomationActualMatchingPageActionType | FetchExpenseAutomationFailedJePostingsActionType | FetchExpenseAutomationFluxAnalysisActionType | FetchExpenseAutomationInitializeTransactionCategorizationViewLocalDataActionType | FetchExpenseAutomationJEScheduleActionType | FetchExpenseAutomationJESchedulePageActionType | FetchExpenseAutomationMarkTransactionAsNotMiscategorizedActionType | FetchExpenseAutomationMissingReceiptsActionType | FetchExpenseAutomationReconciliationsViewActionType | FetchExpenseAutomationSaveTransactionCategorizationActionType | FetchExpenseAutomationTransactionCategorizationActionType | FetchExpenseAutomationTransactionCategorizationViewActionType | FetchExpenseAutomationUpdateTransactionCategorizationEpicActionType | FetchExpenseTrendActionType | FetchExternalConnectionsActionType | FetchFileActionType | FetchFileListActionType | FetchForecastListActionType | FetchGlobalMerchantAutoCompleteActionType | FetchGlobalMerchantRecommendationActionType | FetchIncomeTrendActionType | FetchInternationalWireDynamicFormActionType | FetchIntlVerificationFormActionType | FetchInvoiceCountsActionType | FetchInvoiceDetailActionType | FetchInvoiceKPIsActionType | FetchInvoiceListActionType | FetchInvoiceListPageActionType | FetchIssueCardPageActionType | FetchMagicLinkBankNameByRoutingActionType | FetchMagicLinkBankNameBySwiftActionType | FetchMagicLinkBillActionType | FetchMagicLinkTenantActionType | FetchManagementActionType | FetchMerchantListActionType | FetchMonthClosePerformanceTrendActionType | FetchMonthEndCloseChecksActionType | FetchMoreBatchDetailsActionType | FetchMultipleBatchDetailsActionType | FetchMyProfileActionType | FetchMyProfileViewActionType | FetchNetBurnOrIncomeStoryCardActionType | FetchNetBurnOrIncomeWithForecastActionType | FetchNotificationSettingsActionType | FetchNotificationSettingsViewActionType | FetchNotificationUnreadCountActionType | FetchNotificationViewActionType | FetchOnboardingActionType | FetchOnboardingCompletedCompaniesActionType | FetchOnboardingCustomerSetupViewActionType | FetchOnboardingCustomerViewActionType | FetchOneTimeAccrualActionType | FetchOpExWithForecastActionType | FetchOwnerListActionType | FetchParentSubsidiaryManagementActionType | FetchPaymentAccountBalanceActionType | FetchPaymentAccountListActionType | FetchPaymentSourcesActionType | FetchPortfolioActionType | FetchPortfolioAllocationActionType | FetchPreviousBillsActionType | FetchProjectListActionType | FetchQBOConnectionPoolActionType | FetchRecommendationByEntityIdActionType | FetchRecommendationByEntityNameActionType | FetchRecommendationsAndUpdateMerchantRecommendationsActionType | FetchRecommendationsAndUpdateVendorRecommendationsActionType | FetchRecommendedBillExpenseActionType | FetchReferralsActionType | FetchRegisteredInterestsActionType | FetchReimbursementCardActionType | FetchReimbursementConfigActionType | FetchRemiAndInitializeLocalStoreActionType | FetchRemiApproversDetailsActionType | FetchRemiApproversListActionType | FetchRemiDetailActionType | FetchRemiListActionType | FetchRemiListPerTabActionType | FetchRemiSetupApproverViewActionType | FetchRemiSetupViewActionType | FetchRevenueWithForecastActionType | FetchReviewCompanyActionType | FetchReviewTransferDetailActionType | FetchRewardsPlanActionType | FetchScheduleAccruedDetailsActionType | FetchScheduleAccruedDetailsPageActionType | FetchScheduleDetailsActionType | FetchScheduleDetailsPageActionType | FetchScheduleListActionType | FetchSchedulesListActionType | FetchSkillsActionType | FetchSubscriptionActionType | FetchSubscriptionAddOnsActionType | FetchSubscriptionCouponsActionType | FetchSubscriptionCreateEstimateActionType | FetchSubscriptionDetailsActionType | FetchSubscriptionListActionType | FetchSubscriptionPlansActionType | FetchSubscriptionSummaryForTenantActionType | FetchSubscriptionUpdateEstimateActionType | FetchSubTasksActionType | FetchSuggestedQuestionsActionType | FetchTaskDetailActionType | FetchTaskDetailPageActionType | FetchTaskGroupTemplatesActionType | FetchTaskHistoryActionType | FetchTaskListActionType | FetchTaskListPageActionType | FetchTaskManagerMetricsActionType | FetchTasksCardActionType | FetchTransactionActivityLogActionType | FetchTransactionDetailActionType | FetchTransactionListByAccountActionType | FetchTransactionListByClassActionType | FetchTransactionListByEntityActionType | FetchTransactionListByProjectActionType | FetchTransactionsForEntityActionType | FetchTransactionsListByCategoryTypeActionType | FetchTransferAccountsActionType | FetchTreasuryDetailActionType | FetchTreasuryFundsActionType | FetchTreasuryHistoryActionType | FetchTreasurySetupViewActionType | FetchTreasuryStatementListActionType | FetchTreasuryTaxLetterListActionType | FetchTreasuryTransactionListActionType | FetchTrendForEntityActionType | FetchUserDetailActionType | FetchUserFinancialAccountActionType | FetchUserListByTypeActionType | FetchUserRoleConfigActionType | FetchVendor1099TypeListActionType | FetchVendorActionType | FetchVendorAndUpdateBillLocalDataActionType | FetchVendorByNameAndParseInvoiceActionType | FetchVendorDetailsActionType | FetchVendorFirstReviewAttachmentsActionType | FetchVendorFirstReviewViewActionType | FetchVendorGlobalReviewViewActionType | FetchVendorsActionType | FetchVendorsFiling1099ActionType | FetchVendorsFiling1099AllActionType | FetchVendorsFiling1099DownloadActionType | FetchVendorTabViewActionType | FetchVendorTypeListActionType | FetchZeniAccountListPageActionType | FetchZeniAccountsConfigActionType | FetchZeniAccountSetupViewActionType | FetchZeniAccStatePageActionType | FetchZeniUsersActionType | GetOnboardingEmailGroupActionType | GetOnboardingPlaidLinkTokenActionType | GetPaymentAccountsActionType | GetPlaidLinkTokenActionType | IgnoreActualMatchingSuggestionActionType | IgnoreExpenseAutomationJEScheduleActionType | ImproveUsingZeniGPTActionType | IncludeAccountInReconciliationActionType | InitialiseExpenseAutomationLocalDataForSelectedAccountIdActionType | InitializeAccountMappingViewActionType | InitializeAccountSettingsViewEpicActionType | InitializeBillPaySetupApproverViewUpdateDataActionType | InitializeBillToLocalStoreActionType | InitializeCardUserOnboardingLocalDataActionType | InitializeCompanyHealthMetricViewLocalDataEpicActionType | InitializeEditPersonActionType | InitializeExpenseAutomationJeScheduleLocalDataActionType | InitializeInternationalWireLocalDataActionType | InitializeIntlVerificationFormEpicActionType | InitializeMyProfileLocalDataActionType | InitializeNewScheduleActionType | InitializeOnboardingCustomerViewUpdateDataActionType | InitializeRemiSetupApproverViewUpdateDataActionType | InitializeRemiToLocalStoreActionType | InitializeScheduleAccruedDetailLocalDataActionType | InitializeScheduleDetailLocalDataActionType | InitializeSubscriptionLocalDataActionType | InitializeTaskToLocalStoreActionType | InitializeTransactionDetailLocalDataActionType | InitializeVendorAddressActionType | InitiateChargeCardRepaymentActionType | InitiateReportsClassViewRefetchingActionType | InitiateReportsProjectViewRefetchingActionType | InsightsCardActionType | InvitePeopleActionType | InviteZeniPeopleActionType | InvoiceDetailPageActionType | InvoicingAuditViewActionType | InvoicingCatalogItemDetailFetchActionType | InvoicingCatalogItemDetailPageActionType | InvoicingCatalogItemFormDraftSeedActionType | InvoicingCatalogListViewActionType | InvoicingCatalogPlanActionActionType | InvoicingCatalogProductActionActionType | InvoicingConfigViewActionType | InvoicingCouponDetailFetchActionType | InvoicingCouponDetailPageActionType | InvoicingCouponFormDraftSeedActionType | InvoicingCouponViewActionType | InvoicingCreditNoteDetailViewActionType | InvoicingCreditNoteListViewActionType | InvoicingCustomerDetailPageActionType | InvoicingCustomerFormDraftSeedActionType | InvoicingCustomerListViewActionType | InvoicingCustomerPaymentMethodActionType | InvoicingCustomerRecordViewActionType | InvoicingDataImportViewActionType | InvoicingDiscountActionActionType | InvoicingDunningActionActionType | InvoicingDunningCaseDetailPageActionType | InvoicingDunningCaseDetailViewActionType | InvoicingDunningCaseListViewActionType | InvoicingInvoiceActionActionType | InvoicingOverviewActionType | InvoicingPaymentActionActionType | InvoicingPaymentLinkEmailPreviewActionType | InvoicingPaymentLinkEmailPreviewPageActionType | InvoicingPromotionalCreditActionActionType | InvoicingQboViewActionType | InvoicingSettingsViewActionType | InvoicingSubscriptionActionActionType | InvoicingSubscriptionDetailFetchActionType | InvoicingSubscriptionDetailPageActionType | InvoicingSubscriptionEstimateActionType | InvoicingSubscriptionFormDraftSeedActionType | InvoicingSubscriptionFormPageActionType | InvoicingSubscriptionListViewActionType | InvoicingTransactionDetailViewActionType | InvoicingTransactionListViewActionType | IssueChargeCardActionType | LockChargeCardActionType | LockChargeCardsActionType | MarkAsCompleteScheduleDetailActionType | MarkTransactionAsNotMiscategorizedActionType | MatchAndReverseAccrualsActionType | NetBurnOrIncomeActionType | NetBurnOrIncomeClassesViewActionType | NetBurnOrIncomeForTimeframeActionType | NetBurnOrIncomeForTimeframeClassesViewActionType | NetBurnOrIncomeForTimeframeProjectViewActionType | NetBurnOrIncomeProjectViewActionType | NotifyMeForFeatureActionType | OneTimeAccrualActionsActionType | OpExActionType | OpExByVendorReportActionType | OpExByVendorReportForTimeframeActionType | OpExByVendorReportSummaryActionType | OpExClassesViewActionType | OpExForTimeframeClassesViewActionType | OpExForTimeframeProjectViewActionType | OpExForTimeframeViewActionType | OpExProjectViewActionType | ParallelFetchAccountTransactionListActionType | ParallelFetchClassTransactionListActionType | ParallelFetchEntityTransactionListActionType | ParallelFetchProjectTransactionListActionType | ParallelFetchTransactionListByCategoryTypeActionType | ParseCombinedStatementActionType | ParseInvoiceToBillActionType | ParseReceiptsToRemiActionType | ParseStatementActionType | ParseUploadedKybDocumentActionType | ParseUploadedKycDocumentActionType | PeopleActionType | PeoplePageActionType | PeopleSaveUpdatesActionType | PolicyDocumentExtractionToRecommendationBridgeActionType | PolicyRecommendationFromUploadActionType | PrefetchOtherJeSchedulesTabActionType | ProfitAndLossActionType | ProfitAndLossClassesViewActionType | ProfitAndLossForTimeframeActionType | ProfitAndLossForTimeframeClassesViewActionType | ProfitAndLossForTimeframeProjectViewActionType | ProfitAndLossProjectViewActionType | PushToastNotificationActionType | RecommendationForAccountSettingsActionType | RecommendationForAccountTypeActionType | RecordPaymentActionType | RefetchCompletedTransactionsOnBulkUploadSortActionType | RefreshBatchDetailsForBatchIdActionType | RefreshExpenseAutomationCurrentTabActionType | RefreshIntegrationsDataActionType | RefreshOpExByVendorReportActionType | RejectVendorGlobalReviewActionType | ReorderBillPayApprovalRulesActionType | ReorderRemiApprovalRulesActionType | ReparseStatementActionType | ReportsResyncActionType | ResendCardInviteActionType | ResendInviteActionType | ResendOtpActionType | ResendReferralInviteActionType | ResendVerifyDeviceOTPActionType | ResetKycKybActionType | ResetTransactionVendorLocalDataActionType | ResetVendorDetailLocalDataActionType | RestoreAutomatchingActionType | ResumeEnableAccountingProjectsActionType | RetryBankAccountConnectionActionType | RetryBankAccountConnectionForOnboardingActionType | RetryExpenseAutomationJEScheduleActionType | RetryOrRefundBillActionType | RevenueActionType | RevenueClassesViewActionType | RevenueForTimeframeClassesViewActionType | RevenueForTimeframeProjectViewActionType | RevenueForTimeframeViewActionType | RevenueProjectViewActionType | RevertJeScheduleActionType | ReviewDraftRemisBulkActionActionTye | ReviewExpenseAutomationFluxAnalysisActionType | RevokeCardInviteActionType | RevokeChargeCardsInviteActionType | SaveAccountMappingViewActionType | SaveAccountSettingsViewEpicActionType | SaveAddressActionType | SaveBillDetailActionType | SaveBillPaySetupApproverViewUpdatesActionType | SaveCannedResponseActionType | saveCardOnboardingUserDetailsActionType | SaveCompanyBillingAddressActionType | SaveCompanyHealthMetricByIdEpicActionType | SaveCompanyMonthEndReportActionType | SaveCompanyPassportDetailsActionType | SaveCreditAgentMacroActionType | SaveExpenseAutomationReconciliationDetailActionType | SaveExternalConnectionActionType | SaveMagicLinkBankAccountActionType | SaveNewScheduleActionType | SaveNotificationPreferencesActionType | SaveNotificationSettingsEpicActionType | SaveOnboardingCustomerCompletedStatusActionType | SaveOnboardingCustomerNotesActionType | SaveOnboardingCustomerViewUpdatesActionType | SaveRealTimeApprovalActionType | SaveReasonForAuditRuleActionType | SaveReconciliationReviewActionType | SaveRemiDetailActionType | SaveRemiSetupApproverViewUpdatesActionType | SaveScheduleAccruedDetailsActionType | SaveScheduleDetailsActionType | SaveSubscriptionNotesUpdatesActionType | SaveSubscriptionUpdatesActionType | SaveTaskDetailActionType | SaveTranactionVendorActionType | SaveTransactionDetailActionType | SaveVendorActionType | SaveVendorDetailsViewActionType | SaveVendorFirstReviewViewActionType | ScheduleTenantCreditScoreCronActionType | SearchMatchAccrualsActionType | SearchMatchTransactionsActionType | SearchTransactionsForManualMatchActionType | SearchTransactionsForNewScheduleActionType | SeedAiCardCreationFormDraftActionType | SeedAiCardPolicyFormDraftActionType | SendCompanyMonthEndReportActionType | SendEmailMagicLinkToUserActionType | SendOnboardingCustomerViewInviteActionType | SendOtpActionType | SendReferralInviteActionType | SessionHeartbeatActionType | SignInActionType | SignOutActionType | SnoozeTaskActionType | StatementCloseDayActionType | StopSubmitActionType | StopSubmitQuestionActionType | SubmitDraftBillsBulkActionActionType | SubmitDraftRemisBulkActionActionType | SubmitExpressPayActionType | SubmitFeedbackActionType | SubmitIntlVerificationActionType | SubmitQuestionActionType | SubmitRecommendationFeedbackActionType | SwitchExpenseAutomationJESchedulesTabActionType | SyncInvoicingSubscriptionCouponsActionType | SyncTabsAfterAutomatchActionType | ToggleReportUIOptionForecastModeActionType | TopExActionType | TransferMoneyActionType | TreasuryTransferMoneyActionType | TriggerAiAccountantJobActionType | TriggerReviewTabRefetchActionType | UndoReversalAccrualsActionType | UnlinkPaymentAccountActionType | UnlockChargeCardActionType | UnlockChargeCardsActionType | UnsnoozeTaskActionType | UpdateAccountingClassesEnabledActionType | UpdateAccruedJESchedulesActionType | UpdateAddressActionType | UpdateAmountsInScheduleAccruedDetailActionType | UpdateAmountsInScheduleDetailActionType | UpdateAutoTransferRuleActionType | UpdateBusinessVerificationDetailsActionType | UpdateCapitalizationAccountThresholdActionType | UpdateCardPolicyActionType | UpdateCardProfileActionType | UpdateChargeCardDetailActionType | UpdateChargeCardLimitActionType | UpdateChargeCardNameActionType | UpdateChargeCardsLimitActionType | UpdateCombinedStatementInfoActionType | UpdateCompanyDetailsActionType | UpdateCompanyOfficerActionType | UpdateCompanyPassportLocalStoreDataActionType | UpdateCompanyProductServicesActionType | UpdateCompanyQboRealmIdActionType | UpdateCompanyTaskManagerViewFiltersActionType | UpdateDashboardLayoutActionType | UpdateDebitCardPinAttemptActionType | UpdateDepositAccountActionType | UpdateDynamicFormActionType | UpdateExpenseAutomationReconciliationBalanceLocalDataActionType | UpdateFileNameActionType | UpdateFilesMetadataActionType | UpdateJESchedulesActionType | UpdateMappedCashAccountActionType | UpdateMileageDetailsActionType | UpdateMyProfileActionType | UpdateNetBurnOrIncomeStoryCardSettingsActionType | UpdateNotificationViewAllNotificationsStatusActionType | UpdateNotificationViewNotificationStatusActionType | UpdateOnboardingCustomerViewActionType | UpdateOnboardingCustomerViewCompleteStatusActionType | UpdateOnboardingCustomerViewDashboardLoadedActionType | UpdateOnboardingCustomerViewLocalStoreDataActionType | UpdateOnboardingPaymentAccountLoginStatusActionType | UpdateOnboardingPaymentAccountStatusActionType | UpdatePaymentAccountActionType | UpdatePaymentAccountLoginStatusActionType | UpdatePaymentAccountStatusActionType | UpdatePhysicalChargeCardAttemptActionType | UpdatePortfolioAllocationActionType | UpdatePrimaryContactActionType | UpdatePrimaryFundingAccountActionType | UpdateQBOConnectionPoolExternalConnectionActionType | UpdateReferViewedActionType | UpdateRemiSetupViewLocalStoreDataActionType | UpdateReportUIOptionCOABalancesRangeActionType | UpdateReportUIOptionIsCompareModeActionType | UpdateReportUIOptionIsCompareModeOnActionType | UpdateReportUIOptionThisPeriodActionType | UpdateReportUIOptionTimeFrameActionType | UpdateSectionAccountsViewActionType | UpdateSectionClassesViewV2ActionType | UpdateSectionProjectViewActionType | UpdateSelectedVendorForCreateFlowActionType | UpdateSetupViewLocalStoreDataActionType | UpdateStatementInfoActionType | UpdateTaskFromListViewActionType | UpdateTaskGroupNameActionType | UpdateTransactionDetailActionType | UpdateTransactionOnUploadSuccessActionType | UpdateVendorContactActionType | UploadAccountStatementActionType | UploadMissingReceiptSuccessEpicActionType | UploadTransactionReceiptSuccessEpicActionType | ValidateBillsBulkActionActionType | VendorFiling1099UploadDetailsSaveActionType | VendorsTabFetchVendorActionType | VendorsTabFetchVendorDetailPageViewActionType | VendorsTabFetchVendorDetailsActionType | VendorsTabResetVendorDetailLocalDataActionType | VendorsTabSaveVendorActionType | VerifyDeviceWithTwoFAActionType | VerifyOtpActionType | VerifyUserActionType | WatchBulkUploadBatchStatusActionType | WiseRedirectActionType;
|
|
708
709
|
export declare const featureRootEpic: Epic<RootActionType>;
|
package/lib/epic.js
CHANGED
|
@@ -306,6 +306,7 @@ const saveInvoicingCustomerEpic_1 = require("./view/invoicing/editInvoicingCusto
|
|
|
306
306
|
const seedInvoicingCustomerFormDraftEpic_1 = require("./view/invoicing/editInvoicingCustomerDetailView/seedInvoicingCustomerFormDraftEpic");
|
|
307
307
|
const fetchInvoicingSubscriptionDetailEpic_1 = require("./view/invoicing/editInvoicingSubscriptionDetailView/fetchInvoicingSubscriptionDetailEpic");
|
|
308
308
|
const fetchInvoicingSubscriptionDetailPageEpic_1 = require("./view/invoicing/editInvoicingSubscriptionDetailView/fetchInvoicingSubscriptionDetailPageEpic");
|
|
309
|
+
const fetchInvoicingSubscriptionEstimateEpic_1 = require("./view/invoicing/editInvoicingSubscriptionDetailView/fetchInvoicingSubscriptionEstimateEpic");
|
|
309
310
|
const fetchInvoicingSubscriptionFormPageEpic_1 = require("./view/invoicing/editInvoicingSubscriptionDetailView/fetchInvoicingSubscriptionFormPageEpic");
|
|
310
311
|
const initializeInvoicingSubscriptionAddressEpic_1 = require("./view/invoicing/editInvoicingSubscriptionDetailView/initializeInvoicingSubscriptionAddressEpic");
|
|
311
312
|
const runInvoicingSubscriptionActionEpic_1 = require("./view/invoicing/editInvoicingSubscriptionDetailView/runInvoicingSubscriptionActionEpic");
|
|
@@ -1102,6 +1103,7 @@ const ALL_EPICS = [
|
|
|
1102
1103
|
fetchInvoicingSubscriptionCountsEpic_1.fetchInvoicingSubscriptionCountsEpic,
|
|
1103
1104
|
fetchInvoicingSubscriptionDetailEpic_1.fetchInvoicingSubscriptionDetailEpic,
|
|
1104
1105
|
fetchInvoicingSubscriptionDetailPageEpic_1.fetchInvoicingSubscriptionDetailPageEpic,
|
|
1106
|
+
fetchInvoicingSubscriptionEstimateEpic_1.fetchInvoicingSubscriptionEstimateEpic,
|
|
1105
1107
|
fetchInvoicingSubscriptionFormPageEpic_1.fetchInvoicingSubscriptionFormPageEpic,
|
|
1106
1108
|
fetchInvoicingSubscriptionListEpic_1.fetchInvoicingSubscriptionListEpic,
|
|
1107
1109
|
fetchInvoicingSubscriptionListPageEpic_1.fetchInvoicingSubscriptionListPageEpic,
|
|
@@ -7,3 +7,7 @@ export function getInvoicingCouponsByIds(couponState, ids) {
|
|
|
7
7
|
export function getInvoicingCouponById(couponState, id) {
|
|
8
8
|
return recordGet(couponState.couponByID, id);
|
|
9
9
|
}
|
|
10
|
+
// Forms hold a coupon by its code; the store keys coupons by id.
|
|
11
|
+
export function getInvoicingCouponByCode(couponState, couponCode) {
|
|
12
|
+
return Object.values(couponState.couponByID).find((coupon) => coupon.couponCode === couponCode);
|
|
13
|
+
}
|
package/lib/esm/epic.js
CHANGED
|
@@ -303,6 +303,7 @@ import { saveInvoicingCustomerEpic, } from './view/invoicing/editInvoicingCustom
|
|
|
303
303
|
import { seedInvoicingCustomerFormDraftEpic, } from './view/invoicing/editInvoicingCustomerDetailView/seedInvoicingCustomerFormDraftEpic';
|
|
304
304
|
import { fetchInvoicingSubscriptionDetailEpic, } from './view/invoicing/editInvoicingSubscriptionDetailView/fetchInvoicingSubscriptionDetailEpic';
|
|
305
305
|
import { fetchInvoicingSubscriptionDetailPageEpic, } from './view/invoicing/editInvoicingSubscriptionDetailView/fetchInvoicingSubscriptionDetailPageEpic';
|
|
306
|
+
import { fetchInvoicingSubscriptionEstimateEpic, } from './view/invoicing/editInvoicingSubscriptionDetailView/fetchInvoicingSubscriptionEstimateEpic';
|
|
306
307
|
import { fetchInvoicingSubscriptionFormPageEpic, } from './view/invoicing/editInvoicingSubscriptionDetailView/fetchInvoicingSubscriptionFormPageEpic';
|
|
307
308
|
import { initializeInvoicingSubscriptionAddressEpic } from './view/invoicing/editInvoicingSubscriptionDetailView/initializeInvoicingSubscriptionAddressEpic';
|
|
308
309
|
import { runInvoicingSubscriptionActionEpic, } from './view/invoicing/editInvoicingSubscriptionDetailView/runInvoicingSubscriptionActionEpic';
|
|
@@ -1099,6 +1100,7 @@ const ALL_EPICS = [
|
|
|
1099
1100
|
fetchInvoicingSubscriptionCountsEpic,
|
|
1100
1101
|
fetchInvoicingSubscriptionDetailEpic,
|
|
1101
1102
|
fetchInvoicingSubscriptionDetailPageEpic,
|
|
1103
|
+
fetchInvoicingSubscriptionEstimateEpic,
|
|
1102
1104
|
fetchInvoicingSubscriptionFormPageEpic,
|
|
1103
1105
|
fetchInvoicingSubscriptionListEpic,
|
|
1104
1106
|
fetchInvoicingSubscriptionListPageEpic,
|
package/lib/esm/index.js
CHANGED
|
@@ -774,7 +774,7 @@ export { getRecordPaymentFormView, getRecordPaymentInvoiceOptions, getRecordPaym
|
|
|
774
774
|
export { initializeInvoicingCustomerAddress, resetEditInvoicingCustomerDetailView, submitInvoicingCustomerForm, submitInvoicingCustomerFormFailure, submitInvoicingCustomerFormSuccess, updateInvoicingCustomerFormDraft, } from './view/invoicing/editInvoicingCustomerDetailView/editInvoicingCustomerDetailViewReducer';
|
|
775
775
|
export { INVOICING_CUSTOMER_BILLING_ADDRESS_TYPE, entityToInvoicingCustomerFormLocalData, initialInvoicingCustomerFormLocalData, } from './view/invoicing/editInvoicingCustomerDetailView/invoicingCustomerFormConfig';
|
|
776
776
|
export { getInvoicingCustomerFormView } from './view/invoicing/editInvoicingCustomerDetailView/editInvoicingCustomerDetailViewSelector';
|
|
777
|
-
export { fetchInvoicingSubscriptionFormPage, initializeInvoicingSubscriptionAddress, resetEditInvoicingSubscriptionDetailView, submitInvoicingSubscriptionForm, updateInvoicingSubscriptionFormDraft, } from './view/invoicing/editInvoicingSubscriptionDetailView/editInvoicingSubscriptionDetailViewReducer';
|
|
777
|
+
export { clearInvoicingSubscriptionEstimate, fetchInvoicingSubscriptionEstimate, fetchInvoicingSubscriptionFormPage, initializeInvoicingSubscriptionAddress, resetEditInvoicingSubscriptionDetailView, submitInvoicingSubscriptionForm, updateInvoicingSubscriptionFormDraft, } from './view/invoicing/editInvoicingSubscriptionDetailView/editInvoicingSubscriptionDetailViewReducer';
|
|
778
778
|
export { INVOICING_SUBSCRIPTION_SHIPPING_ADDRESS_TYPE, entityToInvoicingSubscriptionFormLocalData, initialInvoicingSubscriptionFormLocalData, invoicingSubscriptionTodayIso, toInvoicingSubscriptionQuantity, } from './view/invoicing/editInvoicingSubscriptionDetailView/invoicingSubscriptionFormConfig';
|
|
779
779
|
export { getEditInvoicingSubscriptionDetailViewState, getInvoicingSubscriptionFormView, } from './view/invoicing/editInvoicingSubscriptionDetailView/editInvoicingSubscriptionDetailViewSelector';
|
|
780
780
|
export { resetEditInvoicingCatalogItemDetailView, submitInvoicingCatalogItemForm, updateInvoicingCatalogItemFormDraft, } from './view/invoicing/editInvoicingCatalogItemDetailView/editInvoicingCatalogItemDetailViewReducer';
|
|
@@ -1,3 +1,5 @@
|
|
|
1
|
+
import { toAmount } from '../../../commonStateTypes/amount';
|
|
2
|
+
import { date } from '../../../zeniDayJS';
|
|
1
3
|
import { toAddressUpdatableInfoPayload } from '../../addressView/addressViewPayload';
|
|
2
4
|
import { invoicingSubscriptionTodayIso, toInvoicingSubscriptionBillingCycles, toInvoicingSubscriptionQuantity, } from './invoicingSubscriptionFormConfig';
|
|
3
5
|
/**
|
|
@@ -56,3 +58,56 @@ export const localDataToSaveInvoicingSubscriptionPayload = (localData, shippingA
|
|
|
56
58
|
: {}),
|
|
57
59
|
};
|
|
58
60
|
};
|
|
61
|
+
const toEstimateDate = (value) => value != null && value !== '' ? date(value) : undefined;
|
|
62
|
+
const mapInvoiceEstimate = (payload, money) => payload == null
|
|
63
|
+
? undefined
|
|
64
|
+
: {
|
|
65
|
+
amountDue: money(payload.amount_due),
|
|
66
|
+
couponDiscountTotal: money(payload.coupon_discount_total),
|
|
67
|
+
creditsApplied: money(payload.credits_applied),
|
|
68
|
+
dueDate: toEstimateDate(payload.due_date),
|
|
69
|
+
grossSubTotal: money(payload.gross_sub_total),
|
|
70
|
+
invoiceDate: toEstimateDate(payload.invoice_date),
|
|
71
|
+
lineItems: payload.line_items.map((lineItem) => ({
|
|
72
|
+
amount: money(lineItem.amount),
|
|
73
|
+
dateFrom: toEstimateDate(lineItem.date_from),
|
|
74
|
+
dateTo: toEstimateDate(lineItem.date_to),
|
|
75
|
+
description: lineItem.description,
|
|
76
|
+
discountAmount: money(lineItem.discount_amount),
|
|
77
|
+
quantity: lineItem.quantity,
|
|
78
|
+
taxAmount: lineItem.tax_amount != null
|
|
79
|
+
? money(lineItem.tax_amount)
|
|
80
|
+
: undefined,
|
|
81
|
+
unitAmount: money(lineItem.unit_amount),
|
|
82
|
+
})),
|
|
83
|
+
promotionalCreditsApplied: money(payload.promotional_credits_applied),
|
|
84
|
+
subTotal: money(payload.sub_total),
|
|
85
|
+
tax: payload.tax != null ? money(payload.tax) : undefined,
|
|
86
|
+
total: money(payload.total),
|
|
87
|
+
};
|
|
88
|
+
export const mapInvoicingSubscriptionEstimatePayloadToState = (payload) => {
|
|
89
|
+
const money = (amount) => toAmount(amount, payload.currency_code, payload.currency_symbol);
|
|
90
|
+
const term = payload.subscription_estimate;
|
|
91
|
+
const proration = payload.proration_estimate;
|
|
92
|
+
return {
|
|
93
|
+
invoice: mapInvoiceEstimate(payload.invoice_estimate, money),
|
|
94
|
+
nextInvoice: mapInvoiceEstimate(payload.next_invoice_estimate, money),
|
|
95
|
+
proration: proration != null
|
|
96
|
+
? {
|
|
97
|
+
documentType: proration.document_type,
|
|
98
|
+
invoice: mapInvoiceEstimate(proration.invoice_estimate, money),
|
|
99
|
+
net: money(proration.net),
|
|
100
|
+
}
|
|
101
|
+
: undefined,
|
|
102
|
+
reason: payload.reason,
|
|
103
|
+
term: term != null
|
|
104
|
+
? {
|
|
105
|
+
becomesNonRenewing: term.becomes_non_renewing_after_this_term === true,
|
|
106
|
+
currentTermEnd: toEstimateDate(term.current_term_end),
|
|
107
|
+
currentTermStart: toEstimateDate(term.current_term_start),
|
|
108
|
+
nextBillingAt: toEstimateDate(term.next_billing_at),
|
|
109
|
+
}
|
|
110
|
+
: undefined,
|
|
111
|
+
willBeInvoiced: payload.will_be_invoiced,
|
|
112
|
+
};
|
|
113
|
+
};
|
|
@@ -2,10 +2,14 @@ import { createSlice } from '@reduxjs/toolkit';
|
|
|
2
2
|
import { clearAll } from '../../../rootActions';
|
|
3
3
|
import { applyInvoicingFormDraftEdit, applyInvoicingFormDraftFailure, applyInvoicingFormDraftSaved, applyInvoicingFormDraftSeed, } from '../invoicingFormDraft';
|
|
4
4
|
import { initialInvoicingSubscriptionFormLocalData } from './invoicingSubscriptionFormConfig';
|
|
5
|
+
const initialEstimateState = {
|
|
6
|
+
fetchState: { fetchState: 'Not-Started', error: undefined },
|
|
7
|
+
};
|
|
5
8
|
export const initialState = {
|
|
6
9
|
fetchState: 'Not-Started',
|
|
7
10
|
error: undefined,
|
|
8
11
|
editDraftById: {},
|
|
12
|
+
estimateState: initialEstimateState,
|
|
9
13
|
actionStateById: {},
|
|
10
14
|
recordStateById: {},
|
|
11
15
|
shippingAddressOwnerId: undefined,
|
|
@@ -19,6 +23,36 @@ const editInvoicingSubscriptionDetailView = createSlice({
|
|
|
19
23
|
name: 'editInvoicingSubscriptionDetailView',
|
|
20
24
|
initialState,
|
|
21
25
|
reducers: {
|
|
26
|
+
// What saving the draft would bill (no id: create); see the estimate epic.
|
|
27
|
+
fetchInvoicingSubscriptionEstimate(draft, action) {
|
|
28
|
+
draft.estimateState = {
|
|
29
|
+
fetchState: { fetchState: 'In-Progress', error: undefined },
|
|
30
|
+
subscriptionId: action.payload.id,
|
|
31
|
+
};
|
|
32
|
+
},
|
|
33
|
+
// Dropped when the dialog has since moved to another subscription.
|
|
34
|
+
updateInvoicingSubscriptionEstimate(draft, action) {
|
|
35
|
+
if (draft.estimateState.subscriptionId !== action.payload.id) {
|
|
36
|
+
return;
|
|
37
|
+
}
|
|
38
|
+
draft.estimateState.estimate = action.payload.estimate;
|
|
39
|
+
draft.estimateState.fetchState = {
|
|
40
|
+
fetchState: 'Completed',
|
|
41
|
+
error: undefined,
|
|
42
|
+
};
|
|
43
|
+
},
|
|
44
|
+
updateInvoicingSubscriptionEstimateFailure(draft, action) {
|
|
45
|
+
if (draft.estimateState.subscriptionId !== action.payload.id) {
|
|
46
|
+
return;
|
|
47
|
+
}
|
|
48
|
+
draft.estimateState.fetchState = {
|
|
49
|
+
fetchState: 'Error',
|
|
50
|
+
error: action.payload.status,
|
|
51
|
+
};
|
|
52
|
+
},
|
|
53
|
+
clearInvoicingSubscriptionEstimate(draft) {
|
|
54
|
+
draft.estimateState = initialEstimateState;
|
|
55
|
+
},
|
|
22
56
|
runInvoicingSubscriptionAction(draft, action) {
|
|
23
57
|
draft.actionStateById[action.payload.id] = {
|
|
24
58
|
fetchState: 'In-Progress',
|
|
@@ -158,5 +192,5 @@ const editInvoicingSubscriptionDetailView = createSlice({
|
|
|
158
192
|
});
|
|
159
193
|
},
|
|
160
194
|
});
|
|
161
|
-
export const { runInvoicingSubscriptionAction, runInvoicingSubscriptionActionFailure, runInvoicingSubscriptionActionSuccess, fetchInvoicingSubscriptionDetail, fetchInvoicingSubscriptionDetailPage, fetchInvoicingSubscriptionFormPage, seedInvoicingSubscriptionFormDraft, updateInvoicingSubscriptionDetail, updateInvoicingSubscriptionDetailFailure, updateInvoicingSubscriptionFormDraft, submitInvoicingSubscriptionForm, submitInvoicingSubscriptionFormSuccess, submitInvoicingSubscriptionFormFailure, resetEditInvoicingSubscriptionDetailView, initializeInvoicingSubscriptionAddress, claimInvoicingSubscriptionShippingAddress, syncInvoicingSubscriptionCoupons, } = editInvoicingSubscriptionDetailView.actions;
|
|
195
|
+
export const { runInvoicingSubscriptionAction, runInvoicingSubscriptionActionFailure, runInvoicingSubscriptionActionSuccess, fetchInvoicingSubscriptionDetail, fetchInvoicingSubscriptionDetailPage, fetchInvoicingSubscriptionFormPage, seedInvoicingSubscriptionFormDraft, updateInvoicingSubscriptionDetail, updateInvoicingSubscriptionDetailFailure, updateInvoicingSubscriptionFormDraft, submitInvoicingSubscriptionForm, submitInvoicingSubscriptionFormSuccess, submitInvoicingSubscriptionFormFailure, resetEditInvoicingSubscriptionDetailView, initializeInvoicingSubscriptionAddress, claimInvoicingSubscriptionShippingAddress, syncInvoicingSubscriptionCoupons, fetchInvoicingSubscriptionEstimate, updateInvoicingSubscriptionEstimate, updateInvoicingSubscriptionEstimateFailure, clearInvoicingSubscriptionEstimate, } = editInvoicingSubscriptionDetailView.actions;
|
|
162
196
|
export default editInvoicingSubscriptionDetailView.reducer;
|
|
@@ -9,6 +9,57 @@ import { getInvoicingCustomerListView } from '../invoicingCustomerListView/invoi
|
|
|
9
9
|
import { getInvoicingFormDraftLocalData, isInvoicingFormDraftPending, } from '../invoicingFormDraft';
|
|
10
10
|
import { initialInvoicingSubscriptionFormLocalData } from './invoicingSubscriptionFormConfig';
|
|
11
11
|
import { INVOICING_SUBSCRIPTION_SHIPPING_ADDRESS_TYPE } from './invoicingSubscriptionFormConfig';
|
|
12
|
+
const notStartedEstimateView = {
|
|
13
|
+
creditsMayChange: false,
|
|
14
|
+
fetchState: { fetchState: 'Not-Started', error: undefined },
|
|
15
|
+
nonRenewing: false,
|
|
16
|
+
};
|
|
17
|
+
export const toInvoicingSubscriptionEstimateView = ({ estimate, fetchState, subscriptionId }, invoicingSubscriptionID) => {
|
|
18
|
+
// A slot asked for another subscription is not this form's estimate.
|
|
19
|
+
if (subscriptionId !== invoicingSubscriptionID) {
|
|
20
|
+
return notStartedEstimateView;
|
|
21
|
+
}
|
|
22
|
+
if (estimate == null) {
|
|
23
|
+
return { ...notStartedEstimateView, fetchState };
|
|
24
|
+
}
|
|
25
|
+
const { invoice, nextInvoice, proration, reason, term } = estimate;
|
|
26
|
+
const base = {
|
|
27
|
+
fetchState,
|
|
28
|
+
nonRenewing: term?.becomesNonRenewing === true,
|
|
29
|
+
nextBillingAt: term?.nextBillingAt,
|
|
30
|
+
reason: reason !== '' ? reason : undefined,
|
|
31
|
+
termEnd: term?.currentTermEnd,
|
|
32
|
+
termStart: term?.currentTermStart,
|
|
33
|
+
};
|
|
34
|
+
if (proration?.documentType === 'invoice' && proration.invoice != null) {
|
|
35
|
+
return {
|
|
36
|
+
...base,
|
|
37
|
+
creditsMayChange: false,
|
|
38
|
+
invoice: proration.invoice,
|
|
39
|
+
kind: 'proration_invoice',
|
|
40
|
+
};
|
|
41
|
+
}
|
|
42
|
+
if (proration?.documentType === 'credit_note') {
|
|
43
|
+
return {
|
|
44
|
+
...base,
|
|
45
|
+
creditsMayChange: false,
|
|
46
|
+
kind: 'proration_credit',
|
|
47
|
+
storeCredit: { ...proration.net, amount: Math.abs(proration.net.amount) },
|
|
48
|
+
};
|
|
49
|
+
}
|
|
50
|
+
if (estimate.willBeInvoiced && invoice != null) {
|
|
51
|
+
return { ...base, creditsMayChange: false, invoice, kind: 'invoice_now' };
|
|
52
|
+
}
|
|
53
|
+
if (nextInvoice != null) {
|
|
54
|
+
return {
|
|
55
|
+
...base,
|
|
56
|
+
creditsMayChange: true,
|
|
57
|
+
invoice: nextInvoice,
|
|
58
|
+
kind: 'later_invoice',
|
|
59
|
+
};
|
|
60
|
+
}
|
|
61
|
+
return { ...base, creditsMayChange: false, kind: 'reason_only' };
|
|
62
|
+
};
|
|
12
63
|
export const getEditInvoicingSubscriptionDetailViewState = (state, invoicingSubscriptionID) => {
|
|
13
64
|
const { error, fetchState, savedSubscriptionId } = state.editInvoicingSubscriptionDetailViewState;
|
|
14
65
|
const { subscriptionCommercialEditAllowedFromStatuses, subscriptionLifecycleActionOptions, subscriptionMetadataEditAllowedFromStatuses, } = getInvoicingConfigView(state);
|
|
@@ -86,6 +137,27 @@ export const getInvoicingItemsAllowedForPlan = (products, plan) => {
|
|
|
86
137
|
}
|
|
87
138
|
return products.filter((product) => product.itemID != null && allowedItemIDs.includes(product.itemID));
|
|
88
139
|
};
|
|
140
|
+
// Years count as months so they compare; any other unit only meets itself.
|
|
141
|
+
const billingPeriodInCommonUnit = (pricePoint) => {
|
|
142
|
+
const { period, periodUnit } = pricePoint;
|
|
143
|
+
if (period == null || periodUnit == null || periodUnit === '') {
|
|
144
|
+
return undefined;
|
|
145
|
+
}
|
|
146
|
+
return periodUnit === 'year'
|
|
147
|
+
? { count: period * 12, unit: 'month' }
|
|
148
|
+
: { count: period, unit: periodUnit };
|
|
149
|
+
};
|
|
150
|
+
// The add-on's period must divide the plan's (create 422s otherwise); fails open when they cannot be compared.
|
|
151
|
+
export const isInvoicingAddonPeriodCompatible = (addon, plan) => {
|
|
152
|
+
const addonPeriod = billingPeriodInCommonUnit(addon);
|
|
153
|
+
const planPeriod = plan != null ? billingPeriodInCommonUnit(plan) : undefined;
|
|
154
|
+
if (addonPeriod == null ||
|
|
155
|
+
planPeriod == null ||
|
|
156
|
+
addonPeriod.unit !== planPeriod.unit) {
|
|
157
|
+
return true;
|
|
158
|
+
}
|
|
159
|
+
return addonPeriod.count > 0 && planPeriod.count % addonPeriod.count === 0;
|
|
160
|
+
};
|
|
89
161
|
/**
|
|
90
162
|
* A price row can only be subscribed by its price code, so one without a code
|
|
91
163
|
* is not an option the form can offer.
|
|
@@ -149,7 +221,7 @@ const toInvoicingCustomerOption = (customer) => ({
|
|
|
149
221
|
value: customer.id,
|
|
150
222
|
});
|
|
151
223
|
export const getInvoicingSubscriptionFormView = (state, invoicingSubscriptionID) => {
|
|
152
|
-
const { editDraftById, error, fetchState, newSubscriptionDraft, savedSubscriptionId, } = state.editInvoicingSubscriptionDetailViewState;
|
|
224
|
+
const { editDraftById, error, estimateState, fetchState, newSubscriptionDraft, savedSubscriptionId, } = state.editInvoicingSubscriptionDetailViewState;
|
|
153
225
|
const mode = invoicingSubscriptionID != null ? 'edit' : 'create';
|
|
154
226
|
const subscription = invoicingSubscriptionID != null
|
|
155
227
|
? getInvoicingSubscriptionById(state.invoicingSubscriptionState, invoicingSubscriptionID)
|
|
@@ -174,7 +246,12 @@ export const getInvoicingSubscriptionFormView = (state, invoicingSubscriptionID)
|
|
|
174
246
|
// pickers offer only those: subscription create rejects the rest with a 422,
|
|
175
247
|
// and an option that can only fail is not a choice. The applicability rides
|
|
176
248
|
// on the price rows already in the store, so this is a join, not a refetch.
|
|
177
|
-
const
|
|
249
|
+
const selectedPlanPrice = planPrices.find((plan) => plan.priceCode === localData.planPriceCode);
|
|
250
|
+
// Add-ons also have to bill on the plan's cadence; charges are one-time.
|
|
251
|
+
const allowedCatalogPrices = getInvoicingItemsAllowedForPlan(getInvoicingCatalogPrices(catalogListView.products), selectedPlanPrice)
|
|
252
|
+
.filter(hasInvoicingPriceCode)
|
|
253
|
+
.filter((product) => product.itemType !== 'addon' ||
|
|
254
|
+
isInvoicingAddonPeriodCompatible(product, selectedPlanPrice));
|
|
178
255
|
const catalogItemOptionsOfType = (itemType) => allowedCatalogPrices
|
|
179
256
|
.filter((product) => product.itemType === itemType)
|
|
180
257
|
.map(toInvoicingCatalogItemOption);
|
|
@@ -198,6 +275,7 @@ export const getInvoicingSubscriptionFormView = (state, invoicingSubscriptionID)
|
|
|
198
275
|
subscriptionMetadataEditAllowedFromStatuses: configState.subscriptionMetadataEditAllowedFromStatuses,
|
|
199
276
|
recordState,
|
|
200
277
|
isFormLoading: isInvoicingFormDraftPending(editDraftById, invoicingSubscriptionID),
|
|
278
|
+
estimate: toInvoicingSubscriptionEstimateView(estimateState, invoicingSubscriptionID),
|
|
201
279
|
fieldHelp: invoicingFieldHelpForGroup(state, 'subscription'),
|
|
202
280
|
addons: catalogItemOptionsOfType('addon'),
|
|
203
281
|
charges: catalogItemOptionsOfType('charge'),
|
|
@@ -0,0 +1,49 @@
|
|
|
1
|
+
import { of } from 'rxjs';
|
|
2
|
+
import { catchError, filter, map, switchMap } from 'rxjs/operators';
|
|
3
|
+
import { getInvoicingCouponByCode } from '../../../entity/invoicing/coupon/couponSelector';
|
|
4
|
+
import { createZeniAPIStatus, isSuccessResponse } from '../../../responsePayload';
|
|
5
|
+
import { mapInvoicingSubscriptionEstimatePayloadToState, } from './editInvoicingSubscriptionDetailViewPayload';
|
|
6
|
+
import { fetchInvoicingSubscriptionEstimate, updateInvoicingSubscriptionEstimate, updateInvoicingSubscriptionEstimateFailure, } from './editInvoicingSubscriptionDetailViewReducer';
|
|
7
|
+
import { invoicingSubscriptionSaveRequest, isInvoicingSubscriptionCouponChanged, } from './saveInvoicingSubscriptionEpic';
|
|
8
|
+
// Posts Save's exact body; a changed coupon rides along as `coupons` (Save syncs it after the PUT).
|
|
9
|
+
export const fetchInvoicingSubscriptionEstimateEpic = (actions$, state$, zeniAPI) => actions$.pipe(filter(fetchInvoicingSubscriptionEstimate.match), switchMap((action) => {
|
|
10
|
+
const { id } = action.payload;
|
|
11
|
+
const { data, localData, previousCouponCode } = invoicingSubscriptionSaveRequest(state$.value, id);
|
|
12
|
+
const couponCode = localData.couponId;
|
|
13
|
+
const coupon = getInvoicingCouponByCode(state$.value.invoicingCouponState, couponCode);
|
|
14
|
+
const body = id != null &&
|
|
15
|
+
isInvoicingSubscriptionCouponChanged(previousCouponCode, couponCode)
|
|
16
|
+
? {
|
|
17
|
+
...data,
|
|
18
|
+
coupons: couponCode !== ''
|
|
19
|
+
? [
|
|
20
|
+
{
|
|
21
|
+
applied_count: 0,
|
|
22
|
+
apply_till: null,
|
|
23
|
+
coupon_code: couponCode,
|
|
24
|
+
coupon_id: coupon?.id ?? couponCode,
|
|
25
|
+
},
|
|
26
|
+
]
|
|
27
|
+
: [],
|
|
28
|
+
}
|
|
29
|
+
: data;
|
|
30
|
+
const baseUrl = `${zeniAPI.apiEndPoints.invoicingMicroServiceBaseUrl}/1.0/subscriptions`;
|
|
31
|
+
const url = id != null
|
|
32
|
+
? `${baseUrl}/${encodeURIComponent(id)}/estimate`
|
|
33
|
+
: `${baseUrl}/estimate`;
|
|
34
|
+
return zeniAPI
|
|
35
|
+
.postAndGetJSON(url, body)
|
|
36
|
+
.pipe(map((response) => isSuccessResponse(response) && response.data != null
|
|
37
|
+
? updateInvoicingSubscriptionEstimate({
|
|
38
|
+
estimate: mapInvoicingSubscriptionEstimatePayloadToState(response.data),
|
|
39
|
+
id,
|
|
40
|
+
})
|
|
41
|
+
: updateInvoicingSubscriptionEstimateFailure({
|
|
42
|
+
id,
|
|
43
|
+
status: response.status,
|
|
44
|
+
})), catchError((error) => of(updateInvoicingSubscriptionEstimateFailure({
|
|
45
|
+
id,
|
|
46
|
+
status: createZeniAPIStatus('Unexpected Error', 'Subscription estimate REST API call errored out ' +
|
|
47
|
+
JSON.stringify(error)),
|
|
48
|
+
}))));
|
|
49
|
+
}));
|
package/lib/esm/view/invoicing/editInvoicingSubscriptionDetailView/saveInvoicingSubscriptionEpic.js
CHANGED
|
@@ -14,9 +14,10 @@ import { localDataToSaveInvoicingSubscriptionPayload, } from './editInvoicingSub
|
|
|
14
14
|
import { submitInvoicingSubscriptionForm, submitInvoicingSubscriptionFormFailure, submitInvoicingSubscriptionFormSuccess, syncInvoicingSubscriptionCoupons, } from './editInvoicingSubscriptionDetailViewReducer';
|
|
15
15
|
import { INVOICING_SUBSCRIPTION_SHIPPING_ADDRESS_TYPE } from './invoicingSubscriptionFormConfig';
|
|
16
16
|
const normalizeCouponCode = (value) => (value ?? '').trim().toUpperCase();
|
|
17
|
-
export const
|
|
18
|
-
|
|
19
|
-
|
|
17
|
+
export const isInvoicingSubscriptionCouponChanged = (previousCouponCode, nextCouponCode) => normalizeCouponCode(previousCouponCode) !==
|
|
18
|
+
normalizeCouponCode(nextCouponCode);
|
|
19
|
+
// The draft a save reads and the body it sends; the estimate previews the same body.
|
|
20
|
+
export const invoicingSubscriptionSaveRequest = (rootState, id) => {
|
|
20
21
|
const viewState = rootState.editInvoicingSubscriptionDetailViewState;
|
|
21
22
|
const localData = (id != null
|
|
22
23
|
? viewState.editDraftById[id]?.localData
|
|
@@ -25,18 +26,23 @@ export const saveInvoicingSubscriptionEpic = (actions$, state$, zeniAPI) => acti
|
|
|
25
26
|
// object in the payload (same pattern as the customer save flow).
|
|
26
27
|
const shippingAddress = rootState.addressViewState.newAddressState?.[INVOICING_SUBSCRIPTION_SHIPPING_ADDRESS_TYPE]?.addressToCreate;
|
|
27
28
|
const data = localDataToSaveInvoicingSubscriptionPayload(localData, shippingAddress);
|
|
28
|
-
// Coupons are synced via apply/remove-coupon after PUT (not via coupon_ids).
|
|
29
29
|
if (id != null) {
|
|
30
30
|
delete data.coupon_ids;
|
|
31
31
|
}
|
|
32
|
+
const savedCoupon = id != null
|
|
33
|
+
? rootState.invoicingSubscriptionState.invoicingSubscriptionByID[id]
|
|
34
|
+
?.coupons?.[0]
|
|
35
|
+
: undefined;
|
|
36
|
+
return {
|
|
37
|
+
data,
|
|
38
|
+
localData,
|
|
39
|
+
previousCouponCode: savedCoupon?.couponCode ?? savedCoupon?.couponID ?? '',
|
|
40
|
+
};
|
|
41
|
+
};
|
|
42
|
+
export const saveInvoicingSubscriptionEpic = (actions$, state$, zeniAPI) => actions$.pipe(filter(submitInvoicingSubscriptionForm.match), mergeMap((action) => {
|
|
43
|
+
const { id } = action.payload;
|
|
44
|
+
const { data, localData, previousCouponCode } = invoicingSubscriptionSaveRequest(state$.value, id);
|
|
32
45
|
const baseUrl = `${zeniAPI.apiEndPoints.invoicingMicroServiceBaseUrl}/1.0`;
|
|
33
|
-
const previousCouponCode = id != null
|
|
34
|
-
? (rootState.invoicingSubscriptionState.invoicingSubscriptionByID[id]
|
|
35
|
-
?.coupons?.[0]?.couponCode ??
|
|
36
|
-
rootState.invoicingSubscriptionState.invoicingSubscriptionByID[id]
|
|
37
|
-
?.coupons?.[0]?.couponID ??
|
|
38
|
-
'')
|
|
39
|
-
: '';
|
|
40
46
|
const request$ = id != null
|
|
41
47
|
? zeniAPI.putAndGetJSON(`${baseUrl}/subscriptions/${encodeURIComponent(id)}`, { ...data })
|
|
42
48
|
: zeniAPI.postAndGetJSON(`${baseUrl}/subscriptions`, { ...data });
|
|
@@ -54,8 +60,7 @@ export const saveInvoicingSubscriptionEpic = (actions$, state$, zeniAPI) => acti
|
|
|
54
60
|
}
|
|
55
61
|
const saved = response.data;
|
|
56
62
|
const couponChanged = id != null &&
|
|
57
|
-
|
|
58
|
-
normalizeCouponCode(localData.couponId);
|
|
63
|
+
isInvoicingSubscriptionCouponChanged(previousCouponCode, localData.couponId);
|
|
59
64
|
// Edit + coupon change: merge the saved subscription, then hand the
|
|
60
65
|
// coupon attach/detach to syncInvoicingSubscriptionCouponsEpic, which
|
|
61
66
|
// finishes the flow (form success on both calls ok, form failure
|
|
@@ -90,8 +90,8 @@ export const updateOnboardingCustomerViewEpic = (actions$, state$, zeniAPI) => a
|
|
|
90
90
|
save: 'onboarding_customer_business_verification_save',
|
|
91
91
|
},
|
|
92
92
|
setup_billing: {
|
|
93
|
-
save: '
|
|
94
|
-
sendForVerification: '
|
|
93
|
+
save: 'common',
|
|
94
|
+
sendForVerification: 'common',
|
|
95
95
|
},
|
|
96
96
|
};
|
|
97
97
|
let messageSection;
|
package/lib/index.d.ts
CHANGED
|
@@ -1126,12 +1126,12 @@ export type { InvoicingCustomerFormLocalData } from './view/invoicing/editInvoic
|
|
|
1126
1126
|
export { INVOICING_CUSTOMER_BILLING_ADDRESS_TYPE, entityToInvoicingCustomerFormLocalData, initialInvoicingCustomerFormLocalData, } from './view/invoicing/editInvoicingCustomerDetailView/invoicingCustomerFormConfig';
|
|
1127
1127
|
export { getInvoicingCustomerFormView } from './view/invoicing/editInvoicingCustomerDetailView/editInvoicingCustomerDetailViewSelector';
|
|
1128
1128
|
export type { InvoicingCustomerFormView } from './view/invoicing/editInvoicingCustomerDetailView/editInvoicingCustomerDetailViewSelector';
|
|
1129
|
-
export { fetchInvoicingSubscriptionFormPage, initializeInvoicingSubscriptionAddress, resetEditInvoicingSubscriptionDetailView, submitInvoicingSubscriptionForm, updateInvoicingSubscriptionFormDraft, } from './view/invoicing/editInvoicingSubscriptionDetailView/editInvoicingSubscriptionDetailViewReducer';
|
|
1129
|
+
export { clearInvoicingSubscriptionEstimate, fetchInvoicingSubscriptionEstimate, fetchInvoicingSubscriptionFormPage, initializeInvoicingSubscriptionAddress, resetEditInvoicingSubscriptionDetailView, submitInvoicingSubscriptionForm, updateInvoicingSubscriptionFormDraft, } from './view/invoicing/editInvoicingSubscriptionDetailView/editInvoicingSubscriptionDetailViewReducer';
|
|
1130
1130
|
export type { SubmitInvoicingSubscriptionFormPayload, UpdateInvoicingSubscriptionFormDraftPayload, } from './view/invoicing/editInvoicingSubscriptionDetailView/editInvoicingSubscriptionDetailViewReducer';
|
|
1131
|
-
export type { InvoicingSubscriptionFormLocalData } from './view/invoicing/editInvoicingSubscriptionDetailView/editInvoicingSubscriptionDetailViewState';
|
|
1131
|
+
export type { InvoicingSubscriptionEstimateLineItem, InvoicingSubscriptionFormLocalData, InvoicingSubscriptionInvoiceEstimate, } from './view/invoicing/editInvoicingSubscriptionDetailView/editInvoicingSubscriptionDetailViewState';
|
|
1132
1132
|
export { INVOICING_SUBSCRIPTION_SHIPPING_ADDRESS_TYPE, entityToInvoicingSubscriptionFormLocalData, initialInvoicingSubscriptionFormLocalData, invoicingSubscriptionTodayIso, toInvoicingSubscriptionQuantity, } from './view/invoicing/editInvoicingSubscriptionDetailView/invoicingSubscriptionFormConfig';
|
|
1133
1133
|
export { getEditInvoicingSubscriptionDetailViewState, getInvoicingSubscriptionFormView, } from './view/invoicing/editInvoicingSubscriptionDetailView/editInvoicingSubscriptionDetailViewSelector';
|
|
1134
|
-
export type { EditInvoicingSubscriptionDetailView, InvoicingSubscriptionFormView, InvoicingSubscriptionOption, } from './view/invoicing/editInvoicingSubscriptionDetailView/editInvoicingSubscriptionDetailViewSelector';
|
|
1134
|
+
export type { EditInvoicingSubscriptionDetailView, InvoicingSubscriptionEstimateKind, InvoicingSubscriptionEstimateView, InvoicingSubscriptionFormView, InvoicingSubscriptionOption, } from './view/invoicing/editInvoicingSubscriptionDetailView/editInvoicingSubscriptionDetailViewSelector';
|
|
1135
1135
|
export { resetEditInvoicingCatalogItemDetailView, submitInvoicingCatalogItemForm, updateInvoicingCatalogItemFormDraft, } from './view/invoicing/editInvoicingCatalogItemDetailView/editInvoicingCatalogItemDetailViewReducer';
|
|
1136
1136
|
export type { SubmitInvoicingCatalogItemFormPayload, UpdateInvoicingCatalogItemFormDraftPayload, } from './view/invoicing/editInvoicingCatalogItemDetailView/editInvoicingCatalogItemDetailViewReducer';
|
|
1137
1137
|
export type { InvoicingCatalogAccountingLookup } from './view/invoicing/editInvoicingCatalogItemDetailView/editInvoicingCatalogItemDetailViewPayload';
|