Commit 0c7818a0 authored by 黄奎's avatar 黄奎

页面修改

parent 920ed0e2
......@@ -99,5 +99,10 @@ namespace Edu.Model.CacheModel
/// 功能权限列表
/// </summary>
public object ActionMenuList { get; set; }
/// <summary>
/// 上传配置
/// </summary>
public object UploadConfig { get; set; }
}
}
\ No newline at end of file
......@@ -70,5 +70,10 @@ namespace Edu.Model.ViewModel.Course
/// 查询条件
/// </summary>
public BackClassConditionEnum? Conditon { get; set; }
/// <summary>
/// 是否是特殊节点审核(1-是)
/// </summary>
public int SpecialNode { get; set; }
}
}
......@@ -576,7 +576,6 @@ namespace Edu.Module.Course
/// <param name="modelNext">审核关联</param>
private bool InsertAuditRelevanceNext(RB_Student_BackClass backModel, RB_Student_BackRelevance_ViewModel modelNext)
{
if (modelNext != null)
{
RB_Student_BackRelevance_ViewModel auditRelevance = modelNext.RefMapperTo<RB_Student_BackRelevance_ViewModel>();
......@@ -694,37 +693,62 @@ namespace Edu.Module.Course
obj.Add(new
{
NodeName = "制单人",
AduitStatus = "发起",
AduitStatus = 2,
AuditWayName="",
AduitStatusName = "发起",
SubList = new List<object>()
{
new{
AduitName= UserReidsCache.GetUserLoginInfo(backModel.CreateBy)?.AccountName ?? "",
Description=backModel.ApplyReason,
CreateTime=Common.ConvertHelper.FormatTime(backModel.CreateTime),
AuditStatus=WFRrocessStatus.AuditThrough,
AuditStatusName = WFRrocessStatus.AuditThrough.ToName(),
}
}
});
foreach (var item in arList)
var existsList = arList.Where(qitem => aurList.Any(oldItem => qitem.Id == oldItem.BackrelevanceId));
foreach (var item in existsList)
{
obj.Add(new
{
NodeName = item.AuditDescription,
AduitStatus = item.Stauts,
AuditWayName = item.AuditWay.ToName(),
AduitStatusName = GetWFRrocessStatusStrModule(item.Stauts),
AuditWayName = item.AuditWay != WFTAuditWayEnum.Successively ? item.AuditWay.ToName() : "",
SubList = aurList.Where(qitem => qitem.AuditId == item.Id).Select(qitem => new
{
AduitName = UserReidsCache.GetUserLoginInfo(qitem.AuditEmId)?.AccountName ?? "",
qitem.Description,
Description = !string.IsNullOrEmpty(qitem.Description) ? qitem.Description : "无",
CreateTime = Common.ConvertHelper.FormatTime(qitem.UpdateTime),
AuditStatus = qitem.AuditStatus.ToName(),
AuditWayName = item.AuditWay.ToName(),
qitem.AuditStatus,
AuditStatusName = GetWFRrocessStatusStrModule(qitem.AuditStatus),
})
});
}
return obj;
}
/// <summary>
/// 获取审核状态字符串
/// </summary>
/// <param name="status"></param>
/// <returns></returns>
private string GetWFRrocessStatusStrModule(WFRrocessStatus status)
{
var statusName = "待审";
switch (status)
{
case WFRrocessStatus.AuditNotThrough: statusName = "拒绝"; break;
case WFRrocessStatus.AuditThrough: statusName = "通过"; break;
case WFRrocessStatus.NotAudit: statusName = "待审"; break;
case WFRrocessStatus.OtherHaveAudit: statusName = "通过"; break;
case WFRrocessStatus.Rejected: statusName = "驳回"; break;
}
return statusName;
}
/// <summary>
/// 退课一键制单
/// </summary>
......
......@@ -101,6 +101,17 @@ namespace Edu.Module.System
{
item.FlowId = extModel.FlowId;
item.SortNum = SortNum;
if (item.FlowAduitList != null )
{
if (item.FlowAduitList.Count == 1)
{
item.NodeName = item.FlowAduitList[0].AduitName;
}
else
{
item.NodeName = string.Join(",", item.FlowAduitList.Select(qitem => qitem.AduitName));
}
}
var newNodeId = flow_NodeRepository.Insert(item);
item.NodeId = newNodeId;
flag = newNodeId > 0;
......@@ -141,6 +152,17 @@ namespace Edu.Module.System
{
nItem.FlowId = extModel.FlowId;
nItem.SortNum = SortNum;
if (nItem.FlowAduitList != null)
{
if (nItem.FlowAduitList.Count == 1)
{
nItem.NodeName = nItem.FlowAduitList[0].AduitName;
}
else
{
nItem.NodeName = string.Join(",", nItem.FlowAduitList.Select(qitem => qitem.AduitName));
}
}
if (nItem.NodeId == 0)
{
var newNodeId = flow_NodeRepository.Insert(nItem);
......@@ -162,6 +184,7 @@ namespace Edu.Module.System
flag= flow_AduitInfoRepository.Insert(subItem)>0;
}
}
SortNum++;
}
}
}
......
......@@ -25,9 +25,14 @@ namespace Edu.Repository.Course
{
var parameters = new DynamicParameters();
StringBuilder builder = new StringBuilder();
string isSpecNode = "";
if (query.Conditon == Common.Enum.Course.BackClassConditionEnum.WaitAgree)
{
isSpecNode = string.Format(",IFNULL((SELECT SpecialNode FROM rb_student_backrelevance WHERE Id IN(SELECT BackrelevanceId FROM rb_student_backrecord WHERE ConditionId=A.BackId AND AuditStatus=1 AND AuditEmId={0})),0) AS SpecialNode ", query.CreateBy);
}
builder.AppendFormat(@"
SELECT A.*,IFNULL(B.GuestName,'') AS GuestName,IFNULL(C.SName,'') AS SchoolName,IFNULL(D.ClassName,'') AS ClassName,IFNULL(T.TeacherName,'') AS TeacherName
,IFNULL(E.EnterID,0) AS EnterID,IFNULL(F.CourseName,'') AS CourseName
,IFNULL(E.EnterID,0) AS EnterID,IFNULL(F.CourseName,'') AS CourseName {0}
FROM RB_Student_BackClass AS A LEFT JOIN rb_order_guest AS B ON A.GuestId=B.Id
LEFT JOIN rb_school AS C ON A.SchoolId=C.SId
LEFT JOIN rb_class AS D ON A.ClassId=D.ClassId
......@@ -35,7 +40,7 @@ FROM RB_Student_BackClass AS A LEFT JOIN rb_order_guest AS B ON A.GuestId=B.Id
AS T ON A.TeacherId=T.Id
LEFT JOIN rb_order AS E ON A.OrderId=E.OrderId
LEFT JOIN rb_course AS F ON D.CouseId=F.CourseId
WHERE 1=1 ");
WHERE 1=1 ", isSpecNode);
if (query != null)
{
if (query.Group_Id > 0)
......
......@@ -6,6 +6,7 @@ using Edu.Common.Enum.User;
using Edu.Common.Plugin;
using Edu.Model.CacheModel;
using Edu.Model.ViewModel.User;
using Edu.Module.Public;
using Edu.Module.System;
using Edu.Module.User;
using Edu.WebApi.Filter;
......@@ -34,6 +35,11 @@ namespace Edu.WebApi.Controllers.User
/// </summary>
private readonly MenuModule menuModule = new MenuModule();
/// <summary>
/// 公用处理类
/// </summary>
private readonly PublicModule publicModule = new PublicModule();
/// <summary>
/// 用户登录
/// </summary>
......@@ -93,6 +99,8 @@ namespace Edu.WebApi.Controllers.User
}, postIds: model.Post_Id.ToString());
//获取功能权限列表
var actionList = menuModule.GetPostMenuFunctionListModule(model.Post_Id.ToString());
//上传配置
var uploadConfig = publicModule.GetFileStoreList(new Model.Public.RB_File_Store() { Group_Id = model.Group_Id, IsDefault = 1 })?.FirstOrDefault();
UserInfo obj = new UserInfo
{
Id = model.Id,
......@@ -113,6 +121,15 @@ namespace Edu.WebApi.Controllers.User
PostId = model.Post_Id,
PostName = model.PostName,
ActionMenuList= actionList?.Select(qitem => new {qitem.FunctionCode,qitem.FunctionName,qitem.MenuName,qitem.MenuUrl }),
UploadConfig = new {
uploadConfig?.Bucket,
uploadConfig?.StoreType,
uploadConfig?.Region,
uploadConfig?.CustomDomain,
uploadConfig?.SecretKey,
uploadConfig?.SecretId,
uploadConfig?.UploadDomain
}
};
UserReidsCache.UserInfoSet(Cache.CacheKey.User_Login_Key + model.Id, obj, Common.Config.JwtExpirTime);
return ApiResult.Success(data: obj);
......@@ -149,6 +166,18 @@ namespace Edu.WebApi.Controllers.User
//获取功能权限列表
var actionList = menuModule.GetPostMenuFunctionListModule(userInfo.PostId.ToString());
userInfo.ActionMenuList = actionList?.Select(qitem => new { qitem.FunctionCode, qitem.FunctionName, qitem.MenuName, qitem.MenuUrl });
//上传配置
var uploadConfig = publicModule.GetFileStoreList(new Model.Public.RB_File_Store() { Group_Id = userInfo.Group_Id, IsDefault = 1 })?.FirstOrDefault();
userInfo.UploadConfig = new
{
uploadConfig?.Bucket,
uploadConfig?.StoreType,
uploadConfig?.Region,
uploadConfig?.CustomDomain,
uploadConfig?.SecretKey,
uploadConfig?.SecretId,
uploadConfig?.UploadDomain
};
}
return ApiResult.Success(data: userInfo);
}
......
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