20230825部门人员加岗位查询、上报集团报表工时从月报取当月工时

This commit is contained in:
2023-08-25 16:19:07 +08:00
parent 1a38e3c935
commit 5b857c97fa
8 changed files with 77 additions and 8 deletions
+9 -4
View File
@@ -46,7 +46,7 @@ namespace BLL
/// <param name="personType">人员类型</param>
/// <param name="Grid1"></param>
/// <returns></returns>
public static IEnumerable getListData(string unitId, string departId, string projetcId, string name, string idCard, string isPost, string personType,string account, Grid Grid1)
public static IEnumerable getListData(string unitId, string departId, string projetcId, string name, string idCard, string isPost, string personType, string account,string[] workPostIds, Grid Grid1)
{
IQueryable<Model.Person_Persons> getDataList = getDataLists.OrderBy(x => x.UnitId).ThenBy(x => x.DepartId);
if (!string.IsNullOrEmpty(unitId) && unitId != Const._Null)
@@ -59,8 +59,9 @@ namespace BLL
}
if (!string.IsNullOrEmpty(projetcId) && projetcId != Const._Null)
{
var idLists=(from x in db.SitePerson_PersonItem where x.ProjectId == projetcId && !x.OutTime.HasValue
select x.PersonId).Distinct().ToList();
var idLists = (from x in db.SitePerson_PersonItem
where x.ProjectId == projetcId && !x.OutTime.HasValue
select x.PersonId).Distinct().ToList();
getDataList = getDataList.Where(x => idLists.Contains(x.PersonId));
}
@@ -80,7 +81,7 @@ namespace BLL
{
getDataList = getDataList.Where(e => e.IdentityCard.Contains(idCard));
}
if (!string.IsNullOrEmpty(isPost) && isPost != "-1" && isPost != Const._Null)
{
if (isPost == Const._True)
@@ -93,6 +94,10 @@ namespace BLL
}
}
if (workPostIds.Count() > 0)
{
getDataList = getDataList.Where(e => workPostIds.Contains(e.WorkPostId));
}
count = getDataList.Count();
if (count == 0)
{