优化分类选择功能:新增默认展开分类列表设置,更新相关页面以支持此功能
This commit is contained in:
@@ -108,6 +108,15 @@
|
||||
</template>
|
||||
</f7-list-item>
|
||||
|
||||
<f7-list-item>
|
||||
<template #after-title>
|
||||
{{ tt('Expand Category List By Default') }}
|
||||
</template>
|
||||
<template #after>
|
||||
<f7-toggle :checked="expandCategoryTreeByDefault" @toggle:change="expandCategoryTreeByDefault = $event"></f7-toggle>
|
||||
</template>
|
||||
</f7-list-item>
|
||||
|
||||
<f7-list-item :title="tt('Browser Cache Management')" link="/settings/browser_caches"></f7-list-item>
|
||||
<f7-list-item link="#" no-chevron :title="tt('Switch to Desktop Version')" @click="switchToDesktopVersion"></f7-list-item>
|
||||
|
||||
@@ -153,7 +162,6 @@ const version = `${getClientDisplayVersion()}`;
|
||||
const logouting = ref<boolean>(false);
|
||||
const showThemePopup = ref<boolean>(false);
|
||||
const showTimezonePopup = ref<boolean>(false);
|
||||
|
||||
const currentNickName = computed<string>(() => userStore.currentUserNickname || tt('User'));
|
||||
|
||||
const currentTheme = computed<string>({
|
||||
@@ -176,6 +184,13 @@ const currentTimezoneName = computed<string>(() => {
|
||||
return '';
|
||||
});
|
||||
|
||||
const expandCategoryTreeByDefault = computed<boolean>({
|
||||
get: () => settingsStore.appSettings.expandCategoryTreeByDefault,
|
||||
set: value => {
|
||||
settingsStore.setExpandCategoryTreeByDefault(value);
|
||||
}
|
||||
});
|
||||
|
||||
const isEnableSwipeBack = computed<boolean>({
|
||||
get: () => settingsStore.appSettings.swipeBack,
|
||||
set: value => {
|
||||
|
||||
@@ -119,6 +119,7 @@
|
||||
secondary-icon-field="icon" secondary-icon-type="category" secondary-color-field="color"
|
||||
secondary-hidden-field="hidden"
|
||||
:enable-filter="true" :filter-placeholder="tt('Find category')" :filter-no-items-text="tt('No available category')"
|
||||
:default-expanded="settingsStore.appSettings.expandCategoryTreeByDefault"
|
||||
:items="allCategories[CategoryType.Expense]"
|
||||
v-model:show="showCategorySheet"
|
||||
v-model="transaction.expenseCategoryId">
|
||||
@@ -151,6 +152,7 @@
|
||||
secondary-icon-field="icon" secondary-icon-type="category" secondary-color-field="color"
|
||||
secondary-hidden-field="hidden"
|
||||
:enable-filter="true" :filter-placeholder="tt('Find category')" :filter-no-items-text="tt('No available category')"
|
||||
:default-expanded="settingsStore.appSettings.expandCategoryTreeByDefault"
|
||||
:items="allCategories[CategoryType.Income]"
|
||||
v-model:show="showCategorySheet"
|
||||
v-model="transaction.incomeCategoryId">
|
||||
@@ -183,6 +185,7 @@
|
||||
secondary-icon-field="icon" secondary-icon-type="category" secondary-color-field="color"
|
||||
secondary-hidden-field="hidden"
|
||||
:enable-filter="true" :filter-placeholder="tt('Find category')" :filter-no-items-text="tt('No available category')"
|
||||
:default-expanded="settingsStore.appSettings.expandCategoryTreeByDefault"
|
||||
:items="allCategories[CategoryType.Transfer]"
|
||||
v-model:show="showCategorySheet"
|
||||
v-model="transaction.transferCategoryId">
|
||||
|
||||
Reference in New Issue
Block a user