提交:个人中心 更新头像后保存信息导致更替原来头像问题

This commit is contained in:
23688nl 2022-09-16 15:08:22 +08:00
parent d647200020
commit da45aed2d8
1 changed files with 2 additions and 2 deletions

View File

@ -2,7 +2,7 @@
<el-form ref="form" :model="user" :rules="rules" label-width="80px">
<el-form-item label="用户昵称" prop="nickName">
<el-input v-model="user.nickName" />
</el-form-item>
</el-form-item>
<el-form-item label="手机号码" prop="phonenumber">
<el-input v-model="user.phonenumber" maxlength="11" />
</el-form-item>
@ -61,7 +61,7 @@ export default {
submit() {
this.$refs["form"].validate(valid => {
if (valid) {
updateUserProfile(this.user).then(response => {
updateUserProfile(Object.assign(this.user, { avatar: undefined })).then(response => {
this.msgSuccess("修改成功");
});
}