diff --git a/DataBase/版本日志/SGGLDB_2025-04-17-xiaj.sql b/DataBase/版本日志/SGGLDB_2025-04-17-xiaj.sql index e16e396..d8d9fd0 100644 --- a/DataBase/版本日志/SGGLDB_2025-04-17-xiaj.sql +++ b/DataBase/版本日志/SGGLDB_2025-04-17-xiaj.sql @@ -1,4 +1,26 @@ + +--1Ŀ +IF NOT EXISTS (SELECT * FROM Sys_Menu WHERE MenuId = 'F2601FA2-2C70-44A2-A2B0-2E3A5458AE00') +BEGIN + --Ŀ + INSERT INTO dbo.Sys_Menu(MenuId,MenuName,Url,SortIndex,SuperMenu,MenuType,IsOffice,IsEnd,IsUsed) + VALUES('F2601FA2-2C70-44A2-A2B0-2E3A5458AE00','Ŀ','/SysManage/Schedule.aspx',100,'0','Menu_ProjectSet',0,1,1) +END +GO + +IF NOT EXISTS (SELECT * FROM Sys_ButtonToMenu WHERE MenuId = 'F2601FA2-2C70-44A2-A2B0-2E3A5458AE00') +BEGIN + --Ŀ + INSERT INTO dbo.Sys_ButtonToMenu(ButtonToMenuId,MenuId,ButtonName,SortIndex) + VALUES('9FE81E00-A0B5-4CCF-8324-8E9D8F683468','F2601FA2-2C70-44A2-A2B0-2E3A5458AE00','',1) + INSERT INTO dbo.Sys_ButtonToMenu(ButtonToMenuId,MenuId,ButtonName,SortIndex) + VALUES('289CA335-8A27-45D6-A45C-576B20396534','F2601FA2-2C70-44A2-A2B0-2E3A5458AE00','޸',2) + INSERT INTO dbo.Sys_ButtonToMenu(ButtonToMenuId,MenuId,ButtonName,SortIndex) + VALUES('5DE2147A-C361-4931-AD0C-AE1866AFC9EB','F2601FA2-2C70-44A2-A2B0-2E3A5458AE00','ɾ',3) + INSERT INTO dbo.Sys_ButtonToMenu(ButtonToMenuId,MenuId,ButtonName,SortIndex) + VALUES('ADCFE25F-2F13-46A1-A367-70E942D0F1A2','F2601FA2-2C70-44A2-A2B0-2E3A5458AE00','',4) +END GO /****** Object: Table [dbo].[Sys_Schedule] Script Date: 2025-4-17 16:33:59 ******/ diff --git a/SUBQHSE/BLL/BLL.csproj b/SUBQHSE/BLL/BLL.csproj index 8017a91..0dce8de 100644 --- a/SUBQHSE/BLL/BLL.csproj +++ b/SUBQHSE/BLL/BLL.csproj @@ -855,6 +855,7 @@ + diff --git a/SUBQHSE/BLL/Common/Const.cs b/SUBQHSE/BLL/Common/Const.cs index 78bcccd..2d66c6c 100644 --- a/SUBQHSE/BLL/Common/Const.cs +++ b/SUBQHSE/BLL/Common/Const.cs @@ -4402,6 +4402,10 @@ namespace BLL /// 项目环境设置 /// public const string CQMSSysSetMenuId = "9c62332c-d31f-4575-a323-49537bf335e8"; + /// + /// 项目进度设置 + /// + public const string SysSetScheduleMenuId = "F2601FA2-2C70-44A2-A2B0-2E3A5458AE00"; #endregion #region WBS定制管理 diff --git a/SUBQHSE/BLL/SysManage/ScheduleService.cs b/SUBQHSE/BLL/SysManage/ScheduleService.cs new file mode 100644 index 0000000..464d186 --- /dev/null +++ b/SUBQHSE/BLL/SysManage/ScheduleService.cs @@ -0,0 +1,45 @@ +using System.Linq; + +namespace BLL +{ + public class ScheduleService + { + public static Model.SUBQHSEDB db = Funs.DB; + + /// + /// 添加 + /// + /// + public static void Add(Model.Sys_Schedule model) + { + using (Model.SUBQHSEDB db = new Model.SUBQHSEDB(Funs.ConnString)) + { + Model.Sys_Schedule newModel = new Model.Sys_Schedule(); + newModel.ScheduleId = model.ScheduleId; + newModel.ScheduleName = model.ScheduleName; + newModel.ScheduleDate = model.ScheduleDate; + newModel.ProjectId = model.ProjectId; + newModel.SortId = model.SortId; + db.Sys_Schedule.InsertOnSubmit(newModel); + db.SubmitChanges(); + } + } + + /// + /// 修改 + /// + /// + public static void Update(Model.Sys_Schedule model) + { + using (var db = new Model.SUBQHSEDB(Funs.ConnString)) + { + Model.Sys_Schedule newModel = db.Sys_Schedule.First(e => e.ScheduleId == model.ScheduleId); + newModel.ScheduleName = model.ScheduleName; + newModel.ScheduleDate = model.ScheduleDate; + newModel.ScheduleDate = model.ScheduleDate; + newModel.ProjectId = model.ProjectId; + db.SubmitChanges(); + } + } + } +} diff --git a/SUBQHSE/FineUIPro.Web/FineUIPro.Web.csproj b/SUBQHSE/FineUIPro.Web/FineUIPro.Web.csproj index f0b30e5..b86f715 100644 --- a/SUBQHSE/FineUIPro.Web/FineUIPro.Web.csproj +++ b/SUBQHSE/FineUIPro.Web/FineUIPro.Web.csproj @@ -1251,6 +1251,8 @@ + + @@ -12264,6 +12266,20 @@ LocationSelect.aspx + + Schedule.aspx + ASPXCodeBehind + + + Schedule.aspx + + + ScheduleEdit.aspx + ASPXCodeBehind + + + ScheduleEdit.aspx + BenchmarkWorkSite.aspx ASPXCodeBehind diff --git a/SUBQHSE/FineUIPro.Web/SysManage/Schedule.aspx b/SUBQHSE/FineUIPro.Web/SysManage/Schedule.aspx new file mode 100644 index 0000000..f640bff --- /dev/null +++ b/SUBQHSE/FineUIPro.Web/SysManage/Schedule.aspx @@ -0,0 +1,87 @@ +<%@ Page Language="C#" AutoEventWireup="true" CodeBehind="Schedule.aspx.cs" Inherits="FineUIPro.Web.SysManage.Schedule" %> + + + + + + + + + + +
+ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + \ No newline at end of file diff --git a/SUBQHSE/FineUIPro.Web/SysManage/Schedule.aspx.cs b/SUBQHSE/FineUIPro.Web/SysManage/Schedule.aspx.cs new file mode 100644 index 0000000..d350d68 --- /dev/null +++ b/SUBQHSE/FineUIPro.Web/SysManage/Schedule.aspx.cs @@ -0,0 +1,139 @@ +using System; +using System.Collections.Generic; +using System.Data; +using System.Data.SqlClient; +using System.Linq; +using BLL; + + +namespace FineUIPro.Web.SysManage +{ + public partial class Schedule : PageBase + { + public string Projectid + { + get + { + return (string)ViewState["Projectid"]; + } + set + { + ViewState["Projectid"] = value; + } + } + protected void Page_Load(object sender, EventArgs e) + { + if (!IsPostBack) + { + Projectid = CurrUser.LoginProjectId; + ////权限按钮方法 + this.GetButtonPower(); + // 绑定表格 + this.BindGrid(); + } + } + + #region 获取按钮权限 + /// + /// 获取按钮权限 + /// + /// + /// + private void GetButtonPower() + { + if (Request.Params["value"] == "0") + { + return; + } + + var buttonList = BLL.CommonService.GetAllButtonList(this.CurrUser.LoginProjectId, this.CurrUser.UserId, Const.SysSetScheduleMenuId); + if (buttonList.Count() > 0) + { + if (buttonList.Contains(BLL.Const.BtnAdd)) + { + this.btnNew.Hidden = false; + } + if (buttonList.Contains(BLL.Const.BtnModify)) + { + this.btnMenuEdit.Hidden = false; + } + } + } + #endregion + + #region 绑定表格 + /// + /// 绑定数据 + /// + private void BindGrid() + { + //查询user表里岗位项目角色是群安员的用户 + string strSql = @"select ScheduleId,ScheduleName,ScheduleDate,S.ProjectId,J.ProjectName,SortId from Sys_Schedule S + left join Base_Project J on S.ProjectId= J.ProjectId + WHERE 1=1 "; + List listStr = new List(); + strSql += " AND S.ProjectId=@ProjectId "; + listStr.Add(new SqlParameter("@ProjectId", CurrUser.LoginProjectId)); + strSql += " order by SortId "; + SqlParameter[] parameter = listStr.ToArray(); + DataTable tb = SQLHelper.GetDataTableRunText(strSql, parameter); + + Grid1.RecordCount = tb.Rows.Count; + //tb = GetFilteredTable(Grid1.FilteredData, tb); + var table = this.GetPagedDataTable(Grid1, tb); + Grid1.DataSource = table; + Grid1.DataBind(); + } + #endregion + + /// + /// 关闭弹出窗 + /// + /// + /// + protected void Window1_Close(object sender, WindowCloseEventArgs e) + { + BindGrid(); + } + + /// + /// 右键编辑事件 + /// + /// + /// + protected void btnMenuEdit_Click(object sender, EventArgs e) + { + if (!string.IsNullOrEmpty(Projectid)) + { + string id = Grid1.SelectedRowID; + PageContext.RegisterStartupScript(Window1.GetShowReference(String.Format("ScheduleEdit.aspx?ScheduleId={0}", id, "编辑 - "))); + } + else + { + Alert.ShowInTop("未获取到当前项目,请刷新页面或重新选择项目", MessageBoxIcon.Warning); + } + + } + protected void btnMenuAdd_Click(object sender, EventArgs e) + { + //判断是否已经存在6个 + if (!string.IsNullOrEmpty(Projectid)) + { + var listSchedule = Funs.DB.Sys_Schedule.Where(x => x.ProjectId == Projectid).ToList(); + if (listSchedule.Count >= 6) + { + Alert.ShowInTop("进度节点数据最多添加6条!", MessageBoxIcon.Warning); + } + else + { + PageContext.RegisterStartupScript(Window1.GetShowReference(String.Format("ScheduleEdit.aspx", "添加 - "))); + } + } + else + { + Alert.ShowInTop("未获取到当前项目,请刷新页面或重新选择项目", MessageBoxIcon.Warning); + } + } + + } +} \ No newline at end of file diff --git a/SUBQHSE/FineUIPro.Web/SysManage/Schedule.aspx.designer.cs b/SUBQHSE/FineUIPro.Web/SysManage/Schedule.aspx.designer.cs new file mode 100644 index 0000000..f072f82 --- /dev/null +++ b/SUBQHSE/FineUIPro.Web/SysManage/Schedule.aspx.designer.cs @@ -0,0 +1,107 @@ +//------------------------------------------------------------------------------ +// <自动生成> +// 此代码由工具生成。 +// +// 对此文件的更改可能导致不正确的行为,如果 +// 重新生成代码,则所做更改将丢失。 +// +//------------------------------------------------------------------------------ + +namespace FineUIPro.Web.SysManage +{ + + + public partial class Schedule + { + + /// + /// form1 控件。 + /// + /// + /// 自动生成的字段。 + /// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。 + /// + protected global::System.Web.UI.HtmlControls.HtmlForm form1; + + /// + /// PageManager1 控件。 + /// + /// + /// 自动生成的字段。 + /// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。 + /// + protected global::FineUIPro.PageManager PageManager1; + + /// + /// Panel1 控件。 + /// + /// + /// 自动生成的字段。 + /// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。 + /// + protected global::FineUIPro.Panel Panel1; + + /// + /// Grid1 控件。 + /// + /// + /// 自动生成的字段。 + /// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。 + /// + protected global::FineUIPro.Grid Grid1; + + /// + /// Toolbar2 控件。 + /// + /// + /// 自动生成的字段。 + /// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。 + /// + protected global::FineUIPro.Toolbar Toolbar2; + + /// + /// btnNew 控件。 + /// + /// + /// 自动生成的字段。 + /// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。 + /// + protected global::FineUIPro.Button btnNew; + + /// + /// lblNumber 控件。 + /// + /// + /// 自动生成的字段。 + /// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。 + /// + protected global::System.Web.UI.WebControls.Label lblNumber; + + /// + /// Window1 控件。 + /// + /// + /// 自动生成的字段。 + /// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。 + /// + protected global::FineUIPro.Window Window1; + + /// + /// Menu1 控件。 + /// + /// + /// 自动生成的字段。 + /// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。 + /// + protected global::FineUIPro.Menu Menu1; + + /// + /// btnMenuEdit 控件。 + /// + /// + /// 自动生成的字段。 + /// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。 + /// + protected global::FineUIPro.MenuButton btnMenuEdit; + } +} diff --git a/SUBQHSE/FineUIPro.Web/SysManage/ScheduleEdit.aspx b/SUBQHSE/FineUIPro.Web/SysManage/ScheduleEdit.aspx new file mode 100644 index 0000000..3522bf9 --- /dev/null +++ b/SUBQHSE/FineUIPro.Web/SysManage/ScheduleEdit.aspx @@ -0,0 +1,76 @@ +<%@ Page Language="C#" AutoEventWireup="true" CodeBehind="ScheduleEdit.aspx.cs" Inherits="FineUIPro.Web.SysManage.ScheduleEdit" %> + + + + + + + + + + +
+ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/SUBQHSE/FineUIPro.Web/SysManage/ScheduleEdit.aspx.cs b/SUBQHSE/FineUIPro.Web/SysManage/ScheduleEdit.aspx.cs new file mode 100644 index 0000000..c1afb34 --- /dev/null +++ b/SUBQHSE/FineUIPro.Web/SysManage/ScheduleEdit.aspx.cs @@ -0,0 +1,102 @@ + +using BLL; +using System; +using System.Data; +using System.Linq; + +namespace FineUIPro.Web.SysManage +{ + public partial class ScheduleEdit : PageBase + { + /// + /// 主键 + /// + public string ScheduleId + { + get + { + return (string)ViewState["ScheduleId"]; + } + set + { + ViewState["ScheduleId"] = value; + } + } + + public string Projectid + { + get + { + return (string)ViewState["Projectid"]; + } + set + { + ViewState["Projectid"] = value; + } + } + + /// + /// 加载页面 + /// + /// + /// + protected void Page_Load(object sender, EventArgs e) + { + if (!IsPostBack) + { + ScheduleId = Request.Params["ScheduleId"]; + Projectid = CurrUser.LoginProjectId; + if (!string.IsNullOrEmpty(ScheduleId)) + { + if (!string.IsNullOrEmpty(Projectid)) + { + Model.Sys_Schedule model = Funs.DB.Sys_Schedule.FirstOrDefault(x => x.ScheduleId == ScheduleId && x.ProjectId == Projectid); + txtScheduleName.Text = model.ScheduleName; + txtScheduleDate.Text = model.ScheduleDate.ToString(); + txtSortId.Text = model.SortId.ToString(); + } + + } + else + { + Model.Sys_Schedule model = Funs.DB.Sys_Schedule.OrderByDescending(x => x.SortId).FirstOrDefault(x => x.ProjectId == Projectid); + if (model != null) + { + txtSortId.Text = (model.SortId + 1).ToString(); + } + else + { + txtSortId.Text = "1"; + } + } + } + } + + /// + /// 保存事件 + /// + /// + /// + protected void btnSave_Click(object sender, EventArgs e) + { + Model.Sys_Schedule model = new Model.Sys_Schedule(); + model.ScheduleDate = Convert.ToDateTime(txtScheduleDate.Text); + model.ScheduleName = txtScheduleName.Text.Trim(); + model.SortId = Convert.ToInt32(txtSortId.Text); + model.ProjectId = Projectid; + + if (!string.IsNullOrEmpty(ScheduleId)) + { + model.ScheduleId = ScheduleId; + ScheduleService.Update(model); + PageContext.RegisterStartupScript(ActiveWindow.GetHidePostBackReference()); + } + else + { + model.ScheduleId = SQLHelper.GetNewID(typeof(Model.Sys_Schedule)); ; + ScheduleService.Add(model); + PageContext.RegisterStartupScript(ActiveWindow.GetHidePostBackReference()); + } + } + } +} \ No newline at end of file diff --git a/SUBQHSE/FineUIPro.Web/SysManage/ScheduleEdit.aspx.designer.cs b/SUBQHSE/FineUIPro.Web/SysManage/ScheduleEdit.aspx.designer.cs new file mode 100644 index 0000000..b320ce6 --- /dev/null +++ b/SUBQHSE/FineUIPro.Web/SysManage/ScheduleEdit.aspx.designer.cs @@ -0,0 +1,125 @@ +//------------------------------------------------------------------------------ +// <自动生成> +// 此代码由工具生成。 +// +// 对此文件的更改可能导致不正确的行为,如果 +// 重新生成代码,则所做更改将丢失。 +// +//------------------------------------------------------------------------------ + +namespace FineUIPro.Web.SysManage +{ + + + public partial class ScheduleEdit + { + + /// + /// form1 控件。 + /// + /// + /// 自动生成的字段。 + /// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。 + /// + protected global::System.Web.UI.HtmlControls.HtmlForm form1; + + /// + /// PageManager1 控件。 + /// + /// + /// 自动生成的字段。 + /// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。 + /// + protected global::FineUIPro.PageManager PageManager1; + + /// + /// SimpleForm1 控件。 + /// + /// + /// 自动生成的字段。 + /// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。 + /// + protected global::FineUIPro.Form SimpleForm1; + + /// + /// txtScheduleName 控件。 + /// + /// + /// 自动生成的字段。 + /// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。 + /// + protected global::FineUIPro.TextBox txtScheduleName; + + /// + /// txtScheduleDate 控件。 + /// + /// + /// 自动生成的字段。 + /// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。 + /// + protected global::FineUIPro.DatePicker txtScheduleDate; + + /// + /// txtSortId 控件。 + /// + /// + /// 自动生成的字段。 + /// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。 + /// + protected global::FineUIPro.TextBox txtSortId; + + /// + /// Toolbar1 控件。 + /// + /// + /// 自动生成的字段。 + /// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。 + /// + protected global::FineUIPro.Toolbar Toolbar1; + + /// + /// hdCheckControlCode 控件。 + /// + /// + /// 自动生成的字段。 + /// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。 + /// + protected global::FineUIPro.TextBox hdCheckControlCode; + + /// + /// ToolbarFill1 控件。 + /// + /// + /// 自动生成的字段。 + /// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。 + /// + protected global::FineUIPro.ToolbarFill ToolbarFill1; + + /// + /// btnSave 控件。 + /// + /// + /// 自动生成的字段。 + /// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。 + /// + protected global::FineUIPro.Button btnSave; + + /// + /// hdId 控件。 + /// + /// + /// 自动生成的字段。 + /// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。 + /// + protected global::FineUIPro.TextBox hdId; + + /// + /// hdAttachUrl 控件。 + /// + /// + /// 自动生成的字段。 + /// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。 + /// + protected global::FineUIPro.TextBox hdAttachUrl; + } +} diff --git a/SUBQHSE/FineUIPro.Web/common/main.aspx b/SUBQHSE/FineUIPro.Web/common/main.aspx index caf9945..37ffea0 100644 --- a/SUBQHSE/FineUIPro.Web/common/main.aspx +++ b/SUBQHSE/FineUIPro.Web/common/main.aspx @@ -122,7 +122,7 @@
安全检查
质量检查
-
+
问题
{{form.hsseCheck.generalNum}}
@@ -140,6 +140,24 @@
{{form.hsseCheck.rectificationRate}}%
+
@@ -412,7 +430,7 @@ 质量教育数据
-
+
@@ -461,6 +479,14 @@
+
@@ -783,9 +809,25 @@ }, onChangeEducation(idx) { this.educationIdx = idx; + if (this.educationIdx == 0) { + $("#hsseEduTrain").show(); + $("#cqmsEduTrain").hide(); + } + else { + $("#hsseEduTrain").hide(); + $("#cqmsEduTrain").show(); + } }, onChangeCheck(idx) { this.checkIdx = idx; + if (this.checkIdx == 0) { + $("#hsseCheck").show(); + $("#cqmsCheck").hide(); + } + else { + $("#hsseCheck").hide(); + $("#cqmsCheck").show(); + } }, // 创建中国地图 createChinaMap(data) { diff --git a/SUBQHSE/FineUIPro.Web/common/mainProject.aspx b/SUBQHSE/FineUIPro.Web/common/mainProject.aspx index 1d7fdff..74a3c21 100644 --- a/SUBQHSE/FineUIPro.Web/common/mainProject.aspx +++ b/SUBQHSE/FineUIPro.Web/common/mainProject.aspx @@ -19,10 +19,10 @@
-
+
-
+
组织机构人员
@@ -49,7 +49,7 @@
-
安管人员与作业人员配比
+
安管人员与作业人员配比
{{form.org.projectPersonRatio}}
@@ -57,7 +57,8 @@
-
+
预警警报
@@ -80,12 +81,13 @@
-
+
安全检查
质量检查
-
+
问题
{{form.hsseCheck.generalNum}}
@@ -103,9 +105,28 @@
{{form.hsseCheck.rectificationRate}}%
+
-
+
风险分级管控
@@ -139,12 +160,14 @@
-
+
费用、机具及会议
- +

安全费用

@@ -158,7 +181,8 @@
- +

施工机具设备

@@ -172,7 +196,8 @@
- +

会议

@@ -187,9 +212,9 @@
-
+
-
+
@@ -216,12 +241,14 @@
-
+
项目进度计划
-
-
+
+
-
+
@@ -233,7 +260,7 @@
-
+
危大工程管控数据
@@ -277,8 +304,11 @@
-
+ style=" height: 1.85rem; + display: grid; + grid-template-columns: 5.5rem 4.25rem; + gap: 0.25rem;"> +
应急管理数据
@@ -305,7 +335,7 @@
-
+
工程划分
@@ -329,7 +359,7 @@
-
+
质量验收数据
@@ -341,7 +371,10 @@
-
+
特种设备质保体系
@@ -368,7 +401,8 @@
-
+
安全教育
@@ -376,21 +410,21 @@ 质量教育数据
-
+
-
+
专项培训
-
{{form.hsseEduTrain.specialTrainNum}} +
{{form.hsseEduTrain.specialTrainNum}}
-
+
特种作业培训
-
{{form.hsseEduTrain.specialOperationTrainNum}} +
{{form.hsseEduTrain.specialOperationTrainNum}}
@@ -400,21 +434,21 @@
安全工时

{{form.hsseEduTrain.safeWorkingHour}}h

-
+
-
+
三级安全教育培训
-
{{form.hsseEduTrain.safeTrainNum}} +
{{form.hsseEduTrain.safeTrainNum}}
-
+
安全技术交底
-
{{form.designBriefing.safetyTechnicalBriefing}} +
{{form.designBriefing.safetyTechnicalBriefing}}
@@ -422,9 +456,18 @@
+
-
+
报验记录
@@ -435,7 +478,10 @@
合格率
-
+
@@ -446,7 +492,10 @@
合格率
-
+
@@ -457,7 +506,10 @@
合格率
-
+
@@ -467,7 +519,11 @@
+ style=" height: 2.1875rem; + margin-top: 0.25rem; + display: grid; + grid-template-columns: 3.75rem 2.25rem; + gap: 0.25rem;">
施工方案
@@ -509,7 +565,8 @@
-
+
计量器具数据
@@ -555,14 +612,6 @@ // 当前激活的管理菜单索引 manage_idx: 1, // 存储所有数据的主要对象 - xmjdData: [ - { date: '2025-01-01', title: '项目启动', description: '项目正式开始', isClosed: true }, - { date: '2025-02-01', title: '需求分析', description: '完成需求分析阶段', isClosed: true }, - { date: '2025-03-01', title: '设计阶段', description: '完成系统设计', isClosed: true }, - { date: '2025-04-01', title: '开发阶段', description: '开始软件开发', isClosed: true }, - { date: '2025-05-01', title: '测试阶段', description: '进行系统测试', isClosed: false }, - { date: '2025-06-01', title: '部署阶段', description: '系统部署上线', isClosed: false } - ], form: { org: {//组织机构人员 projectSum: 0, // 项目总人数 @@ -616,6 +665,7 @@ projectEndDate: '2049-12-31',//项目到期时间 projectEndDays: 0,//合同倒计时 }, + xmjdData: [],//项目进度计划 dangerousProject: {//危大工程管控数据 approvalCompleted: 0,//审批完成 @@ -701,6 +751,7 @@ if (response.d.success) { // 更新数据成功 that.form = { ...response.d.data }; // 更新表单数据 + console.log(that.form) } else { // 更新数据失败 alert("加载数据失败:" + response.d.msg); @@ -730,9 +781,25 @@ }, onChangeEducation(idx) { this.educationIdx = idx; + if (this.educationIdx == 0) { + $("#hsseEduTrain").show(); + $("#cqmsEduTrain").hide(); + } + else { + $("#hsseEduTrain").hide(); + $("#cqmsEduTrain").show(); + } }, onChangeCheck(idx) { this.checkIdx = idx; + if (this.checkIdx == 0) { + $("#hsseCheck").show(); + $("#cqmsCheck").hide(); + } + else { + $("#hsseCheck").hide(); + $("#cqmsCheck").show(); + } }, /** * diff --git a/SUBQHSE/FineUIPro.Web/common/mainProject.aspx.cs b/SUBQHSE/FineUIPro.Web/common/mainProject.aspx.cs index 6180607..a4384d0 100644 --- a/SUBQHSE/FineUIPro.Web/common/mainProject.aspx.cs +++ b/SUBQHSE/FineUIPro.Web/common/mainProject.aspx.cs @@ -7,6 +7,7 @@ using System.Linq; using System.Web.UI.WebControls; using System.Threading.Tasks; using FineUIPro.Web.ProjectData; +using FineUIPro.Web.DataShow; namespace FineUIPro.Web.common { @@ -87,12 +88,12 @@ namespace FineUIPro.Web.common var inspectionMachineList = (from x in db.Comprehensive_InspectionMachine where x.ProjectId == projectId select x).ToList(); //质量 - var cqmsProjectData = (from x in Funs.DB.Project_CQMSData_CQMS + var cqmsProjectData = (from x in db.Project_CQMSData_CQMS where x.ProjectId == projectId select x).OrderByDescending(x => x.ReportDate).FirstOrDefault(); //质量培训人数 //var cqmsTrainPersonNum = cqmsProjectData.TrainPersonNum; - var cqmsTrainPersonNum = Funs.DB.Comprehensive_InspectionPerson.Where(x => x.IsTrain == true && x.ProjectId == projectId).Count(); + var cqmsTrainPersonNum = db.Comprehensive_InspectionPerson.Where(x => x.IsTrain == true && x.ProjectId == projectId).Count(); //var getJointCheckDetail = from x in Funs.DB.Check_JointCheckDetail // join y in Funs.DB.Check_JointCheck on x.JointCheckId equals y.JointCheckId @@ -142,6 +143,17 @@ namespace FineUIPro.Web.common double inspectionPersonRate = inspectionPersonIsCheckOk > 0 ? Math.Round((100 * (double)(inspectionPersonIsCheckOk / inspectionPerson)), 2) : 0; double inspectionMachineRate = inspectionMachineIsCheckOk > 0 ? Math.Round((100 * (double)(inspectionMachineIsCheckOk / inspectionMachine)), 2) : 0; + //项目进度计划 + var scheduleList = (from x in db.Sys_Schedule + where x.ProjectId == projectId + orderby x.SortId + select new + { + date = x.ScheduleDate, + title = x.ScheduleName, + description = x.ScheduleName, + isClosed = DateTime.Now > x.ScheduleDate + }).ToList(); // 构造返回数据 var returnData = new { @@ -203,9 +215,13 @@ namespace FineUIPro.Web.common projectEndDate = string.Format("{0:yyyy-MM-dd}", project.EndDate),//项目到期时间 projectEndDays = endDays > 0 ? endDays : 0,//合同倒计时 }, - //xmjdData = new {//项目进度计划【待汇总】 - - //}, + xmjdData = scheduleList.Select(x => new + {//项目进度计划 + x.isClosed, + date = ((DateTime)x.date).ToString("yyyy-MM-dd"), + x.title, + x.description + }), dangerousProject = new {//危大工程管控数据 approvalCompleted = hsseData.CompletedNum ?? 0,//审批完成 diff --git a/SUBQHSE/Model/Model.cs b/SUBQHSE/Model/Model.cs index 7af1061..d98d96b 100644 --- a/SUBQHSE/Model/Model.cs +++ b/SUBQHSE/Model/Model.cs @@ -2594,6 +2594,9 @@ namespace Model partial void InsertSys_RolePower(Sys_RolePower instance); partial void UpdateSys_RolePower(Sys_RolePower instance); partial void DeleteSys_RolePower(Sys_RolePower instance); + partial void InsertSys_Schedule(Sys_Schedule instance); + partial void UpdateSys_Schedule(Sys_Schedule instance); + partial void DeleteSys_Schedule(Sys_Schedule instance); partial void InsertSys_Set(Sys_Set instance); partial void UpdateSys_Set(Sys_Set instance); partial void DeleteSys_Set(Sys_Set instance); @@ -9837,6 +9840,14 @@ namespace Model } } + public System.Data.Linq.Table Sys_Schedule + { + get + { + return this.GetTable(); + } + } + public System.Data.Linq.Table Sys_Set { get @@ -363803,7 +363814,7 @@ namespace Model } } - [global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_PersonName", DbType="NVarChar(50)")] + [global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_PersonName", DbType="NVarChar(50) NOT NULL", CanBeNull=false)] public string PersonName { get @@ -403874,6 +403885,164 @@ namespace Model } } + [global::System.Data.Linq.Mapping.TableAttribute(Name="dbo.Sys_Schedule")] + public partial class Sys_Schedule : INotifyPropertyChanging, INotifyPropertyChanged + { + + private static PropertyChangingEventArgs emptyChangingEventArgs = new PropertyChangingEventArgs(String.Empty); + + private string _ScheduleId; + + private string _ScheduleName; + + private System.Nullable _ScheduleDate; + + private string _ProjectId; + + private System.Nullable _SortId; + + #region 可扩展性方法定义 + partial void OnLoaded(); + partial void OnValidate(System.Data.Linq.ChangeAction action); + partial void OnCreated(); + partial void OnScheduleIdChanging(string value); + partial void OnScheduleIdChanged(); + partial void OnScheduleNameChanging(string value); + partial void OnScheduleNameChanged(); + partial void OnScheduleDateChanging(System.Nullable value); + partial void OnScheduleDateChanged(); + partial void OnProjectIdChanging(string value); + partial void OnProjectIdChanged(); + partial void OnSortIdChanging(System.Nullable value); + partial void OnSortIdChanged(); + #endregion + + public Sys_Schedule() + { + OnCreated(); + } + + [global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_ScheduleId", DbType="NVarChar(50) NOT NULL", CanBeNull=false, IsPrimaryKey=true)] + public string ScheduleId + { + get + { + return this._ScheduleId; + } + set + { + if ((this._ScheduleId != value)) + { + this.OnScheduleIdChanging(value); + this.SendPropertyChanging(); + this._ScheduleId = value; + this.SendPropertyChanged("ScheduleId"); + this.OnScheduleIdChanged(); + } + } + } + + [global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_ScheduleName", DbType="NVarChar(50)")] + public string ScheduleName + { + get + { + return this._ScheduleName; + } + set + { + if ((this._ScheduleName != value)) + { + this.OnScheduleNameChanging(value); + this.SendPropertyChanging(); + this._ScheduleName = value; + this.SendPropertyChanged("ScheduleName"); + this.OnScheduleNameChanged(); + } + } + } + + [global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_ScheduleDate", DbType="DateTime")] + public System.Nullable ScheduleDate + { + get + { + return this._ScheduleDate; + } + set + { + if ((this._ScheduleDate != value)) + { + this.OnScheduleDateChanging(value); + this.SendPropertyChanging(); + this._ScheduleDate = value; + this.SendPropertyChanged("ScheduleDate"); + this.OnScheduleDateChanged(); + } + } + } + + [global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_ProjectId", DbType="NVarChar(50)")] + public string ProjectId + { + get + { + return this._ProjectId; + } + set + { + if ((this._ProjectId != value)) + { + this.OnProjectIdChanging(value); + this.SendPropertyChanging(); + this._ProjectId = value; + this.SendPropertyChanged("ProjectId"); + this.OnProjectIdChanged(); + } + } + } + + [global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_SortId", DbType="Int")] + public System.Nullable SortId + { + get + { + return this._SortId; + } + set + { + if ((this._SortId != value)) + { + this.OnSortIdChanging(value); + this.SendPropertyChanging(); + this._SortId = value; + this.SendPropertyChanged("SortId"); + this.OnSortIdChanged(); + } + } + } + + public event PropertyChangingEventHandler PropertyChanging; + + public event PropertyChangedEventHandler PropertyChanged; + + protected virtual void SendPropertyChanging() + { + if ((this.PropertyChanging != null)) + { + this.PropertyChanging(this, emptyChangingEventArgs); + } + } + + protected virtual void SendPropertyChanged(String propertyName) + { + if ((this.PropertyChanged != null)) + { + this.PropertyChanged(this, new PropertyChangedEventArgs(propertyName)); + } + } + } + [global::System.Data.Linq.Mapping.TableAttribute(Name="dbo.Sys_Set")] public partial class Sys_Set : INotifyPropertyChanging, INotifyPropertyChanged { @@ -482650,7 +482819,7 @@ namespace Model } } - [global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_PersonName", DbType="NVarChar(50)")] + [global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_PersonName", DbType="NVarChar(50) NOT NULL", CanBeNull=false)] public string PersonName { get @@ -486408,7 +486577,7 @@ namespace Model } } - [global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_PersonName", DbType="NVarChar(50)")] + [global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_PersonName", DbType="NVarChar(50) NOT NULL", CanBeNull=false)] public string PersonName { get @@ -494691,7 +494860,7 @@ namespace Model } } - [global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_PersonName", DbType="NVarChar(50)")] + [global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_PersonName", DbType="NVarChar(50) NOT NULL", CanBeNull=false)] public string PersonName { get