From b8dae5be20cb5df0f3a7f6acfd94dbe2e6e3b9f2 Mon Sep 17 00:00:00 2001 From: gaofei1985 <181547018@qq.com> Date: Tue, 25 Jul 2023 14:08:48 +0800 Subject: [PATCH] =?UTF-8?q?=E4=BF=AE=E6=94=B9=E5=AE=89=E5=85=A8=E5=AE=9E?= =?UTF-8?q?=E6=96=BD=E8=AE=A1=E5=88=92=E5=AF=BC=E5=87=BA=E5=8F=8A=E8=BF=9B?= =?UTF-8?q?=E5=BA=A6=E5=8A=9F=E8=83=BD?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- DataBase/版本日志/SGGLDB_V2023-07-25.sql | 27 ++ .../1-4进度管理(Menu_JDGL).sql | 100 ++-- SGGL/BLL/CQMS/WBS/WorkPackageService.cs | 152 +++++- SGGL/BLL/Common/Const.cs | 7 + SGGL/BLL/ProjectData/UnitWorkService.cs | 4 + .../Word/ZHGL/项目安全生产策划书评审表.doc | Bin 10240 -> 27648 bytes SGGL/FineUIPro.Web/FineUIPro.Web.csproj | 8 + .../HSSE/ActionPlan/ActionPlanList.aspx.cs | 134 +++--- SGGL/FineUIPro.Web/JDGL/Check/PlanSet.aspx | 130 ++++++ SGGL/FineUIPro.Web/JDGL/Check/PlanSet.aspx.cs | 387 ++++++++++++++++ .../JDGL/Check/PlanSet.aspx.designer.cs | 168 +++++++ .../ZHGL/Plan/ActionPlanList.aspx | 2 +- .../ZHGL/Plan/ActionPlanList.aspx.cs | 130 +++--- SGGL/Model/Model.cs | 437 ++++++++++++++++++ 14 files changed, 1512 insertions(+), 174 deletions(-) create mode 100644 DataBase/版本日志/SGGLDB_V2023-07-25.sql create mode 100644 SGGL/FineUIPro.Web/JDGL/Check/PlanSet.aspx create mode 100644 SGGL/FineUIPro.Web/JDGL/Check/PlanSet.aspx.cs create mode 100644 SGGL/FineUIPro.Web/JDGL/Check/PlanSet.aspx.designer.cs diff --git a/DataBase/版本日志/SGGLDB_V2023-07-25.sql b/DataBase/版本日志/SGGLDB_V2023-07-25.sql new file mode 100644 index 00000000..97a8e7a0 --- /dev/null +++ b/DataBase/版本日志/SGGLDB_V2023-07-25.sql @@ -0,0 +1,27 @@ +alter table [dbo].[WBS_WorkPackage] add PreJobId nvarchar(50) null +GO +alter table [dbo].[WBS_WorkPackage] add PlanProjectQuantity decimal(18,2) null +GO +alter table [dbo].[WBS_WorkPackage] add RealProjectQuantity decimal(18,2) null +GO +alter table [dbo].[WBS_WorkPackage] add PlanStartDate datetime null +GO +alter table [dbo].[WBS_WorkPackage] add PlanEndDate datetime null +GO +alter table [dbo].[WBS_WorkPackage] add RealStartDate datetime null +GO +alter table [dbo].[WBS_WorkPackage] add RealEndDate datetime null +GO +alter table [dbo].[WBS_WorkPackage] add Unit nvarchar(50) null +GO +alter table [dbo].[WBS_WorkPackage] add IsMileStone bit null +GO + +alter table [dbo].[WBS_UnitWork] add PlanStartDate datetime null +GO +alter table [dbo].[WBS_UnitWork] add PlanEndDate datetime null +GO +alter table [dbo].[WBS_UnitWork] add RealStartDate datetime null +GO +alter table [dbo].[WBS_UnitWork] add RealEndDate datetime null +GO \ No newline at end of file diff --git a/DataBase/菜单初始化脚本/1-4进度管理(Menu_JDGL).sql b/DataBase/菜单初始化脚本/1-4进度管理(Menu_JDGL).sql index 94d52f2c..02b777c5 100644 --- a/DataBase/菜单初始化脚本/1-4进度管理(Menu_JDGL).sql +++ b/DataBase/菜单初始化脚本/1-4进度管理(Menu_JDGL).sql @@ -1,55 +1,63 @@ ---delete from Sys_ButtonToMenu where MenuId in (select MenuId from Sys_Menu where MenuType='Menu_JDGL') ---go ---delete from Sys_Menu where MenuType='Menu_JDGL' ---go +delete from Sys_ButtonToMenu where MenuId in (select MenuId from Sys_Menu where MenuType='Menu_JDGL') +go +delete from Sys_Menu where MenuType='Menu_JDGL' +go --INSERT INTO dbo.Sys_Menu(MenuId,MenuName,Url,SortIndex,SuperMenu,MenuType,IsOffice,IsEnd,IsUsed) --VALUES('6890E0DD-9606-41BC-8700-D32FA5B65B66','施工进度','',10,'0','Menu_JDGL',0,0,1) --GO -INSERT INTO dbo.Sys_Menu(MenuId,MenuName,Url,SortIndex,SuperMenu,MenuType,IsOffice,IsEnd,IsUsed) -VALUES('BAC3D994-03A8-466C-8975-A31039998BCC','施工进度统计','JDGL/Check/ProgressShow.aspx',10,'0','Menu_JDGL',0,1,1) -GO +--INSERT INTO dbo.Sys_Menu(MenuId,MenuName,Url,SortIndex,SuperMenu,MenuType,IsOffice,IsEnd,IsUsed) +--VALUES('BAC3D994-03A8-466C-8975-A31039998BCC','施工进度统计','JDGL/Check/ProgressShow.aspx',10,'0','Menu_JDGL',0,1,1) +--GO + +--INSERT INTO dbo.Sys_Menu(MenuId,MenuName,Url,SortIndex,SuperMenu,MenuType,IsOffice,IsEnd,IsUsed) +--VALUES('1172B112-2A12-4410-AD66-E5BA6B461475','施工进度赢得值曲线','JDGL/Check/ProgressStatistics.aspx',20,'0','Menu_JDGL',0,1,1) +--GO + +--INSERT INTO dbo.Sys_Menu(MenuId,MenuName,Url,SortIndex,SuperMenu,MenuType,IsOffice,IsEnd,IsUsed) +--VALUES('4288426D-E49B-4E5D-A495-7E6A76F269B5','周计划','',30,'0','Menu_JDGL',0,1,1) +--GO +--INSERT INTO dbo.Sys_ButtonToMenu(ButtonToMenuId,MenuId,ButtonName,SortIndex) +--VALUES('98E9B88C-5BB8-4673-9B6C-69B446E57C11','4288426D-E49B-4E5D-A495-7E6A76F269B5','增加',1) +--INSERT INTO dbo.Sys_ButtonToMenu(ButtonToMenuId,MenuId,ButtonName,SortIndex) +--VALUES('B69119FC-F0AB-4C07-83FB-48D2CEF00C5F','4288426D-E49B-4E5D-A495-7E6A76F269B5','修改',2) +--INSERT INTO dbo.Sys_ButtonToMenu(ButtonToMenuId,MenuId,ButtonName,SortIndex) +--VALUES('DC33D5E2-2C3B-4C9B-9887-1CF2EB2A3C7F','4288426D-E49B-4E5D-A495-7E6A76F269B5','删除',3) +--INSERT INTO dbo.Sys_ButtonToMenu(ButtonToMenuId,MenuId,ButtonName,SortIndex) +--VALUES('CBF94555-B633-44CC-9919-3CE579D368CD','4288426D-E49B-4E5D-A495-7E6A76F269B5','保存',4) +--GO + +--INSERT INTO dbo.Sys_Menu(MenuId,MenuName,Url,SortIndex,SuperMenu,MenuType,IsOffice,IsEnd,IsUsed) +--VALUES('C75F0853-8A2B-4B32-83B7-509278D11957','项目里程碑节点','',40,'0','Menu_JDGL',0,1,1) +--GO +--INSERT INTO dbo.Sys_ButtonToMenu(ButtonToMenuId,MenuId,ButtonName,SortIndex) +--VALUES('3BCA8C5D-C781-4BF7-90C5-1EE569D0F810','C75F0853-8A2B-4B32-83B7-509278D11957','增加',1) +--INSERT INTO dbo.Sys_ButtonToMenu(ButtonToMenuId,MenuId,ButtonName,SortIndex) +--VALUES('1AC052E6-0FA0-45C4-A8AB-A8C71931DEC6','C75F0853-8A2B-4B32-83B7-509278D11957','修改',2) +--INSERT INTO dbo.Sys_ButtonToMenu(ButtonToMenuId,MenuId,ButtonName,SortIndex) +--VALUES('08B9E2EB-2998-4225-A6E5-F51597608000','C75F0853-8A2B-4B32-83B7-509278D11957','删除',3) +--INSERT INTO dbo.Sys_ButtonToMenu(ButtonToMenuId,MenuId,ButtonName,SortIndex) +--VALUES('FAF17C45-6D8A-4679-90A8-B8AF4F86EFB8','C75F0853-8A2B-4B32-83B7-509278D11957','保存',4) +--GO + +--INSERT INTO dbo.Sys_Menu(MenuId,MenuName,Url,SortIndex,SuperMenu,MenuType,IsOffice,IsEnd,IsUsed) +--VALUES('3550F422-E520-4962-9816-B691B0EE2865','形象进度照片','',50,'0','Menu_JDGL',0,1,1) +--GO +--INSERT INTO dbo.Sys_ButtonToMenu(ButtonToMenuId,MenuId,ButtonName,SortIndex) +--VALUES('92792060-5ED8-4A87-A355-93728321D4E8','3550F422-E520-4962-9816-B691B0EE2865','增加',1) +--INSERT INTO dbo.Sys_ButtonToMenu(ButtonToMenuId,MenuId,ButtonName,SortIndex) +--VALUES('6859B3C5-A8CF-48CF-8F7C-EA707ED5710A','3550F422-E520-4962-9816-B691B0EE2865','修改',2) +--INSERT INTO dbo.Sys_ButtonToMenu(ButtonToMenuId,MenuId,ButtonName,SortIndex) +--VALUES('274A6E9E-193A-498F-ABD3-A78437C79C00','3550F422-E520-4962-9816-B691B0EE2865','删除',3) +--INSERT INTO dbo.Sys_ButtonToMenu(ButtonToMenuId,MenuId,ButtonName,SortIndex) +--VALUES('947CD34B-57C0-40EE-9773-53A75925D9AD','3550F422-E520-4962-9816-B691B0EE2865','保存',4) +--GO INSERT INTO dbo.Sys_Menu(MenuId,MenuName,Url,SortIndex,SuperMenu,MenuType,IsOffice,IsEnd,IsUsed) -VALUES('1172B112-2A12-4410-AD66-E5BA6B461475','施工进度赢得值曲线','JDGL/Check/ProgressStatistics.aspx',20,'0','Menu_JDGL',0,1,1) +VALUES('E23F0879-3E9F-4E7B-9A2D-EFF34798D629','进度计划设置','JDGL/Check/PlanSet.aspx',10,'0','Menu_JDGL',0,1,1) +GO +INSERT INTO dbo.Sys_ButtonToMenu(ButtonToMenuId,MenuId,ButtonName,SortIndex) +VALUES('F5055103-6182-43E0-93EC-7DD7BEF2B71C','E23F0879-3E9F-4E7B-9A2D-EFF34798D629','保存',4) GO -INSERT INTO dbo.Sys_Menu(MenuId,MenuName,Url,SortIndex,SuperMenu,MenuType,IsOffice,IsEnd,IsUsed) -VALUES('4288426D-E49B-4E5D-A495-7E6A76F269B5','周计划','',30,'0','Menu_JDGL',0,1,1) -GO -INSERT INTO dbo.Sys_ButtonToMenu(ButtonToMenuId,MenuId,ButtonName,SortIndex) -VALUES('98E9B88C-5BB8-4673-9B6C-69B446E57C11','4288426D-E49B-4E5D-A495-7E6A76F269B5','增加',1) -INSERT INTO dbo.Sys_ButtonToMenu(ButtonToMenuId,MenuId,ButtonName,SortIndex) -VALUES('B69119FC-F0AB-4C07-83FB-48D2CEF00C5F','4288426D-E49B-4E5D-A495-7E6A76F269B5','修改',2) -INSERT INTO dbo.Sys_ButtonToMenu(ButtonToMenuId,MenuId,ButtonName,SortIndex) -VALUES('DC33D5E2-2C3B-4C9B-9887-1CF2EB2A3C7F','4288426D-E49B-4E5D-A495-7E6A76F269B5','删除',3) -INSERT INTO dbo.Sys_ButtonToMenu(ButtonToMenuId,MenuId,ButtonName,SortIndex) -VALUES('CBF94555-B633-44CC-9919-3CE579D368CD','4288426D-E49B-4E5D-A495-7E6A76F269B5','保存',4) -GO - -INSERT INTO dbo.Sys_Menu(MenuId,MenuName,Url,SortIndex,SuperMenu,MenuType,IsOffice,IsEnd,IsUsed) -VALUES('C75F0853-8A2B-4B32-83B7-509278D11957','项目里程碑节点','',40,'0','Menu_JDGL',0,1,1) -GO -INSERT INTO dbo.Sys_ButtonToMenu(ButtonToMenuId,MenuId,ButtonName,SortIndex) -VALUES('3BCA8C5D-C781-4BF7-90C5-1EE569D0F810','C75F0853-8A2B-4B32-83B7-509278D11957','增加',1) -INSERT INTO dbo.Sys_ButtonToMenu(ButtonToMenuId,MenuId,ButtonName,SortIndex) -VALUES('1AC052E6-0FA0-45C4-A8AB-A8C71931DEC6','C75F0853-8A2B-4B32-83B7-509278D11957','修改',2) -INSERT INTO dbo.Sys_ButtonToMenu(ButtonToMenuId,MenuId,ButtonName,SortIndex) -VALUES('08B9E2EB-2998-4225-A6E5-F51597608000','C75F0853-8A2B-4B32-83B7-509278D11957','删除',3) -INSERT INTO dbo.Sys_ButtonToMenu(ButtonToMenuId,MenuId,ButtonName,SortIndex) -VALUES('FAF17C45-6D8A-4679-90A8-B8AF4F86EFB8','C75F0853-8A2B-4B32-83B7-509278D11957','保存',4) -GO - -INSERT INTO dbo.Sys_Menu(MenuId,MenuName,Url,SortIndex,SuperMenu,MenuType,IsOffice,IsEnd,IsUsed) -VALUES('3550F422-E520-4962-9816-B691B0EE2865','形象进度照片','',50,'0','Menu_JDGL',0,1,1) -GO -INSERT INTO dbo.Sys_ButtonToMenu(ButtonToMenuId,MenuId,ButtonName,SortIndex) -VALUES('92792060-5ED8-4A87-A355-93728321D4E8','3550F422-E520-4962-9816-B691B0EE2865','增加',1) -INSERT INTO dbo.Sys_ButtonToMenu(ButtonToMenuId,MenuId,ButtonName,SortIndex) -VALUES('6859B3C5-A8CF-48CF-8F7C-EA707ED5710A','3550F422-E520-4962-9816-B691B0EE2865','修改',2) -INSERT INTO dbo.Sys_ButtonToMenu(ButtonToMenuId,MenuId,ButtonName,SortIndex) -VALUES('274A6E9E-193A-498F-ABD3-A78437C79C00','3550F422-E520-4962-9816-B691B0EE2865','删除',3) -INSERT INTO dbo.Sys_ButtonToMenu(ButtonToMenuId,MenuId,ButtonName,SortIndex) -VALUES('947CD34B-57C0-40EE-9773-53A75925D9AD','3550F422-E520-4962-9816-B691B0EE2865','保存',4) -GO \ No newline at end of file diff --git a/SGGL/BLL/CQMS/WBS/WorkPackageService.cs b/SGGL/BLL/CQMS/WBS/WorkPackageService.cs index f82496c3..644354cb 100644 --- a/SGGL/BLL/CQMS/WBS/WorkPackageService.cs +++ b/SGGL/BLL/CQMS/WBS/WorkPackageService.cs @@ -1,4 +1,6 @@ -using System.Collections.Generic; +using System; +using System.Collections.Generic; +using System.Data; using System.Linq; namespace BLL @@ -30,6 +32,14 @@ namespace BLL newWorkPackage.IsApprove = WorkPackage.IsApprove; newWorkPackage.Costs = WorkPackage.Costs; newWorkPackage.SubItemType = WorkPackage.SubItemType; + newWorkPackage.PreJobId = WorkPackage.PreJobId; + newWorkPackage.PlanProjectQuantity = WorkPackage.PlanProjectQuantity; + newWorkPackage.RealProjectQuantity = WorkPackage.RealProjectQuantity; + newWorkPackage.PlanStartDate = WorkPackage.PlanStartDate; + newWorkPackage.PlanEndDate = WorkPackage.PlanEndDate; + newWorkPackage.RealStartDate = WorkPackage.RealStartDate; + newWorkPackage.RealEndDate = WorkPackage.RealEndDate; + newWorkPackage.Unit = WorkPackage.Unit; db.WBS_WorkPackage.InsertOnSubmit(newWorkPackage); db.SubmitChanges(); @@ -54,6 +64,15 @@ namespace BLL newWorkPackage.IsApprove = WorkPackage.IsApprove; newWorkPackage.Costs = WorkPackage.Costs; newWorkPackage.SubItemType = WorkPackage.SubItemType; + newWorkPackage.PreJobId = WorkPackage.PreJobId; + newWorkPackage.PlanProjectQuantity = WorkPackage.PlanProjectQuantity; + newWorkPackage.RealProjectQuantity = WorkPackage.RealProjectQuantity; + newWorkPackage.PlanStartDate = WorkPackage.PlanStartDate; + newWorkPackage.PlanEndDate = WorkPackage.PlanEndDate; + newWorkPackage.RealStartDate = WorkPackage.RealStartDate; + newWorkPackage.RealEndDate = WorkPackage.RealEndDate; + newWorkPackage.Unit = WorkPackage.Unit; + newWorkPackage.IsMileStone = WorkPackage.IsMileStone; db.SubmitChanges(); } @@ -218,5 +237,136 @@ namespace BLL Funs.FineUIPleaseSelect(dropName); } } + + /// + /// 获取模拟树表格 + /// + /// + public static DataTable GetAllTreeDataTable(string projectId) + { + using (var db = new Model.SGGLDB(Funs.ConnString)) + { + IQueryable workPackages = from x in db.WBS_WorkPackage where x.ProjectId == projectId select x; + IQueryable unitWorks = from x in db.WBS_UnitWork where x.ProjectId == projectId select x; + List getWBSs = (from x in db.View_WBS where x.ProjectId == projectId select x).ToList(); + List WBSList = new List(); + DataTable table = new DataTable(); + table.Columns.Add(new DataColumn("Id", typeof(String))); + table.Columns.Add(new DataColumn("SupId", typeof(String))); + table.Columns.Add(new DataColumn("Name", typeof(String))); + table.Columns.Add(new DataColumn("WBSType", typeof(String))); + table.Columns.Add(new DataColumn("ProjectId", typeof(String))); + table.Columns.Add(new DataColumn("ShowId", typeof(String))); + table.Columns.Add(new DataColumn("Weights", typeof(String))); + table.Columns.Add(new DataColumn("Unit", typeof(String))); + table.Columns.Add(new DataColumn("PlanProjectQuantity", typeof(String))); + table.Columns.Add(new DataColumn("RealProjectQuantity", typeof(String))); + table.Columns.Add(new DataColumn("PlanStartDate", typeof(DateTime))); + table.Columns.Add(new DataColumn("PlanEndDate", typeof(DateTime))); + table.Columns.Add(new DataColumn("RealStartDate", typeof(DateTime))); + table.Columns.Add(new DataColumn("RealEndDate", typeof(DateTime))); + table.Columns.Add(new DataColumn("IsMileStone", typeof(bool))); + if (getWBSs.Count() > 0) + { + List newList = new List(); + var projectTypes = getWBSs.Where(x => x.WBSType == "ProjectType" && x.SupId == "0"); + foreach (var item in projectTypes) + { + newList.Add(item); + AddDetail(newList, getWBSs.ToList(), item.Id); + } + DataRow row; + foreach (Model.View_WBS item in newList) + { + row = table.NewRow(); + row[0] = item.Id; + row[1] = item.SupId; + row[2] = item.Name; + row[3] = item.WBSType; + row[4] = item.ProjectId; + if (item.WBSType == "WorkPackage") + { + var childWorkPackages = from x in workPackages where x.SuperWorkPackageId == item.Id && x.IsApprove == true select x; + if (childWorkPackages.Count() == 0) + { + row[5] = item.Id; + var workPackage = workPackages.FirstOrDefault(x => x.WorkPackageId == item.Id); + if (workPackage != null) + { + if (workPackage.Weights != null) + { + row[6] = decimal.Round(Convert.ToDecimal(workPackage.Weights), 2); + } + row[7] = workPackage.Unit; + if (workPackage.PlanProjectQuantity != null) + { + row[8] = decimal.Round(Convert.ToDecimal(workPackage.PlanProjectQuantity), 2); + } + if (workPackage.RealProjectQuantity != null) + { + row[9] = decimal.Round(Convert.ToDecimal(workPackage.RealProjectQuantity), 2); + } + if (workPackage.PlanStartDate != null) + { + row[10] = workPackage.PlanStartDate; + } + if (workPackage.PlanEndDate != null) + { + row[11] = workPackage.PlanEndDate; + } + if (workPackage.RealStartDate != null) + { + row[12] = workPackage.RealStartDate; + } + if (workPackage.RealEndDate != null) + { + row[13] = workPackage.RealEndDate; + } + if (workPackage.IsMileStone != null) + { + row[14] = workPackage.IsMileStone; + } + } + } + } + else if (item.WBSType == "UnitWork") + { + var unitWork = unitWorks.FirstOrDefault(x => x.UnitWorkId == item.Id); + if (unitWork != null) + { + if (unitWork.PlanStartDate != null) + { + row[10] = unitWork.PlanStartDate; + } + if (unitWork.PlanEndDate != null) + { + row[11] = unitWork.PlanEndDate; + } + if (unitWork.RealStartDate != null) + { + row[12] = unitWork.RealStartDate; + } + if (unitWork.RealEndDate != null) + { + row[13] = unitWork.RealEndDate; + } + } + } + table.Rows.Add(row); + } + } + return table; + } + } + + private static void AddDetail(List newList, List oldList, string id) + { + var items = oldList.Where(x => x.SupId == id).OrderBy(x => x.Code); + foreach (var item in items) + { + newList.Add(item); + AddDetail(newList, oldList, item.Id); + } + } } } diff --git a/SGGL/BLL/Common/Const.cs b/SGGL/BLL/Common/Const.cs index b8934340..e5b1a509 100644 --- a/SGGL/BLL/Common/Const.cs +++ b/SGGL/BLL/Common/Const.cs @@ -4452,6 +4452,13 @@ #endregion + #region 进度 + /// + /// 项目施工WBS定制 + /// + public const string PlanSetMenuId = "E23F0879-3E9F-4E7B-9A2D-EFF34798D629"; + #endregion + #region 施工综合 #region 菜单Id /// diff --git a/SGGL/BLL/ProjectData/UnitWorkService.cs b/SGGL/BLL/ProjectData/UnitWorkService.cs index adde94de..92425604 100644 --- a/SGGL/BLL/ProjectData/UnitWorkService.cs +++ b/SGGL/BLL/ProjectData/UnitWorkService.cs @@ -58,6 +58,10 @@ namespace BLL newUnitWork.NDEUnit = UnitWork.NDEUnit; newUnitWork.Costs = UnitWork.Costs; newUnitWork.MainItemAndDesignProfessionalIds = UnitWork.MainItemAndDesignProfessionalIds; + newUnitWork.PlanStartDate = UnitWork.PlanStartDate; + newUnitWork.PlanEndDate = UnitWork.PlanEndDate; + newUnitWork.RealStartDate = UnitWork.RealStartDate; + newUnitWork.RealEndDate = UnitWork.RealEndDate; db.SubmitChanges(); } GetWeights(UnitWork.ProjectId); diff --git a/SGGL/FineUIPro.Web/File/Word/ZHGL/项目安全生产策划书评审表.doc b/SGGL/FineUIPro.Web/File/Word/ZHGL/项目安全生产策划书评审表.doc index c0a689c3437b419e227d2fd6fea586d71c795a02..643930966301585303b1c1d589c0b2584fec6d0d 100644 GIT binary patch literal 27648 zcmeHQ2V7Lg)}L*#^dcQ1OA$~hyL1&4#DWM)x1i$E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lV;go24v6-rf}y2tTh>Y+`D!?hv~6K8WsSj>UnQV#gGn1Y*Orw z*qyOiv4t}n&-FrH#LM+Yd1JghZ=5&Lo9sEh>yPkr{n7qdztErJPxqJm75*dsc7KQ8 zJLGLuE9wngia0PlhU^8gsj;Xx(i`oK_42(5-Xt%Id`tZX|APPC4NDar@j~Pk^Sp7p zvUPd`q7T^gzn9VqyH>3_70yojd5(#bK083w%;r}gp*UTR{p%Y1eU;4w=^)lB(fZIb z%>0slf7K=D;>^E?pLp~?qmMrLhlLN#d3t%It?GV_m^MWFO`*+pwzHEl-7q;xjM}(# zrkAP+tkk|_^NgE3N@2c<3xHrC)4|J7d1GCZSb%;%K7(Edw&b}YixQiXXcwZ vCoiLXGbAWiyw}piX + @@ -11502,6 +11503,13 @@ index.aspx + + PlanSet.aspx + ASPXCodeBehind + + + PlanSet.aspx + ProgressShow.aspx ASPXCodeBehind diff --git a/SGGL/FineUIPro.Web/HSSE/ActionPlan/ActionPlanList.aspx.cs b/SGGL/FineUIPro.Web/HSSE/ActionPlan/ActionPlanList.aspx.cs index f4189c52..307a7d79 100644 --- a/SGGL/FineUIPro.Web/HSSE/ActionPlan/ActionPlanList.aspx.cs +++ b/SGGL/FineUIPro.Web/HSSE/ActionPlan/ActionPlanList.aspx.cs @@ -410,58 +410,59 @@ namespace FineUIPro.Web.HSSE.ActionPlan { projectName = "(" + projectName + ")"; } + else + { + projectName = "(无项目)"; + } projectName = projectName.Replace("/", "_"); newUrl = uploadfilepath.Replace(".doc", projectName + ".doc"); + filePath = uploadfilepath.Replace(".doc", projectName + ".pdf"); if (File.Exists(newUrl)) { File.Delete(newUrl); } File.Copy(uploadfilepath, newUrl); + + + ///更新书签 Document doc = new Aspose.Words.Document(newUrl); - Aspose.Words.DocumentBuilder builder = new Aspose.Words.DocumentBuilder(doc); - builder.MoveToBookmark("tab"); - builder.StartTable(); - builder.CellFormat.Borders.LineStyle = LineStyle.Single; - builder.CellFormat.Borders.Color = System.Drawing.Color.Black; - builder.Bold = false; - builder.RowFormat.Height = 20; - builder.Font.Size = 9; - #region 工程名称和项目部编制人员 - //工程名称和项目部编制人员 - builder.InsertCell(); - builder.CellFormat.VerticalMerge = Aspose.Words.Tables.CellMerge.None; - builder.CellFormat.HorizontalMerge = Aspose.Words.Tables.CellMerge.First; - builder.CellFormat.VerticalAlignment = Aspose.Words.Tables.CellVerticalAlignment.Center;//垂直居中对齐 - builder.ParagraphFormat.Alignment = ParagraphAlignment.Center;//水平居中对齐 - builder.CellFormat.Width = 100; - builder.Font.Bold = true; - builder.Write("工程名称"); + //写入第一行 + Bookmark bookmarkProjectName = doc.Range.Bookmarks["ProjectName"]; using (Model.SGGLDB db = new Model.SGGLDB(Funs.ConnString)) { - builder.InsertCell(); - builder.CellFormat.VerticalMerge = Aspose.Words.Tables.CellMerge.None; - builder.CellFormat.HorizontalMerge = Aspose.Words.Tables.CellMerge.First; - builder.CellFormat.VerticalAlignment = Aspose.Words.Tables.CellVerticalAlignment.Center;//垂直居中对齐 - builder.ParagraphFormat.Alignment = ParagraphAlignment.Center;//水平居中对齐 - builder.CellFormat.Width = 130; - builder.Font.Bold = false; var project = ProjectService.GetProjectByProjectId(actionPlanList.ProjectId); var ActionPlan_ActionPlanListApproveList = db.ActionPlan_ActionPlanListApprove.Where(x => x.ActionPlanListId == Id && x.ApproveType == "2").ToList(); - if (project != null) - { - if (project.ProjectName.Length > 20 && ActionPlan_ActionPlanListApproveList.Count != 0) - { - builder.Write(project.ProjectName.Substring(0, 20) + "\n" + - project.ProjectName.Substring(20)); - } - else - { - builder.Write(project.ProjectName); - } + + + if (bookmarkProjectName != null) + { + + if (project != null) + { + if (project.ProjectName.Length > 20 && ActionPlan_ActionPlanListApproveList.Count != 0) + { + bookmarkProjectName.Text = project.ProjectName.Substring(0, 20) + "\n" + + project.ProjectName.Substring(20); + } + else + { + bookmarkProjectName.Text = project.ProjectName; + } + + } } - builder.EndRow(); + + Aspose.Words.DocumentBuilder builder = new Aspose.Words.DocumentBuilder(doc); + builder.MoveToBookmark("tab"); + builder.StartTable(); + builder.CellFormat.Borders.LineStyle = LineStyle.Single; + builder.CellFormat.Borders.Color = System.Drawing.Color.Black; + builder.Bold = false; + builder.RowFormat.Height = 20; + builder.Font.Size = 9; + #region 工程名称和项目部编制人员 builder.InsertCell(); builder.CellFormat.VerticalMerge = Aspose.Words.Tables.CellMerge.None; builder.CellFormat.HorizontalMerge = Aspose.Words.Tables.CellMerge.First; @@ -476,7 +477,7 @@ namespace FineUIPro.Web.HSSE.ActionPlan builder.CellFormat.HorizontalMerge = Aspose.Words.Tables.CellMerge.First; builder.CellFormat.VerticalAlignment = Aspose.Words.Tables.CellVerticalAlignment.Center;//垂直居中对齐 builder.ParagraphFormat.Alignment = ParagraphAlignment.Center;//水平居中对齐 - builder.CellFormat.Width = 130; + builder.CellFormat.Width = 300; builder.Font.Bold = false; var getCompileMan = Person_PersonsService.GetPerson_PersonsById(actionPlanList.CompileMan); if (!string.IsNullOrEmpty(getCompileMan.SignatureUrl) && File.Exists(rootPath + getCompileMan.SignatureUrl)) @@ -517,7 +518,7 @@ namespace FineUIPro.Web.HSSE.ActionPlan //判断是不是最后一个 if (ActionPlan_ActionPlanListApproveList.Count == i + 1) { - builder.CellFormat.Width = 40; + builder.CellFormat.Width = 150; builder.Font.Bold = false; if (!string.IsNullOrEmpty(getApproveMan.SignatureUrl) && File.Exists(rootPath + getApproveMan.SignatureUrl)) { @@ -534,12 +535,12 @@ namespace FineUIPro.Web.HSSE.ActionPlan builder.CellFormat.HorizontalMerge = Aspose.Words.Tables.CellMerge.First; builder.CellFormat.VerticalAlignment = Aspose.Words.Tables.CellVerticalAlignment.Center;//垂直居中对齐 builder.ParagraphFormat.Alignment = ParagraphAlignment.Center;//水平居中对齐 - builder.CellFormat.Width = 90; + builder.CellFormat.Width = 150; builder.Write(""); } else { - builder.CellFormat.Width = 40; + builder.CellFormat.Width = 150; builder.Font.Bold = false; if (!string.IsNullOrEmpty(getApproveMan.SignatureUrl) && File.Exists(rootPath + getApproveMan.SignatureUrl)) { @@ -561,7 +562,7 @@ namespace FineUIPro.Web.HSSE.ActionPlan builder.CellFormat.HorizontalMerge = Aspose.Words.Tables.CellMerge.First; builder.CellFormat.VerticalAlignment = Aspose.Words.Tables.CellVerticalAlignment.Center;//垂直居中对齐 builder.ParagraphFormat.Alignment = ParagraphAlignment.Center;//水平居中对齐 - builder.CellFormat.Width = 70; + builder.CellFormat.Width = 100; builder.Font.Bold = true; builder.Write("项目部审核人"); @@ -570,7 +571,7 @@ namespace FineUIPro.Web.HSSE.ActionPlan builder.CellFormat.HorizontalMerge = Aspose.Words.Tables.CellMerge.First; builder.CellFormat.VerticalAlignment = Aspose.Words.Tables.CellVerticalAlignment.Center;//垂直居中对齐 builder.ParagraphFormat.Alignment = ParagraphAlignment.Center;//水平居中对齐 - builder.CellFormat.Width = 20; + builder.CellFormat.Width = 50; var getApproveMan2 = Person_PersonsService.GetPerson_PersonsById(ActionPlan_ActionPlanListApproveList[i + 1].ApproveMan); builder.Font.Bold = false; if (!string.IsNullOrEmpty(getApproveMan2.SignatureUrl) && File.Exists(rootPath + getApproveMan2.SignatureUrl)) @@ -608,7 +609,7 @@ namespace FineUIPro.Web.HSSE.ActionPlan builder.CellFormat.HorizontalMerge = Aspose.Words.Tables.CellMerge.First; builder.CellFormat.VerticalAlignment = Aspose.Words.Tables.CellVerticalAlignment.Center;//垂直居中对齐 builder.ParagraphFormat.Alignment = ParagraphAlignment.Center;//水平居中对齐 - builder.CellFormat.Width = 230; + builder.CellFormat.Width = 400; builder.Font.Bold = true; builder.Write("主要评审部门"); builder.EndRow(); @@ -618,7 +619,7 @@ namespace FineUIPro.Web.HSSE.ActionPlan builder.CellFormat.HorizontalMerge = Aspose.Words.Tables.CellMerge.First; builder.CellFormat.VerticalAlignment = Aspose.Words.Tables.CellVerticalAlignment.Center;//垂直居中对齐 builder.ParagraphFormat.Alignment = ParagraphAlignment.Center;//水平居中对齐 - builder.CellFormat.Width = 80; + builder.CellFormat.Width = 150; builder.Font.Bold = true; builder.Write("评审部门"); @@ -627,7 +628,7 @@ namespace FineUIPro.Web.HSSE.ActionPlan builder.CellFormat.HorizontalMerge = Aspose.Words.Tables.CellMerge.First; builder.CellFormat.VerticalAlignment = Aspose.Words.Tables.CellVerticalAlignment.Center;//垂直居中对齐 builder.ParagraphFormat.Alignment = ParagraphAlignment.Center;//水平居中对齐 - builder.CellFormat.Width = 80; + builder.CellFormat.Width = 100; builder.Font.Bold = true; builder.Write("评审意见"); @@ -636,7 +637,7 @@ namespace FineUIPro.Web.HSSE.ActionPlan builder.CellFormat.HorizontalMerge = Aspose.Words.Tables.CellMerge.First; builder.CellFormat.VerticalAlignment = Aspose.Words.Tables.CellVerticalAlignment.Center;//垂直居中对齐 builder.ParagraphFormat.Alignment = ParagraphAlignment.Center;//水平居中对齐 - builder.CellFormat.Width = 70; + builder.CellFormat.Width = 150; builder.Font.Bold = true; builder.Write("评审部门负责人/日期"); builder.EndRow(); @@ -649,7 +650,7 @@ namespace FineUIPro.Web.HSSE.ActionPlan builder.CellFormat.HorizontalMerge = Aspose.Words.Tables.CellMerge.First; builder.CellFormat.VerticalAlignment = Aspose.Words.Tables.CellVerticalAlignment.Center;//垂直居中对齐 builder.ParagraphFormat.Alignment = ParagraphAlignment.Center;//水平居中对齐 - builder.CellFormat.Width = 80; + builder.CellFormat.Width = 150; builder.Font.Bold = false; builder.Write("施工管理部"); //评审意见 @@ -658,7 +659,7 @@ namespace FineUIPro.Web.HSSE.ActionPlan builder.CellFormat.HorizontalMerge = Aspose.Words.Tables.CellMerge.First; builder.CellFormat.VerticalAlignment = Aspose.Words.Tables.CellVerticalAlignment.Center;//垂直居中对齐 builder.ParagraphFormat.Alignment = ParagraphAlignment.Center;//水平居中对齐 - builder.CellFormat.Width = 80; + builder.CellFormat.Width = 100; builder.Font.Bold = false; if (!string.IsNullOrEmpty(item.ApproveIdea)) { @@ -676,7 +677,7 @@ namespace FineUIPro.Web.HSSE.ActionPlan builder.CellFormat.HorizontalMerge = Aspose.Words.Tables.CellMerge.First; builder.CellFormat.VerticalAlignment = Aspose.Words.Tables.CellVerticalAlignment.Center;//垂直居中对齐 builder.ParagraphFormat.Alignment = ParagraphAlignment.Center;//水平居中对齐 - builder.CellFormat.Width = 70; + builder.CellFormat.Width = 150; builder.Font.Bold = false; if (item.ApproveDate != null) { @@ -706,7 +707,7 @@ namespace FineUIPro.Web.HSSE.ActionPlan builder.CellFormat.HorizontalMerge = Aspose.Words.Tables.CellMerge.First; builder.CellFormat.VerticalAlignment = Aspose.Words.Tables.CellVerticalAlignment.Center;//垂直居中对齐 builder.ParagraphFormat.Alignment = ParagraphAlignment.Center;//水平居中对齐 - builder.CellFormat.Width = 80; + builder.CellFormat.Width = 150; var departModel = db.Base_Depart.FirstOrDefault(x => x.DepartId == item.DepartId); builder.Font.Bold = false; if (departModel != null) @@ -719,7 +720,7 @@ namespace FineUIPro.Web.HSSE.ActionPlan builder.CellFormat.HorizontalMerge = Aspose.Words.Tables.CellMerge.First; builder.CellFormat.VerticalAlignment = Aspose.Words.Tables.CellVerticalAlignment.Center;//垂直居中对齐 builder.ParagraphFormat.Alignment = ParagraphAlignment.Center;//水平居中对齐 - builder.CellFormat.Width = 80; + builder.CellFormat.Width = 100; builder.Font.Bold = false; if (!string.IsNullOrEmpty(item.ApproveIdea)) { @@ -737,7 +738,7 @@ namespace FineUIPro.Web.HSSE.ActionPlan builder.CellFormat.HorizontalMerge = Aspose.Words.Tables.CellMerge.First; builder.CellFormat.VerticalAlignment = Aspose.Words.Tables.CellVerticalAlignment.Center;//垂直居中对齐 builder.ParagraphFormat.Alignment = ParagraphAlignment.Center;//水平居中对齐 - builder.CellFormat.Width = 70; + builder.CellFormat.Width = 150; builder.Font.Bold = false; if (item.ApproveDate != null) { @@ -777,13 +778,13 @@ namespace FineUIPro.Web.HSSE.ActionPlan builder.CellFormat.HorizontalMerge = Aspose.Words.Tables.CellMerge.First; builder.CellFormat.VerticalAlignment = Aspose.Words.Tables.CellVerticalAlignment.Bottom;//底部对齐 builder.ParagraphFormat.Alignment = ParagraphAlignment.Left;//水平居中对齐 - builder.CellFormat.Width = 130; + builder.CellFormat.Width = 300; builder.Font.Bold = true; builder.RowFormat.Height = 40; builder.Write("公司安全总监/部门负责人:"); - builder.Write(" 年"); + builder.Write(" 年"); builder.Write(" 月"); - builder.Write(" 日"); + builder.Write(" 日"); builder.EndRow(); builder.InsertCell(); @@ -793,20 +794,20 @@ namespace FineUIPro.Web.HSSE.ActionPlan builder.ParagraphFormat.Alignment = ParagraphAlignment.Center;//水平居中对齐 builder.CellFormat.Width = 100; builder.Font.Bold = true; - builder.Write("审核"); + builder.Write("审批"); //公司安全总监/部门负责人 builder.InsertCell(); builder.CellFormat.VerticalMerge = Aspose.Words.Tables.CellMerge.None; builder.CellFormat.HorizontalMerge = Aspose.Words.Tables.CellMerge.First; builder.CellFormat.VerticalAlignment = Aspose.Words.Tables.CellVerticalAlignment.Bottom;//底部对齐 builder.ParagraphFormat.Alignment = ParagraphAlignment.Left;//水平居中对齐 - builder.CellFormat.Width = 130; + builder.CellFormat.Width = 300; builder.Font.Bold = true; builder.RowFormat.Height = 40; builder.Write("公司主管生产/安全领导:"); - builder.Write(" 年"); + builder.Write(" 年"); builder.Write(" 月"); - builder.Write(" 日"); + builder.Write(" 日"); builder.EndRow(); builder.Font.Bold = false; @@ -816,17 +817,24 @@ namespace FineUIPro.Web.HSSE.ActionPlan } doc.Save(newUrl); - string fileName = Path.GetFileName(newUrl); - FileInfo info = new FileInfo(newUrl); + //生成PDF文件 + string pdfUrl = newUrl.Replace(".doc", ".pdf"); + Document doc1 = new Aspose.Words.Document(newUrl); + //验证参数 + if (doc1 == null) { throw new Exception("Word文件无效"); } + doc1.Save(pdfUrl, Aspose.Words.SaveFormat.Pdf);//还可以改成其它格式 + string fileName = Path.GetFileName(filePath); + FileInfo info = new FileInfo(pdfUrl); long fileSize = info.Length; Response.Clear(); Response.ContentType = "application/x-zip-compressed"; Response.AddHeader("Content-Disposition", "attachment;filename=" + System.Web.HttpUtility.UrlEncode(fileName, System.Text.Encoding.UTF8)); Response.AddHeader("Content-Length", fileSize.ToString()); - Response.TransmitFile(newUrl, 0, fileSize); + Response.TransmitFile(pdfUrl, 0, fileSize); Response.Flush(); Response.Close(); File.Delete(newUrl); + File.Delete(pdfUrl); } catch (Exception ex) { diff --git a/SGGL/FineUIPro.Web/JDGL/Check/PlanSet.aspx b/SGGL/FineUIPro.Web/JDGL/Check/PlanSet.aspx new file mode 100644 index 00000000..108e4e79 --- /dev/null +++ b/SGGL/FineUIPro.Web/JDGL/Check/PlanSet.aspx @@ -0,0 +1,130 @@ +<%@ Page Language="C#" AutoEventWireup="true" CodeBehind="PlanSet.aspx.cs" Inherits="FineUIPro.Web.JDGL.Check.PlanSet" %> + + + + + +进度计划设置 + + + +
+ + + + + + + + + + + + + + + + <%----%> + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/SGGL/FineUIPro.Web/JDGL/Check/PlanSet.aspx.cs b/SGGL/FineUIPro.Web/JDGL/Check/PlanSet.aspx.cs new file mode 100644 index 00000000..9d34cda5 --- /dev/null +++ b/SGGL/FineUIPro.Web/JDGL/Check/PlanSet.aspx.cs @@ -0,0 +1,387 @@ +using BLL; +using Newtonsoft.Json.Linq; +using System; +using System.Collections.Generic; +using System.Data; +using System.Linq; +using System.Web.UI.WebControls; + +namespace FineUIPro.Web.JDGL.Check +{ + public partial class PlanSet : PageBase + { + #region 加载 + /// + /// 加载页面 + /// + /// + /// + protected void Page_Load(object sender, EventArgs e) + { + if (!IsPostBack) + { + BindGrid(); + } + } + #endregion + + private void BindGrid() + { + DataTable table = BLL.WorkPackageService.GetAllTreeDataTable(this.CurrUser.LoginProjectId); + Grid1.DataSource = table; + Grid1.DataBind(); + for (int i = 0; i < this.Grid1.Rows.Count; i++) + { + if (string.IsNullOrEmpty(this.Grid1.Rows[i].DataKeys[2].ToString())) + { + System.Web.UI.WebControls.CheckBox cbIsMileStone = (System.Web.UI.WebControls.CheckBox)(this.Grid1.Rows[i].FindControl("cbIsMileStone")); + cbIsMileStone.Visible = false; + foreach (GridColumn column in Grid1.Columns) + { + if (column.ColumnIndex != 0) + { + this.Grid1.Rows[i].CellCssClasses[column.ColumnIndex] = "f-grid-cell-uneditable"; + } + } + } + else + { + System.Web.UI.WebControls.CheckBox cbIsMileStone = (System.Web.UI.WebControls.CheckBox)(this.Grid1.Rows[i].FindControl("cbIsMileStone")); + Model.WBS_WorkPackage workPackage = BLL.WorkPackageService.GetWorkPackageByWorkPackageId(this.Grid1.Rows[i].DataKeys[2].ToString()); + if (workPackage != null && workPackage.IsMileStone == true) + { + cbIsMileStone.Checked = true; + } + } + } + } + + #region 保存 + /// + /// 保存按钮 + /// + /// + /// + protected void btnSave_Click(object sender, EventArgs e) + { + if (BLL.CommonService.GetAllButtonPowerList(this.CurrUser.LoginProjectId, this.CurrUser.PersonId, BLL.Const.PlanSetMenuId, BLL.Const.BtnSave)) + { + Save(); + BindGrid(); + ShowNotify("保存成功!", MessageBoxIcon.Success); + PageContext.RegisterStartupScript(ActiveWindow.GetHideReference()); + } + else + { + ShowNotify("您没有这个权限,请与管理员联系!", MessageBoxIcon.Warning); + } + } + + private void Save() + { + Model.SGGLDB db = Funs.DB; + var workPackages = from x in db.WBS_WorkPackage + where x.ProjectId == this.CurrUser.LoginProjectId + select x; + var unitWorks = from x in db.WBS_UnitWork + where x.ProjectId == this.CurrUser.LoginProjectId + select x; + string[] ids = this.hdId.Text.Split(','); + if (ids.Length > 0) + { + foreach (JObject mergedRow in Grid1.GetMergedData()) + { + JObject values = mergedRow.Value("values"); + int i = mergedRow.Value("index"); + if (this.Grid1.Rows[i].DataKeys[2] != null) + { + Model.WBS_WorkPackage workPackage = workPackages.FirstOrDefault(x => x.WorkPackageId == this.Grid1.Rows[i].DataKeys[2].ToString()); + if (workPackage != null) + { + string weights = values.Value("Weights"); + string unit = values.Value("Unit"); + string planProjectQuantity = values.Value("PlanProjectQuantity"); + string realProjectQuantity = values.Value("RealProjectQuantity"); + string planStartDate = values.Value("PlanStartDate"); + string planEndDate = values.Value("PlanEndDate"); + string realStartDate = values.Value("RealStartDate"); + string realEndDate = values.Value("RealEndDate"); + System.Web.UI.WebControls.CheckBox cbIsMileStone = (System.Web.UI.WebControls.CheckBox)(this.Grid1.Rows[i].FindControl("cbIsMileStone")); + workPackage.Weights = Funs.GetNewDecimal(weights); + workPackage.Unit = unit; + workPackage.PlanProjectQuantity = Funs.GetNewDecimal(planProjectQuantity); + workPackage.RealProjectQuantity = Funs.GetNewDecimal(realProjectQuantity); + workPackage.PlanStartDate = Funs.GetNewDateTime(planStartDate); + workPackage.PlanEndDate = Funs.GetNewDateTime(planEndDate); + workPackage.RealStartDate = Funs.GetNewDateTime(realStartDate); + workPackage.RealEndDate = Funs.GetNewDateTime(realEndDate); + workPackage.IsMileStone = cbIsMileStone.Checked; + BLL.WorkPackageService.UpdateWorkPackage(workPackage); + if (workPackage.PlanStartDate != null || workPackage.PlanEndDate != null || workPackage.RealStartDate != null || workPackage.RealEndDate != null) + { + UpdateWorkPackages(db, workPackage, workPackage.PlanStartDate, workPackage.PlanEndDate, workPackage.RealStartDate, workPackage.RealEndDate); + var unitWork = unitWorks.FirstOrDefault(x => x.UnitWorkId == workPackage.UnitWorkId); + if (workPackage.PlanStartDate != null) + { + if (unitWork.PlanStartDate == null) + { + unitWork.PlanStartDate = workPackage.PlanStartDate; + } + else + { + if (unitWork.PlanStartDate > workPackage.PlanStartDate) + { + unitWork.PlanStartDate = workPackage.PlanStartDate; + } + } + } + if (workPackage.PlanEndDate != null) + { + if (unitWork.PlanEndDate == null) + { + unitWork.PlanEndDate = workPackage.PlanEndDate; + } + else + { + if (unitWork.PlanEndDate < workPackage.PlanEndDate) + { + unitWork.PlanEndDate = workPackage.PlanEndDate; + } + } + } + if (workPackage.RealStartDate != null) + { + if (unitWork.RealStartDate == null) + { + unitWork.RealStartDate = workPackage.RealStartDate; + } + else + { + if (unitWork.RealStartDate > workPackage.RealStartDate) + { + unitWork.RealStartDate = workPackage.RealStartDate; + } + } + } + if (workPackage.RealEndDate != null) + { + if (unitWork.RealEndDate == null) + { + unitWork.RealEndDate = workPackage.RealEndDate; + } + else + { + if (unitWork.RealEndDate < workPackage.RealEndDate) + { + unitWork.RealEndDate = workPackage.RealEndDate; + } + } + } + } + db.SubmitChanges(); + } + } + } + } + } + + #region 更新工作包、工作项 + /// + /// 更新月工作包、工作项 + /// + /// + /// + /// + /// + private void UpdateWorkPackages(Model.SGGLDB db, Model.WBS_WorkPackage workPackage, DateTime? planStartDate, DateTime? planEndDate, DateTime? realStartDate, DateTime? realEndDate) + { + if (workPackage != null) + { + Model.WBS_WorkPackage parentWorkPackage = BLL.WorkPackageService.GetWorkPackageByWorkPackageId(workPackage.SuperWorkPackageId); + if (parentWorkPackage != null) + { + if (planStartDate != null) + { + if (parentWorkPackage.PlanStartDate == null) + { + parentWorkPackage.PlanStartDate = planStartDate; + } + else + { + if (parentWorkPackage.PlanStartDate > planStartDate) + { + parentWorkPackage.PlanStartDate = planStartDate; + } + } + } + if (planEndDate != null) + { + if (parentWorkPackage.PlanEndDate == null) + { + parentWorkPackage.PlanEndDate = planEndDate; + } + else + { + if (parentWorkPackage.PlanEndDate < planEndDate) + { + parentWorkPackage.PlanEndDate = planEndDate; + } + } + } + if (realStartDate != null) + { + if (parentWorkPackage.RealStartDate == null) + { + parentWorkPackage.RealStartDate = realStartDate; + } + else + { + if (parentWorkPackage.RealStartDate > realStartDate) + { + parentWorkPackage.RealStartDate = realStartDate; + } + } + } + if (realEndDate != null) + { + if (parentWorkPackage.RealEndDate == null) + { + parentWorkPackage.RealEndDate = realEndDate; + } + else + { + if (parentWorkPackage.RealEndDate < realEndDate) + { + parentWorkPackage.RealEndDate = realEndDate; + } + } + } + UpdateWorkPackages(db, parentWorkPackage, planStartDate, planEndDate, realStartDate, realEndDate); + } + } + } + + /// + /// 更新周工作包、工作项 + /// + /// + /// + /// + /// + private void UpdateWeekWbsSetDetail(string wbsSetId, DateTime months, DateTime startDate, DateTime endDate, decimal changeThisPlanValue, decimal changeThisRealCost, decimal changeThisPlanCost) + { + //Model.Wbs_WbsSet wbsSet = BLL.WbsSetService.GetWbsSetByWbsSetId(wbsSetId); + //if (wbsSet != null) + //{ + // Model.WBS_CostControlParentDetail parentDetail = BLL.CostControlParentDetailService.GetCostControlParentDetailByParentIdAndMonthsWeek(wbsSetId, months, startDate); + // if (parentDetail != null) + // { + // parentDetail.ThisPlanValue += changeThisPlanValue; + // parentDetail.ThisRealCost += changeThisRealCost; + // parentDetail.ThisPlanCost += changeThisPlanCost; + // BLL.CostControlParentDetailService.UpdateCostControlParentDetail(parentDetail); + // } + // else + // { + // parentDetail = new Model.WBS_CostControlParentDetail(); + // parentDetail.CostControlParentDetailId = SQLHelper.GetNewID(); + // parentDetail.ParentId = wbsSetId; + // parentDetail.Months = months; + // parentDetail.StartDate = startDate; + // parentDetail.EndDate = endDate; + // parentDetail.ThisPlanValue = changeThisPlanValue; + // parentDetail.ThisRealCost = changeThisRealCost; + // parentDetail.ThisPlanCost = changeThisPlanCost; + // BLL.CostControlParentDetailService.AddCostControlParentDetail(parentDetail); + // } + // if (wbsSet.SuperWbsSetId != null) //还存在上级节点,需要继续循环 + // { + // UpdateWeekWbsSetDetail(wbsSet.SuperWbsSetId, months, startDate, endDate, changeThisPlanValue, changeThisRealCost, changeThisPlanCost); + // } + //} + } + #endregion + + #region 更新装置 + /// + /// 更新月装置 + /// + /// + /// + /// + /// + private void UpdateInstallationDetail(Model.SGGLDB db, string installationId, DateTime months, decimal changeThisPlanValue, decimal changeThisRealCost, decimal changeThisPlanCost) + { + //Model.Project_Installation installation = BLL.Project_InstallationService.GetInstallationByInstallationId(installationId); + //if (installation != null) + //{ + // Model.WBS_CostControlParentDetail parentDetail = BLL.CostControlParentDetailService.GetCostControlParentDetailByParentIdAndMonths(installationId, months); + // if (parentDetail != null) + // { + // parentDetail.ThisPlanValue += changeThisPlanValue; + // parentDetail.ThisRealCost += changeThisRealCost; + // parentDetail.ThisPlanCost += changeThisPlanCost; + // //BLL.CostControlParentDetailService.UpdateCostControlParentDetail(parentDetail); + // } + // else + // { + // parentDetail = new Model.WBS_CostControlParentDetail(); + // parentDetail.CostControlParentDetailId = SQLHelper.GetNewID(); + // parentDetail.ParentId = installationId; + // parentDetail.Months = months; + // parentDetail.ThisPlanValue = changeThisPlanValue; + // parentDetail.ThisRealCost = changeThisRealCost; + // parentDetail.ThisPlanCost = changeThisPlanCost; + // //BLL.CostControlParentDetailService.AddCostControlParentDetail(parentDetail); + // db.WBS_CostControlParentDetail.InsertOnSubmit(parentDetail); + // } + // if (installation.SuperInstallationId != null) //还存在上级节点,需要继续循环 + // { + // UpdateInstallationDetail(db, installation.SuperInstallationId, months, changeThisPlanValue, changeThisRealCost, changeThisPlanCost); + // } + //} + } + + /// + /// 更新周装置 + /// + /// + /// + /// + /// + private void UpdateWeekInstallationDetail(string installationId, DateTime months, DateTime startDate, DateTime endDate, decimal changeThisPlanValue, decimal changeThisRealCost, decimal changeThisPlanCost) + { + //Model.Project_Installation installation = BLL.Project_InstallationService.GetInstallationByInstallationId(installationId); + //if (installation != null) + //{ + // Model.WBS_CostControlParentDetail parentDetail = BLL.CostControlParentDetailService.GetCostControlParentDetailByParentIdAndMonths(installationId, months); + // if (parentDetail != null) + // { + // parentDetail.ThisPlanValue += changeThisPlanValue; + // parentDetail.ThisRealCost += changeThisRealCost; + // parentDetail.ThisPlanCost += changeThisPlanCost; + // BLL.CostControlParentDetailService.UpdateCostControlParentDetail(parentDetail); + // } + // else + // { + // parentDetail = new Model.WBS_CostControlParentDetail(); + // parentDetail.CostControlParentDetailId = SQLHelper.GetNewID(); + // parentDetail.ParentId = installationId; + // parentDetail.Months = months; + // parentDetail.StartDate = startDate; + // parentDetail.EndDate = endDate; + // parentDetail.ThisPlanValue = changeThisPlanValue; + // parentDetail.ThisRealCost = changeThisRealCost; + // parentDetail.ThisPlanCost = changeThisPlanCost; + // BLL.CostControlParentDetailService.AddCostControlParentDetail(parentDetail); + // } + // if (installation.SuperInstallationId != null) //还存在上级节点,需要继续循环 + // { + // UpdateWeekInstallationDetail(installation.SuperInstallationId, months, startDate, endDate, changeThisPlanValue, changeThisRealCost, changeThisPlanCost); + // } + //} + } + #endregion + #endregion + } +} \ No newline at end of file diff --git a/SGGL/FineUIPro.Web/JDGL/Check/PlanSet.aspx.designer.cs b/SGGL/FineUIPro.Web/JDGL/Check/PlanSet.aspx.designer.cs new file mode 100644 index 00000000..32e0bca6 --- /dev/null +++ b/SGGL/FineUIPro.Web/JDGL/Check/PlanSet.aspx.designer.cs @@ -0,0 +1,168 @@ +//------------------------------------------------------------------------------ +// <自动生成> +// 此代码由工具生成。 +// +// 对此文件的更改可能导致不正确的行为,如果 +// 重新生成代码,则所做更改将丢失。 +// +//------------------------------------------------------------------------------ + +namespace FineUIPro.Web.JDGL.Check { + + + public partial class PlanSet { + + /// + /// 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; + + /// + /// hdId 控件。 + /// + /// + /// 自动生成的字段。 + /// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。 + /// + protected global::FineUIPro.TextBox hdId; + + /// + /// btnSave 控件。 + /// + /// + /// 自动生成的字段。 + /// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。 + /// + protected global::FineUIPro.Button btnSave; + + /// + /// IsMileStone 控件。 + /// + /// + /// 自动生成的字段。 + /// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。 + /// + protected global::FineUIPro.TemplateField IsMileStone; + + /// + /// cbIsMileStone 控件。 + /// + /// + /// 自动生成的字段。 + /// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。 + /// + protected global::System.Web.UI.WebControls.CheckBox cbIsMileStone; + + /// + /// nbWeights 控件。 + /// + /// + /// 自动生成的字段。 + /// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。 + /// + protected global::FineUIPro.NumberBox nbWeights; + + /// + /// txtUnit 控件。 + /// + /// + /// 自动生成的字段。 + /// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。 + /// + protected global::FineUIPro.TextBox txtUnit; + + /// + /// nbPlanProjectQuantity 控件。 + /// + /// + /// 自动生成的字段。 + /// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。 + /// + protected global::FineUIPro.NumberBox nbPlanProjectQuantity; + + /// + /// nbRealProjectQuantity 控件。 + /// + /// + /// 自动生成的字段。 + /// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。 + /// + protected global::FineUIPro.NumberBox nbRealProjectQuantity; + + /// + /// txtPlanStartDate 控件。 + /// + /// + /// 自动生成的字段。 + /// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。 + /// + protected global::FineUIPro.DatePicker txtPlanStartDate; + + /// + /// txtPlanEndDate 控件。 + /// + /// + /// 自动生成的字段。 + /// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。 + /// + protected global::FineUIPro.DatePicker txtPlanEndDate; + + /// + /// txtRealStartDate 控件。 + /// + /// + /// 自动生成的字段。 + /// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。 + /// + protected global::FineUIPro.DatePicker txtRealStartDate; + + /// + /// txtRealEndDate 控件。 + /// + /// + /// 自动生成的字段。 + /// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。 + /// + protected global::FineUIPro.DatePicker txtRealEndDate; + } +} diff --git a/SGGL/FineUIPro.Web/ZHGL/Plan/ActionPlanList.aspx b/SGGL/FineUIPro.Web/ZHGL/Plan/ActionPlanList.aspx index d94bfeb4..6f498392 100644 --- a/SGGL/FineUIPro.Web/ZHGL/Plan/ActionPlanList.aspx +++ b/SGGL/FineUIPro.Web/ZHGL/Plan/ActionPlanList.aspx @@ -143,4 +143,4 @@ } - + \ No newline at end of file diff --git a/SGGL/FineUIPro.Web/ZHGL/Plan/ActionPlanList.aspx.cs b/SGGL/FineUIPro.Web/ZHGL/Plan/ActionPlanList.aspx.cs index 1e997fe1..a2920c36 100644 --- a/SGGL/FineUIPro.Web/ZHGL/Plan/ActionPlanList.aspx.cs +++ b/SGGL/FineUIPro.Web/ZHGL/Plan/ActionPlanList.aspx.cs @@ -398,56 +398,53 @@ namespace FineUIPro.Web.ZHGL.Plan } projectName = projectName.Replace("/", "_"); newUrl = uploadfilepath.Replace(".doc", projectName + ".doc"); + filePath = uploadfilepath.Replace(".doc", projectName + ".pdf"); if (File.Exists(newUrl)) { File.Delete(newUrl); } File.Copy(uploadfilepath, newUrl); + + + ///更新书签 Document doc = new Aspose.Words.Document(newUrl); - Aspose.Words.DocumentBuilder builder = new Aspose.Words.DocumentBuilder(doc); - builder.MoveToBookmark("tab"); - builder.StartTable(); - builder.CellFormat.Borders.LineStyle = LineStyle.Single; - builder.CellFormat.Borders.Color = System.Drawing.Color.Black; - builder.Bold = false; - builder.RowFormat.Height = 20; - builder.Font.Size = 9; - #region 工程名称和项目部编制人员 - //工程名称和项目部编制人员 - builder.InsertCell(); - builder.CellFormat.VerticalMerge = Aspose.Words.Tables.CellMerge.None; - builder.CellFormat.HorizontalMerge = Aspose.Words.Tables.CellMerge.First; - builder.CellFormat.VerticalAlignment = Aspose.Words.Tables.CellVerticalAlignment.Center;//垂直居中对齐 - builder.ParagraphFormat.Alignment = ParagraphAlignment.Center;//水平居中对齐 - builder.CellFormat.Width = 100; - builder.Font.Bold = true; - builder.Write("工程名称"); + //写入第一行 + Bookmark bookmarkProjectName = doc.Range.Bookmarks["ProjectName"]; using (Model.SGGLDB db = new Model.SGGLDB(Funs.ConnString)) { - builder.InsertCell(); - builder.CellFormat.VerticalMerge = Aspose.Words.Tables.CellMerge.None; - builder.CellFormat.HorizontalMerge = Aspose.Words.Tables.CellMerge.First; - builder.CellFormat.VerticalAlignment = Aspose.Words.Tables.CellVerticalAlignment.Center;//垂直居中对齐 - builder.ParagraphFormat.Alignment = ParagraphAlignment.Center;//水平居中对齐 - builder.CellFormat.Width = 130; - builder.Font.Bold = false; var project = ProjectService.GetProjectByProjectId(actionPlanList.ProjectId); var ActionPlan_ActionPlanListApproveList = db.ActionPlan_ActionPlanListApprove.Where(x => x.ActionPlanListId == Id && x.ApproveType == "2").ToList(); - if (project != null) - { - if (project.ProjectName.Length > 20 && ActionPlan_ActionPlanListApproveList.Count != 0) - { - builder.Write(project.ProjectName.Substring(0, 20) + "\n" + - project.ProjectName.Substring(20)); - } - else - { - builder.Write(project.ProjectName); - } + + + if (bookmarkProjectName != null) + { + + if (project != null) + { + if (project.ProjectName.Length > 20 && ActionPlan_ActionPlanListApproveList.Count != 0) + { + bookmarkProjectName.Text = project.ProjectName.Substring(0, 20) + "\n" + + project.ProjectName.Substring(20); + } + else + { + bookmarkProjectName.Text = project.ProjectName; + } + + } } - builder.EndRow(); + + Aspose.Words.DocumentBuilder builder = new Aspose.Words.DocumentBuilder(doc); + builder.MoveToBookmark("tab"); + builder.StartTable(); + builder.CellFormat.Borders.LineStyle = LineStyle.Single; + builder.CellFormat.Borders.Color = System.Drawing.Color.Black; + builder.Bold = false; + builder.RowFormat.Height = 20; + builder.Font.Size = 9; + #region 工程名称和项目部编制人员 builder.InsertCell(); builder.CellFormat.VerticalMerge = Aspose.Words.Tables.CellMerge.None; builder.CellFormat.HorizontalMerge = Aspose.Words.Tables.CellMerge.First; @@ -462,7 +459,7 @@ namespace FineUIPro.Web.ZHGL.Plan builder.CellFormat.HorizontalMerge = Aspose.Words.Tables.CellMerge.First; builder.CellFormat.VerticalAlignment = Aspose.Words.Tables.CellVerticalAlignment.Center;//垂直居中对齐 builder.ParagraphFormat.Alignment = ParagraphAlignment.Center;//水平居中对齐 - builder.CellFormat.Width = 130; + builder.CellFormat.Width = 300; builder.Font.Bold = false; var getCompileMan = Person_PersonsService.GetPerson_PersonsById(actionPlanList.CompileMan); if (!string.IsNullOrEmpty(getCompileMan.SignatureUrl) && File.Exists(rootPath + getCompileMan.SignatureUrl)) @@ -503,7 +500,7 @@ namespace FineUIPro.Web.ZHGL.Plan //判断是不是最后一个 if (ActionPlan_ActionPlanListApproveList.Count == i + 1) { - builder.CellFormat.Width = 40; + builder.CellFormat.Width = 150; builder.Font.Bold = false; if (!string.IsNullOrEmpty(getApproveMan.SignatureUrl) && File.Exists(rootPath + getApproveMan.SignatureUrl)) { @@ -520,12 +517,12 @@ namespace FineUIPro.Web.ZHGL.Plan builder.CellFormat.HorizontalMerge = Aspose.Words.Tables.CellMerge.First; builder.CellFormat.VerticalAlignment = Aspose.Words.Tables.CellVerticalAlignment.Center;//垂直居中对齐 builder.ParagraphFormat.Alignment = ParagraphAlignment.Center;//水平居中对齐 - builder.CellFormat.Width = 90; + builder.CellFormat.Width = 150; builder.Write(""); } else { - builder.CellFormat.Width = 40; + builder.CellFormat.Width = 150; builder.Font.Bold = false; if (!string.IsNullOrEmpty(getApproveMan.SignatureUrl) && File.Exists(rootPath + getApproveMan.SignatureUrl)) { @@ -547,7 +544,7 @@ namespace FineUIPro.Web.ZHGL.Plan builder.CellFormat.HorizontalMerge = Aspose.Words.Tables.CellMerge.First; builder.CellFormat.VerticalAlignment = Aspose.Words.Tables.CellVerticalAlignment.Center;//垂直居中对齐 builder.ParagraphFormat.Alignment = ParagraphAlignment.Center;//水平居中对齐 - builder.CellFormat.Width = 70; + builder.CellFormat.Width = 100; builder.Font.Bold = true; builder.Write("项目部审核人"); @@ -556,7 +553,7 @@ namespace FineUIPro.Web.ZHGL.Plan builder.CellFormat.HorizontalMerge = Aspose.Words.Tables.CellMerge.First; builder.CellFormat.VerticalAlignment = Aspose.Words.Tables.CellVerticalAlignment.Center;//垂直居中对齐 builder.ParagraphFormat.Alignment = ParagraphAlignment.Center;//水平居中对齐 - builder.CellFormat.Width = 20; + builder.CellFormat.Width = 50; var getApproveMan2 = Person_PersonsService.GetPerson_PersonsById(ActionPlan_ActionPlanListApproveList[i + 1].ApproveMan); builder.Font.Bold = false; if (!string.IsNullOrEmpty(getApproveMan2.SignatureUrl) && File.Exists(rootPath + getApproveMan2.SignatureUrl)) @@ -594,7 +591,7 @@ namespace FineUIPro.Web.ZHGL.Plan builder.CellFormat.HorizontalMerge = Aspose.Words.Tables.CellMerge.First; builder.CellFormat.VerticalAlignment = Aspose.Words.Tables.CellVerticalAlignment.Center;//垂直居中对齐 builder.ParagraphFormat.Alignment = ParagraphAlignment.Center;//水平居中对齐 - builder.CellFormat.Width = 230; + builder.CellFormat.Width = 400; builder.Font.Bold = true; builder.Write("主要评审部门"); builder.EndRow(); @@ -604,7 +601,7 @@ namespace FineUIPro.Web.ZHGL.Plan builder.CellFormat.HorizontalMerge = Aspose.Words.Tables.CellMerge.First; builder.CellFormat.VerticalAlignment = Aspose.Words.Tables.CellVerticalAlignment.Center;//垂直居中对齐 builder.ParagraphFormat.Alignment = ParagraphAlignment.Center;//水平居中对齐 - builder.CellFormat.Width = 80; + builder.CellFormat.Width = 150; builder.Font.Bold = true; builder.Write("评审部门"); @@ -613,7 +610,7 @@ namespace FineUIPro.Web.ZHGL.Plan builder.CellFormat.HorizontalMerge = Aspose.Words.Tables.CellMerge.First; builder.CellFormat.VerticalAlignment = Aspose.Words.Tables.CellVerticalAlignment.Center;//垂直居中对齐 builder.ParagraphFormat.Alignment = ParagraphAlignment.Center;//水平居中对齐 - builder.CellFormat.Width = 80; + builder.CellFormat.Width = 100; builder.Font.Bold = true; builder.Write("评审意见"); @@ -622,7 +619,7 @@ namespace FineUIPro.Web.ZHGL.Plan builder.CellFormat.HorizontalMerge = Aspose.Words.Tables.CellMerge.First; builder.CellFormat.VerticalAlignment = Aspose.Words.Tables.CellVerticalAlignment.Center;//垂直居中对齐 builder.ParagraphFormat.Alignment = ParagraphAlignment.Center;//水平居中对齐 - builder.CellFormat.Width = 70; + builder.CellFormat.Width = 150; builder.Font.Bold = true; builder.Write("评审部门负责人/日期"); builder.EndRow(); @@ -635,7 +632,7 @@ namespace FineUIPro.Web.ZHGL.Plan builder.CellFormat.HorizontalMerge = Aspose.Words.Tables.CellMerge.First; builder.CellFormat.VerticalAlignment = Aspose.Words.Tables.CellVerticalAlignment.Center;//垂直居中对齐 builder.ParagraphFormat.Alignment = ParagraphAlignment.Center;//水平居中对齐 - builder.CellFormat.Width = 80; + builder.CellFormat.Width = 150; builder.Font.Bold = false; builder.Write("施工管理部"); //评审意见 @@ -644,7 +641,7 @@ namespace FineUIPro.Web.ZHGL.Plan builder.CellFormat.HorizontalMerge = Aspose.Words.Tables.CellMerge.First; builder.CellFormat.VerticalAlignment = Aspose.Words.Tables.CellVerticalAlignment.Center;//垂直居中对齐 builder.ParagraphFormat.Alignment = ParagraphAlignment.Center;//水平居中对齐 - builder.CellFormat.Width = 80; + builder.CellFormat.Width = 100; builder.Font.Bold = false; if (!string.IsNullOrEmpty(item.ApproveIdea)) { @@ -662,7 +659,7 @@ namespace FineUIPro.Web.ZHGL.Plan builder.CellFormat.HorizontalMerge = Aspose.Words.Tables.CellMerge.First; builder.CellFormat.VerticalAlignment = Aspose.Words.Tables.CellVerticalAlignment.Center;//垂直居中对齐 builder.ParagraphFormat.Alignment = ParagraphAlignment.Center;//水平居中对齐 - builder.CellFormat.Width = 70; + builder.CellFormat.Width = 150; builder.Font.Bold = false; if (item.ApproveDate != null) { @@ -692,7 +689,7 @@ namespace FineUIPro.Web.ZHGL.Plan builder.CellFormat.HorizontalMerge = Aspose.Words.Tables.CellMerge.First; builder.CellFormat.VerticalAlignment = Aspose.Words.Tables.CellVerticalAlignment.Center;//垂直居中对齐 builder.ParagraphFormat.Alignment = ParagraphAlignment.Center;//水平居中对齐 - builder.CellFormat.Width = 80; + builder.CellFormat.Width = 150; var departModel = db.Base_Depart.FirstOrDefault(x => x.DepartId == item.DepartId); builder.Font.Bold = false; if (departModel != null) @@ -705,7 +702,7 @@ namespace FineUIPro.Web.ZHGL.Plan builder.CellFormat.HorizontalMerge = Aspose.Words.Tables.CellMerge.First; builder.CellFormat.VerticalAlignment = Aspose.Words.Tables.CellVerticalAlignment.Center;//垂直居中对齐 builder.ParagraphFormat.Alignment = ParagraphAlignment.Center;//水平居中对齐 - builder.CellFormat.Width = 80; + builder.CellFormat.Width = 100; builder.Font.Bold = false; if (!string.IsNullOrEmpty(item.ApproveIdea)) { @@ -723,7 +720,7 @@ namespace FineUIPro.Web.ZHGL.Plan builder.CellFormat.HorizontalMerge = Aspose.Words.Tables.CellMerge.First; builder.CellFormat.VerticalAlignment = Aspose.Words.Tables.CellVerticalAlignment.Center;//垂直居中对齐 builder.ParagraphFormat.Alignment = ParagraphAlignment.Center;//水平居中对齐 - builder.CellFormat.Width = 70; + builder.CellFormat.Width = 150; builder.Font.Bold = false; if (item.ApproveDate != null) { @@ -763,13 +760,13 @@ namespace FineUIPro.Web.ZHGL.Plan builder.CellFormat.HorizontalMerge = Aspose.Words.Tables.CellMerge.First; builder.CellFormat.VerticalAlignment = Aspose.Words.Tables.CellVerticalAlignment.Bottom;//底部对齐 builder.ParagraphFormat.Alignment = ParagraphAlignment.Left;//水平居中对齐 - builder.CellFormat.Width = 130; + builder.CellFormat.Width = 300; builder.Font.Bold = true; builder.RowFormat.Height = 40; builder.Write("公司安全总监/部门负责人:"); - builder.Write(" 年"); + builder.Write(" 年"); builder.Write(" 月"); - builder.Write(" 日"); + builder.Write(" 日"); builder.EndRow(); builder.InsertCell(); @@ -779,20 +776,20 @@ namespace FineUIPro.Web.ZHGL.Plan builder.ParagraphFormat.Alignment = ParagraphAlignment.Center;//水平居中对齐 builder.CellFormat.Width = 100; builder.Font.Bold = true; - builder.Write("审核"); + builder.Write("审批"); //公司安全总监/部门负责人 builder.InsertCell(); builder.CellFormat.VerticalMerge = Aspose.Words.Tables.CellMerge.None; builder.CellFormat.HorizontalMerge = Aspose.Words.Tables.CellMerge.First; builder.CellFormat.VerticalAlignment = Aspose.Words.Tables.CellVerticalAlignment.Bottom;//底部对齐 builder.ParagraphFormat.Alignment = ParagraphAlignment.Left;//水平居中对齐 - builder.CellFormat.Width = 130; + builder.CellFormat.Width = 300; builder.Font.Bold = true; builder.RowFormat.Height = 40; builder.Write("公司主管生产/安全领导:"); - builder.Write(" 年"); + builder.Write(" 年"); builder.Write(" 月"); - builder.Write(" 日"); + builder.Write(" 日"); builder.EndRow(); builder.Font.Bold = false; @@ -802,17 +799,24 @@ namespace FineUIPro.Web.ZHGL.Plan } doc.Save(newUrl); - string fileName = Path.GetFileName(newUrl); - FileInfo info = new FileInfo(newUrl); + //生成PDF文件 + string pdfUrl = newUrl.Replace(".doc", ".pdf"); + Document doc1 = new Aspose.Words.Document(newUrl); + //验证参数 + if (doc1 == null) { throw new Exception("Word文件无效"); } + doc1.Save(pdfUrl, Aspose.Words.SaveFormat.Pdf);//还可以改成其它格式 + string fileName = Path.GetFileName(filePath); + FileInfo info = new FileInfo(pdfUrl); long fileSize = info.Length; Response.Clear(); Response.ContentType = "application/x-zip-compressed"; Response.AddHeader("Content-Disposition", "attachment;filename=" + System.Web.HttpUtility.UrlEncode(fileName, System.Text.Encoding.UTF8)); Response.AddHeader("Content-Length", fileSize.ToString()); - Response.TransmitFile(newUrl, 0, fileSize); + Response.TransmitFile(pdfUrl, 0, fileSize); Response.Flush(); Response.Close(); File.Delete(newUrl); + File.Delete(pdfUrl); } catch (Exception ex) { diff --git a/SGGL/Model/Model.cs b/SGGL/Model/Model.cs index 4577002e..e4459f04 100644 --- a/SGGL/Model/Model.cs +++ b/SGGL/Model/Model.cs @@ -6696,6 +6696,14 @@ namespace Model } } + public System.Data.Linq.Table View_WBS + { + get + { + return this.GetTable(); + } + } + public System.Data.Linq.Table View_WBS_ControlItemAndCycle { get @@ -287728,6 +287736,123 @@ namespace Model } } + [global::System.Data.Linq.Mapping.TableAttribute(Name="dbo.View_WBS")] + public partial class View_WBS + { + + private string _Id; + + private string _SupId; + + private string _Code; + + private string _Name; + + private string _WBSType; + + private string _ProjectId; + + public View_WBS() + { + } + + [global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_Id", DbType="NVarChar(50) NOT NULL", CanBeNull=false)] + public string Id + { + get + { + return this._Id; + } + set + { + if ((this._Id != value)) + { + this._Id = value; + } + } + } + + [global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_SupId", DbType="NVarChar(50)")] + public string SupId + { + get + { + return this._SupId; + } + set + { + if ((this._SupId != value)) + { + this._SupId = value; + } + } + } + + [global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_Code", DbType="NVarChar(30)")] + public string Code + { + get + { + return this._Code; + } + set + { + if ((this._Code != value)) + { + this._Code = value; + } + } + } + + [global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_Name", DbType="NVarChar(50)")] + public string Name + { + get + { + return this._Name; + } + set + { + if ((this._Name != value)) + { + this._Name = value; + } + } + } + + [global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_WBSType", DbType="VarChar(11) NOT NULL", CanBeNull=false)] + public string WBSType + { + get + { + return this._WBSType; + } + set + { + if ((this._WBSType != value)) + { + this._WBSType = value; + } + } + } + + [global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_ProjectId", DbType="NVarChar(50)")] + public string ProjectId + { + get + { + return this._ProjectId; + } + set + { + if ((this._ProjectId != value)) + { + this._ProjectId = value; + } + } + } + } + [global::System.Data.Linq.Mapping.TableAttribute(Name="dbo.View_WBS_ControlItemAndCycle")] public partial class View_WBS_ControlItemAndCycle { @@ -291336,6 +291461,14 @@ namespace Model private string _MainItemAndDesignProfessionalIds; + private System.Nullable _PlanStartDate; + + private System.Nullable _PlanEndDate; + + private System.Nullable _RealStartDate; + + private System.Nullable _RealEndDate; + private EntitySet _Accident_AccidentPersonRecord; private EntitySet _Accident_AccidentReport; @@ -291414,6 +291547,14 @@ namespace Model partial void OnCostsChanged(); partial void OnMainItemAndDesignProfessionalIdsChanging(string value); partial void OnMainItemAndDesignProfessionalIdsChanged(); + partial void OnPlanStartDateChanging(System.Nullable value); + partial void OnPlanStartDateChanged(); + partial void OnPlanEndDateChanging(System.Nullable value); + partial void OnPlanEndDateChanged(); + partial void OnRealStartDateChanging(System.Nullable value); + partial void OnRealStartDateChanged(); + partial void OnRealEndDateChanging(System.Nullable value); + partial void OnRealEndDateChanged(); #endregion public WBS_UnitWork() @@ -291717,6 +291858,86 @@ namespace Model } } + [global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_PlanStartDate", DbType="DateTime")] + public System.Nullable PlanStartDate + { + get + { + return this._PlanStartDate; + } + set + { + if ((this._PlanStartDate != value)) + { + this.OnPlanStartDateChanging(value); + this.SendPropertyChanging(); + this._PlanStartDate = value; + this.SendPropertyChanged("PlanStartDate"); + this.OnPlanStartDateChanged(); + } + } + } + + [global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_PlanEndDate", DbType="DateTime")] + public System.Nullable PlanEndDate + { + get + { + return this._PlanEndDate; + } + set + { + if ((this._PlanEndDate != value)) + { + this.OnPlanEndDateChanging(value); + this.SendPropertyChanging(); + this._PlanEndDate = value; + this.SendPropertyChanged("PlanEndDate"); + this.OnPlanEndDateChanged(); + } + } + } + + [global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_RealStartDate", DbType="DateTime")] + public System.Nullable RealStartDate + { + get + { + return this._RealStartDate; + } + set + { + if ((this._RealStartDate != value)) + { + this.OnRealStartDateChanging(value); + this.SendPropertyChanging(); + this._RealStartDate = value; + this.SendPropertyChanged("RealStartDate"); + this.OnRealStartDateChanged(); + } + } + } + + [global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_RealEndDate", DbType="DateTime")] + public System.Nullable RealEndDate + { + get + { + return this._RealEndDate; + } + set + { + if ((this._RealEndDate != value)) + { + this.OnRealEndDateChanging(value); + this.SendPropertyChanging(); + this._RealEndDate = value; + this.SendPropertyChanged("RealEndDate"); + this.OnRealEndDateChanged(); + } + } + } + [global::System.Data.Linq.Mapping.AssociationAttribute(Name="FK_Accident_AccidentPersonRecord_ProjectData_WorkArea", Storage="_Accident_AccidentPersonRecord", ThisKey="UnitWorkId", OtherKey="WorkAreaId", DeleteRule="NO ACTION")] public EntitySet Accident_AccidentPersonRecord { @@ -292407,6 +292628,24 @@ namespace Model private string _SubItemType; + private string _PreJobId; + + private System.Nullable _PlanProjectQuantity; + + private System.Nullable _RealProjectQuantity; + + private System.Nullable _PlanStartDate; + + private System.Nullable _PlanEndDate; + + private System.Nullable _RealStartDate; + + private System.Nullable _RealEndDate; + + private string _Unit; + + private System.Nullable _IsMileStone; + private EntitySet _WBS_ControlItemAndCycle; private EntityRef _WBS_UnitWork; @@ -292451,6 +292690,24 @@ namespace Model partial void OnCostsChanged(); partial void OnSubItemTypeChanging(string value); partial void OnSubItemTypeChanged(); + partial void OnPreJobIdChanging(string value); + partial void OnPreJobIdChanged(); + partial void OnPlanProjectQuantityChanging(System.Nullable value); + partial void OnPlanProjectQuantityChanged(); + partial void OnRealProjectQuantityChanging(System.Nullable value); + partial void OnRealProjectQuantityChanged(); + partial void OnPlanStartDateChanging(System.Nullable value); + partial void OnPlanStartDateChanged(); + partial void OnPlanEndDateChanging(System.Nullable value); + partial void OnPlanEndDateChanged(); + partial void OnRealStartDateChanging(System.Nullable value); + partial void OnRealStartDateChanged(); + partial void OnRealEndDateChanging(System.Nullable value); + partial void OnRealEndDateChanged(); + partial void OnUnitChanging(string value); + partial void OnUnitChanged(); + partial void OnIsMileStoneChanging(System.Nullable value); + partial void OnIsMileStoneChanged(); #endregion public WBS_WorkPackage() @@ -292824,6 +293081,186 @@ namespace Model } } + [global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_PreJobId", DbType="NVarChar(50)")] + public string PreJobId + { + get + { + return this._PreJobId; + } + set + { + if ((this._PreJobId != value)) + { + this.OnPreJobIdChanging(value); + this.SendPropertyChanging(); + this._PreJobId = value; + this.SendPropertyChanged("PreJobId"); + this.OnPreJobIdChanged(); + } + } + } + + [global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_PlanProjectQuantity", DbType="Decimal(18,2)")] + public System.Nullable PlanProjectQuantity + { + get + { + return this._PlanProjectQuantity; + } + set + { + if ((this._PlanProjectQuantity != value)) + { + this.OnPlanProjectQuantityChanging(value); + this.SendPropertyChanging(); + this._PlanProjectQuantity = value; + this.SendPropertyChanged("PlanProjectQuantity"); + this.OnPlanProjectQuantityChanged(); + } + } + } + + [global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_RealProjectQuantity", DbType="Decimal(18,2)")] + public System.Nullable RealProjectQuantity + { + get + { + return this._RealProjectQuantity; + } + set + { + if ((this._RealProjectQuantity != value)) + { + this.OnRealProjectQuantityChanging(value); + this.SendPropertyChanging(); + this._RealProjectQuantity = value; + this.SendPropertyChanged("RealProjectQuantity"); + this.OnRealProjectQuantityChanged(); + } + } + } + + [global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_PlanStartDate", DbType="DateTime")] + public System.Nullable PlanStartDate + { + get + { + return this._PlanStartDate; + } + set + { + if ((this._PlanStartDate != value)) + { + this.OnPlanStartDateChanging(value); + this.SendPropertyChanging(); + this._PlanStartDate = value; + this.SendPropertyChanged("PlanStartDate"); + this.OnPlanStartDateChanged(); + } + } + } + + [global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_PlanEndDate", DbType="DateTime")] + public System.Nullable PlanEndDate + { + get + { + return this._PlanEndDate; + } + set + { + if ((this._PlanEndDate != value)) + { + this.OnPlanEndDateChanging(value); + this.SendPropertyChanging(); + this._PlanEndDate = value; + this.SendPropertyChanged("PlanEndDate"); + this.OnPlanEndDateChanged(); + } + } + } + + [global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_RealStartDate", DbType="DateTime")] + public System.Nullable RealStartDate + { + get + { + return this._RealStartDate; + } + set + { + if ((this._RealStartDate != value)) + { + this.OnRealStartDateChanging(value); + this.SendPropertyChanging(); + this._RealStartDate = value; + this.SendPropertyChanged("RealStartDate"); + this.OnRealStartDateChanged(); + } + } + } + + [global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_RealEndDate", DbType="DateTime")] + public System.Nullable RealEndDate + { + get + { + return this._RealEndDate; + } + set + { + if ((this._RealEndDate != value)) + { + this.OnRealEndDateChanging(value); + this.SendPropertyChanging(); + this._RealEndDate = value; + this.SendPropertyChanged("RealEndDate"); + this.OnRealEndDateChanged(); + } + } + } + + [global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_Unit", DbType="NVarChar(50)")] + public string Unit + { + get + { + return this._Unit; + } + set + { + if ((this._Unit != value)) + { + this.OnUnitChanging(value); + this.SendPropertyChanging(); + this._Unit = value; + this.SendPropertyChanged("Unit"); + this.OnUnitChanged(); + } + } + } + + [global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_IsMileStone", DbType="Bit")] + public System.Nullable IsMileStone + { + get + { + return this._IsMileStone; + } + set + { + if ((this._IsMileStone != value)) + { + this.OnIsMileStoneChanging(value); + this.SendPropertyChanging(); + this._IsMileStone = value; + this.SendPropertyChanged("IsMileStone"); + this.OnIsMileStoneChanged(); + } + } + } + [global::System.Data.Linq.Mapping.AssociationAttribute(Name="FK_WBS_ControlItemAndCycle_WBS_ControlItemAndCycle", Storage="_WBS_ControlItemAndCycle", ThisKey="WorkPackageId", OtherKey="WorkPackageId", DeleteRule="NO ACTION")] public EntitySet WBS_ControlItemAndCycle {