diff --git a/DataBase/版本日志/SUBQHSE_V2024-10-31-xiaj.sql b/DataBase/版本日志/SUBQHSE_V2024-10-31-xiaj.sql new file mode 100644 index 00000000..309d41e4 --- /dev/null +++ b/DataBase/版本日志/SUBQHSE_V2024-10-31-xiaj.sql @@ -0,0 +1,48 @@ + + +--1ĿУɾӢģ +update Sys_Menu set MenuName='β' where MenuId='016903B1-3B86-4CF5-AFF8-FF8BE389BEE5'; +update Sys_Menu set MenuName='ǹϵͳ嵥' where MenuId='022428DC-FC99-4916-B8AF-6A9DC885DFAF'; +update Sys_Menu set MenuName='ϵͳ嵥' where MenuId='197F9A9A-480C-4CC3-B6B7-3A7D382DC3EB'; +update Sys_Menu set MenuName='βͳƱ' where MenuId='2352E44F-BE12-4012-B43F-AAF649EDAC32'; +update Sys_Menu set MenuName='ƽ״̬ܱ' where MenuId='25C13642-AE77-42E2-B0FB-32663B68F93F'; +update Sys_Menu set MenuName='' where MenuId='296E75D2-192A-4D1F-8471-DD34263F8691'; +update Sys_Menu set MenuName='βȸٱ' where MenuId='549DD0B6-05CB-4C75-B8F5-9AADDEDF399F'; +update Sys_Menu set MenuName='' where MenuId='58FFBD80-ACB9-4830-A18A-E025D9600D94'; +update Sys_Menu set MenuName='ƽͳͼ' where MenuId='60838E30-4A46-4878-B299-C234900B10B7'; +update Sys_Menu set MenuName='豸' where MenuId='7E2FB5F9-FB99-4455-B68F-460F1F9A2676'; +update Sys_Menu set MenuName='DZ' where MenuId='88F51059-55B4-4CD5-A38C-36404E5029F6'; +update Sys_Menu set MenuName='//ṹ' where MenuId='95C39F86-C060-452E-BA37-D891C466A39B'; +update Sys_Menu set MenuName='豸' where MenuId='982F746C-084C-445C-9AE8-8C37BDFE7994'; +update Sys_Menu set MenuName='β' where MenuId='CB76462E-9444-4946-B787-ECB33C21E6D0'; +update Sys_Menu set MenuName='ܵ' where MenuId='D94C1BA4-9DFD-4514-AE12-6F886C5D8C9B'; +update Sys_Menu set MenuName='ƽͳƱ' where MenuId='E305689E-5D84-4C1A-BF67-85FA2D828115'; +go +--2ɾĿеĵعܺ2Ŀز˵ +update Sys_Menu set MenuName='',IsUsed=0 where MenuId='794E64E2-FDD2-4B7D-8408-F7FB06F9C92A'; +update Sys_Menu set MenuName='ع',IsUsed=0 where MenuId='95295BF7-FB51-480D-9902-6ADA4E8427FC'; +go +--3¹ܵı +--жֶβ +IF NOT EXISTS(select * from sys.columns where name='TotalFactor' and [object_id]=object_id(N'Transfer_Piping')) +BEGIN + --ܴ + ALTER TABLE Transfer_Piping ADD TotalFactor nvarchar(50) NULL; + --ɴ + ALTER TABLE Transfer_Piping ADD CompleteFactor nvarchar(50) NULL; + --ɱ + ALTER TABLE Transfer_Piping ADD CompleteProportion nvarchar(50) NULL; + --ѹ + ALTER TABLE Transfer_Piping ADD PressureTestCompleted nvarchar(50) NULL; + --ϴɨ + ALTER TABLE Transfer_Piping ADD RinseAndBlowClean nvarchar(50) NULL; + --λ + ALTER TABLE Transfer_Piping ADD Reduction nvarchar(50) NULL; + -- + ALTER TABLE Transfer_Piping ADD ElectricHeatTracing nvarchar(50) NULL; + --/ + ALTER TABLE Transfer_Piping ADD Insulation nvarchar(50) NULL; +END +go + + diff --git a/SGGL/BLL/Common/AttachFileService.cs b/SGGL/BLL/Common/AttachFileService.cs index 9a50abef..d4a5d72d 100644 --- a/SGGL/BLL/Common/AttachFileService.cs +++ b/SGGL/BLL/Common/AttachFileService.cs @@ -501,6 +501,9 @@ namespace BLL list.Add(".txt"); list.Add(".xlsx"); list.Add(".xls"); + list.Add(".png"); + list.Add(".jpg"); + list.Add(".jpeg"); foreach (var item in list) { if (item == FiletExtension) diff --git a/SGGL/FineUIPro.Web/File/Excel/DataIn/Instrumentation导入模板.xls b/SGGL/FineUIPro.Web/File/Excel/DataIn/Instrumentation导入模板.xls index ffd0af3e..b02bca19 100644 Binary files a/SGGL/FineUIPro.Web/File/Excel/DataIn/Instrumentation导入模板.xls and b/SGGL/FineUIPro.Web/File/Excel/DataIn/Instrumentation导入模板.xls differ diff --git a/SGGL/FineUIPro.Web/File/Excel/DataIn/Piping导入模板.xls b/SGGL/FineUIPro.Web/File/Excel/DataIn/Piping导入模板.xls index 5d30839f..48132ef0 100644 Binary files a/SGGL/FineUIPro.Web/File/Excel/DataIn/Piping导入模板.xls and b/SGGL/FineUIPro.Web/File/Excel/DataIn/Piping导入模板.xls differ diff --git a/SGGL/FineUIPro.Web/Transfer/Chart/PunchlistFromChartNew.aspx b/SGGL/FineUIPro.Web/Transfer/Chart/PunchlistFromChartNew.aspx index f85d259d..3539a569 100644 --- a/SGGL/FineUIPro.Web/Transfer/Chart/PunchlistFromChartNew.aspx +++ b/SGGL/FineUIPro.Web/Transfer/Chart/PunchlistFromChartNew.aspx @@ -94,8 +94,6 @@ - - @@ -233,6 +231,7 @@ + @@ -244,6 +243,7 @@ + @@ -253,6 +253,7 @@ + @@ -262,6 +263,7 @@ + @@ -271,6 +273,7 @@ + diff --git a/SGGL/FineUIPro.Web/Transfer/Chart/PunchlistFromChartNew.aspx.cs b/SGGL/FineUIPro.Web/Transfer/Chart/PunchlistFromChartNew.aspx.cs index 52de22e5..80e69fda 100644 --- a/SGGL/FineUIPro.Web/Transfer/Chart/PunchlistFromChartNew.aspx.cs +++ b/SGGL/FineUIPro.Web/Transfer/Chart/PunchlistFromChartNew.aspx.cs @@ -79,7 +79,7 @@ namespace FineUIPro.Web.Transfer.Chart { #region 加载尾项完成统计表(30天以内) var nowDate = Convert.ToDateTime(DateTime.Now.ToString("yyyy-MM-dd")); - for (var i = nowDate.AddDays(-30); i <= nowDate; i=i.AddDays(1)) + for (var i = nowDate.AddDays(-30); i <= nowDate; i = i.AddDays(1)) { //i是日期 @@ -87,7 +87,7 @@ namespace FineUIPro.Web.Transfer.Chart DateTime startTime = Convert.ToDateTime(i.ToString("yyyy-MM-dd") + " 00:00:00"); DateTime endTime = Convert.ToDateTime(i.ToString("yyyy-MM-dd") + " 23:59:59"); //当天计划完成量 - var dtjhwcl= forms.Where(x => x.Required_Date >= startTime && x.Required_Date <= endTime).Count(); + var dtjhwcl = forms.Where(x => x.Required_Date >= startTime && x.Required_Date <= endTime).Count(); wcl1 += "'" + dtjhwcl + "',"; //当天实际完成量 var dtsjwcl = forms.Where(x => x.Actual_Date >= startTime && x.Actual_Date <= endTime).Count(); @@ -96,12 +96,12 @@ namespace FineUIPro.Web.Transfer.Chart var ljjhwcl = forms.Where(x => x.Required_Date <= endTime).Count(); wcl3 += "'" + ljjhwcl + "',"; //累计实际完成量 - var ljsjwcl= forms.Where(x => x.Actual_Date <= endTime).Count(); + var ljsjwcl = forms.Where(x => x.Actual_Date <= endTime).Count(); wcl4 += "'" + ljsjwcl + "',"; - AllxDate += "'"+ d + "',"; + AllxDate += "'" + d + "',"; } - if (AllxDate.Length>0) + if (AllxDate.Length > 0) { AllxDate = AllxDate.Substring(0, AllxDate.Length - 1); wcl1 = wcl1.Substring(0, wcl1.Length - 1); @@ -403,7 +403,7 @@ namespace FineUIPro.Web.Transfer.Chart cat_C_Count += Convert.ToInt32(row["Cat_C_Count"]); cat_D_Count += Convert.ToInt32(row["Cat_D_Count"]); // - Cat_A_Countf+= Convert.ToInt32(row["Cat_A_Countf"]); + Cat_A_Countf += Convert.ToInt32(row["Cat_A_Countf"]); Cat_A_CountWUH += Convert.ToInt32(row["Cat_A_CountWUH"]); Cat_A_CountBASF += Convert.ToInt32(row["Cat_A_CountBASF"]); @@ -604,7 +604,7 @@ namespace FineUIPro.Web.Transfer.Chart protected void TabStrip1_TabIndexChanged(object sender, EventArgs e) { - if (TabStrip1.ActiveTabIndex ==0) + if (TabStrip1.ActiveTabIndex == 0) { ddlSystemNo.Hidden = true; ddlDateType.Hidden = true; @@ -636,7 +636,8 @@ namespace FineUIPro.Web.Transfer.Chart BtnAnalyse.Hidden = false; BindGrid3(); } - else { + else + { this.AnalyseData(); ddlSystemNo.Hidden = false; ddlDateType.Hidden = false; @@ -667,14 +668,14 @@ namespace FineUIPro.Web.Transfer.Chart strSql.AppendLine(@" select System_No, cast(0 as decimal(18, 2)) Cat_A_Count, - cast(0 as decimal(18, 2)) Cat_A_Countf, cast(0 as decimal(18, 2)) Cat_A_CountWUH, cast(0 as decimal(18, 2)) Cat_A_CountBASF, + cast(0 as decimal(18, 2)) Cat_A_Countf,cast(0 as decimal(18, 2)) Cat_A_CountPercent, cast(0 as decimal(18, 2)) Cat_A_CountWUH, cast(0 as decimal(18, 2)) Cat_A_CountBASF, cast(0 as decimal(18, 2)) Cat_B_Count, - cast(0 as decimal(18, 2)) Cat_B_Countf, cast(0 as decimal(18, 2)) Cat_B_CountWUH, cast(0 as decimal(18, 2)) Cat_B_CountBASF, + cast(0 as decimal(18, 2)) Cat_B_Countf,cast(0 as decimal(18, 2)) Cat_B_CountPercent, cast(0 as decimal(18, 2)) Cat_B_CountWUH, cast(0 as decimal(18, 2)) Cat_B_CountBASF, cast(0 as decimal(18, 2)) Cat_C_Count, - cast(0 as decimal(18, 2)) Cat_C_Countf, cast(0 as decimal(18, 2)) Cat_C_CountWUH, cast(0 as decimal(18, 2)) Cat_C_CountBASF, + cast(0 as decimal(18, 2)) Cat_C_Countf,cast(0 as decimal(18, 2)) Cat_C_CountPercent, cast(0 as decimal(18, 2)) Cat_C_CountWUH, cast(0 as decimal(18, 2)) Cat_C_CountBASF, cast(0 as decimal(18, 2)) Cat_D_Count, - cast(0 as decimal(18, 2)) Cat_D_Countf, cast(0 as decimal(18, 2)) Cat_D_CountWUH, cast(0 as decimal(18, 2)) Cat_D_CountBASF, - cast(0 as decimal(18, 2)) allCount, cast(0 as decimal(18, 2)) allfinshedCount, cast(0 as decimal(18, 2)) allWUH, cast(0 as decimal(18, 2)) allBASF + cast(0 as decimal(18, 2)) Cat_D_Countf,cast(0 as decimal(18, 2)) Cat_D_CountPercent, cast(0 as decimal(18, 2)) Cat_D_CountWUH, cast(0 as decimal(18, 2)) Cat_D_CountBASF, + cast(0 as decimal(18, 2)) allCount,cast(0 as decimal(18, 2)) allfinshedCount,cast(0 as decimal(18, 2)) allCountPercent,cast(0 as decimal(18, 2)) allWUH, cast(0 as decimal(18, 2)) allBASF INTO #PunchlistFromProgressTemp from #AllPunchlistFromProgressTemp Group by System_No; "); strSql.AppendLine(@" update a set @@ -710,7 +711,14 @@ namespace FineUIPro.Web.Transfer.Chart from #PunchlistFromProgressTemp a;"); - + strSql.AppendLine(@" update a set + a.Cat_A_CountPercent=(case ISNULL(a.Cat_A_Count,0) when 0 then 0 else CONVERT(DECIMAL(10,2),100*(ISNULL(a.Cat_A_Countf,0)*1.0/ISNULL(a.Cat_A_Count,0))) end ), + a.Cat_B_CountPercent=(case ISNULL(a.Cat_B_Count,0) when 0 then 0 else CONVERT(DECIMAL(10,2),100*(ISNULL(a.Cat_B_Countf,0)*1.0/ISNULL(a.Cat_B_Count,0))) end ), + a.Cat_C_CountPercent=(case ISNULL(a.Cat_C_Count,0) when 0 then 0 else CONVERT(DECIMAL(10,2),100*(ISNULL(a.Cat_C_Countf,0)*1.0/ISNULL(a.Cat_C_Count,0))) end ), + a.Cat_D_CountPercent=(case ISNULL(a.Cat_D_Count,0) when 0 then 0 else CONVERT(DECIMAL(10,2),100*(ISNULL(a.Cat_D_Countf,0)*1.0/ISNULL(a.Cat_D_Count,0))) end ), + a.allCountPercent=(case ISNULL(a.allCount,0) when 0 then 0 else CONVERT(DECIMAL(10,2),100*(ISNULL(a.allfinshedCount,0)*1.0/ISNULL(a.allCount,0))) end ) + from #PunchlistFromProgressTemp a; "); + strSql.AppendLine(" select * from #PunchlistFromProgressTemp "); List listStr = new List(); listStr.Add(new SqlParameter("@ProjectId", this.CurrUser.LoginProjectId)); @@ -734,13 +742,14 @@ namespace FineUIPro.Web.Transfer.Chart Cat_C_Countf = 0, Cat_C_CountWUH = 0, Cat_C_CountBASF = 0, Cat_D_Countf = 0, Cat_D_CountWUH = 0, Cat_D_CountBASF = 0, allCount = 0, allfinshedCount = 0, allWUH = 0, allBASF = 0; + foreach (DataRow row in tb.Rows) { cat_A_Count += Convert.ToInt32(row["Cat_A_Count"]); cat_B_Count += Convert.ToInt32(row["Cat_B_Count"]); cat_C_Count += Convert.ToInt32(row["Cat_C_Count"]); cat_D_Count += Convert.ToInt32(row["Cat_D_Count"]); - // + Cat_A_Countf += Convert.ToInt32(row["Cat_A_Countf"]); Cat_A_CountWUH += Convert.ToInt32(row["Cat_A_CountWUH"]); Cat_A_CountBASF += Convert.ToInt32(row["Cat_A_CountBASF"]); @@ -763,6 +772,11 @@ namespace FineUIPro.Web.Transfer.Chart allBASF += Convert.ToInt32(row["allBASF"]); } + var Cat_A_CountPercent = 100 * ((float)Cat_A_Countf / (float)cat_A_Count); + var Cat_B_CountPercent = 100 * ((float)Cat_B_Countf / (float)cat_B_Count); + var Cat_C_CountPercent = 100 * ((float)Cat_C_Countf / (float)cat_C_Count); + var Cat_D_CountPercent = 100 * ((float)Cat_D_Countf / (float)cat_D_Count); + var allCountPercent = 100 * ((float)allfinshedCount / (float)allCount); JObject summary = new JObject(); summary.Add("System_No", "合计"); @@ -772,27 +786,31 @@ namespace FineUIPro.Web.Transfer.Chart summary.Add("Cat_D_Count", cat_D_Count.ToString()); summary.Add("Cat_A_Countf", Cat_A_Countf.ToString()); + summary.Add("Cat_A_CountPercent", Cat_A_CountPercent.ToString("F2")); summary.Add("Cat_A_CountWUH", Cat_A_CountWUH.ToString()); summary.Add("Cat_A_CountBASF", Cat_A_CountBASF.ToString()); summary.Add("Cat_B_Countf", Cat_B_Countf.ToString()); + summary.Add("Cat_B_CountPercent", Cat_B_CountPercent.ToString("F2")); summary.Add("Cat_B_CountWUH", Cat_B_CountWUH.ToString()); summary.Add("Cat_B_CountBASF", Cat_B_CountBASF.ToString()); summary.Add("Cat_C_Countf", Cat_C_Countf.ToString()); + summary.Add("Cat_C_CountPercent", Cat_C_CountPercent.ToString("F2")); summary.Add("Cat_C_CountWUH", Cat_C_CountWUH.ToString()); summary.Add("Cat_C_CountBASF", Cat_C_CountBASF.ToString()); summary.Add("Cat_D_Countf", Cat_D_Countf.ToString()); + summary.Add("Cat_D_CountPercent", Cat_D_CountPercent.ToString("F2")); summary.Add("Cat_D_CountWUH", Cat_D_CountWUH.ToString()); summary.Add("Cat_D_CountBASF", Cat_D_CountBASF.ToString()); summary.Add("allCount", allCount.ToString()); summary.Add("allfinshedCount", allfinshedCount.ToString()); + summary.Add("allCountPercent", allCountPercent.ToString("F2")); summary.Add("allWUH", allWUH.ToString()); summary.Add("allBASF", allBASF.ToString()); - Grid3.SummaryData = summary; } diff --git a/SGGL/FineUIPro.Web/Transfer/Chart/Systemstatus.aspx b/SGGL/FineUIPro.Web/Transfer/Chart/Systemstatus.aspx index 9fdbb1db..75552ffc 100644 --- a/SGGL/FineUIPro.Web/Transfer/Chart/Systemstatus.aspx +++ b/SGGL/FineUIPro.Web/Transfer/Chart/Systemstatus.aspx @@ -15,7 +15,7 @@ @@ -28,21 +28,21 @@ - + - - <%-- --%> @@ -53,17 +53,30 @@ + FieldType="Date" Renderer="Date" RendererArgument="yyyy-MM-dd" EnableLock="true" Locked="true" /> + FieldType="Date" Renderer="Date" RendererArgument="yyyy-MM-dd" EnableLock="true" Locked="true" /> + FieldType="Date" Renderer="Date" RendererArgument="yyyy-MM-dd" EnableLock="true" Locked="true" /> + + + + - + + + + + + + @@ -75,6 +88,19 @@ HeaderText="完成率(%)" TextAlign="Center" /> + + + + + + + + + + @@ -115,7 +141,7 @@ - + @@ -154,7 +180,7 @@ - + <%-- @@ -165,23 +191,31 @@ - + --%> - + + + - + + + FieldType="String" /> - - + <%-- @@ -192,7 +226,7 @@ - + --%> - + <%-- @@ -211,7 +245,7 @@ - + --%> - + FieldType="String" /> - + FieldType="String" /> - + FieldType="String" /> - + FieldType="String" /> - + FieldType="String" /> + FieldType="String" /> - + @@ -261,11 +295,11 @@ - - + diff --git a/SGGL/FineUIPro.Web/Transfer/Chart/Systemstatus.aspx.cs b/SGGL/FineUIPro.Web/Transfer/Chart/Systemstatus.aspx.cs index 489cb0c2..c4a4d4a0 100644 --- a/SGGL/FineUIPro.Web/Transfer/Chart/Systemstatus.aspx.cs +++ b/SGGL/FineUIPro.Web/Transfer/Chart/Systemstatus.aspx.cs @@ -47,10 +47,15 @@ namespace FineUIPro.Web.Transfer.Chart { string strSql = @" select f.SystemNo,f.ProjectId, + pp.TotalFactor,pp.CompleteFactor,pp.CompleteProportion,pp.ElectricHeatTracing,pp.Insulation, ISNULL(tpi.PipingCount,0) PipingCount,ISNULL(tpi1.PipingScount,0) PipingScount, case ISNULL(tpi.PipingCount,0) when 0 then 0 else CONVERT(DECIMAL(10,2),100*(ISNULL(tpi1.PipingScount,0)*1.0/ISNULL(tpi.PipingCount,0))) end PipingPercent, + ISNULL(tpi.PipingCount,0) ReinstateCount,ISNULL(tpi2.ReinstateScount,0) ReinstateScount, + case ISNULL(tpi.PipingCount,0) + when 0 then 0 + else CONVERT(DECIMAL(10,2),100*(ISNULL(tpi2.ReinstateScount,0)*1.0/ISNULL(tpi.PipingCount,0))) end ReinstatePercent, ISNULL((TseCount+TreCount),0) as EqCount,ISNULL((TseSCount+TreSCount),0) as EqScount, case ISNULL((TseCount+TreCount),0) @@ -82,22 +87,17 @@ namespace FineUIPro.Web.Transfer.Chart when 0 then 0 else CONVERT(DECIMAL(10,2),100*(ISNULL(TtScount,0)*1.0/ISNULL(TtCount,0))) end TtPercent, - ISNULL(TpCount,0) TpCount,ISNULL(TpScount,0) TpScount, - - case ISNULL(TpCount,0) - when 0 then 0 - else CONVERT(DECIMAL(10,2),100*(ISNULL(TpScount,0)*1.0/ISNULL(TpCount,0))) end TpPercent, - ts.PlanPWD,PlanJWD,McPlan, SubmitPackage,ActualPWD,ActualJWD,ActualMC,Commissioning, - IaQian,TcccQ,SystemStatus,TurnoverDescription,ts.Remark, - ISNULL(pwdACount,0) pwdACount,ISNULL(pwdBCount,0) pwdBCount,ISNULL(pwdCCount,0) pwdCCount, - ISNULL(fwdACount,0) fwdACount,ISNULL(fwdBCount,0) fwdBCount,ISNULL(fwdCCount,0) fwdCCount + IaQian,TcccQ,SystemStatus,TurnoverDescription,ts.Remark + from( SELECT SystemNo,ProjectId FROM Transfer_LHCSystemList group by SystemNo,ProjectId ) f left join Transfer_SystemControl ts on f.ProjectId=ts.ProjectId and f.SystemNo=ts.SystemNo --piping + left join Transfer_Piping pp on f.ProjectId=pp.ProjectId and f.SystemNo=pp.SYSTEM + left join (select count(*)as PipingCount,ProjectId,SYSTEM from Transfer_Piping group by ProjectId,SYSTEM) tpi on f.ProjectId=tpi.ProjectId and f.SystemNo=tpi.SYSTEM @@ -105,6 +105,11 @@ namespace FineUIPro.Web.Transfer.Chart left join (select count(*)as PipingScount,ProjectId,SYSTEM from Transfer_Piping where FINALStatus='Completed' group by ProjectId,SYSTEM) tpi1 on f.ProjectId=tpi1.ProjectId and f.SystemNo=tpi1.SYSTEM + + left join (select count(*)as ReinstateScount,ProjectId,SYSTEM from Transfer_Piping where RinseAndBlowClean='Completed' and Reduction='Completed' + group by ProjectId,SYSTEM) + tpi2 on f.ProjectId=tpi2.ProjectId and f.SystemNo=tpi2.SYSTEM + --设备测试包 left join (select count(*)as TseCount,ProjectId,SYSTEM from Transfer_StaticEquipment group by ProjectId,SYSTEM) @@ -167,40 +172,169 @@ namespace FineUIPro.Web.Transfer.Chart group by ProjectId,SystemName) Tt1 on f.ProjectId=Tt1.ProjectId and f.SystemNo=Tt1.SystemName - --Transfer_Plumbing - left join (select count(*)as TpCount,ProjectId,SystemName from Transfer_Plumbing - group by ProjectId,SystemName) - tp on f.ProjectId=tp.ProjectId and f.SystemNo=tp.SystemName + where f.ProjectId = @ProjectId"; - left join (select count(*)as TpScount,ProjectId,SystemName from Transfer_Plumbing where FINAL_Status='Completed' - group by ProjectId,SystemName) - tp1 on f.ProjectId=tp1.ProjectId and f.SystemNo=tp1.SystemName + #region 调整前sql + + //string strSql = @" + // select f.SystemNo,f.ProjectId, + // ISNULL(tpi.PipingCount,0) PipingCount,ISNULL(tpi1.PipingScount,0) PipingScount, + // case ISNULL(tpi.PipingCount,0) + // when 0 then 0 + // else CONVERT(DECIMAL(10,2),100*(ISNULL(tpi1.PipingScount,0)*1.0/ISNULL(tpi.PipingCount,0))) end PipingPercent, + + // ISNULL((TseCount+TreCount),0) as EqCount,ISNULL((TseSCount+TreSCount),0) as EqScount, + // case ISNULL((TseCount+TreCount),0) + // when 0 then 0 + // else CONVERT(DECIMAL(10,2),100 *(ISNULL((TseSCount+TreSCount),0)*1.0/ISNULL((TseCount+TreCount),0))) end EqPercent, + + // ISNULL(TeCount,0) TeCount,ISNULL(TeScount,0) TeScount, + // case ISNULL(TeCount,0) + // when 0 then 0 + // else CONVERT(DECIMAL(10,2),100*(ISNULL(TeScount,0)*1.0/ISNULL(TeCount,0))) end TePercent, + + // ISNULL(TiCount,0) TiCount,ISNULL(TiScount,0) TiScount, + // case ISNULL(TiCount,0) + // when 0 then 0 + // else CONVERT(DECIMAL(10,2),100*(ISNULL(TiScount,0)*1.0/ISNULL(TiCount,0))) end TiPercent, + + // ISNULL(TcsCount,0) TcsCount,ISNULL(TcsScount,0) TcsScount, + // case ISNULL(TcsCount,0) + // when 0 then 0 + // else CONVERT(DECIMAL(10,2),100*(ISNULL(TcsScount,0)*1.0/ISNULL(TcsCount,0))) end TcsPercent, + + // ISNULL(TfCount,0) TfCount,ISNULL(TfScount,0) TfScount, + // case ISNULL(TfCount,0) + // when 0 then 0 + // else CONVERT(DECIMAL(10,2),100*(ISNULL(TfScount,0)*1.0/ISNULL(TfCount,0))) end TfPercent, + + // ISNULL(TtCount,0) TtCount,ISNULL(TtScount,0) TtScount, + // case ISNULL(TtCount,0) + // when 0 then 0 + // else CONVERT(DECIMAL(10,2),100*(ISNULL(TtScount,0)*1.0/ISNULL(TtCount,0))) end TtPercent, + + // ISNULL(TpCount,0) TpCount,ISNULL(TpScount,0) TpScount, + + // case ISNULL(TpCount,0) + // when 0 then 0 + // else CONVERT(DECIMAL(10,2),100*(ISNULL(TpScount,0)*1.0/ISNULL(TpCount,0))) end TpPercent, + + // ts.PlanPWD,PlanJWD,McPlan, + // SubmitPackage,ActualPWD,ActualJWD,ActualMC,Commissioning, + // IaQian,TcccQ,SystemStatus,TurnoverDescription,ts.Remark, + // ISNULL(pwdACount,0) pwdACount,ISNULL(pwdBCount,0) pwdBCount,ISNULL(pwdCCount,0) pwdCCount, + // ISNULL(fwdACount,0) fwdACount,ISNULL(fwdBCount,0) fwdBCount,ISNULL(fwdCCount,0) fwdCCount + // from( + // SELECT SystemNo,ProjectId FROM Transfer_LHCSystemList group by SystemNo,ProjectId + // ) f + // left join Transfer_SystemControl ts on f.ProjectId=ts.ProjectId and f.SystemNo=ts.SystemNo + // --piping + // left join (select count(*)as PipingCount,ProjectId,SYSTEM from Transfer_Piping + // group by ProjectId,SYSTEM) + // tpi on f.ProjectId=tpi.ProjectId and f.SystemNo=tpi.SYSTEM + + // left join (select count(*)as PipingScount,ProjectId,SYSTEM from Transfer_Piping where FINALStatus='Completed' + // group by ProjectId,SYSTEM) + // tpi1 on f.ProjectId=tpi1.ProjectId and f.SystemNo=tpi1.SYSTEM + // --设备测试包 + // left join (select count(*)as TseCount,ProjectId,SYSTEM from Transfer_StaticEquipment + // group by ProjectId,SYSTEM) + // tse on f.ProjectId=tse.ProjectId and f.SystemNo=tse.SYSTEM + + // left join (select count(*)as TseSCount,ProjectId,SYSTEM from Transfer_StaticEquipment where MechanicalFINALStatus='Completed' + // group by ProjectId,SYSTEM) + // tse1 on f.ProjectId=tse1.ProjectId and f.SystemNo=tse1.SYSTEM + // -- + // left join (select count(*)as TreCount,ProjectId,SYSTEM from Transfer_RotatingEquipment + // group by ProjectId,SYSTEM) + // tre on f.ProjectId=tre.ProjectId and f.SystemNo=tre.SYSTEM + + // left join (select count(*)as TreSCount,ProjectId,SYSTEM from Transfer_RotatingEquipment where MechanicalFINALStatus='Completed' + // group by ProjectId,SYSTEM) + // tre1 on f.ProjectId=tre1.ProjectId and f.SystemNo=tre1.SYSTEM + + // --Transfer_Electrical + // left join (select count(*)as TeCount,ProjectId,SystemName from Transfer_Electrical + // group by ProjectId,SystemName) + // te on f.ProjectId=te.ProjectId and f.SystemNo=te.SystemName + + // left join (select count(*)as TeScount,ProjectId,SystemName from Transfer_Electrical where FINAL_Status='Completed' + // group by ProjectId,SystemName) + // te1 on f.ProjectId=te1.ProjectId and f.SystemNo=te1.SystemName + + // --Transfer_Instrumentation + // left join (select count(*)as TiCount,ProjectId,SystemName from Transfer_Instrumentation + // group by ProjectId,SystemName) + // ti on f.ProjectId=ti.ProjectId and f.SystemNo=ti.SystemName + + // left join (select count(*)as TiScount,ProjectId,SystemName from Transfer_Instrumentation where FINAL_Status='Completed' + // group by ProjectId,SystemName) + // ti1 on f.ProjectId=ti1.ProjectId and f.SystemNo=ti1.SystemName + + // --Transfer_Civil_Structure + // left join (select count(*)as TcsCount,ProjectId,SystemName from Transfer_Civil_Structure + // group by ProjectId,SystemName) + // tcs on f.ProjectId=tcs.ProjectId and f.SystemNo=tcs.SystemName + + // left join (select count(*)as TcsScount,ProjectId,SystemName from Transfer_Civil_Structure where FINAL_Status='Completed' + // group by ProjectId,SystemName) + // tcs1 on f.ProjectId=tcs1.ProjectId and f.SystemNo=tcs1.SystemName + + // --Transfer_Firefighting + // left join (select count(*)as TfCount,ProjectId,SystemName from Transfer_Firefighting + // group by ProjectId,SystemName) + // tf on f.ProjectId=tf.ProjectId and f.SystemNo=tf.SystemName + + // left join (select count(*)as TfScount,ProjectId,SystemName from Transfer_Firefighting where FINAL_Status='Completed' + // group by ProjectId,SystemName) + // tf1 on f.ProjectId=tf1.ProjectId and f.SystemNo=tf1.SystemName + + // --Transfer_Telecom + // left join (select count(*)as TtCount,ProjectId,SystemName from Transfer_Telecom + // group by ProjectId,SystemName) + // Tt on f.ProjectId=Tt.ProjectId and f.SystemNo=Tt.SystemName + + // left join (select count(*)as TtScount,ProjectId,SystemName from Transfer_Telecom where FINAL_Status='Completed' + // group by ProjectId,SystemName) + // Tt1 on f.ProjectId=Tt1.ProjectId and f.SystemNo=Tt1.SystemName + + // --Transfer_Plumbing + // left join (select count(*)as TpCount,ProjectId,SystemName from Transfer_Plumbing + // group by ProjectId,SystemName) + // tp on f.ProjectId=tp.ProjectId and f.SystemNo=tp.SystemName + + // left join (select count(*)as TpScount,ProjectId,SystemName from Transfer_Plumbing where FINAL_Status='Completed' + // group by ProjectId,SystemName) + // tp1 on f.ProjectId=tp1.ProjectId and f.SystemNo=tp1.SystemName - left join (select count(*) as pwdACount,ProjectId,System_No from Transfer_PunchlistFrom where Status!='Completed' - and Punch_Type='PWD' and Cat='A' group by ProjectId,System_No) - tpA on f.ProjectId=tpA.ProjectId and f.SystemNo=tpA.System_No + // left join (select count(*) as pwdACount,ProjectId,System_No from Transfer_PunchlistFrom where Status!='Completed' + // and Punch_Type='PWD' and Cat='A' group by ProjectId,System_No) + // tpA on f.ProjectId=tpA.ProjectId and f.SystemNo=tpA.System_No - left join (select count(*) as pwdBCount,ProjectId,System_No from Transfer_PunchlistFrom where Status!='Completed' - and Punch_Type='PWD' and Cat='B' group by ProjectId,System_No) - tpB on f.ProjectId=tpB.ProjectId and f.SystemNo=tpB.System_No + // left join (select count(*) as pwdBCount,ProjectId,System_No from Transfer_PunchlistFrom where Status!='Completed' + // and Punch_Type='PWD' and Cat='B' group by ProjectId,System_No) + // tpB on f.ProjectId=tpB.ProjectId and f.SystemNo=tpB.System_No - left join (select count(*) as pwdCCount,ProjectId,System_No from Transfer_PunchlistFrom where Status!='Completed' - and Punch_Type='PWD' and Cat='C' group by ProjectId,System_No) - tpC on f.ProjectId=tpC.ProjectId and f.SystemNo=tpC.System_No + // left join (select count(*) as pwdCCount,ProjectId,System_No from Transfer_PunchlistFrom where Status!='Completed' + // and Punch_Type='PWD' and Cat='C' group by ProjectId,System_No) + // tpC on f.ProjectId=tpC.ProjectId and f.SystemNo=tpC.System_No - left join (select count(*) as fwdACount,ProjectId,System_No from Transfer_PunchlistFrom where Status!='Completed' - and Punch_Type='FWD' and Cat='A' group by ProjectId,System_No) - tpfA on f.ProjectId=tpfA.ProjectId and f.SystemNo=tpfA.System_No + // left join (select count(*) as fwdACount,ProjectId,System_No from Transfer_PunchlistFrom where Status!='Completed' + // and Punch_Type='FWD' and Cat='A' group by ProjectId,System_No) + // tpfA on f.ProjectId=tpfA.ProjectId and f.SystemNo=tpfA.System_No - left join (select count(*) as fwdBCount,ProjectId,System_No from Transfer_PunchlistFrom where Status!='Completed' - and Punch_Type='FWD' and Cat='B' group by ProjectId,System_No) - tpfB on f.ProjectId=tpfB.ProjectId and f.SystemNo=tpfB.System_No + // left join (select count(*) as fwdBCount,ProjectId,System_No from Transfer_PunchlistFrom where Status!='Completed' + // and Punch_Type='FWD' and Cat='B' group by ProjectId,System_No) + // tpfB on f.ProjectId=tpfB.ProjectId and f.SystemNo=tpfB.System_No - left join (select count(*) as fwdCCount,ProjectId,System_No from Transfer_PunchlistFrom where Status!='Completed' - and Punch_Type='FWD' and Cat='C' group by ProjectId,System_No) - tpfC on f.ProjectId=tpfC.ProjectId and f.SystemNo=tpfC.System_No + // left join (select count(*) as fwdCCount,ProjectId,System_No from Transfer_PunchlistFrom where Status!='Completed' + // and Punch_Type='FWD' and Cat='C' group by ProjectId,System_No) + // tpfC on f.ProjectId=tpfC.ProjectId and f.SystemNo=tpfC.System_No + + // where f.ProjectId = @ProjectId"; + + #endregion - where f.ProjectId = @ProjectId"; List listStr = new List(); listStr.Add(new SqlParameter("@ProjectId", this.CurrUser.LoginProjectId)); diff --git a/SGGL/FineUIPro.Web/Transfer/Instrumentation.aspx b/SGGL/FineUIPro.Web/Transfer/Instrumentation.aspx index 652aac34..a406cb7d 100644 --- a/SGGL/FineUIPro.Web/Transfer/Instrumentation.aspx +++ b/SGGL/FineUIPro.Web/Transfer/Instrumentation.aspx @@ -76,9 +76,9 @@ - - + --%> @@ -102,7 +102,7 @@ - + diff --git a/SGGL/FineUIPro.Web/Transfer/InstrumentationDataIn.aspx.cs b/SGGL/FineUIPro.Web/Transfer/InstrumentationDataIn.aspx.cs index 670c27aa..5a8f1225 100644 --- a/SGGL/FineUIPro.Web/Transfer/InstrumentationDataIn.aspx.cs +++ b/SGGL/FineUIPro.Web/Transfer/InstrumentationDataIn.aspx.cs @@ -327,12 +327,19 @@ namespace FineUIPro.Web.Transfer model.Subsystem = pds.Rows[i][2 + 1].ToString().Trim(); model.Test_Package = pds.Rows[i][3 + 1].ToString().Trim(); - var obj0 = model.Calibration = pds.Rows[i][5].ToString().Trim(); - var obj1 = model.InstallationCalibration = pds.Rows[i][6].ToString().Trim(); - var obj2 = model.PipingPressuretest = pds.Rows[i][7].ToString().Trim(); - var obj3 = model.PipingLeak = pds.Rows[i][8].ToString().Trim(); - var obj4 = model.PipingBlowing = pds.Rows[i][9].ToString().Trim(); - var obj5 = model.Looptest = pds.Rows[i][10].ToString().Trim(); + //var obj0 = model.Calibration = pds.Rows[i][5].ToString().Trim(); + //var obj1 = model.InstallationCalibration = pds.Rows[i][6].ToString().Trim(); + //var obj2 = model.PipingPressuretest = pds.Rows[i][7].ToString().Trim(); + //var obj3 = model.PipingLeak = pds.Rows[i][8].ToString().Trim(); + //var obj4 = model.PipingBlowing = pds.Rows[i][9].ToString().Trim(); + //var obj5 = model.Looptest = pds.Rows[i][10].ToString().Trim(); + + var obj1 = model.InstallationCalibration = pds.Rows[i][5].ToString().Trim(); + var obj2 = model.PipingPressuretest = pds.Rows[i][6].ToString().Trim(); + var obj3 = model.PipingLeak = pds.Rows[i][7].ToString().Trim(); + var obj4 = model.PipingBlowing = pds.Rows[i][8].ToString().Trim(); + var obj5 = model.Looptest = pds.Rows[i][9].ToString().Trim(); + #region 判断状态 var listObj = new List(); listObj.Add(obj1); @@ -340,9 +347,9 @@ namespace FineUIPro.Web.Transfer listObj.Add(obj3); listObj.Add(obj4); listObj.Add(obj5); - listObj.Add(obj0); + //listObj.Add(obj0); //全是NA或Completed 状态是Completed - if (listObj.Where(x => x == "NA" || x == "Completed").ToList().Count == 6) + if (listObj.Where(x => x == "NA" || x == "Completed").ToList().Count == 5) { model.FINAL_Status = "Completed"; list.Add(model); @@ -351,7 +358,7 @@ namespace FineUIPro.Web.Transfer //如果全是Not Start 就是 Not Start - if (listObj.Where(x => x == "Not Start").ToList().Count == 6) + if (listObj.Where(x => x == "Not Start").ToList().Count == 5) { model.FINAL_Status = "Not Start"; list.Add(model); diff --git a/SGGL/FineUIPro.Web/Transfer/InstrumentationEdit.aspx b/SGGL/FineUIPro.Web/Transfer/InstrumentationEdit.aspx index 96108c87..ee95e0a5 100644 --- a/SGGL/FineUIPro.Web/Transfer/InstrumentationEdit.aspx +++ b/SGGL/FineUIPro.Web/Transfer/InstrumentationEdit.aspx @@ -50,12 +50,12 @@ - + <%-- - + --%> diff --git a/SGGL/FineUIPro.Web/Transfer/InstrumentationEdit.aspx.cs b/SGGL/FineUIPro.Web/Transfer/InstrumentationEdit.aspx.cs index f7c1eed8..80abe14c 100644 --- a/SGGL/FineUIPro.Web/Transfer/InstrumentationEdit.aspx.cs +++ b/SGGL/FineUIPro.Web/Transfer/InstrumentationEdit.aspx.cs @@ -60,7 +60,7 @@ namespace FineUIPro.Web.Transfer ddlPipingLeak.SelectedValue = model.PipingLeak; ddlPipingBlowing.SelectedValue = model.PipingBlowing; ddlLooptest.SelectedValue = model.Looptest; - ddlCalibration.SelectedValue = model.Calibration; + //ddlCalibration.SelectedValue = model.Calibration; txtDescriptions.Text = model.Descriptions; } } @@ -81,7 +81,7 @@ namespace FineUIPro.Web.Transfer PipingLeak = ddlPipingLeak.SelectedValue, PipingBlowing = ddlPipingBlowing.SelectedValue, Looptest = ddlLooptest.SelectedValue, - Calibration= ddlCalibration.SelectedValue, + //Calibration= ddlCalibration.SelectedValue, Descriptions = txtDescriptions.Text }; @@ -126,7 +126,7 @@ namespace FineUIPro.Web.Transfer newModel.PipingLeak = ddlPipingLeak.SelectedValue; newModel.PipingBlowing = ddlPipingBlowing.SelectedValue; newModel.Looptest = ddlLooptest.SelectedValue; - newModel.Calibration = ddlCalibration.SelectedValue; + //newModel.Calibration = ddlCalibration.SelectedValue; newModel.FINAL_Status = model.FINAL_Status; newModel.Descriptions = txtDescriptions.Text; } diff --git a/SGGL/FineUIPro.Web/Transfer/InstrumentationEdit.aspx.designer.cs b/SGGL/FineUIPro.Web/Transfer/InstrumentationEdit.aspx.designer.cs index 2f84802f..2f26b40a 100644 --- a/SGGL/FineUIPro.Web/Transfer/InstrumentationEdit.aspx.designer.cs +++ b/SGGL/FineUIPro.Web/Transfer/InstrumentationEdit.aspx.designer.cs @@ -86,15 +86,6 @@ namespace FineUIPro.Web.Transfer /// protected global::FineUIPro.TextBox txtDescriptions; - /// - /// ddlCalibration 控件。 - /// - /// - /// 自动生成的字段。 - /// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。 - /// - protected global::FineUIPro.DropDownList ddlCalibration; - /// /// ddlInstallationCalibration 控件。 /// diff --git a/SGGL/FineUIPro.Web/Transfer/Piping.aspx b/SGGL/FineUIPro.Web/Transfer/Piping.aspx index 260ce638..73b1959c 100644 --- a/SGGL/FineUIPro.Web/Transfer/Piping.aspx +++ b/SGGL/FineUIPro.Web/Transfer/Piping.aspx @@ -27,17 +27,17 @@ - - - - + + + + - +