Versie 0.3.3

This commit is contained in:
Atreides Assets committed 2026-10-30 12:28:48 +01:00
1 parent 1cf6eeed29
commit 6e741a51fe
57 files changed
+1362 -2135

No files matched your search

+3 -8
View File
@@ -1,4 +1,4 @@
// Generated, do not edit. sha256:84e73291cc02df3176d4ba8acbc3d3f1b844080d320978a75a2af8c8bde70e30
// Generated, do not edit. sha256:064fe66c277773dbc29669a7a0cdf7abab018774c71a0f8e1d2a5cceea3a4d22
import { listSelectableAccounts } from '../data/accounts.js';
import { dayNl, localTime, toUtcIso } from '../../shared/time.js';
import { listAssets, listBookableAssets } from '../data/assets.js';
@@ -18,7 +18,6 @@ import { ensurePriceHistoryFor, historicalPointForVia, primarySourceKey } from '
import { bookDifference, acceptDifference } from '../actions/valuation-widget.js';
import { TARGETS, targetHash } from '../../shared/config.js';
import { emptyStateHtml } from '../ui/empty-state.js';
import { capacityCfg } from '../ui/lock.js';
import { setPageHint } from '../ui/page-hint.js';
let tableApi = null;
@@ -146,11 +145,9 @@ async function buildTable(el) {
const toPayload = valuationPayload;
const rijen = await rows();
let used = rijen.length;
const reload = async () => { const r = await rows(); used = r.length; tableApi.refresh(r); };
const reload = async () => tableApi.refresh(await rows());
tableApi = renderTable(el.querySelector('#tbl'), {
columns, rows: rijen,
...capacityCfg('valuations', () => used),
...(await tableViewCfg('valuations', { key: 'valuedOn', dir: 'desc' }, onlyAccount != null ? 'assetId' : null)),
emptyText: t('valuations.none'),
noneLabel: t('table.none'),
@@ -161,9 +158,7 @@ async function buildTable(el) {
saveLabel: t('trades.save'), cancelLabel: t('trades.cancel'),
onCreate: async v => {
const id = await createValuation(await toPayload(v, null));
const r = await rows();
used = r.length;
tableApi.refresh(r, { locate: id });
tableApi.refresh(await rows(), { locate: id });
},
onSave: async (id, v) => {
const ex = (await listValuations()).find(x => x.id === id);