@zeniai/client-epic-state 4.19.77-betaSS3 → 4.19.78
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/lib/entity/jeSchedules/jeSchedulesPayload.d.ts +0 -35
- package/lib/entity/jeSchedules/jeSchedulesPayload.js +0 -44
- package/lib/entity/jeSchedules/jeSchedulesSelector.d.ts +1 -2
- package/lib/entity/jeSchedules/jeSchedulesSelector.js +1 -2
- package/lib/entity/jeSchedules/jeSchedulesState.d.ts +0 -13
- package/lib/esm/entity/jeSchedules/jeSchedulesPayload.js +0 -44
- package/lib/esm/entity/jeSchedules/jeSchedulesSelector.js +1 -2
- package/lib/index.d.ts +1 -2
- package/lib/tsconfig.typecheck.tsbuildinfo +1 -0
- package/package.json +1 -1
|
@@ -13,39 +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
|
-
}
|
|
29
|
-
export interface JEScheduleRecommendationsPayload {
|
|
30
|
-
amortization_days?: number | null;
|
|
31
|
-
amortization_months_estimate?: number | null;
|
|
32
|
-
credit_account_confidence?: number;
|
|
33
|
-
credit_account_id?: string | null;
|
|
34
|
-
credit_accounting_class_id?: string | null;
|
|
35
|
-
credit_class_confidence?: number;
|
|
36
|
-
debit_account_confidence?: number;
|
|
37
|
-
debit_account_id?: string | null;
|
|
38
|
-
debit_accounting_class_id?: string | null;
|
|
39
|
-
debit_class_confidence?: number;
|
|
40
|
-
end_date?: string | null;
|
|
41
|
-
je_schedule_type?: string | null;
|
|
42
|
-
period?: number | null;
|
|
43
|
-
period_confidence?: number;
|
|
44
|
-
posting_date?: string | null;
|
|
45
|
-
similar_transactions?: unknown[];
|
|
46
|
-
start_date?: string | null;
|
|
47
|
-
starting_month?: string | null;
|
|
48
|
-
}
|
|
49
16
|
export interface JEScheduledTransactionPayload {
|
|
50
17
|
balance: number | null;
|
|
51
18
|
base_transaction: ScheduleTransactionPayload;
|
|
@@ -68,9 +35,7 @@ export interface JEScheduledTransactionPayload {
|
|
|
68
35
|
status: StatusCodeWithLabelPayload;
|
|
69
36
|
updated_by: UserPayload;
|
|
70
37
|
vendor: VendorPayload;
|
|
71
|
-
ai_summaries?: JEScheduleAISummariesPayload;
|
|
72
38
|
end_date?: string | null;
|
|
73
|
-
recommendations?: JEScheduleRecommendationsPayload;
|
|
74
39
|
updated_at?: string | null;
|
|
75
40
|
}
|
|
76
41
|
export interface JEAccruedScheduledTransactionPayload extends Omit<JEScheduledTransactionPayload, 'base_transaction' | 'je_schedule_id' | 'je_schedule_type'> {
|
|
@@ -144,49 +144,6 @@ function toJEScheduleOtherAttributes(payload) {
|
|
|
144
144
|
assetId: payload.asset_id ?? undefined,
|
|
145
145
|
};
|
|
146
146
|
}
|
|
147
|
-
function toJEScheduleAIRecommendations(payload) {
|
|
148
|
-
if (payload == null) {
|
|
149
|
-
return undefined;
|
|
150
|
-
}
|
|
151
|
-
const result = {};
|
|
152
|
-
if (payload.debit_account != null) {
|
|
153
|
-
result.debitAccount = {
|
|
154
|
-
confidence: payload.debit_account.confidence,
|
|
155
|
-
reasoning: payload.debit_account.reasoning,
|
|
156
|
-
};
|
|
157
|
-
}
|
|
158
|
-
if (payload.credit_account != null) {
|
|
159
|
-
result.creditAccount = {
|
|
160
|
-
confidence: payload.credit_account.confidence,
|
|
161
|
-
reasoning: payload.credit_account.reasoning,
|
|
162
|
-
};
|
|
163
|
-
}
|
|
164
|
-
if (payload.debit_accounting_class != null) {
|
|
165
|
-
result.debitClass = {
|
|
166
|
-
confidence: payload.debit_accounting_class.confidence,
|
|
167
|
-
reasoning: payload.debit_accounting_class.reasoning,
|
|
168
|
-
};
|
|
169
|
-
}
|
|
170
|
-
if (payload.credit_accounting_class != null) {
|
|
171
|
-
result.creditClass = {
|
|
172
|
-
confidence: payload.credit_accounting_class.confidence,
|
|
173
|
-
reasoning: payload.credit_accounting_class.reasoning,
|
|
174
|
-
};
|
|
175
|
-
}
|
|
176
|
-
if (payload.period != null) {
|
|
177
|
-
result.period = {
|
|
178
|
-
confidence: payload.period.confidence,
|
|
179
|
-
reasoning: payload.period.reasoning,
|
|
180
|
-
};
|
|
181
|
-
}
|
|
182
|
-
if (payload.posting_date != null) {
|
|
183
|
-
result.postingDate = {
|
|
184
|
-
confidence: payload.posting_date.confidence,
|
|
185
|
-
reasoning: payload.posting_date.reasoning,
|
|
186
|
-
};
|
|
187
|
-
}
|
|
188
|
-
return Object.keys(result).length > 0 ? result : undefined;
|
|
189
|
-
}
|
|
190
147
|
function toJEScheduledTransaction(payload) {
|
|
191
148
|
return {
|
|
192
149
|
jeScheduleId: payload.je_schedule_id ?? undefined,
|
|
@@ -228,7 +185,6 @@ function toJEScheduledTransaction(payload) {
|
|
|
228
185
|
? toJEScheduleOtherAttributes(payload.other_attributes)
|
|
229
186
|
: {},
|
|
230
187
|
scheduledJournalEntry: [],
|
|
231
|
-
aiRecommendations: toJEScheduleAIRecommendations(payload.ai_summaries),
|
|
232
188
|
};
|
|
233
189
|
}
|
|
234
190
|
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,7 +59,6 @@ export interface JEScheduledTransaction {
|
|
|
59
59
|
scheduledJournalEntry: ScheduledJournalEntry[];
|
|
60
60
|
status: ScheduleStatus;
|
|
61
61
|
vendor: Vendor;
|
|
62
|
-
aiRecommendations?: JEScheduleAIRecommendations;
|
|
63
62
|
balanceAsOfToday?: Amount;
|
|
64
63
|
dayOfPostingDate?: ScheduleDaysOfMonth;
|
|
65
64
|
endDate?: ZeniDate;
|
|
@@ -77,7 +77,7 @@ 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, vendorId, jeCredit, jeDebit, currencyCode, currencySymbol, balanceAsOfToday, baseTransaction, startDate, endDate, status, updatedAt, jeScheduleId, scheduledJournalEntry, dayOfPostingDate: postingDate, lastDayOfMonth, otherAttributes, jeScheduleType,
|
|
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`);
|
|
@@ -134,7 +134,6 @@ const getJEScheduledTransactionByJEScheduleTransactionKey = (jeScheduleTransacti
|
|
|
134
134
|
account: accountDebit,
|
|
135
135
|
},
|
|
136
136
|
scheduledJournalEntry,
|
|
137
|
-
aiRecommendations,
|
|
138
137
|
};
|
|
139
138
|
};
|
|
140
139
|
exports.getJEScheduledTransactionByJEScheduleTransactionKey = getJEScheduledTransactionByJEScheduleTransactionKey;
|
|
@@ -13,18 +13,6 @@ export interface ScheduleJournalStatusCode {
|
|
|
13
13
|
code: ScheduleJournalEntryStatusCodeType;
|
|
14
14
|
label: string;
|
|
15
15
|
}
|
|
16
|
-
export interface JEScheduleFieldRecommendation {
|
|
17
|
-
confidence: number;
|
|
18
|
-
reasoning: string;
|
|
19
|
-
}
|
|
20
|
-
export interface JEScheduleAIRecommendations {
|
|
21
|
-
creditAccount?: JEScheduleFieldRecommendation;
|
|
22
|
-
creditClass?: JEScheduleFieldRecommendation;
|
|
23
|
-
debitAccount?: JEScheduleFieldRecommendation;
|
|
24
|
-
debitClass?: JEScheduleFieldRecommendation;
|
|
25
|
-
period?: JEScheduleFieldRecommendation;
|
|
26
|
-
postingDate?: JEScheduleFieldRecommendation;
|
|
27
|
-
}
|
|
28
16
|
export interface JEScheduleOtherAttributes {
|
|
29
17
|
assetId?: string;
|
|
30
18
|
startingBalance?: Amount;
|
|
@@ -69,7 +57,6 @@ export interface JEScheduledTransactionState {
|
|
|
69
57
|
scheduledJournalEntry: ScheduledJournalEntryState[];
|
|
70
58
|
status: ScheduleStatus;
|
|
71
59
|
vendorId: ID;
|
|
72
|
-
aiRecommendations?: JEScheduleAIRecommendations;
|
|
73
60
|
balanceAsOfToday?: number;
|
|
74
61
|
dayOfPostingDate?: ScheduleDaysOfMonth;
|
|
75
62
|
endDate?: ZeniDate;
|
|
@@ -134,49 +134,6 @@ function toJEScheduleOtherAttributes(payload) {
|
|
|
134
134
|
assetId: payload.asset_id ?? undefined,
|
|
135
135
|
};
|
|
136
136
|
}
|
|
137
|
-
function toJEScheduleAIRecommendations(payload) {
|
|
138
|
-
if (payload == null) {
|
|
139
|
-
return undefined;
|
|
140
|
-
}
|
|
141
|
-
const result = {};
|
|
142
|
-
if (payload.debit_account != null) {
|
|
143
|
-
result.debitAccount = {
|
|
144
|
-
confidence: payload.debit_account.confidence,
|
|
145
|
-
reasoning: payload.debit_account.reasoning,
|
|
146
|
-
};
|
|
147
|
-
}
|
|
148
|
-
if (payload.credit_account != null) {
|
|
149
|
-
result.creditAccount = {
|
|
150
|
-
confidence: payload.credit_account.confidence,
|
|
151
|
-
reasoning: payload.credit_account.reasoning,
|
|
152
|
-
};
|
|
153
|
-
}
|
|
154
|
-
if (payload.debit_accounting_class != null) {
|
|
155
|
-
result.debitClass = {
|
|
156
|
-
confidence: payload.debit_accounting_class.confidence,
|
|
157
|
-
reasoning: payload.debit_accounting_class.reasoning,
|
|
158
|
-
};
|
|
159
|
-
}
|
|
160
|
-
if (payload.credit_accounting_class != null) {
|
|
161
|
-
result.creditClass = {
|
|
162
|
-
confidence: payload.credit_accounting_class.confidence,
|
|
163
|
-
reasoning: payload.credit_accounting_class.reasoning,
|
|
164
|
-
};
|
|
165
|
-
}
|
|
166
|
-
if (payload.period != null) {
|
|
167
|
-
result.period = {
|
|
168
|
-
confidence: payload.period.confidence,
|
|
169
|
-
reasoning: payload.period.reasoning,
|
|
170
|
-
};
|
|
171
|
-
}
|
|
172
|
-
if (payload.posting_date != null) {
|
|
173
|
-
result.postingDate = {
|
|
174
|
-
confidence: payload.posting_date.confidence,
|
|
175
|
-
reasoning: payload.posting_date.reasoning,
|
|
176
|
-
};
|
|
177
|
-
}
|
|
178
|
-
return Object.keys(result).length > 0 ? result : undefined;
|
|
179
|
-
}
|
|
180
137
|
export function toJEScheduledTransaction(payload) {
|
|
181
138
|
return {
|
|
182
139
|
jeScheduleId: payload.je_schedule_id ?? undefined,
|
|
@@ -218,7 +175,6 @@ export function toJEScheduledTransaction(payload) {
|
|
|
218
175
|
? toJEScheduleOtherAttributes(payload.other_attributes)
|
|
219
176
|
: {},
|
|
220
177
|
scheduledJournalEntry: [],
|
|
221
|
-
aiRecommendations: toJEScheduleAIRecommendations(payload.ai_summaries),
|
|
222
178
|
};
|
|
223
179
|
}
|
|
224
180
|
export function toJEAccruedScheduledTransaction(payload) {
|
|
@@ -70,7 +70,7 @@ export const getJEAccruedScheduleByJEScheduleKey = (JEScheduleKey, state) => {
|
|
|
70
70
|
export const getJEScheduledTransactionByJEScheduleTransactionKey = (jeScheduleTransactionKey, state) => {
|
|
71
71
|
const { jeSchedulesState, vendorState, accountState, userState, classState, transactionState, } = state;
|
|
72
72
|
const jeScheduleTransactionState = recordGet(jeSchedulesState.schedulesByTransactionKey, jeScheduleTransactionKey);
|
|
73
|
-
const { period, updatedByUserID: updatedBy, vendorId, jeCredit, jeDebit, currencyCode, currencySymbol, balanceAsOfToday, baseTransaction, startDate, endDate, status, updatedAt, jeScheduleId, scheduledJournalEntry, dayOfPostingDate: postingDate, lastDayOfMonth, otherAttributes, jeScheduleType,
|
|
73
|
+
const { period, updatedByUserID: updatedBy, vendorId, jeCredit, jeDebit, currencyCode, currencySymbol, balanceAsOfToday, baseTransaction, startDate, endDate, status, updatedAt, jeScheduleId, scheduledJournalEntry, dayOfPostingDate: postingDate, lastDayOfMonth, otherAttributes, jeScheduleType, } = jeScheduleTransactionState;
|
|
74
74
|
const vendorDetails = getVendorByVendorId(vendorState, vendorId);
|
|
75
75
|
if (vendorDetails == null) {
|
|
76
76
|
throw new Error(`Vendor with ${vendorId} doesn't exist`);
|
|
@@ -127,6 +127,5 @@ export const getJEScheduledTransactionByJEScheduleTransactionKey = (jeScheduleTr
|
|
|
127
127
|
account: accountDebit,
|
|
128
128
|
},
|
|
129
129
|
scheduledJournalEntry,
|
|
130
|
-
aiRecommendations,
|
|
131
130
|
};
|
|
132
131
|
};
|
package/lib/index.d.ts
CHANGED
|
@@ -91,7 +91,6 @@ import { TrendChangeType } from './entity/insights/insightPayload';
|
|
|
91
91
|
import { Insight } from './entity/insights/insightState';
|
|
92
92
|
import { InsightSummary } from './entity/insights/insightSummary';
|
|
93
93
|
import { JEAccruedSchedule, JEScheduledTransaction, ScheduledJournalEntry } from './entity/jeSchedules/jeSchedulesSelector';
|
|
94
|
-
import { JEScheduleAIRecommendations, JEScheduleFieldRecommendation } from './entity/jeSchedules/jeSchedulesState';
|
|
95
94
|
import { ALL_SCHEDULES_TYPES, JEScheduleKey, JEScheduleTransactionKey, JournalEntryErrorCodeType, ScheduleJournalEntryStatusCodeType, ScheduleStatusCodeType, ScheduleTypes, toScheduleTypesType, toScheduleTypesTypeStrict } from './entity/jeSchedules/jeSchedulesTypes';
|
|
96
95
|
import { Merchant } from './entity/merchant/merchant';
|
|
97
96
|
import { ALL_MONTH_END_CLOSE_CHECKS_FREQUENCY, MonthCloseCheckMetrics, MonthEndAuditSummary, MonthEndCloseCheck, MonthEndCloseCheckFrequency } from './entity/monthEndCloseChecks/monthEndCloseChecksState';
|
|
@@ -824,7 +823,7 @@ export { fetchApAgingDetail, AgingReportInvoice, ApAgingDetail, getApAgingDetail
|
|
|
824
823
|
export { LinkBillExpenseKey };
|
|
825
824
|
export { clearExpenseAutomationJEScheduleLocalData, clearExpenseAutomationJESchedulesView, fetchExpenseAutomationJESchedulesPage, ignoreExpenseAutomationJESchedule, initializeJeAccountSettingsView, initializeJeScheduleLocalData, removeJeScheduleTransactionKey, retryExpenseAutomationJESchedule, updateJeScheduleLocalDataById, updateJeScheduleTransactionKeys, };
|
|
826
825
|
export { createNewSchedulesAccrued, deleteScheduleAccruedDetail, cancelScheduleAccruedJournalEntry, fetchScheduleAccruedDetails, fetchScheduleAccruedDetailsPage, resetJEAccruedLinkInLocalData, saveScheduleAccruedDetails, updateAmountsInScheduleAccruedDetail, updatedJEAccruedLinkWithRecommendedLocalData, updatedJELinkInLocalDataAccruedExpenses, fetchRecommendedTransactionRowIndex, clearSelectedJELinkRowIndex, updateLinkBillExpenseLocalData, updateScheduleAccruedDetailsLocalData, updateSelectedJEAccruedScheduleKey, resetSelectedJEAccruedScheduleKey, resetAccruedDetailNewScheduleState, };
|
|
827
|
-
export { JEScheduleKey, JEScheduleTransactionKey, ALL_SCHEDULES_TYPES, JEScheduledTransaction, JEAccruedSchedule,
|
|
826
|
+
export { JEScheduleKey, JEScheduleTransactionKey, ALL_SCHEDULES_TYPES, JEScheduledTransaction, JEAccruedSchedule, ScheduleTypes, ScheduleJournalEntryStatusCodeType, ScheduleListReport, ScheduleAccruedListReport, getScheduleListReport, getAccruedScheduleListReport, ScheduleSubTabType, ScheduleListSortKey, fetchScheduleList, fetchAccruedScheduleList, fetchDownloadSchedules, fetchSchedulesAccount, updateScheduleListLocalData, getFetchStateForScheduleAccountList, toScheduleTypesType, toScheduleTypesTypeStrict, toScheduleListTabsFileTypeStrict, ScheduleListLocalData, ScheduleDetailsLocalDataFixedAssets, ScheduleDetailsLocalDataAccruedExpenses, ScheduleDetailsView, ScheduleAccruedDetailsView, LinkBillExpenseView, LinkBillExpenseLocalData, JEScheduleDetailsLocalData, ScheduleDetailsLocalData, toScheduleSubTabType, ScheduleStatusCodeType, JournalEntryErrorCodeType, ScheduleTransaction, updateScheduleListSubTab, updateScheduleListSearchText, updateScheduleListScrollState, updateScheduleListSortState, ScheduleDetailSortKey, ScheduledJournalEntry, updateSelectedJEScheduleKey, fetchScheduleDetails, getScheduleDetailsView, getAccruedScheduleDetailsView, fetchScheduleDetailsPage, saveScheduleDetails, deleteScheduleDetail, createNewSchedules, updateScheduleDetailsLocalData, JETransactionLink, updateScheduleListDownloadState, updateAccruedJEScheduleAccruedByListKey, DownloadJEScheduleTabOptions, updatedSelectedJELinkRowIndex, ScheduleListTabsFileType, getQBOUrlForLink, getThirdPartyIDFromQBOURL, updatedJELinkInLocalData, updateAmountsInScheduleDetail, ScheduleDetailUIState, resetJELinkInLocalData, JEScheduledTransactionWithBalance, JEScheduleWithBalance, JELinkType, updatedJELinkWithRecommendedLocalData, getFetchStateForScheduleListByType, getDefaultSelectedTimeframeForScheduleType, markAsCompleteScheduleDetail, resetMarkAsCompleteStatus, fetchVendorTabView, updateVendorTabViewTab, VendorTabViewTabType, getVendorTabView, VendorTabViewSelectorView, };
|
|
828
827
|
export { GlobalMerchant, GlobalMerchantBase, TenantMerchant };
|
|
829
828
|
export { ReviewStatus, VendorTransactionAttachment, VendorTransactionAttachmentPayload, VendorFirstReviewViewSelectorView, VendorFirstReviewViewLocalData, VendorFirstReviewSelectorView, VendorFirstReviewSelectorAttachmentView, VendorFirstReviewViewUIState, VendorFirstReviewViewColumnKey, GlobalMerchantAutoCompleteView, VendorReviewRowCurrentSelection, toVendorFirstReviewViewColumnKeyType, RecommendedNonExistingGlobalMerchant, getGlobalMerchantAutoCompleteResults, VendorReviewRecommendationViewState, GlobalMerchantType, getVendorFirstReviewView, getVendorFirstReviewAttachmentView, fetchVendorFirstReviewView, fetchVendorFirstReviewAttachments, updateVendorFirstReviewViewScrollYOffset, resetVendorFirstReviewLocalData, updateVendorFirstReviewViewPageToken, clearRecentlySavedErroredVendorData, saveVendorFirstReviewView, updateVendorFirstReviewViewLocalData, updateVendorFirstReviewSortUiState, fetchGlobalMerchantAutoCompleteView, clearGlobalMerchantAutoCompleteResults, GlobalVendorReviewRowCurrentSelection, FirstReviewPageCurrentSelectionByColumn, updateReviewVendorDetailLocalData, saveVendorDetailsView, getVendorDetailSelectorView, FirstReviewVendorDetailSelectorView, VendorViewLocalData, };
|
|
830
829
|
export { fetchGlobalMerchantRecommendation, createGlobalMerchant, updateCreateGlobalMerchantLocalData, clearGlobalMerchantView, getGlobalMerchantView, GlobalMerchantViewSelectorView, GlobalMerchantViewState, NewGlobalMerchantData, NewGlobalMerchantCurrentSelection, };
|