@zeniai/client-epic-state 5.1.40-betaDI2 → 5.1.41-beta0ND
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/selectorTypes/pickAndMergeForecastCalculatedSection.d.ts +1 -1
- package/lib/entity/account/accountSelector.d.ts +6 -6
- package/lib/entity/account/pickAndMergeForecastAccountReport.d.ts +18 -18
- package/lib/entity/accountGroup/accountGroupSelector.d.ts +44 -44
- package/lib/entity/snackbar/snackbarTypes.d.ts +1 -1
- package/lib/entity/snackbar/snackbarTypes.js +1 -1
- package/lib/entity/task/taskPayload.d.ts +1 -2
- package/lib/entity/task/taskPayload.js +1 -8
- package/lib/entity/task/taskReducer.d.ts +1 -8
- package/lib/entity/task/taskReducer.js +4 -29
- package/lib/entity/task/taskState.d.ts +0 -1
- package/lib/entity/tenant/epic/saveExternalConnectionEpic.js +15 -7
- package/lib/entity/toastNotification/epic/pushToastNotificationEpic.d.ts +3 -3
- package/lib/epic.d.ts +3 -5
- package/lib/epic.js +3 -5
- package/lib/esm/entity/snackbar/snackbarTypes.js +1 -1
- package/lib/esm/entity/task/taskPayload.js +1 -8
- package/lib/esm/entity/task/taskReducer.js +3 -28
- package/lib/esm/entity/tenant/epic/saveExternalConnectionEpic.js +15 -7
- package/lib/esm/epic.js +3 -5
- package/lib/esm/view/companyTaskManagerView/epics/fetchCompanyTaskManagerViewEpic.js +0 -3
- package/lib/esm/view/companyTaskManagerView/epics/fetchTaskManagerMetricsEpic.js +1 -7
- package/lib/esm/view/expenseAutomationView/epics/transactionCategorization/fetchTransactionCategorizationViewEpic.js +3 -2
- package/lib/esm/view/taskManager/taskDetailView/epics/initializeTaskToLocalStoreEpic.js +0 -1
- package/lib/esm/view/taskManager/taskDetailView/epics/saveTaskDetailEpic.js +9 -70
- package/lib/esm/view/taskManager/taskDetailView/taskDetailReducer.js +2 -56
- package/lib/esm/view/taskManager/taskDetailView/taskDetailSelector.js +9 -32
- package/lib/esm/view/taskManager/taskListView/epics/fetchTaskListEpic.js +1 -3
- package/lib/esm/view/taskManager/taskListView/taskList.js +0 -1
- package/lib/esm/view/taskManager/taskListView/taskListReducer.js +12 -240
- package/lib/esm/view/taskManager/taskListView/taskListSelector.js +0 -1
- package/lib/view/addressView/epic/fetchAddressEpic.d.ts +1 -1
- package/lib/view/addressView/epic/updateAddressEpic.d.ts +1 -1
- package/lib/view/aiAccountantView/epics/cancelAiAccountantOnboardingEpic.d.ts +3 -3
- package/lib/view/aiAccountantView/epics/fetchAiAccountantCustomersEpic.d.ts +2 -2
- package/lib/view/aiAccountantView/epics/fetchAiAccountantJobsEpic.d.ts +3 -3
- package/lib/view/aiAccountantView/epics/triggerAiAccountantJobEpic.d.ts +3 -3
- package/lib/view/aiCfoView/epics/deleteChatSessionEpic.d.ts +5 -5
- package/lib/view/auditReportView/auditReportViewSelector.d.ts +1 -1
- package/lib/view/billPayCard/billPayCardSelector.d.ts +3 -3
- package/lib/view/cardBalance/cardBalanceEpic.d.ts +2 -2
- package/lib/view/cardBalance/cardBalanceSelector.d.ts +8 -8
- package/lib/view/cardBalance/statementCloseDayEpic.d.ts +3 -3
- package/lib/view/cardPayment/epic/addCardPaymentSourceEpic.d.ts +4 -4
- package/lib/view/cardPayment/epic/confirmCardSetupIntentEpic.d.ts +4 -4
- package/lib/view/cardPayment/epic/createCardSetupIntentEpic.d.ts +5 -5
- package/lib/view/cardPayment/epic/fetchPaymentSourcesEpic.d.ts +5 -5
- package/lib/view/cashBalance/cashBalanceEpic.d.ts +2 -2
- package/lib/view/cashBalance/cashBalanceSelector.d.ts +8 -8
- package/lib/view/cashInCashOut/cashInCashOutEpic.d.ts +5 -5
- package/lib/view/cashInCashOut/cashInCashOutSelector.d.ts +5 -5
- package/lib/view/cashPosition/cashPositionEpic.d.ts +3 -3
- package/lib/view/cashPosition/cashPositionSelector.d.ts +5 -5
- package/lib/view/companyConfigView/companyConfigSelector.d.ts +2 -2
- package/lib/view/companyTaskManagerView/epics/fetchCompanyTaskManagerViewEpic.js +0 -3
- package/lib/view/companyTaskManagerView/epics/fetchTaskManagerMetricsEpic.js +1 -7
- package/lib/view/companyView/epic/companyPassport/saveCompanyPassportDetailsEpic.d.ts +1 -1
- package/lib/view/companyView/types/cockpitTypes.d.ts +0 -3
- package/lib/view/createTransferEntry/createTransferEntrySelector.d.ts +1 -1
- package/lib/view/creditAgentView/epics/saveCreditAgentMacroEpic.d.ts +3 -3
- package/lib/view/creditAgentView/epics/scheduleTenantCreditScoreCronEpic.d.ts +3 -3
- package/lib/view/creditAgentView/epics/updateCardProfileEpic.d.ts +3 -3
- package/lib/view/expenseAutomationView/epics/accountRecon/reparseStatementEpic.d.ts +4 -4
- package/lib/view/expenseAutomationView/epics/accountRecon/updateStatementInfoEpic.d.ts +3 -3
- package/lib/view/expenseAutomationView/epics/accountRecon/uploadAccountStatementEpic.d.ts +1 -1
- package/lib/view/expenseAutomationView/epics/missingReceipts/bulkUploadReceiptsEpic.d.ts +1 -1
- package/lib/view/expenseAutomationView/epics/transactionCategorization/fetchTransactionCategorizationViewEpic.js +3 -2
- package/lib/view/expenseAutomationView/helpers/transactionCategorizationLocalDataHelper.d.ts +1 -1
- package/lib/view/forecastList/forecastListSelector.d.ts +4 -4
- package/lib/view/insightsCard/insightsCardEpic.d.ts +1 -1
- package/lib/view/people/changeZeniPersonRolesEpic.d.ts +5 -5
- package/lib/view/people/deletePersonEpic.d.ts +4 -4
- package/lib/view/people/fetchPeopleEpic.d.ts +2 -2
- package/lib/view/people/invitePeopleEpic.d.ts +7 -7
- package/lib/view/people/inviteZeniPeopleEpic.d.ts +7 -7
- package/lib/view/people/resendInviteEpic.d.ts +3 -3
- package/lib/view/reimbursementCard/reimbursementCardSelector.d.ts +3 -3
- package/lib/view/reportUIOptions/updateReportUIOptionCOABalancesRangeEpic.d.ts +11 -11
- package/lib/view/reportUIOptions/updateReportUIOptionCompareModeEpic.d.ts +8 -8
- package/lib/view/reportUIOptions/updateReportUIOptionThisPeriodEpic.d.ts +8 -8
- package/lib/view/settingsView/epic/fetchBankAccountsListEpic.d.ts +3 -3
- package/lib/view/settingsView/epic/saveNotificationSettingsEpic.d.ts +3 -3
- package/lib/view/spendManagement/billPay/magicLinkView/magicLinkViewSelector.d.ts +2 -2
- package/lib/view/spendManagement/commonSetup/epic/setup/parseUploadedKybDocumentEpic.d.ts +4 -4
- package/lib/view/spendManagement/helpers.d.ts +1 -1
- package/lib/view/spendManagement/reimbursement/editRemiView/epics/fetchRecommendationsAndUpdateMerchantRecommendationsEpic.d.ts +3 -3
- package/lib/view/tagView/epics/createTagEpic.d.ts +3 -3
- package/lib/view/tagView/epics/deleteTagEpic.d.ts +7 -7
- package/lib/view/taskManager/taskDetailView/epics/initializeTaskToLocalStoreEpic.js +0 -1
- package/lib/view/taskManager/taskDetailView/epics/saveTaskDetailEpic.d.ts +2 -2
- package/lib/view/taskManager/taskDetailView/epics/saveTaskDetailEpic.js +8 -69
- package/lib/view/taskManager/taskDetailView/taskDetail.d.ts +0 -15
- package/lib/view/taskManager/taskDetailView/taskDetailReducer.d.ts +2 -14
- package/lib/view/taskManager/taskDetailView/taskDetailReducer.js +3 -57
- package/lib/view/taskManager/taskDetailView/taskDetailSelector.d.ts +1 -2
- package/lib/view/taskManager/taskDetailView/taskDetailSelector.js +7 -30
- package/lib/view/taskManager/taskListView/epics/fetchTaskListEpic.js +1 -3
- package/lib/view/taskManager/taskListView/taskList.d.ts +1 -1
- package/lib/view/taskManager/taskListView/taskList.js +0 -1
- package/lib/view/taskManager/taskListView/taskListPayload.d.ts +0 -4
- package/lib/view/taskManager/taskListView/taskListReducer.d.ts +2 -6
- package/lib/view/taskManager/taskListView/taskListReducer.js +13 -241
- package/lib/view/taskManager/taskListView/taskListSelector.js +0 -1
- package/lib/view/tasksCard/tasksCardSelector.d.ts +2 -2
- package/lib/view/topEx/topExEpic.d.ts +2 -2
- package/lib/view/topEx/topExSelector.d.ts +7 -7
- package/lib/view/transactionDetail/epics/uploadMissingAttachmentSuccessEpic.d.ts +5 -5
- package/lib/view/transactionDetail/transactionDetailLocalDataHelper.d.ts +1 -1
- package/lib/view/userRoleConfigView/userRoleConfigSelector.d.ts +2 -2
- package/lib/view/zeniOAuthView/epics/approveOAuthConsentEpic.d.ts +3 -3
- package/package.json +1 -1
- package/lib/esm/index.js +0 -711
- package/lib/esm/view/taskManager/taskDetailView/epics/createSubTaskEpic.js +0 -96
- package/lib/esm/view/taskManager/taskDetailView/epics/fetchSubTasksEpic.js +0 -53
- package/lib/index.d.ts +0 -995
- package/lib/index.js +0 -2611
- package/lib/view/taskManager/taskDetailView/epics/createSubTaskEpic.d.ts +0 -9
- package/lib/view/taskManager/taskDetailView/epics/createSubTaskEpic.js +0 -100
- package/lib/view/taskManager/taskDetailView/epics/fetchSubTasksEpic.d.ts +0 -8
- package/lib/view/taskManager/taskDetailView/epics/fetchSubTasksEpic.js +0 -57
|
@@ -1,5 +1,4 @@
|
|
|
1
1
|
import { createSlice } from '@reduxjs/toolkit';
|
|
2
|
-
import { updateTasks } from '../../../entity/task/taskReducer';
|
|
3
2
|
import { toPriorityCodeType, toTaskStatusCodeType, } from '../../../entity/task/taskState';
|
|
4
3
|
import { date, dateNow } from '../../../zeniDayJS';
|
|
5
4
|
import { toDueDateGroupKeyType, } from './taskList';
|
|
@@ -43,7 +42,6 @@ export const initialState = {
|
|
|
43
42
|
currentTab: 'live',
|
|
44
43
|
byTab: {
|
|
45
44
|
live: { ...initialTabData },
|
|
46
|
-
completed: { ...initialTabData },
|
|
47
45
|
archived: { ...initialTabData },
|
|
48
46
|
deleted: { ...initialTabData },
|
|
49
47
|
snoozed: { ...initialTabData },
|
|
@@ -65,12 +63,14 @@ export const initialState = {
|
|
|
65
63
|
},
|
|
66
64
|
filters: {
|
|
67
65
|
categoryCombinationOperator: 'AND',
|
|
68
|
-
|
|
69
|
-
|
|
70
|
-
|
|
71
|
-
|
|
72
|
-
|
|
73
|
-
|
|
66
|
+
categories: [
|
|
67
|
+
{
|
|
68
|
+
field: 'status',
|
|
69
|
+
matchingOperator: 'not_equal',
|
|
70
|
+
values: ['resolved'],
|
|
71
|
+
valuesCombinationOperator: 'ANY',
|
|
72
|
+
},
|
|
73
|
+
],
|
|
74
74
|
},
|
|
75
75
|
hasValidState() {
|
|
76
76
|
return this.fetchState == 'Completed';
|
|
@@ -102,16 +102,13 @@ const taskList = createSlice({
|
|
|
102
102
|
draft.error = undefined;
|
|
103
103
|
},
|
|
104
104
|
updateTaskList(draft, action) {
|
|
105
|
-
const { data, archived,
|
|
105
|
+
const { data, archived, deleted, snoozed } = action.payload;
|
|
106
106
|
draft.fetchState = 'Completed';
|
|
107
107
|
draft.error = undefined;
|
|
108
108
|
// Group live tasks
|
|
109
109
|
const liveGrouped = getGroupedTaskIds(data);
|
|
110
110
|
draft.byTab.live = toTabData(liveGrouped);
|
|
111
111
|
// Group other tabs if provided
|
|
112
|
-
if (completed != null) {
|
|
113
|
-
draft.byTab.completed = toTabData(getGroupedTaskIds(completed));
|
|
114
|
-
}
|
|
115
112
|
if (archived != null) {
|
|
116
113
|
draft.byTab.archived = toTabData(getGroupedTaskIds(archived));
|
|
117
114
|
}
|
|
@@ -357,26 +354,9 @@ const taskList = createSlice({
|
|
|
357
354
|
draft.taskIdsByAssignees[assigneeKey] = draft.taskIdsByAssignees[assigneeKey].filter((taskId) => taskId !== currentTaskState.id);
|
|
358
355
|
draft.taskIdsByTags[tagsKey] = draft.taskIdsByTags[tagsKey].filter((taskId) => taskId !== currentTaskState.id);
|
|
359
356
|
draft.taskIdsByDueDate[dueDateKey] = draft.taskIdsByDueDate[dueDateKey].filter((taskId) => taskId !== currentTaskState.id);
|
|
360
|
-
|
|
361
|
-
// just the destination bucket. Otherwise a detail-page save that
|
|
362
|
-
// moves a task from group A to group B leaves the row listed
|
|
363
|
-
// under both A and B until refetch.
|
|
364
|
-
const previousGroupIds = currentTaskState.taskGroupIds ?? [];
|
|
365
|
-
const allGroupIdsToClean = new Set([
|
|
366
|
-
...previousGroupIds,
|
|
367
|
-
taskGroupId,
|
|
368
|
-
]);
|
|
369
|
-
allGroupIdsToClean.forEach((gid) => {
|
|
370
|
-
if (draft.taskIdsByGroupsIds[gid] != null) {
|
|
371
|
-
draft.taskIdsByGroupsIds[gid] = draft.taskIdsByGroupsIds[gid].filter((id) => id !== currentTaskState.id);
|
|
372
|
-
}
|
|
373
|
-
});
|
|
357
|
+
draft.taskIdsByGroupsIds[taskGroupId] = draft.taskIdsByGroupsIds[taskGroupId].filter((taskId) => taskId !== currentTaskState.id);
|
|
374
358
|
}
|
|
375
359
|
doUpdateTaskList(draft, task, taskGroupId);
|
|
376
|
-
// Mirror top-level grouping into the active tab's byTab snapshot,
|
|
377
|
-
// otherwise the next updateTaskListTab call copies stale byTab data
|
|
378
|
-
// back over this optimistic update.
|
|
379
|
-
syncTopLevelToActiveTab(draft);
|
|
380
360
|
},
|
|
381
361
|
updateTaskListOnCreateTaskFromTemplateSuccess(draft, action) {
|
|
382
362
|
const { tasks } = action.payload;
|
|
@@ -400,7 +380,6 @@ const taskList = createSlice({
|
|
|
400
380
|
const taskId = task.id;
|
|
401
381
|
draft.updateTasksFetchState.fetchState = 'In-Progress';
|
|
402
382
|
draft.updateTasksFetchState.error = undefined;
|
|
403
|
-
let didMigrateTab = false;
|
|
404
383
|
if (updates.priority != null) {
|
|
405
384
|
const prevPriorityCode = toPriorityCodeType(task.priority.code);
|
|
406
385
|
draft.taskIdsByPriority[prevPriorityCode] = draft.taskIdsByPriority[prevPriorityCode].filter((id) => id != taskId);
|
|
@@ -412,25 +391,6 @@ const taskList = createSlice({
|
|
|
412
391
|
draft.taskIdsByStatus[prevStatusCode] = draft.taskIdsByStatus[prevStatusCode].filter((id) => id != taskId);
|
|
413
392
|
const newStatusCode = toTaskStatusCodeType(updates.status.code);
|
|
414
393
|
draft.taskIdsByStatus[newStatusCode].push(taskId);
|
|
415
|
-
// Optimistically re-bucket between the live and completed tabs
|
|
416
|
-
// when status transitions in/out of "resolved", so the task
|
|
417
|
-
// moves to the Completed tab without waiting for the next
|
|
418
|
-
// fetch. Mirrors backend split in task_handler.py: only
|
|
419
|
-
// `resolved` counts as completed; `done` stays Active.
|
|
420
|
-
//
|
|
421
|
-
// Subtasks travel with their parent — they appear nested under
|
|
422
|
-
// the parent row, not as standalone entries in byTab.taskIds.
|
|
423
|
-
// So we only rebucket parent tasks (tasks with no parentTaskId).
|
|
424
|
-
const isTopLevelTask = task.parentTaskId == null;
|
|
425
|
-
const wasCompleted = prevStatusCode === 'resolved';
|
|
426
|
-
const isCompleted = newStatusCode === 'resolved';
|
|
427
|
-
if (isTopLevelTask && wasCompleted !== isCompleted) {
|
|
428
|
-
const from = isCompleted ? 'live' : 'completed';
|
|
429
|
-
const to = isCompleted ? 'completed' : 'live';
|
|
430
|
-
const updatedTask = { ...task, ...updates };
|
|
431
|
-
migrateTaskBetweenTabs(draft, taskId, updatedTask, from, to);
|
|
432
|
-
didMigrateTab = true;
|
|
433
|
-
}
|
|
434
394
|
}
|
|
435
395
|
if (updates.assignees != null) {
|
|
436
396
|
const prevGroupId = getAssigneesGroupKey(task.assignees);
|
|
@@ -470,18 +430,7 @@ const taskList = createSlice({
|
|
|
470
430
|
};
|
|
471
431
|
}
|
|
472
432
|
}
|
|
473
|
-
|
|
474
|
-
// The migration moved the task out of the source byTab and into
|
|
475
|
-
// the destination byTab. The active tab's grouping arrays are
|
|
476
|
-
// now authoritative — mirror them back to the top-level so the
|
|
477
|
-
// UI sees the task gone from Live (or freshly arrived in
|
|
478
|
-
// Completed). Inverse of syncTopLevelToActiveTab, used only on
|
|
479
|
-
// this path.
|
|
480
|
-
copyTabDataToTopLevel(draft, draft.byTab[draft.currentTab]);
|
|
481
|
-
}
|
|
482
|
-
else {
|
|
483
|
-
syncTopLevelToActiveTab(draft);
|
|
484
|
-
}
|
|
433
|
+
syncTopLevelToActiveTab(draft);
|
|
485
434
|
},
|
|
486
435
|
updateTasksListOnUpdateTaskSuccess(draft) {
|
|
487
436
|
draft.updateTasksFetchState.fetchState = 'Completed';
|
|
@@ -494,80 +443,12 @@ const taskList = createSlice({
|
|
|
494
443
|
removeTaskFromList(draft, action) {
|
|
495
444
|
removeTaskIds(draft, [action.payload]);
|
|
496
445
|
},
|
|
497
|
-
/**
|
|
498
|
-
* Remove a task id from a single group bucket without touching tab
|
|
499
|
-
* membership or other groupings. Used when the user clears a task's
|
|
500
|
-
* group on the Detail page so the row stops appearing under the old
|
|
501
|
-
* group while saveTaskDetailEpic skips the standard list re-insert.
|
|
502
|
-
*/
|
|
503
|
-
removeTaskFromGroupBucket(draft, action) {
|
|
504
|
-
const { taskId, taskGroupId } = action.payload;
|
|
505
|
-
if (draft.taskIdsByGroupsIds[taskGroupId] != null) {
|
|
506
|
-
draft.taskIdsByGroupsIds[taskGroupId] = draft.taskIdsByGroupsIds[taskGroupId].filter((id) => id !== taskId);
|
|
507
|
-
}
|
|
508
|
-
// Mirror to the active tab's grouping so the UI re-renders.
|
|
509
|
-
const activeTab = draft.byTab[draft.currentTab];
|
|
510
|
-
if (activeTab.taskIdsByGroupsIds[taskGroupId] != null) {
|
|
511
|
-
activeTab.taskIdsByGroupsIds[taskGroupId] =
|
|
512
|
-
activeTab.taskIdsByGroupsIds[taskGroupId].filter((id) => id !== taskId);
|
|
513
|
-
}
|
|
514
|
-
},
|
|
515
446
|
clearTaskList(draft) {
|
|
516
447
|
Object.assign(draft, initialState);
|
|
517
448
|
},
|
|
518
449
|
},
|
|
519
|
-
extraReducers: (builder) => {
|
|
520
|
-
// When the entity store receives updated tasks (e.g. from task detail
|
|
521
|
-
// save, snooze/archive/unarchive, etc.), re-bucket parent tasks between
|
|
522
|
-
// the live and completed tabs based on the new status. Mirrors the
|
|
523
|
-
// backend split in task_handler.py: only `resolved` parents count as
|
|
524
|
-
// completed. Subtasks are nested under their parent row, so they
|
|
525
|
-
// never move between tabs on their own.
|
|
526
|
-
builder.addCase(updateTasks, (draft, action) => {
|
|
527
|
-
action.payload.forEach((taskPayload) => {
|
|
528
|
-
// Only re-bucket parents; subtasks (parent_task_id is a non-empty
|
|
529
|
-
// string) are nested under their parent row and don't move tabs.
|
|
530
|
-
if (taskPayload.parent_task_id != null &&
|
|
531
|
-
taskPayload.parent_task_id !== '') {
|
|
532
|
-
return;
|
|
533
|
-
}
|
|
534
|
-
const taskId = taskPayload.task_id;
|
|
535
|
-
// `TaskPayload.status` is required per the type — every producer
|
|
536
|
-
// in this repo sends it, and `mapTaskPayloadToTask` dereferences
|
|
537
|
-
// it unguarded. The optional chain + null guard are defensive
|
|
538
|
-
// only, in case a downstream consumer (web-app-ui / cockpit-ui)
|
|
539
|
-
// ever dispatches `updateTasks` with a partial payload; in that
|
|
540
|
-
// case we treat missing status as "no status change" and skip
|
|
541
|
-
// re-bucketing so we don't migrate a Completed task back into
|
|
542
|
-
// the Live tab.
|
|
543
|
-
const statusCode = taskPayload.status?.code;
|
|
544
|
-
if (statusCode == null) {
|
|
545
|
-
return;
|
|
546
|
-
}
|
|
547
|
-
const isCompleted = statusCode === 'resolved';
|
|
548
|
-
const targetTab = isCompleted ? 'completed' : 'live';
|
|
549
|
-
const otherTab = isCompleted ? 'live' : 'completed';
|
|
550
|
-
// Skip if the task isn't currently in either of these buckets
|
|
551
|
-
// (archived/snoozed/deleted are managed by their own actions).
|
|
552
|
-
const inLive = draft.byTab.live.taskIds.includes(taskId);
|
|
553
|
-
const inCompleted = draft.byTab.completed.taskIds.includes(taskId);
|
|
554
|
-
if (!inLive && !inCompleted) {
|
|
555
|
-
return;
|
|
556
|
-
}
|
|
557
|
-
if (draft.byTab[otherTab].taskIds.includes(taskId)) {
|
|
558
|
-
migrateTaskPayloadBetweenTabs(draft, taskId, taskPayload, otherTab, targetTab);
|
|
559
|
-
}
|
|
560
|
-
else if (!draft.byTab[targetTab].taskIds.includes(taskId)) {
|
|
561
|
-
draft.byTab[targetTab].taskIds.push(taskId);
|
|
562
|
-
}
|
|
563
|
-
});
|
|
564
|
-
// Re-sync the top-level taskIds / grouping arrays for whichever
|
|
565
|
-
// tab the user is currently looking at.
|
|
566
|
-
copyTabDataToTopLevel(draft, draft.byTab[draft.currentTab]);
|
|
567
|
-
});
|
|
568
|
-
},
|
|
569
450
|
});
|
|
570
|
-
export const { fetchTaskListPage, fetchTaskList, updateTaskList, updateTaskListTab, updateTaskListFetchStatus, updateTaskListSearchText, updateTaskListUIState, updateTaskFilters, updateTaskListOnNewGroupCreationSuccess, bulkUpdateTaskList, updateTasksListOnBulkUpdateTasksSuccess, updateTasksListOnBulkUpdateTasksFailure, initiateTaskListLocalData, updateTaskListLocalData, updateTaskListOnTaskGroupDeletion, dragNDropTasks, updateTaskListOnNewTaskCreationSuccess, updateTaskListOnTaskGroupNameUpdate, updateTaskFromListView, updateTasksListOnUpdateTaskSuccess, updateTasksListOnUpdateTaskFailure, updateTaskListOnCreateTaskFromTemplateSuccess, removeTaskFromList,
|
|
451
|
+
export const { fetchTaskListPage, fetchTaskList, updateTaskList, updateTaskListTab, updateTaskListFetchStatus, updateTaskListSearchText, updateTaskListUIState, updateTaskFilters, updateTaskListOnNewGroupCreationSuccess, bulkUpdateTaskList, updateTasksListOnBulkUpdateTasksSuccess, updateTasksListOnBulkUpdateTasksFailure, initiateTaskListLocalData, updateTaskListLocalData, updateTaskListOnTaskGroupDeletion, dragNDropTasks, updateTaskListOnNewTaskCreationSuccess, updateTaskListOnTaskGroupNameUpdate, updateTaskFromListView, updateTasksListOnUpdateTaskSuccess, updateTasksListOnUpdateTaskFailure, updateTaskListOnCreateTaskFromTemplateSuccess, removeTaskFromList, clearTaskList, } = taskList.actions;
|
|
571
452
|
export default taskList.reducer;
|
|
572
453
|
/**
|
|
573
454
|
* helpers
|
|
@@ -674,115 +555,6 @@ const copyTabDataToTopLevel = (draft, tabData) => {
|
|
|
674
555
|
draft.taskIdsByDueDate = tabData.taskIdsByDueDate;
|
|
675
556
|
draft.taskIdsByTags = tabData.taskIdsByTags;
|
|
676
557
|
};
|
|
677
|
-
/**
|
|
678
|
-
* Migrate a parent task between two `byTab` buckets (live ↔ completed)
|
|
679
|
-
* when its status flips into / out of `resolved`. The destination tab
|
|
680
|
-
* picks up the task in EVERY grouping dimension (status, priority,
|
|
681
|
-
* group id, assignees, dueDate, tags) using the UPDATED task as the
|
|
682
|
-
* source-of-truth for the new bucket keys. Otherwise the Completed tab
|
|
683
|
-
* shows the task in the right tab-level list but the grouped views
|
|
684
|
-
* (Group by Status, Group by Priority, etc.) miss it until the next
|
|
685
|
-
* full fetch.
|
|
686
|
-
*/
|
|
687
|
-
const migrateTaskBetweenTabs = (draft, taskId, updatedTask, from, to) => {
|
|
688
|
-
const fromTab = draft.byTab[from];
|
|
689
|
-
const toTab = draft.byTab[to];
|
|
690
|
-
// Source tab: drop the task from every grouping dimension.
|
|
691
|
-
removeIdsFromTabData(fromTab, [taskId]);
|
|
692
|
-
// Destination tab: add the task to taskIds (deduped) plus the
|
|
693
|
-
// appropriate bucket inside each grouping dimension based on the
|
|
694
|
-
// updated task.
|
|
695
|
-
if (!toTab.taskIds.includes(taskId)) {
|
|
696
|
-
toTab.taskIds.push(taskId);
|
|
697
|
-
}
|
|
698
|
-
const priorityKey = toPriorityCodeType(updatedTask.priority.code);
|
|
699
|
-
if (!toTab.taskIdsByPriority[priorityKey].includes(taskId)) {
|
|
700
|
-
toTab.taskIdsByPriority[priorityKey].push(taskId);
|
|
701
|
-
}
|
|
702
|
-
const statusKey = toTaskStatusCodeType(updatedTask.status.code);
|
|
703
|
-
if (!toTab.taskIdsByStatus[statusKey].includes(taskId)) {
|
|
704
|
-
toTab.taskIdsByStatus[statusKey].push(taskId);
|
|
705
|
-
}
|
|
706
|
-
const dueDateKey = updatedTask.dueDate != null
|
|
707
|
-
? getDueDateGroupKey(updatedTask.dueDate.toString())
|
|
708
|
-
: 'upcoming';
|
|
709
|
-
if (!toTab.taskIdsByDueDate[dueDateKey].includes(taskId)) {
|
|
710
|
-
toTab.taskIdsByDueDate[dueDateKey].push(taskId);
|
|
711
|
-
}
|
|
712
|
-
const assigneeKey = getAssigneesGroupKey(updatedTask.assignees);
|
|
713
|
-
if (toTab.taskIdsByAssignees[assigneeKey] == null) {
|
|
714
|
-
toTab.taskIdsByAssignees[assigneeKey] = [taskId];
|
|
715
|
-
}
|
|
716
|
-
else if (!toTab.taskIdsByAssignees[assigneeKey].includes(taskId)) {
|
|
717
|
-
toTab.taskIdsByAssignees[assigneeKey].push(taskId);
|
|
718
|
-
}
|
|
719
|
-
const tagIds = [...updatedTask.tagIds].sort();
|
|
720
|
-
const tagsKey = tagIds.join(',');
|
|
721
|
-
if (toTab.taskIdsByTags[tagsKey] == null) {
|
|
722
|
-
toTab.taskIdsByTags[tagsKey] = [taskId];
|
|
723
|
-
}
|
|
724
|
-
else if (!toTab.taskIdsByTags[tagsKey].includes(taskId)) {
|
|
725
|
-
toTab.taskIdsByTags[tagsKey].push(taskId);
|
|
726
|
-
}
|
|
727
|
-
(updatedTask.taskGroupIds ?? []).forEach((groupId) => {
|
|
728
|
-
if (toTab.taskIdsByGroupsIds[groupId] == null) {
|
|
729
|
-
toTab.taskIdsByGroupsIds[groupId] = [taskId];
|
|
730
|
-
}
|
|
731
|
-
else if (!toTab.taskIdsByGroupsIds[groupId].includes(taskId)) {
|
|
732
|
-
toTab.taskIdsByGroupsIds[groupId].push(taskId);
|
|
733
|
-
}
|
|
734
|
-
});
|
|
735
|
-
};
|
|
736
|
-
/**
|
|
737
|
-
* `updateTasks` extraReducer variant — same migration semantics but
|
|
738
|
-
* keyed off the raw `TaskPayload` instead of the rich `Task` entity.
|
|
739
|
-
*/
|
|
740
|
-
const migrateTaskPayloadBetweenTabs = (draft, taskId, payload, from, to) => {
|
|
741
|
-
const fromTab = draft.byTab[from];
|
|
742
|
-
const toTab = draft.byTab[to];
|
|
743
|
-
removeIdsFromTabData(fromTab, [taskId]);
|
|
744
|
-
if (!toTab.taskIds.includes(taskId)) {
|
|
745
|
-
toTab.taskIds.push(taskId);
|
|
746
|
-
}
|
|
747
|
-
if (payload.priority?.code != null) {
|
|
748
|
-
const priorityKey = toPriorityCodeType(payload.priority.code);
|
|
749
|
-
if (!toTab.taskIdsByPriority[priorityKey].includes(taskId)) {
|
|
750
|
-
toTab.taskIdsByPriority[priorityKey].push(taskId);
|
|
751
|
-
}
|
|
752
|
-
}
|
|
753
|
-
if (payload.status?.code != null) {
|
|
754
|
-
const statusKey = toTaskStatusCodeType(payload.status.code);
|
|
755
|
-
if (!toTab.taskIdsByStatus[statusKey].includes(taskId)) {
|
|
756
|
-
toTab.taskIdsByStatus[statusKey].push(taskId);
|
|
757
|
-
}
|
|
758
|
-
}
|
|
759
|
-
const dueDateKey = getDueDateGroupKey(payload.due_date);
|
|
760
|
-
if (!toTab.taskIdsByDueDate[dueDateKey].includes(taskId)) {
|
|
761
|
-
toTab.taskIdsByDueDate[dueDateKey].push(taskId);
|
|
762
|
-
}
|
|
763
|
-
const assigneeKey = getAssigneesGroupKey(payload.assignees ?? []);
|
|
764
|
-
if (toTab.taskIdsByAssignees[assigneeKey] == null) {
|
|
765
|
-
toTab.taskIdsByAssignees[assigneeKey] = [taskId];
|
|
766
|
-
}
|
|
767
|
-
else if (!toTab.taskIdsByAssignees[assigneeKey].includes(taskId)) {
|
|
768
|
-
toTab.taskIdsByAssignees[assigneeKey].push(taskId);
|
|
769
|
-
}
|
|
770
|
-
const tagsKey = getTagsGroupKey(payload.tags ?? []);
|
|
771
|
-
if (toTab.taskIdsByTags[tagsKey] == null) {
|
|
772
|
-
toTab.taskIdsByTags[tagsKey] = [taskId];
|
|
773
|
-
}
|
|
774
|
-
else if (!toTab.taskIdsByTags[tagsKey].includes(taskId)) {
|
|
775
|
-
toTab.taskIdsByTags[tagsKey].push(taskId);
|
|
776
|
-
}
|
|
777
|
-
(payload.task_group_ids ?? []).forEach((groupId) => {
|
|
778
|
-
if (toTab.taskIdsByGroupsIds[groupId] == null) {
|
|
779
|
-
toTab.taskIdsByGroupsIds[groupId] = [taskId];
|
|
780
|
-
}
|
|
781
|
-
else if (!toTab.taskIdsByGroupsIds[groupId].includes(taskId)) {
|
|
782
|
-
toTab.taskIdsByGroupsIds[groupId].push(taskId);
|
|
783
|
-
}
|
|
784
|
-
});
|
|
785
|
-
};
|
|
786
558
|
const removeIdsFromTabData = (tabData, taskIds) => {
|
|
787
559
|
const removedSet = new Set(taskIds);
|
|
788
560
|
const isRemoved = (id) => removedSet.has(id);
|
|
@@ -334,7 +334,6 @@ export const getAllTasks = createSelector((state) => state.taskListState, (state
|
|
|
334
334
|
const taskGroupTemplates = getTaskGroupTemplateByIds(taskGroupTemplateState, taskGroupTemplateViewState.taskGroupTemplateIds);
|
|
335
335
|
const tabCounts = {
|
|
336
336
|
live: taskListState.byTab.live.taskIds.length,
|
|
337
|
-
completed: taskListState.byTab.completed.taskIds.length,
|
|
338
337
|
archived: taskListState.byTab.archived.taskIds.length,
|
|
339
338
|
deleted: taskListState.byTab.deleted.taskIds.length,
|
|
340
339
|
snoozed: taskListState.byTab.snoozed.taskIds.length,
|
|
@@ -12,7 +12,7 @@ export declare const fetchAddressEpic: (actions$: ActionsObservable<ActionType>,
|
|
|
12
12
|
type: "addressView/fetchAddressSuccess";
|
|
13
13
|
} | {
|
|
14
14
|
payload: {
|
|
15
|
-
addressId: import("
|
|
15
|
+
addressId: import("../../../commonStateTypes/common").ID;
|
|
16
16
|
status: import("../../../responsePayload").ZeniAPIStatus;
|
|
17
17
|
};
|
|
18
18
|
type: "addressView/fetchAddressFailure";
|
|
@@ -12,7 +12,7 @@ export declare const updateAddressEpic: (actions$: ActionsObservable<ActionType>
|
|
|
12
12
|
type: "addressView/updateAddressSuccess";
|
|
13
13
|
} | {
|
|
14
14
|
payload: {
|
|
15
|
-
addressId: import("
|
|
15
|
+
addressId: import("../../../commonStateTypes/common").ID;
|
|
16
16
|
status: import("../../../responsePayload").ZeniAPIStatus;
|
|
17
17
|
};
|
|
18
18
|
type: "addressView/updateAddressFailure";
|
|
@@ -6,9 +6,9 @@ import { cancelAiAccountantOnboarding, cancelAiAccountantOnboardingFailure, canc
|
|
|
6
6
|
export type ActionType = ReturnType<typeof cancelAiAccountantOnboarding> | ReturnType<typeof cancelAiAccountantOnboardingSuccess> | ReturnType<typeof cancelAiAccountantOnboardingFailure> | ReturnType<typeof fetchAiAccountantCustomers> | ReturnType<typeof openSnackbar>;
|
|
7
7
|
export declare const cancelAiAccountantOnboardingEpic: (actions$: ActionsObservable<ActionType>, _: StateObservable<RootState>, zeniAPI: ZeniAPI) => import("rxjs").Observable<{
|
|
8
8
|
payload: {
|
|
9
|
-
messageSection: import("
|
|
10
|
-
messageText: import("
|
|
11
|
-
type: import("
|
|
9
|
+
messageSection: import("../../../entity/snackbar/snackbarTypes").SnackbarMessageSections;
|
|
10
|
+
messageText: import("../../../entity/snackbar/snackbarTypes").SnackbarMessageSectionTexts;
|
|
11
|
+
type: import("../../../entity/snackbar/snackbarTypes").SnackbarMessageType;
|
|
12
12
|
showStatusIcon?: boolean;
|
|
13
13
|
variables?: {
|
|
14
14
|
variableName: string;
|
|
@@ -7,8 +7,8 @@ import { fetchAiAccountantCustomers, updateAiAccountantCustomers, updateAiAccoun
|
|
|
7
7
|
export type ActionType = ReturnType<typeof fetchAiAccountantCustomers> | ReturnType<typeof updateAiAccountantCustomers> | ReturnType<typeof updateAiAccountantCustomersFailure> | ReturnType<typeof updateAiAccountantCustomerEntities> | ReturnType<typeof updateAllUsers>;
|
|
8
8
|
export declare const fetchAiAccountantCustomersEpic: (actions$: ActionsObservable<ActionType>, _: StateObservable<RootState>, zeniAPI: ZeniAPI) => import("rxjs").Observable<{
|
|
9
9
|
payload: {
|
|
10
|
-
users: import("
|
|
11
|
-
updateType?: import("
|
|
10
|
+
users: import("../../../entity/user/userPayload").UserPayload[];
|
|
11
|
+
updateType?: import("../../../commonStateTypes/common").UpdateType;
|
|
12
12
|
};
|
|
13
13
|
type: "user/updateAllUsers";
|
|
14
14
|
} | {
|
|
@@ -7,8 +7,8 @@ import { fetchAiAccountantJobs, updateAiAccountantJobs, updateAiAccountantJobsFa
|
|
|
7
7
|
export type ActionType = ReturnType<typeof fetchAiAccountantJobs> | ReturnType<typeof updateAiAccountantJobs> | ReturnType<typeof updateAiAccountantJobEntities> | ReturnType<typeof updateAiAccountantJobsFailure> | ReturnType<typeof updateAllUsers>;
|
|
8
8
|
export declare const fetchAiAccountantJobsEpic: (actions$: ActionsObservable<ActionType>, state$: StateObservable<RootState>, zeniAPI: ZeniAPI) => import("rxjs").Observable<{
|
|
9
9
|
payload: {
|
|
10
|
-
users: import("
|
|
11
|
-
updateType?: import("
|
|
10
|
+
users: import("../../../entity/user/userPayload").UserPayload[];
|
|
11
|
+
updateType?: import("../../../commonStateTypes/common").UpdateType;
|
|
12
12
|
};
|
|
13
13
|
type: "user/updateAllUsers";
|
|
14
14
|
} | {
|
|
@@ -27,7 +27,7 @@ export declare const fetchAiAccountantJobsEpic: (actions$: ActionsObservable<Act
|
|
|
27
27
|
} | {
|
|
28
28
|
payload: {
|
|
29
29
|
error: import("../../../responsePayload").ZeniAPIStatus;
|
|
30
|
-
tenantId: import("
|
|
30
|
+
tenantId: import("../../../commonStateTypes/common").ID;
|
|
31
31
|
};
|
|
32
32
|
type: "aiAccountantView/updateAiAccountantJobsFailure";
|
|
33
33
|
}>;
|
|
@@ -6,9 +6,9 @@ import { fetchAiAccountantCustomers, triggerAiAccountantJob, triggerAiAccountant
|
|
|
6
6
|
export type ActionType = ReturnType<typeof triggerAiAccountantJob> | ReturnType<typeof triggerAiAccountantJobSuccess> | ReturnType<typeof triggerAiAccountantJobFailure> | ReturnType<typeof fetchAiAccountantCustomers> | ReturnType<typeof openSnackbar>;
|
|
7
7
|
export declare const triggerAiAccountantJobEpic: (actions$: ActionsObservable<ActionType>, state$: StateObservable<RootState>, zeniAPI: ZeniAPI) => import("rxjs").Observable<{
|
|
8
8
|
payload: {
|
|
9
|
-
messageSection: import("
|
|
10
|
-
messageText: import("
|
|
11
|
-
type: import("
|
|
9
|
+
messageSection: import("../../../entity/snackbar/snackbarTypes").SnackbarMessageSections;
|
|
10
|
+
messageText: import("../../../entity/snackbar/snackbarTypes").SnackbarMessageSectionTexts;
|
|
11
|
+
type: import("../../../entity/snackbar/snackbarTypes").SnackbarMessageType;
|
|
12
12
|
showStatusIcon?: boolean;
|
|
13
13
|
variables?: {
|
|
14
14
|
variableName: string;
|
|
@@ -7,9 +7,9 @@ import { deleteChatSession, deleteChatSessionFailure, deleteChatSessionSuccess }
|
|
|
7
7
|
export type ActionType = ReturnType<typeof deleteChatSession> | ReturnType<typeof clearSession> | ReturnType<typeof deleteChatSessionSuccess> | ReturnType<typeof deleteChatSessionFailure> | ReturnType<typeof openSnackbar>;
|
|
8
8
|
export declare const deleteChatSessionEpic: (actions$: ActionsObservable<ActionType>, _state$: StateObservable<RootState>, zeniAPI: ZeniAPI) => import("rxjs").Observable<{
|
|
9
9
|
payload: {
|
|
10
|
-
messageSection: import("
|
|
11
|
-
messageText: import("
|
|
12
|
-
type: import("
|
|
10
|
+
messageSection: import("../../../entity/snackbar/snackbarTypes").SnackbarMessageSections;
|
|
11
|
+
messageText: import("../../../entity/snackbar/snackbarTypes").SnackbarMessageSectionTexts;
|
|
12
|
+
type: import("../../../entity/snackbar/snackbarTypes").SnackbarMessageType;
|
|
13
13
|
showStatusIcon?: boolean;
|
|
14
14
|
variables?: {
|
|
15
15
|
variableName: string;
|
|
@@ -22,12 +22,12 @@ export declare const deleteChatSessionEpic: (actions$: ActionsObservable<ActionT
|
|
|
22
22
|
type: "aiCfo/clearSession";
|
|
23
23
|
} | {
|
|
24
24
|
payload: {
|
|
25
|
-
chatSessionId: import("
|
|
25
|
+
chatSessionId: import("../../../commonStateTypes/common").ID;
|
|
26
26
|
};
|
|
27
27
|
type: "aiCfoView/deleteChatSessionSuccess";
|
|
28
28
|
} | {
|
|
29
29
|
payload: {
|
|
30
|
-
chatSessionId: import("
|
|
30
|
+
chatSessionId: import("../../../commonStateTypes/common").ID;
|
|
31
31
|
error: import("../../../responsePayload").ZeniAPIStatus;
|
|
32
32
|
};
|
|
33
33
|
type: "aiCfoView/deleteChatSessionFailure";
|
|
@@ -18,7 +18,7 @@ export interface AuditReportGroupViewSelectorView {
|
|
|
18
18
|
export declare const getAuditRuleGroupViewSelectorView: (state: RootState) => {
|
|
19
19
|
auditRuleGroups: AuditRuleGroup[];
|
|
20
20
|
fetchState: import("../../commonStateTypes/common").FetchState;
|
|
21
|
-
error: import("
|
|
21
|
+
error: import("../../responsePayload").ZeniAPIStatus<Record<string, unknown>> | undefined;
|
|
22
22
|
};
|
|
23
23
|
export declare const getAuditReportGroupViewSelectorView: (companyId: ID, state: RootState, loggedInUser?: LoggedInUser) => {
|
|
24
24
|
auditReportGroups: AuditReportGroupSelectorView[];
|
|
@@ -3,9 +3,9 @@ export declare const getBillPayCardReport: (state: RootState) => {
|
|
|
3
3
|
reportId: "cash_balance" | "card_balance" | "expense_automation_card" | "operating_expenses" | "operating_expenses_by_classes" | "revenue" | "revenue_by_classes" | "net_burn_or_income" | "net_burn_or_income_story_card" | "net_burn_or_income_by_classes" | "cash_position" | "top_expenses" | "profit_and_loss" | "profit_and_loss_by_classes" | "profit_and_loss_by_projects" | "balance_sheet" | "cash_flow" | "dashboard" | "finance_statement" | "transaction_list_of_account" | "transaction_list_missing_receipt" | "transaction_list_of_account_by_class" | "transaction_list_of_account_by_project" | "transaction_detail" | "cash_in_cash_out" | "insights_dashboard" | "company_details" | "class_list" | "account_list" | "account_list_by_type" | "vendor" | "task_card" | "bill_pay" | "reimbursement" | "bill_pay_card" | "reimbursement_card" | "bill_pay_promo_card" | "zeni_accounts" | "zeni_accounts_promo_card" | "zeni_treasury" | "charge_cards" | "other_connection" | "reimbursement_promo_card" | "onboarding" | "operating_expenses_by_vendor" | "operating_expenses_by_vendor_summary" | "vendors_tab" | "accounts_payable_aging" | "accounts_receivable_aging" | "vendor_global_review" | "prepaid_expenses" | "fixed_assets" | "notification" | "rewards_card" | "billing" | "flux_analysis_operating_expense" | "account_reconciliation" | "zeni_credit_promo_card" | "treasury_promo_card" | "excluded_account_reconciliation" | "transfer_accounts" | "credit_card_transfer_accounts";
|
|
4
4
|
reportTitle: string;
|
|
5
5
|
version: string | number | undefined;
|
|
6
|
-
fetchState: import("
|
|
7
|
-
billPayAmountByKey: Record<string, import("
|
|
8
|
-
error: import("
|
|
6
|
+
fetchState: import("../../commonStateTypes/common").FetchState;
|
|
7
|
+
billPayAmountByKey: Record<string, import("../../commonStateTypes/amount").Amount>;
|
|
8
|
+
error: import("../../responsePayload").ZeniAPIStatus<Record<string, unknown>> | undefined;
|
|
9
9
|
transactionCount: number;
|
|
10
10
|
firstMonthOfFY: 1 | 3 | 12 | 2 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | 11;
|
|
11
11
|
};
|
|
@@ -5,9 +5,9 @@ import { ZeniAPI } from '../../zeniAPI';
|
|
|
5
5
|
import { fetchCardBalance, updateCardBalance, updateCardBalanceFailure } from './cardBalanceReducer';
|
|
6
6
|
export type ActionType = ReturnType<typeof fetchCardBalance> | ReturnType<typeof updateCardBalance> | ReturnType<typeof updateCardBalanceFailure> | ReturnType<typeof updateAccounts>;
|
|
7
7
|
export declare const fetchCardBalanceEpic: (actions$: ActionsObservable<ActionType>, _: StateObservable<RootState>, zeniAPI: ZeniAPI) => import("rxjs").Observable<import("@reduxjs/toolkit").PayloadAction<import("../../entity/account/accountPayload").AccountPayload[], "account/updateAccounts", {
|
|
8
|
-
reportId: import("
|
|
8
|
+
reportId: import("../../commonStateTypes/viewAndReport/viewAndReport").ReportIDPlusForecastID;
|
|
9
9
|
classesViewParentId: import("../../commonStateTypes/classesView/nestedClassID").ClassesViewParentID | undefined;
|
|
10
|
-
updateType: import("
|
|
10
|
+
updateType: import("../../commonStateTypes/common").UpdateType;
|
|
11
11
|
}, never> | {
|
|
12
12
|
payload: import("../../responsePayload").ZeniReportData<import("./cardBalancePayload").CardBalancePayload>;
|
|
13
13
|
type: "cardBalance/updateCardBalance";
|
|
@@ -3,8 +3,8 @@ export declare const getCardBalance: (state: RootState) => {
|
|
|
3
3
|
reportId: "cash_balance" | "card_balance" | "expense_automation_card" | "operating_expenses" | "operating_expenses_by_classes" | "revenue" | "revenue_by_classes" | "net_burn_or_income" | "net_burn_or_income_story_card" | "net_burn_or_income_by_classes" | "cash_position" | "top_expenses" | "profit_and_loss" | "profit_and_loss_by_classes" | "profit_and_loss_by_projects" | "balance_sheet" | "cash_flow" | "dashboard" | "finance_statement" | "transaction_list_of_account" | "transaction_list_missing_receipt" | "transaction_list_of_account_by_class" | "transaction_list_of_account_by_project" | "transaction_detail" | "cash_in_cash_out" | "insights_dashboard" | "company_details" | "class_list" | "account_list" | "account_list_by_type" | "vendor" | "task_card" | "bill_pay" | "reimbursement" | "bill_pay_card" | "reimbursement_card" | "bill_pay_promo_card" | "zeni_accounts" | "zeni_accounts_promo_card" | "zeni_treasury" | "charge_cards" | "other_connection" | "reimbursement_promo_card" | "onboarding" | "operating_expenses_by_vendor" | "operating_expenses_by_vendor_summary" | "vendors_tab" | "accounts_payable_aging" | "accounts_receivable_aging" | "vendor_global_review" | "prepaid_expenses" | "fixed_assets" | "notification" | "rewards_card" | "billing" | "flux_analysis_operating_expense" | "account_reconciliation" | "zeni_credit_promo_card" | "treasury_promo_card" | "excluded_account_reconciliation" | "transfer_accounts" | "credit_card_transfer_accounts";
|
|
4
4
|
reportTitle: string;
|
|
5
5
|
version: string | number | undefined;
|
|
6
|
-
status: import("
|
|
7
|
-
fetchState: import("
|
|
6
|
+
status: import("../../commonStateTypes/status").Status | undefined;
|
|
7
|
+
fetchState: import("../../commonStateTypes/common").FetchState;
|
|
8
8
|
accountsInOrder: {
|
|
9
9
|
accountId: string;
|
|
10
10
|
accountName: string;
|
|
@@ -13,9 +13,9 @@ export declare const getCardBalance: (state: RootState) => {
|
|
|
13
13
|
accountDescription: string;
|
|
14
14
|
last4Digits: string | undefined;
|
|
15
15
|
logo: import("url-parse")<Record<string, string | undefined>> | import("url-parse")<string> | undefined;
|
|
16
|
-
status: import("
|
|
17
|
-
balance: import("
|
|
18
|
-
statementCloseDay: import("
|
|
16
|
+
status: import("../../commonStateTypes/status").Status | undefined;
|
|
17
|
+
balance: import("../../commonStateTypes/balance").Balance | undefined;
|
|
18
|
+
statementCloseDay: import("../../entity/account/accountState").StatementCloseDay | undefined;
|
|
19
19
|
qboId: string | undefined;
|
|
20
20
|
coaId: string | undefined;
|
|
21
21
|
classesViewParentId: import("../../commonStateTypes/classesView/nestedClassID").ClassesViewParentID | undefined;
|
|
@@ -25,9 +25,9 @@ export declare const getCardBalance: (state: RootState) => {
|
|
|
25
25
|
isBillEditableCoaAccountType: boolean;
|
|
26
26
|
isDeleted: boolean;
|
|
27
27
|
}[];
|
|
28
|
-
balance: import("
|
|
28
|
+
balance: import("../../commonStateTypes/balance").Balance | undefined;
|
|
29
29
|
firstMonthOfFY: 1 | 3 | 12 | 2 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | 11;
|
|
30
|
-
dataAvailable: import("
|
|
31
|
-
error: import("
|
|
30
|
+
dataAvailable: import("../../commonStateTypes/timeframeTick").TimeframeTick | undefined;
|
|
31
|
+
error: import("../../responsePayload").ZeniAPIStatus<Record<string, unknown>> | undefined;
|
|
32
32
|
};
|
|
33
33
|
export type CardBalanceReport = ReturnType<typeof getCardBalance>;
|
|
@@ -8,9 +8,9 @@ export declare const statementCloseDayEpic: (actions$: ActionsObservable<ActionT
|
|
|
8
8
|
type: "cardBalance/updateStatementCloseDayFailure";
|
|
9
9
|
} | {
|
|
10
10
|
payload: {
|
|
11
|
-
accountId: import("
|
|
12
|
-
reportId: import("
|
|
13
|
-
statementCloseDay: import("
|
|
11
|
+
accountId: import("../../commonStateTypes/common").ID;
|
|
12
|
+
reportId: import("../../commonStateTypes/viewAndReport/viewAndReport").ReportIDPlusForecastID;
|
|
13
|
+
statementCloseDay: import("../../entity/account/accountState").StatementCloseDay;
|
|
14
14
|
};
|
|
15
15
|
type: "account/updateAccountStatementCloseDay";
|
|
16
16
|
}>;
|
|
@@ -6,9 +6,9 @@ import { addCardPaymentSource, fetchPaymentSources, updateAddCardPaymentSourceSt
|
|
|
6
6
|
export type ActionType = ReturnType<typeof addCardPaymentSource> | ReturnType<typeof openSnackbar> | ReturnType<typeof updateAddCardPaymentSourceStatus> | ReturnType<typeof fetchPaymentSources>;
|
|
7
7
|
export declare const addCardPaymentSourceEpic: (actions$: ActionsObservable<ActionType>, _state$: StateObservable<RootState>, zeniAPI: ZeniAPI) => import("rxjs").Observable<{
|
|
8
8
|
payload: {
|
|
9
|
-
messageSection: import("
|
|
10
|
-
messageText: import("
|
|
11
|
-
type: import("
|
|
9
|
+
messageSection: import("../../../entity/snackbar/snackbarTypes").SnackbarMessageSections;
|
|
10
|
+
messageText: import("../../../entity/snackbar/snackbarTypes").SnackbarMessageSectionTexts;
|
|
11
|
+
type: import("../../../entity/snackbar/snackbarTypes").SnackbarMessageType;
|
|
12
12
|
showStatusIcon?: boolean;
|
|
13
13
|
variables?: {
|
|
14
14
|
variableName: string;
|
|
@@ -18,7 +18,7 @@ export declare const addCardPaymentSourceEpic: (actions$: ActionsObservable<Acti
|
|
|
18
18
|
type: "snackbar/openSnackbar";
|
|
19
19
|
} | {
|
|
20
20
|
payload: {
|
|
21
|
-
fetchState: import("
|
|
21
|
+
fetchState: import("../../../commonStateTypes/common").FetchState;
|
|
22
22
|
error?: import("../../../responsePayload").ZeniAPIStatus;
|
|
23
23
|
paymentSources?: import("../cardPaymentViewPayload").PaymentSourcesPayload;
|
|
24
24
|
};
|
|
@@ -5,9 +5,9 @@ import { SetupIntentData } from '../cardPaymentViewState';
|
|
|
5
5
|
export type ActionType = ReturnType<typeof confirmCardSetupIntent> | ReturnType<typeof openSnackbar> | ReturnType<typeof updateConfirmCardSetupIntentStatus>;
|
|
6
6
|
export declare const confirmCardSetupIntentEpic: (actions$: ActionsObservable<ActionType>) => import("rxjs").Observable<{
|
|
7
7
|
payload: {
|
|
8
|
-
messageSection: import("
|
|
9
|
-
messageText: import("
|
|
10
|
-
type: import("
|
|
8
|
+
messageSection: import("../../../entity/snackbar/snackbarTypes").SnackbarMessageSections;
|
|
9
|
+
messageText: import("../../../entity/snackbar/snackbarTypes").SnackbarMessageSectionTexts;
|
|
10
|
+
type: import("../../../entity/snackbar/snackbarTypes").SnackbarMessageType;
|
|
11
11
|
showStatusIcon?: boolean;
|
|
12
12
|
variables?: {
|
|
13
13
|
variableName: string;
|
|
@@ -17,7 +17,7 @@ export declare const confirmCardSetupIntentEpic: (actions$: ActionsObservable<Ac
|
|
|
17
17
|
type: "snackbar/openSnackbar";
|
|
18
18
|
} | {
|
|
19
19
|
payload: {
|
|
20
|
-
fetchState: import("
|
|
20
|
+
fetchState: import("../../../commonStateTypes/common").FetchState;
|
|
21
21
|
error?: import("@stripe/stripe-js").StripeError;
|
|
22
22
|
setupIntentData?: SetupIntentData;
|
|
23
23
|
};
|
|
@@ -7,9 +7,9 @@ import { createCardSetupIntent, updateCardSetupIntentStatus } from '../cardPayme
|
|
|
7
7
|
export type ActionType = ReturnType<typeof createCardSetupIntent> | ReturnType<typeof updateCardSetupIntentStatus> | ReturnType<typeof openSnackbar> | ReturnType<typeof updateCardPayments>;
|
|
8
8
|
export declare const createCardSetupIntentEpic: (actions$: ActionsObservable<ActionType>, _state$: StateObservable<RootState>, zeniAPI: ZeniAPI) => import("rxjs").Observable<{
|
|
9
9
|
payload: {
|
|
10
|
-
messageSection: import("
|
|
11
|
-
messageText: import("
|
|
12
|
-
type: import("
|
|
10
|
+
messageSection: import("../../../entity/snackbar/snackbarTypes").SnackbarMessageSections;
|
|
11
|
+
messageText: import("../../../entity/snackbar/snackbarTypes").SnackbarMessageSectionTexts;
|
|
12
|
+
type: import("../../../entity/snackbar/snackbarTypes").SnackbarMessageType;
|
|
13
13
|
showStatusIcon?: boolean;
|
|
14
14
|
variables?: {
|
|
15
15
|
variableName: string;
|
|
@@ -19,8 +19,8 @@ export declare const createCardSetupIntentEpic: (actions$: ActionsObservable<Act
|
|
|
19
19
|
type: "snackbar/openSnackbar";
|
|
20
20
|
} | {
|
|
21
21
|
payload: {
|
|
22
|
-
fetchState: import("
|
|
23
|
-
clientSecret?: import("
|
|
22
|
+
fetchState: import("../../../commonStateTypes/common").FetchState;
|
|
23
|
+
clientSecret?: import("../../../commonStateTypes/common").ID;
|
|
24
24
|
error?: import("../../../responsePayload").ZeniAPIStatus;
|
|
25
25
|
};
|
|
26
26
|
type: "cardPaymentView/updateCardSetupIntentStatus";
|