diff --git a/New_College.Api/Controllers/Front/CustomerController.cs b/New_College.Api/Controllers/Front/CustomerController.cs
index 8edb47d..8069d5c 100644
--- a/New_College.Api/Controllers/Front/CustomerController.cs
+++ b/New_College.Api/Controllers/Front/CustomerController.cs
@@ -227,6 +227,31 @@ namespace New_College.Api.Controllers.Front
};
}
+
+
+ ///
+ /// 修改用户头像与名称
+ ///
+ ///
+ ///
+ [HttpPost]
+ public async Task> UpdateCustomerAvatarUrl(UpdateCustomerQuery query)
+ {
+ var result = await _services.UpdateCustomerInfo(query);
+ if (result.Id > 0)
+ {
+ var token = JwtHelper.IssueJwt(new TokenModelJwt() { Uid = result.Id, Role = "学生" });
+ result.Token = token;
+ }
+ return new MessageModel()
+ {
+ success = result.Status == 1,
+ msg = result.Status == 1 ? "成功" : "失败",
+ response = result
+ };
+ }
+
+
///
/// 根绝Id获取用户信息
///
diff --git a/New_College.Api/New_College.xml b/New_College.Api/New_College.xml
index 6f65242..24f863d 100644
--- a/New_College.Api/New_College.xml
+++ b/New_College.Api/New_College.xml
@@ -148,6 +148,13 @@
+
+
+ 修改用户头像与名称
+
+
+
+
根绝Id获取用户信息
diff --git a/New_College.Api/appsettings.json b/New_College.Api/appsettings.json
index 2263d80..344d533 100644
--- a/New_College.Api/appsettings.json
+++ b/New_College.Api/appsettings.json
@@ -201,7 +201,7 @@
},
"AliYunOss": {
- "wendpoint": "https://static-data-ycymedu.oss-cn-shanghai.aliyuncs.com",
+ "wendpoint": "https://static-data.ycymedu.com",
"accessKeyId": "LTAI5tKs3TXSbt7E4WMDcxwR",
"accessKeySecret": "EvC8MjRaQC1kHubgU4MtecZnofOb0v",
"bucket": "static-data-ycymedu",
diff --git a/New_College.Common/Helper/AliYunOssHelper.cs b/New_College.Common/Helper/AliYunOssHelper.cs
index c13f233..ffd62cc 100644
--- a/New_College.Common/Helper/AliYunOssHelper.cs
+++ b/New_College.Common/Helper/AliYunOssHelper.cs
@@ -26,7 +26,7 @@ namespace New_College.Common
{
// 上传文件。
var cc = client.PutObject(AliYunOssConfig.bucket, key, filepath);
- var newurl = string.Format("{0}{1}", AliYunOssConfig.wendpoint, key);
+ var newurl = string.Format("{0}/{1}", AliYunOssConfig.wendpoint, key);
return newurl;
}
catch (ClientException ex)
diff --git a/New_College.Services/V_CustomerInfoServices.cs b/New_College.Services/V_CustomerInfoServices.cs
index cadcbcf..11d3e12 100644
--- a/New_College.Services/V_CustomerInfoServices.cs
+++ b/New_College.Services/V_CustomerInfoServices.cs
@@ -117,6 +117,8 @@ namespace New_College.Services
}
}
+
+
///
/// 完善用户信息
///