refactor: extract navigator into store instead
This commit is contained in:
parent
caa3e59777
commit
6b29d3b017
10 changed files with 68 additions and 76 deletions
|
|
@ -11,7 +11,8 @@ import useAddressStore from 'stores/address';
|
|||
import useMyBranch from 'src/stores/my-branch';
|
||||
import { calculateAge } from 'src/utils/datetime';
|
||||
import { useQuasar, type QTableProps } from 'quasar';
|
||||
import useUtilsStore, { dialog, baseUrl } from 'stores/utils';
|
||||
import { dialog, baseUrl } from 'stores/utils';
|
||||
import { useNavigator } from 'src/stores/navigator';
|
||||
import { isRoleInclude, resetScrollBar } from 'src/stores/utils';
|
||||
import { BranchUserStats } from 'stores/branch/types';
|
||||
|
||||
|
|
@ -53,7 +54,7 @@ const $q = useQuasar();
|
|||
|
||||
const userStore = useUserStore();
|
||||
const flowStore = useFlowStore();
|
||||
const utilsStore = useUtilsStore();
|
||||
const navigatorStore = useNavigator();
|
||||
const optionStore = useOptionStore();
|
||||
const branchStore = useBranchStore();
|
||||
const adrressStore = useAddressStore();
|
||||
|
|
@ -662,8 +663,8 @@ async function fetchUserList() {
|
|||
}
|
||||
|
||||
onMounted(async () => {
|
||||
utilsStore.currentTitle.title = 'personnel.title';
|
||||
utilsStore.currentTitle.path = [{ text: 'personnel.caption', i18n: true }];
|
||||
navigatorStore.current.title = 'personnel.title';
|
||||
navigatorStore.current.path = [{ text: 'personnel.caption', i18n: true }];
|
||||
modeView.value = $q.screen.lt.md ? true : false;
|
||||
|
||||
await fetchUserList();
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue