lin
2024-03-22 ebfc739bdbbc0dd0fccd0bf47b7d2d5397c3c511
src/page/index/top/index.vue
@@ -94,6 +94,7 @@
    </div>
</template>
<script>
import { getStore } from "@/util/store"
import { setTheme } from "@/util/util"
import { resetRouter } from '@/router/router'
import { mapGetters, mapState } from "vuex"
@@ -121,6 +122,7 @@
    name: "top",
    data () {
        return {
            webType: getStore({ name: "webType" }),
            searchShow: false,
            userBox: false,
            userForm: {
@@ -168,7 +170,9 @@
                        }],
                    },
                ]
            }
            },
            showMenu: getStore({ name: "showMenu" }),
            globalUserInfo: getStore({ name: "userInfo" }),
        }
    },
    filters: {},
@@ -186,7 +190,6 @@
            showFullScren: state => state.common.showFullScren,
            showCollapse: state => state.common.showCollapse,
            showSearch: state => state.common.showSearch,
            showMenu: state => state.common.showMenu,
            showColor: state => state.common.showColor
        }),
        ...mapGetters([
@@ -242,7 +245,14 @@
            }).then(() => {
                this.$store.dispatch("LogOut").then(() => {
                    resetRouter()
                    this.$router.push({ path: "/login" })
                    if (this.webType == 'default') {
                        this.$router.push({ path: "/login" })
                    } else if (this.webType == 'govern') {
                        this.$router.push({ path: "/governLogin" })
                    } else {
                        this.$router.push({ path: "/tenementLogin" })
                    }
                })
            })
        }