优化代码

This commit is contained in:
橙子
2021-10-26 00:59:06 +08:00
parent adeb2ead7e
commit b29b6be734
10 changed files with 80 additions and 20 deletions

View File

@@ -15,6 +15,7 @@ namespace Yi.Framework.ApiMicroservice.Controllers
{
[ApiController]
[Route("api/[controller]/[action]")]
[Authorize]
public class UserController : ControllerBase
{
private readonly ILogger<UserController> _logger;
@@ -122,7 +123,7 @@ namespace Yi.Framework.ApiMicroservice.Controllers
/// 根据http上下文的用户得到该用户信息关联角色
/// </summary>
/// <returns></returns>
[Authorize]
[HttpGet]
public async Task<Result> GetUserInfoById()
{