diff --git a/Learun.Framework.Ultimate V7/Learun.Application.Web/XmlConfig/system.config b/Learun.Framework.Ultimate V7/Learun.Application.Web/XmlConfig/system.config index 871d1b737..7044f579f 100644 --- a/Learun.Framework.Ultimate V7/Learun.Application.Web/XmlConfig/system.config +++ b/Learun.Framework.Ultimate V7/Learun.Application.Web/XmlConfig/system.config @@ -167,6 +167,8 @@ + + diff --git a/Learun.Framework.Ultimate V7/Learun.Application.WebApi/XmlConfig/system.config b/Learun.Framework.Ultimate V7/Learun.Application.WebApi/XmlConfig/system.config index 9ef90188b..6958bd859 100644 --- a/Learun.Framework.Ultimate V7/Learun.Application.WebApi/XmlConfig/system.config +++ b/Learun.Framework.Ultimate V7/Learun.Application.WebApi/XmlConfig/system.config @@ -102,8 +102,10 @@ + + - + \ No newline at end of file diff --git a/Learun.Framework.Ultimate V7/Learun.Framework.Module/Learun.Application.Module/Learun.Application.TwoDevelopment/AssetManagementSystem/FundsApply/FundsApplyService.cs b/Learun.Framework.Ultimate V7/Learun.Framework.Module/Learun.Application.Module/Learun.Application.TwoDevelopment/AssetManagementSystem/FundsApply/FundsApplyService.cs index 12ec5cf91..771154266 100644 --- a/Learun.Framework.Ultimate V7/Learun.Framework.Module/Learun.Application.Module/Learun.Application.TwoDevelopment/AssetManagementSystem/FundsApply/FundsApplyService.cs +++ b/Learun.Framework.Ultimate V7/Learun.Framework.Module/Learun.Application.Module/Learun.Application.TwoDevelopment/AssetManagementSystem/FundsApply/FundsApplyService.cs @@ -4,6 +4,7 @@ using Learun.Util; using System; using System.Collections.Generic; using System.Data; +using System.Linq; using System.Text; namespace Learun.Application.TwoDevelopment.AssetManagementSystem @@ -45,10 +46,20 @@ namespace Learun.Application.TwoDevelopment.AssetManagementSystem dp.Add("endTime", queryParam["EndTime"].ToDate(), DbType.DateTime); strSql.Append(" AND ( t.ApplyTime >= @startTime AND t.ApplyTime <= @endTime ) "); } - if (!queryParam["ApplyUser"].IsEmpty()) + var userLogin = LoginUserInfo.Get(); + var PrincipalRole = Config.GetValue("PrincipalRoleId"); + var loginInfoRoleIds = LoginUserInfo.Get().roleIds; + if (!userLogin.Description.Contains("管理员") && !loginInfoRoleIds.Split(',').Contains(PrincipalRole)) { - dp.Add("ApplyUser", queryParam["ApplyUser"].ToString(), DbType.String); - strSql.Append(" AND t.ApplyUser = @ApplyUser "); + strSql.Append(" AND t.ApplyUser = '" + userLogin.userId + "' "); + } + else + { + if (!queryParam["ApplyUser"].IsEmpty()) + { + dp.Add("ApplyUser", queryParam["ApplyUser"].ToString(), DbType.String); + strSql.Append(" AND t.ApplyUser = @ApplyUser "); + } } return this.BaseRepository("CollegeMIS").FindList(strSql.ToString(), dp, pagination); }