@@ -32,7 +32,6 @@ namespace Learun.Application.Web.Areas.EducationalAdministration.Controllers | |||||
public ActionResult Index() | public ActionResult Index() | ||||
{ | { | ||||
var logininfo = LoginUserInfo.Get(); | var logininfo = LoginUserInfo.Get(); | ||||
ViewBag.isSystem = logininfo.isSystem; | |||||
ViewBag.departmentId = ""; | ViewBag.departmentId = ""; | ||||
var Model = departmentIBLL.GetEntity(logininfo.companyId, logininfo.departmentId); | var Model = departmentIBLL.GetEntity(logininfo.companyId, logininfo.departmentId); | ||||
if (Model.F_Manager == logininfo.realName) | if (Model.F_Manager == logininfo.realName) | ||||
@@ -3,8 +3,7 @@ | |||||
Layout = "~/Views/Shared/_Index.cshtml"; | Layout = "~/Views/Shared/_Index.cshtml"; | ||||
} | } | ||||
<script type="text/javascript"> | <script type="text/javascript"> | ||||
var isSystem = '@ViewBag.isSystem'; | |||||
var departmentId= '@ViewBag.departmentId' | |||||
var departmentId = '@ViewBag.departmentId' | |||||
</script> | </script> | ||||
<div class="lr-layout "> | <div class="lr-layout "> | ||||
<div class="lr-layout-center"> | <div class="lr-layout-center"> | ||||
@@ -305,7 +305,6 @@ var bootstrap = function ($, learun) { | |||||
}, | }, | ||||
search: function (param) { | search: function (param) { | ||||
param = param || {}; | param = param || {}; | ||||
param.isSystem = isSystem; | |||||
param.departmentId = departmentId; | param.departmentId = departmentId; | ||||
$('#gridtable').jfGridSet('reload', { queryJson: JSON.stringify(param) }); | $('#gridtable').jfGridSet('reload', { queryJson: JSON.stringify(param) }); | ||||
} | } | ||||
@@ -78,18 +78,10 @@ namespace Learun.Application.TwoDevelopment.EducationalAdministration | |||||
dp.Add("IsFlag", queryParam["IsFlag"].ToString(), DbType.String); | dp.Add("IsFlag", queryParam["IsFlag"].ToString(), DbType.String); | ||||
strSql.Append(" AND t.IsFlag = @IsFlag "); | strSql.Append(" AND t.IsFlag = @IsFlag "); | ||||
} | } | ||||
if (queryParam["isSystem"].ToBool() == false) | |||||
if (!queryParam["departmentId"].IsEmpty()) | |||||
{ | { | ||||
if (!queryParam["departmentId"].IsEmpty()) | |||||
{ | |||||
dp.Add("FillingDept", queryParam["departmentId"].ToString(), DbType.String); | |||||
strSql.Append(" AND t.FillingDept = @FillingDept "); | |||||
} | |||||
else | |||||
{ | |||||
dp.Add("FillingDept", "undefined11", DbType.String); | |||||
strSql.Append(" AND t.FillingDept = @FillingDept "); | |||||
} | |||||
dp.Add("FillingDept", queryParam["departmentId"].ToString(), DbType.String); | |||||
strSql.Append(" AND t.FillingDept = @FillingDept "); | |||||
} | } | ||||
//sql条件 | //sql条件 | ||||
if (!queryParam["SqlParameter"].IsEmpty()) | if (!queryParam["SqlParameter"].IsEmpty()) | ||||