Merge branch 'master' into scrollToLocationBudget

This commit is contained in:
Crazypkr1099
2024-06-19 21:59:42 -04:00
committed by GitHub
14 changed files with 29 additions and 17 deletions

Binary file not shown.

Before

Width:  |  Height:  |  Size: 60 KiB

After

Width:  |  Height:  |  Size: 62 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 60 KiB

After

Width:  |  Height:  |  Size: 62 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 59 KiB

After

Width:  |  Height:  |  Size: 62 KiB

View File

@@ -271,7 +271,7 @@ export function AccountHeader({
} }
style={{ marginRight: 4 }} style={{ marginRight: 4 }}
/>{' '} />{' '}
{isServerOffline ? 'Sync offline' : 'Sync'} {isServerOffline ? 'Bank Sync Offline' : 'Bank Sync'}
</> </>
) : ( ) : (
<> <>

View File

@@ -122,13 +122,12 @@ export function AccountAutocomplete({
.filter(item => { .filter(item => {
return includeClosedAccounts ? item : !item.closed; return includeClosedAccounts ? item : !item.closed;
}) })
.sort((a, b) => { .sort(
if (a.closed === b.closed) { (a, b) =>
return a.offbudget === b.offbudget ? 0 : a.offbudget ? 1 : -1; a.closed - b.closed ||
} else { a.offbudget - b.offbudget ||
return a.closed ? 1 : -1; a.sort_order - b.sort_order,
} );
});
return ( return (
<Autocomplete <Autocomplete

View File

@@ -25,7 +25,6 @@ export function Overview() {
const location = useLocation(); const location = useLocation();
sessionStorage.setItem('url', location.pathname); sessionStorage.setItem('url', location.pathname);
const customReportsFeatureFlag = useFeatureFlag('customReports');
const spendingReportFeatureFlag = useFeatureFlag('spendingReport'); const spendingReportFeatureFlag = useFeatureFlag('spendingReport');
const accounts = useAccounts(); const accounts = useAccounts();
@@ -43,7 +42,7 @@ export function Overview() {
}} }}
> >
<PageHeader title="Reports" /> <PageHeader title="Reports" />
{customReportsFeatureFlag && !isNarrowWidth && ( {!isNarrowWidth && (
<Link to="/reports/custom" style={{ textDecoration: 'none' }}> <Link to="/reports/custom" style={{ textDecoration: 'none' }}>
<Button type="primary"> <Button type="primary">
<Text>Create new custom report</Text> <Text>Create new custom report</Text>
@@ -66,9 +65,7 @@ export function Overview() {
<CashFlowCard /> <CashFlowCard />
{spendingReportFeatureFlag && <SpendingCard />} {spendingReportFeatureFlag && <SpendingCard />}
</View> </View>
{customReportsFeatureFlag && ( <CustomReportListCards reports={customReports} />
<CustomReportListCards reports={customReports} />
)}
</Page> </Page>
); );
} }

View File

@@ -79,7 +79,6 @@ export function ExperimentalFeatures() {
primaryAction={ primaryAction={
expanded ? ( expanded ? (
<View style={{ gap: '1em' }}> <View style={{ gap: '1em' }}>
<FeatureToggle flag="customReports">Custom reports</FeatureToggle>
<FeatureToggle flag="spendingReport"> <FeatureToggle flag="spendingReport">
Monthly spending Monthly spending
</FeatureToggle> </FeatureToggle>

View File

@@ -6,7 +6,6 @@ import type { FeatureFlag } from 'loot-core/src/types/prefs';
const DEFAULT_FEATURE_FLAG_STATE: Record<FeatureFlag, boolean> = { const DEFAULT_FEATURE_FLAG_STATE: Record<FeatureFlag, boolean> = {
reportBudget: false, reportBudget: false,
goalTemplatesEnabled: false, goalTemplatesEnabled: false,
customReports: false,
spendingReport: false, spendingReport: false,
simpleFinSync: false, simpleFinSync: false,
iterableTopologicalSort: true, iterableTopologicalSort: true,

View File

@@ -243,5 +243,6 @@ export function moveAccount(id, targetId) {
return async (dispatch: Dispatch) => { return async (dispatch: Dispatch) => {
await send('account-move', { id, targetId }); await send('account-move', { id, targetId });
dispatch(getAccounts()); dispatch(getAccounts());
dispatch(getPayees());
}; };
} }

View File

@@ -536,7 +536,7 @@ export function getPayees() {
SELECT p.*, COALESCE(a.name, p.name) AS name FROM payees p SELECT p.*, COALESCE(a.name, p.name) AS name FROM payees p
LEFT JOIN accounts a ON (p.transfer_acct = a.id AND a.tombstone = 0) LEFT JOIN accounts a ON (p.transfer_acct = a.id AND a.tombstone = 0)
WHERE p.tombstone = 0 AND (p.transfer_acct IS NULL OR a.id IS NOT NULL) WHERE p.tombstone = 0 AND (p.transfer_acct IS NULL OR a.id IS NOT NULL)
ORDER BY p.transfer_acct IS NULL DESC, p.name COLLATE NOCASE ORDER BY p.transfer_acct IS NULL DESC, p.name COLLATE NOCASE, a.offbudget, a.sort_order
`); `);
} }

View File

@@ -3,7 +3,6 @@ import { type numberFormats } from '../shared/util';
export type FeatureFlag = export type FeatureFlag =
| 'reportBudget' | 'reportBudget'
| 'goalTemplatesEnabled' | 'goalTemplatesEnabled'
| 'customReports'
| 'spendingReport' | 'spendingReport'
| 'simpleFinSync' | 'simpleFinSync'
| 'iterableTopologicalSort'; | 'iterableTopologicalSort';

View File

@@ -0,0 +1,6 @@
---
category: Features
authors: [carkom]
---
Removing custom reports from feature flag "experimental" state.

View File

@@ -0,0 +1,6 @@
---
category: Enhancements
authors: [dymanoid]
---
Respect the user-defined account sort order in all autocomplete lists.

View File

@@ -0,0 +1,6 @@
---
category: Enhancements
authors: [MatissJanis]
---
Bank Sync: update bank-sync button label to "Bank Sync" to improve discoverability for new users