From 79ab6f308d8567805647a77c41900782b0626593 Mon Sep 17 00:00:00 2001 From: sfmind Date: Thu, 21 Apr 2022 01:47:01 +0800 Subject: [PATCH] =?UTF-8?q?=E7=94=A8=E6=88=B7=E4=BF=AE=E6=94=B9=E6=98=B5?= =?UTF-8?q?=E7=A7=B0?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- yudao-ui-app/common/api.js | 6 +++ yudao-ui-app/pages/profile/profile.vue | 72 +++++++++++++++++++------- 2 files changed, 59 insertions(+), 19 deletions(-) diff --git a/yudao-ui-app/common/api.js b/yudao-ui-app/common/api.js index 0ba9e579f..307b37505 100644 --- a/yudao-ui-app/common/api.js +++ b/yudao-ui-app/common/api.js @@ -1,3 +1,4 @@ +//请求工具参考https://ext.dcloud.net.cn/plugin?id=392 const { http } = uni.$u /* login */ @@ -19,6 +20,11 @@ export const updateAvatar = filePath => fileType: 'image', filePath: filePath }) +//修改用户昵称 +export const updateNickname = params => + http.put('/app-api/member/user/update-nickname', {}, { + params + }) /* index */ // 获取滚动图数据 diff --git a/yudao-ui-app/pages/profile/profile.vue b/yudao-ui-app/pages/profile/profile.vue index c556b8c4f..ac129959f 100644 --- a/yudao-ui-app/pages/profile/profile.vue +++ b/yudao-ui-app/pages/profile/profile.vue @@ -10,9 +10,33 @@ 昵称: - + {{ userInfo.nickname }} - + + + + + + + + @@ -27,7 +51,7 @@