1、索引项目中,删除英文,保留中文;
2、尾项管理中,筛选条件调整; 3、尾项管理中,支持点击图片预览; 4、增加尾项统计表中的完成比例; 5、更新管道表的表格(增加焊接信息、试压包状态、电伴热和保温/冷信息); 6、更新移交统计表(补充管道试压包其他信息统计); 7、删除索引项目中的地管和消防2个项目;
This commit is contained in:
@@ -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<SqlParameter> listStr = new List<SqlParameter>();
|
||||
listStr.Add(new SqlParameter("@ProjectId", this.CurrUser.LoginProjectId));
|
||||
|
||||
|
||||
Reference in New Issue
Block a user