@zeniai/client-epic-state 4.20.2-beta0ND → 4.20.2-beta25RR
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/animations.d.ts +1 -1
- package/lib/entity/aiCfo/aiCfoSelector.d.ts +2 -1
- package/lib/entity/billPay/billTransaction/billTransactionState.d.ts +2 -2
- package/lib/entity/jeSchedules/jeSchedulesPayload.d.ts +0 -38
- package/lib/entity/jeSchedules/jeSchedulesPayload.js +0 -78
- package/lib/entity/jeSchedules/jeSchedulesSelector.d.ts +1 -4
- package/lib/entity/jeSchedules/jeSchedulesSelector.js +1 -5
- package/lib/entity/jeSchedules/jeSchedulesState.d.ts +0 -37
- package/lib/entity/snackbar/snackbarTypes.d.ts +1 -1
- package/lib/entity/snackbar/snackbarTypes.js +2 -0
- package/lib/entity/task/taskPayload.d.ts +3 -0
- package/lib/entity/task/taskPayload.js +5 -0
- package/lib/entity/task/taskState.d.ts +3 -0
- package/lib/entity/tenant/tenantPayload.d.ts +0 -1
- package/lib/entity/tenant/tenantReducer.js +0 -1
- package/lib/entity/tenant/tenantSelector.d.ts +0 -1
- package/lib/entity/tenant/tenantSelector.js +1 -9
- package/lib/entity/tenant/tenantState.d.ts +0 -1
- package/lib/entity/transaction/payloadTypes/scheduleTransactionPayload.d.ts +1 -4
- package/lib/entity/transaction/payloadTypes/scheduleTransactionPayload.js +0 -1
- package/lib/entity/transaction/payloadTypes/transactionPayload.d.ts +0 -3
- package/lib/entity/transaction/payloadTypes/transactionPayload.js +1 -17
- package/lib/entity/transaction/stateTypes/scheduleTransaction.d.ts +0 -1
- package/lib/entity/transaction/stateTypes/transaction.d.ts +0 -5
- package/lib/entity/transaction/stateTypes/transactionLine.d.ts +1 -1
- package/lib/epic.d.ts +3 -2
- package/lib/epic.js +3 -2
- package/lib/esm/entity/jeSchedules/jeSchedulesPayload.js +0 -78
- package/lib/esm/entity/jeSchedules/jeSchedulesSelector.js +1 -5
- package/lib/esm/entity/snackbar/snackbarTypes.js +2 -0
- package/lib/esm/entity/task/taskPayload.js +5 -0
- package/lib/esm/entity/tenant/tenantReducer.js +0 -1
- package/lib/esm/entity/tenant/tenantSelector.js +0 -7
- package/lib/esm/entity/transaction/payloadTypes/scheduleTransactionPayload.js +0 -1
- package/lib/esm/entity/transaction/payloadTypes/transactionPayload.js +1 -17
- package/lib/esm/epic.js +3 -2
- package/lib/esm/index.js +9 -10
- package/lib/esm/view/aiCfoView/aiCfoViewReducer.js +1 -82
- package/lib/esm/view/aiCfoView/aiCfoViewSelector.js +2 -8
- package/lib/esm/view/classList/fetchClassListEpic.js +2 -9
- package/lib/esm/view/commonVendorView/vendorView/vendorViewSelector.js +5 -18
- package/lib/esm/view/commonVendorView/vendorsTabVendorView/vendorsTabVendorViewSelector.js +2 -6
- package/lib/esm/view/companyView/types/cockpitTypes.js +1 -0
- package/lib/esm/view/expenseAutomationView/epics/jeSchedule/fetchJeSchedulesEpic.js +2 -2
- package/lib/esm/view/expenseAutomationView/epics/missingReceipts/bulkUploadReceiptsEpic.js +2 -2
- package/lib/esm/view/expenseAutomationView/epics/missingReceipts/watchBulkUploadBatchStatusEpic.js +3 -4
- package/lib/esm/view/expenseAutomationView/expenseAutomationViewSelector.js +1 -0
- package/lib/esm/view/expenseAutomationView/helpers/saveTransactionHelper.js +2 -2
- package/lib/esm/view/expenseAutomationView/helpers/transactionCategorizationLocalDataHelper.js +2 -2
- package/lib/esm/view/expenseAutomationView/reducers/jeSchedulesViewReducer.js +1 -17
- package/lib/esm/view/expenseAutomationView/selectors/fluxAnalysisViewSelector.js +2 -10
- package/lib/esm/view/expenseAutomationView/selectors/jeSchedulesViewSelector.js +6 -63
- package/lib/esm/view/expenseAutomationView/selectors/missingReceiptsSelector.js +4 -12
- package/lib/esm/view/expenseAutomationView/selectors/reconciliationViewSelector.js +9 -22
- package/lib/esm/view/expenseAutomationView/selectors/transactionCategorizationSelector.js +6 -12
- package/lib/esm/view/expenseAutomationView/types/jeSchedulesViewState.js +1 -18
- package/lib/esm/view/profitAndLossClassesView/profitAndLossClassesByClassHorizontalSelector.js +0 -3
- package/lib/esm/view/spendManagement/billPay/billList/billListSelector.js +0 -10
- package/lib/esm/view/spendManagement/billPay/billList/billListState.js +0 -1
- package/lib/esm/view/spendManagement/billPay/billPayReview/billPayReviewSelector.js +3 -7
- package/lib/esm/view/spendManagement/billPay/billPaySetupApproverView/billPaySetupApproverViewSelector.js +5 -5
- package/lib/esm/view/spendManagement/billPay/billPaySetupApproverView/epic/fetchBillPayApproversDetailsEpic.js +2 -7
- package/lib/esm/view/spendManagement/billPay/editBillView/editBillViewSelector.js +6 -13
- package/lib/esm/view/spendManagement/chargeCards/chargeCardList/chargeCardList.js +0 -1
- package/lib/esm/view/spendManagement/chargeCards/chargeCardList/chargeCardListSelector.js +0 -2
- package/lib/esm/view/spendManagement/reimbursement/editRemiView/editRemiViewSelector.js +4 -7
- package/lib/esm/view/spendManagement/reimbursement/remiListView/remiListSelector.js +0 -12
- package/lib/esm/view/spendManagement/reimbursement/remiListView/remiListState.js +0 -1
- package/lib/esm/view/taskManager/taskDetailView/epics/archiveTaskEpic.js +2 -0
- package/lib/esm/view/taskManager/taskDetailView/epics/deleteTaskEpic.js +4 -0
- package/lib/esm/view/taskManager/taskDetailView/epics/initializeTaskToLocalStoreEpic.js +1 -0
- package/lib/esm/view/taskManager/taskDetailView/epics/saveTaskDetailEpic.js +1 -0
- package/lib/esm/view/taskManager/taskDetailView/epics/snoozeTaskEpic.js +64 -0
- package/lib/esm/view/taskManager/taskDetailView/epics/unsnoozeTaskEpic.js +54 -0
- package/lib/esm/view/taskManager/taskDetailView/taskDetail.js +4 -0
- package/lib/esm/view/taskManager/taskDetailView/taskDetailReducer.js +49 -1
- package/lib/esm/view/taskManager/taskDetailView/taskDetailSelector.js +5 -2
- package/lib/esm/view/taskManager/taskListView/taskList.js +1 -0
- package/lib/esm/view/taskManager/taskListView/taskListReducer.js +23 -1
- package/lib/esm/view/taskManager/taskListView/taskListSelector.js +43 -11
- package/lib/esm/view/transactionDetail/epics/saveTransactionHelper.js +2 -2
- package/lib/esm/view/transactionDetail/transactionDetailLocalDataHelper.js +14 -16
- package/lib/index.d.ts +12 -15
- package/lib/index.js +34 -42
- package/lib/tsconfig.typecheck.tsbuildinfo +1 -1
- package/lib/view/aiCfoView/aiCfoViewPayload.d.ts +0 -7
- package/lib/view/aiCfoView/aiCfoViewReducer.d.ts +1 -15
- package/lib/view/aiCfoView/aiCfoViewReducer.js +2 -83
- package/lib/view/aiCfoView/aiCfoViewSelector.d.ts +1 -4
- package/lib/view/aiCfoView/aiCfoViewSelector.js +2 -9
- package/lib/view/aiCfoView/aiCfoViewState.d.ts +1 -15
- package/lib/view/auditReportView/auditReportViewState.d.ts +1 -1
- package/lib/view/classList/fetchClassListEpic.d.ts +1 -1
- package/lib/view/classList/fetchClassListEpic.js +1 -8
- package/lib/view/commonVendorView/vendorView/vendorViewSelector.d.ts +0 -1
- package/lib/view/commonVendorView/vendorView/vendorViewSelector.js +5 -18
- package/lib/view/commonVendorView/vendorsTabVendorView/vendorsTabVendorViewSelector.d.ts +0 -1
- package/lib/view/commonVendorView/vendorsTabVendorView/vendorsTabVendorViewSelector.js +2 -6
- package/lib/view/companyTaskManagerView/companyTaskManagerViewReducer.d.ts +2 -2
- package/lib/view/companyView/types/cockpitTypes.d.ts +1 -1
- package/lib/view/companyView/types/cockpitTypes.js +1 -0
- package/lib/view/expenseAutomationView/epics/jeSchedule/fetchJeSchedulesEpic.js +2 -2
- package/lib/view/expenseAutomationView/epics/missingReceipts/bulkUploadReceiptsEpic.js +1 -1
- package/lib/view/expenseAutomationView/epics/missingReceipts/watchBulkUploadBatchStatusEpic.js +3 -4
- package/lib/view/expenseAutomationView/expenseAutomationViewSelector.js +1 -0
- package/lib/view/expenseAutomationView/helpers/saveTransactionHelper.js +2 -2
- package/lib/view/expenseAutomationView/helpers/transactionCategorizationLocalDataHelper.d.ts +1 -1
- package/lib/view/expenseAutomationView/helpers/transactionCategorizationLocalDataHelper.js +2 -2
- package/lib/view/expenseAutomationView/payload/jeSchedulesPayload.d.ts +1 -1
- package/lib/view/expenseAutomationView/reducers/jeSchedulesViewReducer.d.ts +2 -2
- package/lib/view/expenseAutomationView/reducers/jeSchedulesViewReducer.js +2 -18
- package/lib/view/expenseAutomationView/selectorTypes/jeSchedulesSelectorTypes.d.ts +0 -2
- package/lib/view/expenseAutomationView/selectors/fluxAnalysisViewSelector.js +2 -10
- package/lib/view/expenseAutomationView/selectors/jeSchedulesViewSelector.js +6 -63
- package/lib/view/expenseAutomationView/selectors/missingReceiptsSelector.js +4 -12
- package/lib/view/expenseAutomationView/selectors/reconciliationViewSelector.js +9 -22
- package/lib/view/expenseAutomationView/selectors/transactionCategorizationSelector.js +5 -11
- package/lib/view/expenseAutomationView/types/jeSchedulesViewState.d.ts +0 -5
- package/lib/view/expenseAutomationView/types/jeSchedulesViewState.js +0 -20
- package/lib/view/profitAndLossClassesView/profitAndLossClassesByClassHorizontalSelector.js +0 -3
- package/lib/view/scheduleView/scheduleListView/scheduleListTypes.d.ts +1 -1
- package/lib/view/spendManagement/billPay/billList/billListSelector.js +0 -10
- package/lib/view/spendManagement/billPay/billList/billListState.d.ts +1 -1
- package/lib/view/spendManagement/billPay/billList/billListState.js +0 -1
- package/lib/view/spendManagement/billPay/billPayReview/billPayReviewSelector.js +3 -7
- package/lib/view/spendManagement/billPay/billPaySetupApproverView/billPaySetupApproverViewSelector.js +5 -5
- package/lib/view/spendManagement/billPay/billPaySetupApproverView/epic/fetchBillPayApproversDetailsEpic.js +2 -7
- package/lib/view/spendManagement/billPay/editBillView/editBillViewSelector.js +6 -13
- package/lib/view/spendManagement/chargeCards/chargeCardList/chargeCardList.d.ts +1 -1
- package/lib/view/spendManagement/chargeCards/chargeCardList/chargeCardList.js +0 -1
- package/lib/view/spendManagement/chargeCards/chargeCardList/chargeCardListSelector.js +0 -2
- package/lib/view/spendManagement/reimbursement/editRemiView/editRemiViewSelector.js +3 -6
- package/lib/view/spendManagement/reimbursement/remiListView/remiListSelector.d.ts +0 -1
- package/lib/view/spendManagement/reimbursement/remiListView/remiListSelector.js +0 -12
- package/lib/view/spendManagement/reimbursement/remiListView/remiListState.d.ts +1 -1
- package/lib/view/spendManagement/reimbursement/remiListView/remiListState.js +0 -1
- package/lib/view/taskManager/taskDetailView/epics/archiveTaskEpic.d.ts +2 -1
- package/lib/view/taskManager/taskDetailView/epics/archiveTaskEpic.js +2 -0
- package/lib/view/taskManager/taskDetailView/epics/deleteTaskEpic.d.ts +2 -1
- package/lib/view/taskManager/taskDetailView/epics/deleteTaskEpic.js +4 -0
- package/lib/view/taskManager/taskDetailView/epics/initializeTaskToLocalStoreEpic.js +1 -0
- package/lib/view/taskManager/taskDetailView/epics/saveTaskDetailEpic.js +1 -0
- package/lib/view/taskManager/taskDetailView/epics/snoozeTaskEpic.d.ts +9 -0
- package/lib/view/taskManager/taskDetailView/epics/snoozeTaskEpic.js +68 -0
- package/lib/view/taskManager/taskDetailView/epics/unsnoozeTaskEpic.d.ts +8 -0
- package/lib/view/taskManager/taskDetailView/epics/unsnoozeTaskEpic.js +58 -0
- package/lib/view/taskManager/taskDetailView/taskDetail.d.ts +2 -0
- package/lib/view/taskManager/taskDetailView/taskDetail.js +4 -0
- package/lib/view/taskManager/taskDetailView/taskDetailReducer.d.ts +10 -1
- package/lib/view/taskManager/taskDetailView/taskDetailReducer.js +50 -2
- package/lib/view/taskManager/taskDetailView/taskDetailSelector.d.ts +2 -0
- package/lib/view/taskManager/taskDetailView/taskDetailSelector.js +5 -2
- package/lib/view/taskManager/taskListView/taskList.d.ts +1 -1
- package/lib/view/taskManager/taskListView/taskList.js +1 -0
- package/lib/view/taskManager/taskListView/taskListReducer.d.ts +3 -3
- package/lib/view/taskManager/taskListView/taskListReducer.js +24 -2
- package/lib/view/taskManager/taskListView/taskListSelector.d.ts +6 -2
- package/lib/view/taskManager/taskListView/taskListSelector.js +43 -11
- package/lib/view/transactionDetail/epics/saveTransactionHelper.js +2 -2
- package/lib/view/transactionDetail/transactionDetailLocalDataHelper.js +14 -16
- package/package.json +1 -1
- package/lib/common/aiCfo/aiCfoSuggestedQuestionsPageContext.d.ts +0 -19
- package/lib/common/aiCfo/aiCfoSuggestedQuestionsPageContext.js +0 -2
- package/lib/esm/common/aiCfo/aiCfoSuggestedQuestionsPageContext.js +0 -1
- package/lib/esm/view/aiCfoView/epics/fetchSuggestedQuestionsEpic.js +0 -29
- package/lib/view/aiCfoView/epics/fetchSuggestedQuestionsEpic.d.ts +0 -8
- package/lib/view/aiCfoView/epics/fetchSuggestedQuestionsEpic.js +0 -33
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
export declare const toAnimationsFileName: (v: string) => "
|
|
1
|
+
export declare const toAnimationsFileName: (v: string) => "AiAgent" | "AiIconEntry" | "AiIconExit" | "AiIconLoop" | "AiStar" | "AiStarIcon" | "AiStarPlain" | "AIPoweredInvoiceDark" | "AIPoweredInvoiceLight" | "Angry" | "AutoTransfer" | "CloseCard" | "Confetti" | "ConfettiSuccess" | "DashboardChristmasSnow" | "DashboardNewYearShow" | "DashboardSidebarBottomChristmas" | "DashboardSidebarBottomHalloween" | "DashboardSidebarBottomNewYear" | "DashboardSidebarBottomThanksgiving" | "DashboardSidebarTopChristmas" | "DashboardSidebarTopHalloween" | "DashboardSidebarTopNewYear" | "DashboardSidebarTopThanksgiving" | "EarnYield" | "FastestWayDark" | "FastestWayLight" | "FinanceTeamDark" | "FinanceTeamLight" | "Happy" | "Liquidity" | "LockCard" | "MoneyTransferSuccess" | "MultiLevelApprovalDark" | "MultiLevelApprovalLight" | "NotHappy" | "Protection" | "ReceiptDark" | "ReceiptLight" | "ReimburseDark" | "ReimburseLight" | "RewardsDark" | "RewardsDarkHover" | "RewardsLight" | "RewardsLightHover" | "Secure" | "Success" | "UnlockCard" | "VeryHappy" | "ZeniAssist";
|
|
2
2
|
export type AnimationFileName = ReturnType<typeof toAnimationsFileName>;
|
|
@@ -1,5 +1,6 @@
|
|
|
1
1
|
import { ID } from '../../commonStateTypes/common';
|
|
2
|
-
import { AiCfoQuestionWithAnswer, AiCfoState
|
|
2
|
+
import { AiCfoQuestionWithAnswer, AiCfoState } from './aiCfoState';
|
|
3
|
+
import { ChatSession } from './aiCfoState';
|
|
3
4
|
export declare function getAllQuestionAnswersForChatSession(state: AiCfoState, chatSessionId: ID): AiCfoQuestionWithAnswer[];
|
|
4
5
|
export declare function getQuestionAnswerByIdForChatSession(state: AiCfoState, chatSessionId: ID, questionAnswerId: ID): AiCfoQuestionWithAnswer | undefined;
|
|
5
6
|
export declare function getAllQuestionsForChatSession(state: AiCfoState, chatSessionId: ID): string[];
|
|
@@ -7,6 +7,8 @@ import { VendorTransaction } from '../../transaction/stateTypes/vendorTransactio
|
|
|
7
7
|
export interface BillTransaction extends VendorTransaction {
|
|
8
8
|
billPayInfo: BillPayInfo;
|
|
9
9
|
candidateVendorName: string;
|
|
10
|
+
classId: ID;
|
|
11
|
+
className: string;
|
|
10
12
|
createdBy: ID;
|
|
11
13
|
deletionInfo: DeletionInfo;
|
|
12
14
|
entityApprovalId: ID;
|
|
@@ -19,8 +21,6 @@ export interface BillTransaction extends VendorTransaction {
|
|
|
19
21
|
updateTime: ZeniDate;
|
|
20
22
|
bookCloseDate?: ZeniDate;
|
|
21
23
|
bulkProcessingDetail?: BulkProcessingDetail;
|
|
22
|
-
classId?: ID;
|
|
23
|
-
className?: string;
|
|
24
24
|
lastUpdatedByUserId?: ID;
|
|
25
25
|
recurringBillConfigId?: ID;
|
|
26
26
|
recurringBillInstance?: number;
|
|
@@ -13,41 +13,6 @@ export interface JEScheduleOtherAttributesPayload {
|
|
|
13
13
|
asset_id?: string | null;
|
|
14
14
|
starting_balance?: number | null;
|
|
15
15
|
}
|
|
16
|
-
export interface JEScheduleAISummaryFieldPayload {
|
|
17
|
-
confidence: number;
|
|
18
|
-
reasoning: string;
|
|
19
|
-
predicted_value?: number | string;
|
|
20
|
-
}
|
|
21
|
-
export interface JEScheduleAISummariesPayload {
|
|
22
|
-
credit_account?: JEScheduleAISummaryFieldPayload;
|
|
23
|
-
credit_accounting_class?: JEScheduleAISummaryFieldPayload;
|
|
24
|
-
debit_account?: JEScheduleAISummaryFieldPayload;
|
|
25
|
-
debit_accounting_class?: JEScheduleAISummaryFieldPayload;
|
|
26
|
-
period?: JEScheduleAISummaryFieldPayload;
|
|
27
|
-
posting_date?: JEScheduleAISummaryFieldPayload;
|
|
28
|
-
schedule_type?: JEScheduleAISummaryFieldPayload;
|
|
29
|
-
}
|
|
30
|
-
export interface JEScheduleRecommendationsPayload {
|
|
31
|
-
credit_account_confidence?: number;
|
|
32
|
-
credit_class_confidence?: number;
|
|
33
|
-
debit_account_confidence?: number;
|
|
34
|
-
debit_class_confidence?: number;
|
|
35
|
-
end_date?: string | null;
|
|
36
|
-
je_credit_account_id?: string | null;
|
|
37
|
-
je_credit_accounting_class_id?: string | null;
|
|
38
|
-
je_debit_account_id?: string | null;
|
|
39
|
-
je_debit_accounting_class_id?: string | null;
|
|
40
|
-
je_schedule_type?: string | null;
|
|
41
|
-
je_schedule_type_confidence?: number;
|
|
42
|
-
period?: number | null;
|
|
43
|
-
period_confidence?: number;
|
|
44
|
-
posting_date?: string | null;
|
|
45
|
-
posting_date_confidence?: number;
|
|
46
|
-
similar_transactions?: unknown[];
|
|
47
|
-
start_date?: string | null;
|
|
48
|
-
starting_month?: string | null;
|
|
49
|
-
starting_month_confidence?: number;
|
|
50
|
-
}
|
|
51
16
|
export interface JEScheduledTransactionPayload {
|
|
52
17
|
balance: number | null;
|
|
53
18
|
base_transaction: ScheduleTransactionPayload;
|
|
@@ -70,10 +35,7 @@ export interface JEScheduledTransactionPayload {
|
|
|
70
35
|
status: StatusCodeWithLabelPayload;
|
|
71
36
|
updated_by: UserPayload;
|
|
72
37
|
vendor: VendorPayload;
|
|
73
|
-
ai_summaries?: JEScheduleAISummariesPayload;
|
|
74
|
-
created_by?: UserPayload;
|
|
75
38
|
end_date?: string | null;
|
|
76
|
-
recommendations?: JEScheduleRecommendationsPayload;
|
|
77
39
|
updated_at?: string | null;
|
|
78
40
|
}
|
|
79
41
|
export interface JEAccruedScheduledTransactionPayload extends Omit<JEScheduledTransactionPayload, 'base_transaction' | 'je_schedule_id' | 'je_schedule_type'> {
|
|
@@ -146,81 +146,6 @@ function toJEScheduleOtherAttributes(payload) {
|
|
|
146
146
|
assetId: payload.asset_id ?? undefined,
|
|
147
147
|
};
|
|
148
148
|
}
|
|
149
|
-
function toJEScheduleAISummaries(payload) {
|
|
150
|
-
if (payload == null) {
|
|
151
|
-
return undefined;
|
|
152
|
-
}
|
|
153
|
-
const result = {};
|
|
154
|
-
if (payload.debit_account != null) {
|
|
155
|
-
result.debitAccount = {
|
|
156
|
-
confidence: payload.debit_account.confidence,
|
|
157
|
-
reasoning: payload.debit_account.reasoning,
|
|
158
|
-
};
|
|
159
|
-
}
|
|
160
|
-
if (payload.credit_account != null) {
|
|
161
|
-
result.creditAccount = {
|
|
162
|
-
confidence: payload.credit_account.confidence,
|
|
163
|
-
reasoning: payload.credit_account.reasoning,
|
|
164
|
-
};
|
|
165
|
-
}
|
|
166
|
-
if (payload.debit_accounting_class != null) {
|
|
167
|
-
result.debitClass = {
|
|
168
|
-
confidence: payload.debit_accounting_class.confidence,
|
|
169
|
-
reasoning: payload.debit_accounting_class.reasoning,
|
|
170
|
-
};
|
|
171
|
-
}
|
|
172
|
-
if (payload.credit_accounting_class != null) {
|
|
173
|
-
result.creditClass = {
|
|
174
|
-
confidence: payload.credit_accounting_class.confidence,
|
|
175
|
-
reasoning: payload.credit_accounting_class.reasoning,
|
|
176
|
-
};
|
|
177
|
-
}
|
|
178
|
-
if (payload.period != null) {
|
|
179
|
-
result.period = {
|
|
180
|
-
confidence: payload.period.confidence,
|
|
181
|
-
reasoning: payload.period.reasoning,
|
|
182
|
-
};
|
|
183
|
-
}
|
|
184
|
-
if (payload.posting_date != null) {
|
|
185
|
-
result.postingDate = {
|
|
186
|
-
confidence: payload.posting_date.confidence,
|
|
187
|
-
reasoning: payload.posting_date.reasoning,
|
|
188
|
-
};
|
|
189
|
-
}
|
|
190
|
-
if (payload.schedule_type != null) {
|
|
191
|
-
result.scheduleType = {
|
|
192
|
-
confidence: payload.schedule_type.confidence,
|
|
193
|
-
reasoning: payload.schedule_type.reasoning,
|
|
194
|
-
};
|
|
195
|
-
}
|
|
196
|
-
return Object.keys(result).length > 0 ? result : undefined;
|
|
197
|
-
}
|
|
198
|
-
function toJEScheduleRecommendations(payload) {
|
|
199
|
-
if (payload == null) {
|
|
200
|
-
return undefined;
|
|
201
|
-
}
|
|
202
|
-
return {
|
|
203
|
-
creditAccountConfidence: payload.credit_account_confidence,
|
|
204
|
-
creditClassConfidence: payload.credit_class_confidence,
|
|
205
|
-
debitAccountConfidence: payload.debit_account_confidence,
|
|
206
|
-
debitClassConfidence: payload.debit_class_confidence,
|
|
207
|
-
endDate: payload.end_date ?? undefined,
|
|
208
|
-
jeCreditAccountId: payload.je_credit_account_id ?? undefined,
|
|
209
|
-
jeCreditAccountingClassId: payload.je_credit_accounting_class_id ?? undefined,
|
|
210
|
-
jeDebitAccountId: payload.je_debit_account_id ?? undefined,
|
|
211
|
-
jeDebitAccountingClassId: payload.je_debit_accounting_class_id ?? undefined,
|
|
212
|
-
jeScheduleType: payload.je_schedule_type ?? undefined,
|
|
213
|
-
jeScheduleTypeConfidence: payload.je_schedule_type_confidence,
|
|
214
|
-
period: payload.period ?? undefined,
|
|
215
|
-
periodConfidence: payload.period_confidence,
|
|
216
|
-
postingDate: payload.posting_date ?? undefined,
|
|
217
|
-
postingDateConfidence: payload.posting_date_confidence,
|
|
218
|
-
similarTransactions: payload.similar_transactions,
|
|
219
|
-
startDate: payload.start_date ?? undefined,
|
|
220
|
-
startingMonth: payload.starting_month ?? undefined,
|
|
221
|
-
startingMonthConfidence: payload.starting_month_confidence,
|
|
222
|
-
};
|
|
223
|
-
}
|
|
224
149
|
function toJEScheduledTransaction(payload) {
|
|
225
150
|
return {
|
|
226
151
|
jeScheduleId: payload.je_schedule_id ?? undefined,
|
|
@@ -265,9 +190,6 @@ function toJEScheduledTransaction(payload) {
|
|
|
265
190
|
? toJEScheduleOtherAttributes(payload.other_attributes)
|
|
266
191
|
: {},
|
|
267
192
|
scheduledJournalEntry: [],
|
|
268
|
-
aiSummaries: toJEScheduleAISummaries(payload.ai_summaries),
|
|
269
|
-
createdByUserID: payload.created_by?.user_id ?? undefined,
|
|
270
|
-
recommendations: toJEScheduleRecommendations(payload.recommendations),
|
|
271
193
|
};
|
|
272
194
|
}
|
|
273
195
|
function toJEAccruedScheduledTransaction(payload) {
|
|
@@ -9,7 +9,7 @@ import { ScheduleTransaction } from '../transaction/stateTypes/scheduleTransacti
|
|
|
9
9
|
import { TransactionID } from '../transaction/stateTypes/transaction';
|
|
10
10
|
import { User } from '../user/userState';
|
|
11
11
|
import { Vendor } from '../vendor/vendorState';
|
|
12
|
-
import {
|
|
12
|
+
import { JEScheduleOtherAttributes, ScheduleJournalStatusCode, ScheduleStatus } from './jeSchedulesState';
|
|
13
13
|
import { JEScheduleKey, JEScheduleTransactionKey, JournalEntryErrorCodeType, ScheduleTypes } from './jeSchedulesTypes';
|
|
14
14
|
export interface ScheduledJournalEntry {
|
|
15
15
|
error: JournalEntryErrorCodeType[];
|
|
@@ -59,16 +59,13 @@ export interface JEScheduledTransaction {
|
|
|
59
59
|
scheduledJournalEntry: ScheduledJournalEntry[];
|
|
60
60
|
status: ScheduleStatus;
|
|
61
61
|
vendor: Vendor;
|
|
62
|
-
aiSummaries?: JEScheduleAISummaries;
|
|
63
62
|
balanceAsOfToday?: Amount;
|
|
64
|
-
createdByUser?: User;
|
|
65
63
|
dayOfPostingDate?: ScheduleDaysOfMonth;
|
|
66
64
|
endDate?: ZeniDate;
|
|
67
65
|
jeScheduleId?: ID;
|
|
68
66
|
jeScheduleType?: ScheduleTypes;
|
|
69
67
|
lastDayOfMonth?: boolean;
|
|
70
68
|
period?: number;
|
|
71
|
-
recommendations?: JEScheduleRecommendations;
|
|
72
69
|
startDate?: ZeniDate;
|
|
73
70
|
updatedAt?: ZeniDate;
|
|
74
71
|
updatedByUser?: User;
|
|
@@ -77,13 +77,12 @@ exports.getJEAccruedScheduleByJEScheduleKey = getJEAccruedScheduleByJEScheduleKe
|
|
|
77
77
|
const getJEScheduledTransactionByJEScheduleTransactionKey = (jeScheduleTransactionKey, state) => {
|
|
78
78
|
const { jeSchedulesState, vendorState, accountState, userState, classState, transactionState, } = state;
|
|
79
79
|
const jeScheduleTransactionState = (0, get_1.default)(jeSchedulesState.schedulesByTransactionKey, jeScheduleTransactionKey);
|
|
80
|
-
const { period, updatedByUserID: updatedBy,
|
|
80
|
+
const { period, updatedByUserID: updatedBy, vendorId, jeCredit, jeDebit, currencyCode, currencySymbol, balanceAsOfToday, baseTransaction, startDate, endDate, status, updatedAt, jeScheduleId, scheduledJournalEntry, dayOfPostingDate: postingDate, lastDayOfMonth, otherAttributes, jeScheduleType, } = jeScheduleTransactionState;
|
|
81
81
|
const vendorDetails = (0, vendorSelector_1.getVendorByVendorId)(vendorState, vendorId);
|
|
82
82
|
if (vendorDetails == null) {
|
|
83
83
|
throw new Error(`Vendor with ${vendorId} doesn't exist`);
|
|
84
84
|
}
|
|
85
85
|
const userDetails = updatedBy != null ? (0, userSelector_1.getUserByUserId)(userState, updatedBy) : undefined;
|
|
86
|
-
const createdByUserDetails = createdBy != null ? (0, userSelector_1.getUserByUserId)(userState, createdBy) : undefined;
|
|
87
86
|
const baseTransactionObject = (0, transactionSelector_1.getScheduleTransactionById)(transactionState, baseTransaction);
|
|
88
87
|
if (baseTransactionObject == null) {
|
|
89
88
|
throw Error('Base Schedule transaction cannot be null');
|
|
@@ -135,9 +134,6 @@ const getJEScheduledTransactionByJEScheduleTransactionKey = (jeScheduleTransacti
|
|
|
135
134
|
account: accountDebit,
|
|
136
135
|
},
|
|
137
136
|
scheduledJournalEntry,
|
|
138
|
-
aiSummaries,
|
|
139
|
-
createdByUser: createdByUserDetails,
|
|
140
|
-
recommendations,
|
|
141
137
|
};
|
|
142
138
|
};
|
|
143
139
|
exports.getJEScheduledTransactionByJEScheduleTransactionKey = getJEScheduledTransactionByJEScheduleTransactionKey;
|
|
@@ -12,40 +12,6 @@ export interface ScheduleJournalStatusCode {
|
|
|
12
12
|
code: ScheduleJournalEntryStatusCodeType;
|
|
13
13
|
label: string;
|
|
14
14
|
}
|
|
15
|
-
export interface JEScheduleFieldRecommendation {
|
|
16
|
-
confidence: number;
|
|
17
|
-
reasoning: string;
|
|
18
|
-
}
|
|
19
|
-
export interface JEScheduleAISummaries {
|
|
20
|
-
creditAccount?: JEScheduleFieldRecommendation;
|
|
21
|
-
creditClass?: JEScheduleFieldRecommendation;
|
|
22
|
-
debitAccount?: JEScheduleFieldRecommendation;
|
|
23
|
-
debitClass?: JEScheduleFieldRecommendation;
|
|
24
|
-
period?: JEScheduleFieldRecommendation;
|
|
25
|
-
postingDate?: JEScheduleFieldRecommendation;
|
|
26
|
-
scheduleType?: JEScheduleFieldRecommendation;
|
|
27
|
-
}
|
|
28
|
-
export interface JEScheduleRecommendations {
|
|
29
|
-
creditAccountConfidence?: number;
|
|
30
|
-
creditClassConfidence?: number;
|
|
31
|
-
debitAccountConfidence?: number;
|
|
32
|
-
debitClassConfidence?: number;
|
|
33
|
-
endDate?: string;
|
|
34
|
-
jeCreditAccountId?: string;
|
|
35
|
-
jeCreditAccountingClassId?: string;
|
|
36
|
-
jeDebitAccountId?: string;
|
|
37
|
-
jeDebitAccountingClassId?: string;
|
|
38
|
-
jeScheduleType?: string;
|
|
39
|
-
jeScheduleTypeConfidence?: number;
|
|
40
|
-
period?: number;
|
|
41
|
-
periodConfidence?: number;
|
|
42
|
-
postingDate?: string;
|
|
43
|
-
postingDateConfidence?: number;
|
|
44
|
-
similarTransactions?: unknown[];
|
|
45
|
-
startDate?: string;
|
|
46
|
-
startingMonth?: string;
|
|
47
|
-
startingMonthConfidence?: number;
|
|
48
|
-
}
|
|
49
15
|
export interface JEScheduleOtherAttributes {
|
|
50
16
|
assetId?: string;
|
|
51
17
|
startingBalance?: Amount;
|
|
@@ -90,16 +56,13 @@ export interface JEScheduledTransactionState {
|
|
|
90
56
|
scheduledJournalEntry: ScheduledJournalEntryState[];
|
|
91
57
|
status: ScheduleStatus;
|
|
92
58
|
vendorId: ID;
|
|
93
|
-
aiSummaries?: JEScheduleAISummaries;
|
|
94
59
|
balanceAsOfToday?: number;
|
|
95
|
-
createdByUserID?: ID;
|
|
96
60
|
dayOfPostingDate?: ScheduleDaysOfMonth;
|
|
97
61
|
endDate?: ZeniDate;
|
|
98
62
|
jeScheduleId?: ID;
|
|
99
63
|
jeScheduleType?: ScheduleTypes;
|
|
100
64
|
lastDayOfMonth?: boolean;
|
|
101
65
|
period?: number;
|
|
102
|
-
recommendations?: JEScheduleRecommendations;
|
|
103
66
|
startDate?: ZeniDate;
|
|
104
67
|
updatedAt?: ZeniDate;
|
|
105
68
|
updatedByUserID?: ID;
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
export declare const toSnackbarMessageSection: (v: string) => "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" | "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" | "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" | "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";
|
|
1
|
+
export declare const toSnackbarMessageSection: (v: string) => "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" | "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" | "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";
|
|
2
2
|
export type SnackbarMessageSections = ReturnType<typeof toSnackbarMessageSection>;
|
|
3
3
|
export declare const toSnackbarMessageSectionTexts: (v: string) => "notification" | "success" | "failed";
|
|
4
4
|
export type SnackbarMessageSectionTexts = ReturnType<typeof toSnackbarMessageSectionTexts>;
|
|
@@ -9,6 +9,7 @@ export interface TaskPayload {
|
|
|
9
9
|
file_ids: string[];
|
|
10
10
|
is_archived: boolean;
|
|
11
11
|
is_deleted: boolean;
|
|
12
|
+
is_private: boolean;
|
|
12
13
|
name: string;
|
|
13
14
|
priority: AllowedValueWithCodePayload;
|
|
14
15
|
recurring_end_date: string | null;
|
|
@@ -22,6 +23,8 @@ export interface TaskPayload {
|
|
|
22
23
|
update_time: string | null;
|
|
23
24
|
company_id?: string;
|
|
24
25
|
group_assignees?: string[];
|
|
26
|
+
recurring_source_task_id?: string | null;
|
|
27
|
+
snoozed_until?: string | null;
|
|
25
28
|
sync_token?: string | null;
|
|
26
29
|
task_group_ids?: string[] | null;
|
|
27
30
|
}
|
|
@@ -13,6 +13,7 @@ const mapTaskPayloadToTask = (payload) => ({
|
|
|
13
13
|
fileIds: payload.file_ids,
|
|
14
14
|
isArchived: payload.is_archived,
|
|
15
15
|
isDeleted: payload.is_deleted,
|
|
16
|
+
isPrivate: payload.is_private,
|
|
16
17
|
name: payload.name,
|
|
17
18
|
syncToken: payload.sync_token ?? '',
|
|
18
19
|
priority: {
|
|
@@ -31,12 +32,16 @@ const mapTaskPayloadToTask = (payload) => ({
|
|
|
31
32
|
recurringFrequency: payload.recurring_frequency != null
|
|
32
33
|
? (0, recurringViewHelper_1.toRecurringFrequencyStrict)(payload.recurring_frequency.code)
|
|
33
34
|
: undefined,
|
|
35
|
+
recurringSourceTaskId: payload.recurring_source_task_id != null
|
|
36
|
+
? payload.recurring_source_task_id
|
|
37
|
+
: undefined,
|
|
34
38
|
recurringStartDate: payload.recurring_start_date != null
|
|
35
39
|
? (0, zeniDayJS_1.date)(payload.recurring_start_date)
|
|
36
40
|
: undefined,
|
|
37
41
|
createTime: (0, zeniDayJS_1.date)(payload.create_time),
|
|
38
42
|
dueDate: payload.due_date != null ? (0, zeniDayJS_1.date)(payload.due_date) : undefined,
|
|
39
43
|
updateTime: payload.update_time != null ? (0, zeniDayJS_1.date)(payload.update_time) : undefined,
|
|
44
|
+
snoozedUntil: payload.snoozed_until != null ? (0, zeniDayJS_1.date)(payload.snoozed_until) : undefined,
|
|
40
45
|
companyId: payload.company_id,
|
|
41
46
|
taskGroupIds: payload.task_group_ids != null ? payload.task_group_ids : [],
|
|
42
47
|
timeSpent: payload.time_spent != null
|
|
@@ -11,6 +11,7 @@ export interface Task {
|
|
|
11
11
|
id: ID;
|
|
12
12
|
isArchived: boolean;
|
|
13
13
|
isDeleted: boolean;
|
|
14
|
+
isPrivate: boolean;
|
|
14
15
|
name: string;
|
|
15
16
|
priority: TaskPriority;
|
|
16
17
|
status: TaskStatus;
|
|
@@ -23,7 +24,9 @@ export interface Task {
|
|
|
23
24
|
dueDate?: ZeniDate;
|
|
24
25
|
recurringEndDate?: ZeniDate;
|
|
25
26
|
recurringFrequency?: RecurringFrequencyType;
|
|
27
|
+
recurringSourceTaskId?: ID;
|
|
26
28
|
recurringStartDate?: ZeniDate;
|
|
29
|
+
snoozedUntil?: ZeniDate;
|
|
27
30
|
updateTime?: ZeniDate;
|
|
28
31
|
}
|
|
29
32
|
export interface TaskState {
|
|
@@ -561,7 +561,6 @@ function mapTenantsPayloadToState(tenantsPayload, userTenantPayload) {
|
|
|
561
561
|
function mapTenantPayloadToTenant(payload, userTenantPayload) {
|
|
562
562
|
const tenant = {
|
|
563
563
|
accountingClassIDs: payload.accounting_class_ids,
|
|
564
|
-
isAccountingClassesEnabled: payload.is_accounting_classes_enabled ?? true,
|
|
565
564
|
bookCloseDate: payload.book_close_date != null
|
|
566
565
|
? (0, zeniDayJS_1.date)(payload.book_close_date)
|
|
567
566
|
: undefined,
|
|
@@ -85,7 +85,6 @@ export declare const getCurrentTenantExternalConnections: (tenantState: TenantSt
|
|
|
85
85
|
export declare const toTenantCoreDetailsView: (tenantsBaseView: TenantBaseView[]) => TenantCoreDetailsView[];
|
|
86
86
|
export declare const isTenantBankingOnly: (isDebitCardFlagEnabled: boolean, tenant: Tenant | undefined) => boolean;
|
|
87
87
|
export declare const isTenantCardsOnly: (tenant: Tenant | undefined) => boolean;
|
|
88
|
-
export declare const getIsAccountingClassesEnabled: (state: RootState) => boolean;
|
|
89
88
|
export declare const isTenantBookkeepingEnabled: (tenant: Tenant | undefined) => boolean;
|
|
90
89
|
export declare const isOtherProductsEnabledForTenant: (tenant: Tenant | undefined) => boolean;
|
|
91
90
|
export declare const isTenantTreasuryEnabled: (tenant: Tenant | undefined) => boolean;
|
|
@@ -3,7 +3,7 @@ var __importDefault = (this && this.__importDefault) || function (mod) {
|
|
|
3
3
|
return (mod && mod.__esModule) ? mod : { "default": mod };
|
|
4
4
|
};
|
|
5
5
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
6
|
-
exports.isTenantTreasuryEnabled = exports.isOtherProductsEnabledForTenant = exports.isTenantBookkeepingEnabled = exports.
|
|
6
|
+
exports.isTenantTreasuryEnabled = exports.isOtherProductsEnabledForTenant = exports.isTenantBookkeepingEnabled = exports.isTenantCardsOnly = exports.isTenantBankingOnly = exports.toTenantCoreDetailsView = exports.getCurrentTenantExternalConnections = exports.isTenantUsingZeniCOA = exports.isZeniDomainTenant = exports.getTenantBaseViewForTenantView = exports.getTenantsCoreDetailsByCheckInDateSelector = exports.getTenantsBaseByCheckInDateSelector = exports.getTenantBaseById = exports.getTenantsByCheckInDateSelector = exports.getCurrentTenant = exports.getTenantBaseViewForTenantId = void 0;
|
|
7
7
|
exports.getTenant = getTenant;
|
|
8
8
|
exports.getOnboardingTenantByTenantId = getOnboardingTenantByTenantId;
|
|
9
9
|
const toolkit_1 = require("@reduxjs/toolkit");
|
|
@@ -280,14 +280,6 @@ const isTenantCardsOnly = (tenant) => {
|
|
|
280
280
|
: false;
|
|
281
281
|
};
|
|
282
282
|
exports.isTenantCardsOnly = isTenantCardsOnly;
|
|
283
|
-
const getIsAccountingClassesEnabled = (state) => {
|
|
284
|
-
const { currentTenantId, tenantsById } = state.tenantState;
|
|
285
|
-
if (currentTenantId == null) {
|
|
286
|
-
return true;
|
|
287
|
-
}
|
|
288
|
-
return tenantsById[currentTenantId]?.isAccountingClassesEnabled ?? true;
|
|
289
|
-
};
|
|
290
|
-
exports.getIsAccountingClassesEnabled = getIsAccountingClassesEnabled;
|
|
291
283
|
const isTenantBookkeepingEnabled = (tenant) => {
|
|
292
284
|
// if the tenants API takes time, tenant can be non null with productSettings as null
|
|
293
285
|
return tenant != null && tenant.productSettings != null
|
|
@@ -2,15 +2,12 @@ import { AccountBasePayload } from '../../account/accountPayload';
|
|
|
2
2
|
import { ClassBasePayload } from '../../class/classPayload';
|
|
3
3
|
import { ScheduleTransaction } from '../stateTypes/scheduleTransaction';
|
|
4
4
|
import { TransactionIDPayload } from './transactionIDPayload';
|
|
5
|
-
export interface ScheduleTransactionPayload extends TransactionIDPayload, Omit<AccountBasePayload, 'qbo_id'
|
|
5
|
+
export interface ScheduleTransactionPayload extends TransactionIDPayload, Omit<AccountBasePayload, 'qbo_id'>, Omit<ClassBasePayload, 'qbo_id' | 'labels'> {
|
|
6
6
|
line_id: string;
|
|
7
7
|
third_party_transaction_id: string;
|
|
8
8
|
total_amount: number;
|
|
9
9
|
transaction_date: string;
|
|
10
10
|
transaction_memo: string;
|
|
11
11
|
transaction_type_name: string;
|
|
12
|
-
labels?: string[];
|
|
13
|
-
sync_token?: number;
|
|
14
|
-
transaction_description?: string | null;
|
|
15
12
|
}
|
|
16
13
|
export declare const toScheduleTransaction: (payload: ScheduleTransactionPayload, currency_code: string, currency_symbol: string) => ScheduleTransaction;
|
|
@@ -32,7 +32,6 @@ const toScheduleTransaction = (payload, currency_code, currency_symbol) => {
|
|
|
32
32
|
currencyCode: currency_code,
|
|
33
33
|
currencySymbol: currency_symbol,
|
|
34
34
|
},
|
|
35
|
-
description: payload.transaction_description ?? undefined,
|
|
36
35
|
};
|
|
37
36
|
};
|
|
38
37
|
exports.toScheduleTransaction = toScheduleTransaction;
|
|
@@ -33,9 +33,6 @@ export interface TransactionPayload extends TransactionIDPayload, AccountBasePay
|
|
|
33
33
|
recipient_total_amount?: number;
|
|
34
34
|
recommendations?: RecommendationPayload[];
|
|
35
35
|
sync_token?: string;
|
|
36
|
-
target_account_id?: string | null;
|
|
37
|
-
target_account_integration_id?: string | null;
|
|
38
|
-
target_account_name?: string | null;
|
|
39
36
|
total_amount?: number;
|
|
40
37
|
transaction_type_name?: string;
|
|
41
38
|
transaction_update_time?: string;
|
|
@@ -37,9 +37,6 @@ const getTransactionPayloadRecipientAmount = (payload) => {
|
|
|
37
37
|
const toTransaction = (payload) => {
|
|
38
38
|
const amount = (0, exports.getTransactionPayloadAmount)(payload);
|
|
39
39
|
const recipientAmount = getTransactionPayloadRecipientAmount(payload);
|
|
40
|
-
const lines = payload?.lines?.map((linePayload) => (0, transactionLinePayload_1.toLine)(linePayload, amount, recipientAmount));
|
|
41
|
-
const firstLineWithClass = lines?.find((line) => 'class' in line &&
|
|
42
|
-
line.class?.classId != null);
|
|
43
40
|
return {
|
|
44
41
|
...(0, transactionIDPayload_1.toTransactionID)(payload),
|
|
45
42
|
typeOfTransaction: 'supported',
|
|
@@ -68,24 +65,11 @@ const toTransaction = (payload) => {
|
|
|
68
65
|
...(payload.customer_name !== null && payload.customer_name !== ''
|
|
69
66
|
? { customerName: payload.customer_name }
|
|
70
67
|
: {}),
|
|
71
|
-
...(payload.target_account_id !== null && payload.target_account_id !== ''
|
|
72
|
-
? { targetAccountId: payload.target_account_id }
|
|
73
|
-
: {}),
|
|
74
|
-
...(payload.target_account_integration_id !== null &&
|
|
75
|
-
payload.target_account_integration_id !== ''
|
|
76
|
-
? { targetAccountIntegrationId: payload.target_account_integration_id }
|
|
77
|
-
: {}),
|
|
78
|
-
...(payload.target_account_name !== null &&
|
|
79
|
-
payload.target_account_name !== ''
|
|
80
|
-
? { targetAccountName: payload.target_account_name }
|
|
81
|
-
: {}),
|
|
82
68
|
linkedTransactions: payload.linked_transactions?.map((transactionIDPayload) => (0, transactionIDPayload_1.toTransactionID)(transactionIDPayload)),
|
|
83
|
-
lines,
|
|
69
|
+
lines: payload?.lines?.map((linePayload) => (0, transactionLinePayload_1.toLine)(linePayload, amount, recipientAmount)),
|
|
84
70
|
account: payloadHasAccountInfo(payload)
|
|
85
71
|
? (0, accountPayload_1.mapAccountBasePayloadToAccountBase)(payload)
|
|
86
72
|
: undefined,
|
|
87
|
-
classId: firstLineWithClass?.class?.classId,
|
|
88
|
-
className: firstLineWithClass?.class?.className,
|
|
89
73
|
syncToken: payload.sync_token?.toString(),
|
|
90
74
|
paymentType: payload.payment_type ?? undefined,
|
|
91
75
|
paymentTypeName: payload.payment_type_name ?? undefined,
|
|
@@ -27,8 +27,6 @@ export interface Transaction extends BaseTransaction {
|
|
|
27
27
|
isUpdatingTransaction: boolean;
|
|
28
28
|
attachments?: Attachment[];
|
|
29
29
|
bookCloseDate?: ZeniDate;
|
|
30
|
-
classId?: ID;
|
|
31
|
-
className?: string;
|
|
32
30
|
companyIncDate?: ZeniDate;
|
|
33
31
|
customerId?: ID;
|
|
34
32
|
customerName?: string;
|
|
@@ -42,9 +40,6 @@ export interface Transaction extends BaseTransaction {
|
|
|
42
40
|
qboId?: string;
|
|
43
41
|
recommendations?: RecommendationByLineId;
|
|
44
42
|
syncToken?: string;
|
|
45
|
-
targetAccountId?: ID;
|
|
46
|
-
targetAccountIntegrationId?: string;
|
|
47
|
-
targetAccountName?: string;
|
|
48
43
|
updateTime?: ZeniDate;
|
|
49
44
|
vendorId?: ID;
|
|
50
45
|
vendorName?: string;
|
|
@@ -35,9 +35,9 @@ export interface LinkedTransactionLine extends TransactionLineBase {
|
|
|
35
35
|
export interface TransactionWithAccountAndClassLine extends TransactionLineBase {
|
|
36
36
|
account: AccountBase;
|
|
37
37
|
billable: BillableStatus;
|
|
38
|
+
class: ClassBase;
|
|
38
39
|
isCategoryMiscategorized: boolean;
|
|
39
40
|
isClassMiscategorized: boolean;
|
|
40
|
-
class?: ClassBase;
|
|
41
41
|
customer?: CustomerBase;
|
|
42
42
|
vendor?: VendorBase;
|
|
43
43
|
}
|