From 9910bf9ed232ed66ed57ce878592bb2a2efb52b6 Mon Sep 17 00:00:00 2001
From: yujialong <479214531@qq.com>
Date: Wed, 13 Apr 2022 14:27:01 +0800
Subject: [PATCH] =?UTF-8?q?=E7=94=A8=E6=88=B7=E4=BF=AE=E6=94=B9=EF=BC=88?=
=?UTF-8?q?=E9=9D=99=E6=80=81=EF=BC=89?=
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
---
src/utils/api.js | 2 +-
src/utils/http.js | 4 +-
src/views/course/contentSettings.vue | 49 +++-
src/views/setting/index.vue | 9 +-
src/views/setting/info.vue | 4 +-
src/views/user/AddUser.vue | 347 ++++++---------------------
src/views/user/User.vue | 26 +-
7 files changed, 129 insertions(+), 312 deletions(-)
diff --git a/src/utils/api.js b/src/utils/api.js
index 51e754d..ca10056 100644
--- a/src/utils/api.js
+++ b/src/utils/api.js
@@ -56,7 +56,7 @@ export default {
selectAccountDetail: `users/users/userAccount/selectAccountDetail`,
selectUserSysBind: `users/users/userAccount/selectUserSysBind`,
updatePersonCenter: `users/users/userAccount/updatePersonCenter`,
- updateUserAvatars: `users/users/userAccount/updateUserAvatars`,
+ updateUserAvatars: `${Setting.host}users/users/userAccount/updateUserAvatars`,
userInfo: `users/users/userAccount/userInfo`,
// bindPhoneOrEmail: `users/users/userAccount/bindPhoneOrEmail`,
// sendPhoneOrEmailCode: `users/users/userAccount/sendPhoneOrEmailCode`,
diff --git a/src/utils/http.js b/src/utils/http.js
index 306219a..20c4416 100644
--- a/src/utils/http.js
+++ b/src/utils/http.js
@@ -132,9 +132,9 @@ export function get(url, params){
/**
* post方法,对应post请求
*/
-export function post(url, params) {
+export function post(url, params, config) {
return new Promise((resolve, reject) => {
- axios.post(url,params)
+ axios.post(url,params, config)
.then(res => {
return resolve(res.data);
})
diff --git a/src/views/course/contentSettings.vue b/src/views/course/contentSettings.vue
index 3be1904..269d5d2 100644
--- a/src/views/course/contentSettings.vue
+++ b/src/views/course/contentSettings.vue
@@ -85,17 +85,18 @@
:before-upload="beforeUpload"
:on-remove="handleRemove"
:on-error="uploadError"
- :on-success="uploadSuccess"
:before-remove="beforeRemove"
:limit="1"
:on-exceed="handleExceed"
:action="this.api.fileupload"
:file-list="uploadList"
:headers="headers"
+ :http-request="handleRequest"
name="file"
>
上传资源
+
@@ -113,17 +114,18 @@
:before-upload="beforeUpload"
:on-remove="handleRemove"
:on-error="uploadError"
- :on-success="uploadSuccess"
:before-remove="beforeRemove"
:limit="1"
:on-exceed="handleExceed"
:action="this.api.fileupload"
:file-list="uploadList"
:headers="headers"
+ :http-request="handleRequest"
name="file"
>
上传资源
+