河北专项检查和移动端

This commit is contained in:
2025-04-06 23:26:22 +08:00
parent 64c7be5db4
commit 8aba5b01bc
204 changed files with 41904 additions and 3226 deletions
+3 -1
View File
@@ -614,7 +614,9 @@ namespace BLL
var getDataLists = (from x in Funs.DB.ProjectData_TeamGroup
where x.ProjectId == projectId && (unitId == null || x.UnitId == unitId)
orderby x.TeamGroupCode
select new Model.BaseInfoItem { BaseInfoId = x.TeamGroupId, BaseInfoCode = x.TeamGroupCode, BaseInfoName = x.TeamGroupName }).ToList();
select new Model.BaseInfoItem { BaseInfoId = x.TeamGroupId, BaseInfoCode = x.TeamGroupCode, BaseInfoName = x.TeamGroupName, GroupLeaderId=x.GroupLeaderId,
GroupLeaderName= Funs.DB.SitePerson_Person.FirstOrDefault(p=>p.PersonId == x.GroupLeaderId).PersonName,
Remark = x.Remark }).ToList();
return getDataLists;
}
+18
View File
@@ -1,4 +1,5 @@
using EmitMapper;
using Model;
using System.Collections.Generic;
using System.Linq;
@@ -6,6 +7,23 @@ namespace BLL
{
public static class APIProjectService
{
#region
public static List<Model.ProjectItem> geProjects()
{
using (Model.SGGLDB db = new Model.SGGLDB(Funs.ConnString))
{
return (from x in db.Base_Project
select new Model.ProjectItem()
{
ProjectId = x.ProjectId,
ProjectName = x.ProjectName
}).ToList(); ;
}
}
#endregion
/// <summary>
/// 根据userId获取用户信息
/// </summary>
@@ -150,6 +150,42 @@ namespace BLL
}
#region
public static List<Model.HazardRegisterItem> getHazardRegisterByProjectIdStates(string projectId, string date)
{
using (Model.SGGLDB db = new Model.SGGLDB(Funs.ConnString))
{
DateTime mdate = Funs.GetNewDateTimeOrNow(date);
var hazardRegisters = (from x in db.HSSE_Hazard_HazardRegister
//join y in db.Base_Project on x.ProjectId equals projectId
where x.ProjectId == projectId
&& x.CheckTime.Value.Year == mdate.Year
&& x.CheckTime.Value.Month == mdate.Month
&& x.CheckTime.Value.Day == mdate.Day
select new Model.HazardRegisterItem
{
HazardRegisterId = x.HazardRegisterId,
ProjectId = x.ProjectId,
ProjectName = db.Base_Project.First(p=>p.ProjectId == x.ProjectId).ProjectName,
States = x.States,
Place = x.Place,
CheckTime = x.CheckTime,
CheckManName = db.Sys_User.First(u => u.UserId == x.CheckManId).UserName,
RectifyName = x.RectifyName,
RegisterDef = x.RegisterDef,
RegisterTypesName = db.HSSE_Hazard_HazardRegisterTypes.First(T => x.RegisterTypesId == T.RegisterTypesId).RegisterTypesName,
Rectification = x.Rectification,
ResponsibilityUnitName = db.Base_Unit.First(U => x.ResponsibleUnit == U.UnitId).UnitName,
ResponsibilityManName = db.Sys_User.First(User => x.ResponsibleMan == User.UserId).UserName,
RectificationTime = x.RectificationTime,
Risk_Level = x.Risk_Level,
}).OrderBy(x => x.CheckTime).ToList();
return hazardRegisters;
}
}
#endregion
/// <summary>
/// 安全巡检
/// </summary>
+33
View File
@@ -653,6 +653,39 @@ namespace BLL
}
#endregion
#region ()
public static List<Model.MeetingItem> getClassMeetingList(string projectId, string meetingDate)
{
using (Model.SGGLDB db = new Model.SGGLDB(Funs.ConnString))
{
List<Model.MeetingItem> getMeetItem = new List<Model.MeetingItem>();
DateTime mdate = Funs.GetNewDateTimeOrNow(meetingDate);
getMeetItem = (from x in db.Meeting_ClassMeeting
where x.ProjectId == projectId
&& x.ClassMeetingDate.Value.Year == mdate.Year && x.ClassMeetingDate.Value.Month == mdate.Month && x.ClassMeetingDate.Value.Day == mdate.Day
select new Model.MeetingItem
{
MeetingId = x.ClassMeetingId,
ProjectId = x.ProjectId,
UnitId = x.UnitId,
UnitName = db.Base_Unit.First(u => u.UnitId == x.UnitId).UnitName,
TeamGroupId = x.TeamGroupId,
TeamGroupName = db.ProjectData_TeamGroup.First(u => u.TeamGroupId == x.TeamGroupId).TeamGroupName,
MeetingCode = x.ClassMeetingCode,
MeetingName = x.ClassMeetingName,
CompileDate = string.Format("{0:yyyy-MM-dd HH:mm}", x.CompileDate),
MeetingHostManOther = x.MeetingHostManOther,
CompileManId = x.CompileMan,
CompileManName = db.Sys_User.First(u => u.UserId == x.CompileMan).UserName,
AttentPersonNum = x.AttentPersonNum ?? 0,
}).ToList();
return getMeetItem;
}
}
#endregion
#region
/// <summary>
/// 根据时间获取各单位班会情况