|
|
@@ -38,18 +38,19 @@ import { ref, onMounted } from "vue";
|
|
|
export default {
|
|
|
setup() {
|
|
|
let tabs = ref([
|
|
|
- { path: 0, tabText: "运输安全管理中心" },
|
|
|
- { path: 0, tabText: "智能交易中心" },
|
|
|
- { path: 0, tabText: "环境中心" },
|
|
|
+ { path: "/transportationSafetyCenter", tabText: "运输安全管理中心" },
|
|
|
+ { path: "/transportationSafetyCenter", tabText: "智能交易中心" },
|
|
|
+ { path: "/transportationSafetyCenter", tabText: "环境中心" },
|
|
|
{ path: "/digitalEmpowermentCenter", tabText: "数字化赋能中心" },
|
|
|
]);
|
|
|
function changeTab(item) {
|
|
|
store.commit("changeTab", item.tabText);
|
|
|
- if (item.path) {
|
|
|
- router.push(item.path);
|
|
|
- } else {
|
|
|
- router.push("/transportationSafetyCenter");
|
|
|
- }
|
|
|
+ router.push({
|
|
|
+ path: item.path,
|
|
|
+ query: {
|
|
|
+ tabText: item.tabText,
|
|
|
+ },
|
|
|
+ });
|
|
|
}
|
|
|
async function logOut() {
|
|
|
let res = await store.dispatch("LogOut");
|