This commit is contained in:
2025-06-25 20:25:40 +08:00
parent 90d974d739
commit 8e6df5b498
14 changed files with 357 additions and 31 deletions

View File

@@ -1,16 +1,22 @@
import router from "../router/index.js";
import {useSystemStore} from "../pinia/SystemStore/index.js";
export const toPath = (path, query = {}) => {
export const toPath = (path, query = {}, flag = false) => {
router.push({
path: path, query: query
}).then(() => {
const SystemStore = useSystemStore();
SystemStore.NOW_ROUTER = path;
Object.assign(SystemStore.NOW_ROUTER_QUERY, query);
if (!flag) {
SystemStore.NOW_ROUTER = path;
Object.assign(SystemStore.NOW_ROUTER_QUERY, query);
}
});
}
export const openPage = (path, query = {}) => {
window.open('http://localhost:9050/#/manage-materials', '_blank');
}
export const VITE_TINYMCE_KEY = () => {
return import.meta.env.VITE_TINYMCE_KEY;
}