| | |
| | | import * as api from "@/axios/api"; |
| | | import { Toast, MessageBox } from "mint-ui"; |
| | | import { isNull, pwdReg } from "@/utils/utils"; |
| | | import { mapMutations } from "vuex"; |
| | | |
| | | export default { |
| | | name: "newUser", |
| | |
| | | } |
| | | }, |
| | | methods: { |
| | | ...mapMutations(["undataToken"]), |
| | | popClose() { |
| | | this.settingDialog = false; |
| | | }, |
| | |
| | | }, |
| | | async toRegister() { |
| | | // 注销登陆 |
| | | |
| | | window.localStorage.removeItem("USERTOKEN"); // 清空本地存储 USERTOKEN字段 |
| | | this.clearCookie(); |
| | | let data = await api.logout(); |
| | | if (data.status === 0) { |
| | | this.undataToken(""); |
| | | // Toast(data.msg) |
| | | this.$router.push("/login"); |
| | | } else { |