Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion openapi.yaml.txt
Original file line number Diff line number Diff line change
Expand Up @@ -34,7 +34,7 @@ tags:
description: Analytics and summaries

servers:
- url: http://localhost:3000/api
- url: http://localhost:3000/api/v1
description: Local development server (HTTPS)
security:
- BearerAuth: []
Expand Down
2 changes: 2 additions & 0 deletions src/components/features/Settings.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,7 @@ import { CurrencySettings } from './settings/CurrencySettings';
import { ThemeSettings } from './settings/ThemeSettings';
import { LanguageSettings } from './settings/LanguageSettings';
import { MainSettings } from './settings/MainSettings';
import { DataExportSettings } from './settings/DataExportSettings';

const Settings = () => {
const { settingsView, setSettingsView } = useGlobal();
Expand All @@ -20,6 +21,7 @@ const Settings = () => {
{settingsView === 'CURRENCY' && <CurrencySettings onBack={() => setSettingsView('MAIN')} onUpgrade={() => setSettingsView('SUBSCRIPTION')} />}
{settingsView === 'THEME' && <ThemeSettings onBack={() => setSettingsView('MAIN')} onUpgrade={() => setSettingsView('SUBSCRIPTION')} />}
{settingsView === 'LANGUAGE' && <LanguageSettings onBack={() => setSettingsView('MAIN')} />}
{settingsView === 'DATA_EXPORT' && <DataExportSettings onBack={() => setSettingsView('MAIN')} />}
</div>
);
};
Expand Down
24 changes: 24 additions & 0 deletions src/components/features/TaskCenterModal.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -102,12 +102,36 @@ const TaskCenterModal = () => {
return `${sourceAccountName} → ${targetAccountIds.length} ${t('common:accounts')}`;
}
return sourceAccountName;
} else if (task.type === 'DATA_EXPORT' && task.payload) {
const payload = task.payload as { startDate: string; endDate: string };
return `${payload.startDate} - ${payload.endDate}`;
} else if (task.type === 'DATA_IMPORT' && task.payload) {
const payload = task.payload as { fileName: string };
// Extract filename from path if needed, or just show it
const fileName = payload.fileName.split(/[/\\]/).pop() || payload.fileName;

if (task.status === 'COMPLETED' && task.result) {
const result = task.result as {
accountsImported?: number;
transactionsImported?: number;
accountsSkipped?: number;
transactionsSkipped?: number;
};
const added = (result.accountsImported || 0) + (result.transactionsImported || 0);
const updated = (result.accountsSkipped || 0) + (result.transactionsSkipped || 0);
const duplicated = updated;
return `${fileName} (${t('settings:import_result_summary', { added, updated, duplicated })})`;
}

return fileName;
}
return '';
};

const getTypeText = (type: string) => {
if (type === 'ACCOUNT_MIGRATION') return t('settings:task_type_account_migration');
if (type === 'DATA_EXPORT') return t('settings:task_type_data_export');
if (type === 'DATA_IMPORT') return t('settings:task_type_data_import');
return type;
};

Expand Down
Loading