@actual-app/api 26.2.0-nightly.20260106 → 26.2.0-nightly.20260107
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.
|
@@ -79,7 +79,7 @@ export declare function getCategoriesGrouped(ids?: Array<DbCategoryGroup['id']>)
|
|
|
79
79
|
categories: DbCategory[];
|
|
80
80
|
}>>;
|
|
81
81
|
export declare function insertCategoryGroup(group: WithRequired<Partial<DbCategoryGroup>, 'name'>): Promise<DbCategoryGroup['id']>;
|
|
82
|
-
export declare function updateCategoryGroup(group: WithRequired<Partial<DbCategoryGroup>, 'name' | 'is_income'>): Promise<void>;
|
|
82
|
+
export declare function updateCategoryGroup(group: WithRequired<Partial<DbCategoryGroup>, 'id' | 'name' | 'is_income'>): Promise<void>;
|
|
83
83
|
export declare function moveCategoryGroup(id: DbCategoryGroup['id'], targetId?: DbCategoryGroup['id'] | null): Promise<void>;
|
|
84
84
|
export declare function deleteCategoryGroup(group: Pick<DbCategoryGroup, 'id'>, transferId?: DbCategory['id'] | null): Promise<void>;
|
|
85
85
|
export declare function insertCategory(category: WithRequired<Partial<DbCategory>, 'name' | 'cat_group'>, { atEnd }?: {
|
|
@@ -63,37 +63,6 @@ export declare function splitTransaction(transactions: readonly TransactionEntit
|
|
|
63
63
|
export declare function realizeTempTransactions(transactions: TransactionEntity[]): TransactionEntity[];
|
|
64
64
|
export declare function makeAsNonChildTransactions(childTransactionsToUpdate: TransactionEntity[], transactions: TransactionEntity[]): {
|
|
65
65
|
updated: TransactionEntity[];
|
|
66
|
-
deleted:
|
|
67
|
-
amount: import("./util").IntegerAmount;
|
|
68
|
-
id: string;
|
|
69
|
-
is_parent?: boolean;
|
|
70
|
-
is_child?: boolean;
|
|
71
|
-
parent_id?: TransactionEntity["id"];
|
|
72
|
-
account: import("../types/models").AccountEntity["id"];
|
|
73
|
-
category?: import("../types/models").CategoryEntity["id"];
|
|
74
|
-
payee?: import("../types/models").PayeeEntity["id"];
|
|
75
|
-
notes?: string;
|
|
76
|
-
date: string;
|
|
77
|
-
imported_id?: string;
|
|
78
|
-
imported_payee?: string;
|
|
79
|
-
starting_balance_flag?: boolean;
|
|
80
|
-
transfer_id?: TransactionEntity["id"];
|
|
81
|
-
sort_order?: number;
|
|
82
|
-
cleared?: boolean;
|
|
83
|
-
reconciled?: boolean;
|
|
84
|
-
tombstone?: boolean;
|
|
85
|
-
forceUpcoming?: boolean;
|
|
86
|
-
schedule?: import("../types/models").ScheduleEntity["id"];
|
|
87
|
-
subtransactions?: TransactionEntity[];
|
|
88
|
-
_unmatched?: boolean;
|
|
89
|
-
_deleted?: boolean;
|
|
90
|
-
error?: {
|
|
91
|
-
type: "SplitTransactionError";
|
|
92
|
-
version: 1;
|
|
93
|
-
difference: number;
|
|
94
|
-
} | null;
|
|
95
|
-
raw_synced_data?: string | undefined;
|
|
96
|
-
_ruleErrors?: string[];
|
|
97
|
-
}[];
|
|
66
|
+
deleted: TransactionEntity[];
|
|
98
67
|
};
|
|
99
68
|
export {};
|
|
@@ -50,6 +50,7 @@ export type CrossoverWidget = AbstractWidget<'crossover-card', {
|
|
|
50
50
|
estimatedReturn?: number | null;
|
|
51
51
|
projectionType?: 'trend' | 'hampel';
|
|
52
52
|
showHiddenCategories?: boolean;
|
|
53
|
+
expenseAdjustmentFactor?: number;
|
|
53
54
|
} | null>;
|
|
54
55
|
export type MarkdownWidget = AbstractWidget<'markdown-card', {
|
|
55
56
|
content: string;
|
package/dist/app/bundle.api.js
CHANGED
|
@@ -3520,43 +3520,6 @@ let send$2;
|
|
|
3520
3520
|
function override(sendImplementation) {
|
|
3521
3521
|
send$2 = sendImplementation;
|
|
3522
3522
|
}
|
|
3523
|
-
let verboseMode = true;
|
|
3524
|
-
function setVerboseMode(verbose) {
|
|
3525
|
-
verboseMode = verbose;
|
|
3526
|
-
}
|
|
3527
|
-
const logger = {
|
|
3528
|
-
info: (...args) => {
|
|
3529
|
-
if (verboseMode) {
|
|
3530
|
-
console.log(...args);
|
|
3531
|
-
}
|
|
3532
|
-
},
|
|
3533
|
-
warn: (...args) => {
|
|
3534
|
-
console.warn(...args);
|
|
3535
|
-
},
|
|
3536
|
-
log: (...args) => {
|
|
3537
|
-
if (verboseMode) {
|
|
3538
|
-
console.log(...args);
|
|
3539
|
-
}
|
|
3540
|
-
},
|
|
3541
|
-
error: (...args) => {
|
|
3542
|
-
console.error(...args);
|
|
3543
|
-
},
|
|
3544
|
-
debug: (...args) => {
|
|
3545
|
-
if (verboseMode) {
|
|
3546
|
-
console.debug(...args);
|
|
3547
|
-
}
|
|
3548
|
-
},
|
|
3549
|
-
group: (...args) => {
|
|
3550
|
-
if (verboseMode) {
|
|
3551
|
-
console.group(...args);
|
|
3552
|
-
}
|
|
3553
|
-
},
|
|
3554
|
-
groupEnd: () => {
|
|
3555
|
-
if (verboseMode) {
|
|
3556
|
-
console.groupEnd();
|
|
3557
|
-
}
|
|
3558
|
-
}
|
|
3559
|
-
};
|
|
3560
3523
|
var errCode;
|
|
3561
3524
|
var hasRequiredErrCode;
|
|
3562
3525
|
function requireErrCode() {
|
|
@@ -3882,6 +3845,43 @@ function requirePromiseRetry() {
|
|
|
3882
3845
|
}
|
|
3883
3846
|
var promiseRetryExports = requirePromiseRetry();
|
|
3884
3847
|
const promiseRetry = /* @__PURE__ */ getDefaultExportFromCjs(promiseRetryExports);
|
|
3848
|
+
let verboseMode = true;
|
|
3849
|
+
function setVerboseMode(verbose) {
|
|
3850
|
+
verboseMode = verbose;
|
|
3851
|
+
}
|
|
3852
|
+
const logger = {
|
|
3853
|
+
info: (...args) => {
|
|
3854
|
+
if (verboseMode) {
|
|
3855
|
+
console.log(...args);
|
|
3856
|
+
}
|
|
3857
|
+
},
|
|
3858
|
+
warn: (...args) => {
|
|
3859
|
+
console.warn(...args);
|
|
3860
|
+
},
|
|
3861
|
+
log: (...args) => {
|
|
3862
|
+
if (verboseMode) {
|
|
3863
|
+
console.log(...args);
|
|
3864
|
+
}
|
|
3865
|
+
},
|
|
3866
|
+
error: (...args) => {
|
|
3867
|
+
console.error(...args);
|
|
3868
|
+
},
|
|
3869
|
+
debug: (...args) => {
|
|
3870
|
+
if (verboseMode) {
|
|
3871
|
+
console.debug(...args);
|
|
3872
|
+
}
|
|
3873
|
+
},
|
|
3874
|
+
group: (...args) => {
|
|
3875
|
+
if (verboseMode) {
|
|
3876
|
+
console.group(...args);
|
|
3877
|
+
}
|
|
3878
|
+
},
|
|
3879
|
+
groupEnd: () => {
|
|
3880
|
+
if (verboseMode) {
|
|
3881
|
+
console.groupEnd();
|
|
3882
|
+
}
|
|
3883
|
+
}
|
|
3884
|
+
};
|
|
3885
3885
|
let documentDir;
|
|
3886
3886
|
const _setDocumentDir = (dir) => documentDir = dir;
|
|
3887
3887
|
const getDocumentDir = () => {
|
|
@@ -60539,10 +60539,10 @@ async function getCategories$3(ids) {
|
|
|
60539
60539
|
async function getCategoriesGrouped(ids) {
|
|
60540
60540
|
const categoryGroupWhereIn = ids ? `cg.id IN (${toSqlQueryParameters(ids)}) AND` : "";
|
|
60541
60541
|
const categoryGroupQuery = `SELECT cg.* FROM category_groups cg WHERE ${categoryGroupWhereIn} cg.tombstone = 0
|
|
60542
|
-
|
|
60542
|
+
ORDER BY cg.is_income, cg.sort_order, cg.id`;
|
|
60543
60543
|
const categoryWhereIn = ids ? `c.cat_group IN (${toSqlQueryParameters(ids)}) AND` : "";
|
|
60544
60544
|
const categoryQuery = `SELECT c.* FROM categories c WHERE ${categoryWhereIn} c.tombstone = 0
|
|
60545
|
-
|
|
60545
|
+
ORDER BY c.sort_order, c.id`;
|
|
60546
60546
|
const groups = ids ? await all(categoryGroupQuery, [...ids]) : await all(categoryGroupQuery);
|
|
60547
60547
|
const categories = ids ? await all(categoryQuery, [...ids]) : await all(categoryQuery);
|
|
60548
60548
|
return groups.map((group) => ({
|
|
@@ -60566,7 +60566,11 @@ async function insertCategoryGroup(group) {
|
|
|
60566
60566
|
const id2 = await insertWithUUID("category_groups", group);
|
|
60567
60567
|
return id2;
|
|
60568
60568
|
}
|
|
60569
|
-
function updateCategoryGroup$1(group) {
|
|
60569
|
+
async function updateCategoryGroup$1(group) {
|
|
60570
|
+
const existingGroup = await first$2(`SELECT id, name, hidden FROM category_groups WHERE UPPER(name) = ? AND id != ? AND tombstone = 0 LIMIT 1`, [group.name.toUpperCase(), group.id]);
|
|
60571
|
+
if (existingGroup) {
|
|
60572
|
+
throw new Error(`A ${existingGroup.hidden ? "hidden " : ""}'${existingGroup.name}' category group already exists.`);
|
|
60573
|
+
}
|
|
60570
60574
|
group = categoryGroupModel$1.validate(group, { update: true });
|
|
60571
60575
|
return update("category_groups", group);
|
|
60572
60576
|
}
|
|
@@ -60831,10 +60835,10 @@ function updateTag$1(tag) {
|
|
|
60831
60835
|
}
|
|
60832
60836
|
function findTags$1() {
|
|
60833
60837
|
return all(`
|
|
60834
|
-
|
|
60835
|
-
|
|
60836
|
-
|
|
60837
|
-
|
|
60838
|
+
SELECT notes
|
|
60839
|
+
FROM transactions
|
|
60840
|
+
WHERE tombstone = 0 AND notes LIKE ?
|
|
60841
|
+
`, ["%#%"]);
|
|
60838
60842
|
}
|
|
60839
60843
|
async function findOrCreateBank(institution, requisitionId) {
|
|
60840
60844
|
const bank = await first$2("SELECT id, bank_id FROM banks WHERE bank_id = ?", [requisitionId]);
|
|
@@ -119198,7 +119202,7 @@ class CategoryTemplateContext {
|
|
|
119198
119202
|
return amountToInteger(template.monthly, templateContext.currency.decimalPlaces);
|
|
119199
119203
|
}
|
|
119200
119204
|
else {
|
|
119201
|
-
return templateContext.limitAmount;
|
|
119205
|
+
return templateContext.limitAmount - templateContext.fromLastMonth;
|
|
119202
119206
|
}
|
|
119203
119207
|
}
|
|
119204
119208
|
static async runCopy(template, templateContext) {
|
package/dist/package.json
CHANGED