Commit f3500547 authored by 黄奎's avatar 黄奎

页面修改

parent 5ea75dbf
using Edu.Model.ViewModel.System;
using Edu.Common.Enum.User;
using Edu.Model.ViewModel.System;
using System.Collections.Generic;
namespace Edu.Model.CacheModel
......@@ -28,6 +29,11 @@ namespace Edu.Model.CacheModel
/// </summary>
public string AccountName { get; set; }
/// <summary>
/// 账号类型(1-管理端,2,-教师端,3-助教,4-学生)
/// </summary>
public AccountTypeEnum AccountType { get; set; }
/// <summary>
/// 学校名称
/// </summary>
......
......@@ -81,6 +81,7 @@ namespace Edu.WebApi.Controllers.User
UserInfo obj = new UserInfo
{
Id = model.Id,
AccountType=model.AccountType,
Group_Id = model.Group_Id,
School_Id = model.School_Id,
AccountName = model.AccountName,
......@@ -115,8 +116,16 @@ namespace Edu.WebApi.Controllers.User
}
if (Uid > 0)
{
object obj = UserReidsCache.GetUserLoginInfo(Uid);
return ApiResult.Success(data: obj);
UserInfo userInfo = UserReidsCache.GetUserLoginInfo(Uid);
if (userInfo != null)
{
var treeList = menuModule.GetTreeMenuModule(new Model.ViewModel.System.RB_Menu_ViewModel()
{
MenuType =(int) userInfo.AccountType
});
userInfo.MenuList = treeList;
}
return ApiResult.Success(data: userInfo);
}
else
{
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment