| | |
| | | <template>
|
| | | <el-form ref="form" :model="user" :rules="rules" label-width="80px">
|
| | | <el-form-item label="用户昵称" prop="nickName">
|
| | | <el-input v-model="user.nickName" />
|
| | | <el-input v-model="user.nickName" maxlength="30" />
|
| | | </el-form-item>
|
| | | <el-form-item label="手机号码" prop="phonenumber">
|
| | | <el-input v-model="user.phonenumber" maxlength="11" />
|
| | |
| | |
|
| | | <script>
|
| | | import { updateUserProfile } from "@/api/system/user";
|
| | | import Global from "@/layout/components/global.js";
|
| | |
|
| | | export default {
|
| | | props: {
|
| | |
| | | { required: true, message: "邮箱地址不能为空", trigger: "blur" },
|
| | | {
|
| | | type: "email",
|
| | | message: "'请输入正确的邮箱地址",
|
| | | message: "请输入正确的邮箱地址",
|
| | | trigger: ["blur", "change"]
|
| | | }
|
| | | ],
|
| | |
| | | this.$refs["form"].validate(valid => {
|
| | | if (valid) {
|
| | | updateUserProfile(this.user).then(response => {
|
| | | this.msgSuccess("修改成功");
|
| | | this.$modal.msgSuccess("修改成功");
|
| | | });
|
| | | }
|
| | | });
|
| | | },
|
| | | close() {
|
| | | Global.$emit("removeCache", "closeSelectedTag", this.$route);
|
| | | this.$store.dispatch("tagsView/delView", this.$route);
|
| | | this.$router.push({ path: "/index" });
|
| | | this.$tab.closePage();
|
| | | }
|
| | | }
|
| | | };
|