|
|
@@ -3510,10 +3510,17 @@ namespace Dongke.IBOSS.PRD.Service.PMModuleLogic
|
|
|
try
|
|
|
{
|
|
|
con.Open();
|
|
|
+
|
|
|
// hg5020 半检只定成型和干补的责任 by chenxy 2020-03-30
|
|
|
// and(TP_PM_ProductionDataIn.modeltype = 8 or(TP_PM_ProductionDataIn.modeltype = 5 and(exists(select 1 from tp_pm_groutingdailydetail gdd where gdd.groutingdailydetailID = TP_PM_ProductionDataIn.groutingdailydetailID and gdd.SPECIALREPAIRFLAG = '0'))))
|
|
|
// and (TP_PM_ProductionDataIn.modeltype <> 5 or (exists (select 1 from tp_pm_groutingdailydetail gdd where gdd.groutingdailydetailID=TP_PM_ProductionDataIn.groutingdailydetailID and gdd.SPECIALREPAIRFLAG='0')))
|
|
|
- string sqlString = @"select
|
|
|
+ string twcode = con.GetSqlResultToStr("select t.tagcode||t.workcode twcode from tp_mst_account t where t.accountid=1");
|
|
|
+ if (twcode == "HEGII5020")
|
|
|
+ {
|
|
|
+ // hg5020 半检只定成型和干补的责任 by chenxy 2020-03-30
|
|
|
+ // and(TP_PM_ProductionDataIn.modeltype = 8 or(TP_PM_ProductionDataIn.modeltype = 5 and(exists(select 1 from tp_pm_groutingdailydetail gdd where gdd.groutingdailydetailID = TP_PM_ProductionDataIn.groutingdailydetailID and gdd.SPECIALREPAIRFLAG = '0'))))
|
|
|
+ // and (TP_PM_ProductionDataIn.modeltype <> 5 or (exists (select 1 from tp_pm_groutingdailydetail gdd where gdd.groutingdailydetailID=TP_PM_ProductionDataIn.groutingdailydetailID and gdd.SPECIALREPAIRFLAG='0')))
|
|
|
+ string sqlString1 = @"select
|
|
|
TP_PM_ProductionDataIn.Barcode as BarCode,
|
|
|
TP_PM_ProductionDataIn.UserID,
|
|
|
TP_PM_ProductionDataIn.UserCode,
|
|
|
@@ -3526,9 +3533,33 @@ namespace Dongke.IBOSS.PRD.Service.PMModuleLogic
|
|
|
--left join TP_PC_Procedure
|
|
|
--on TP_PM_ProductionDataIn.ProcedureID=TP_PC_Procedure.ProcedureID
|
|
|
where TP_PM_ProductionDataIn.BarCode=:BarCode and TP_PM_ProductionDataIn.valueflag = '1'
|
|
|
+--and (TP_PM_ProductionDataIn.modeltype <> 5 or (exists (select 1 from tp_pm_groutingdailydetail gdd where gdd.groutingdailydetailID=TP_PM_ProductionDataIn.groutingdailydetailID and gdd.SPECIALREPAIRFLAG='0')))
|
|
|
and (TP_PM_ProductionDataIn.modeltype=8 or (TP_PM_ProductionDataIn.modeltype = 5 and (exists (select 1 from tp_pm_groutingdailydetail gdd where gdd.groutingdailydetailID=TP_PM_ProductionDataIn.groutingdailydetailID and gdd.SPECIALREPAIRFLAG='0'))))
|
|
|
order by TP_PM_ProductionDataIn.ProductionDataID
|
|
|
";
|
|
|
+ // 干补后 半检 不能选成型责任
|
|
|
+ OracleParameter[] paras1 = new OracleParameter[]{
|
|
|
+ new OracleParameter(":BarCode",OracleDbType.NVarchar2, barcode,ParameterDirection.Input),
|
|
|
+ };
|
|
|
+ return con.GetSqlResultToDs(sqlString1, paras1);
|
|
|
+ }
|
|
|
+
|
|
|
+ string sqlString = @"select
|
|
|
+ TP_PM_ProductionDataIn.Barcode as BarCode,
|
|
|
+ TP_PM_ProductionDataIn.UserID,
|
|
|
+ TP_PM_ProductionDataIn.UserCode,
|
|
|
+ TP_PM_ProductionDataIn.UserName,
|
|
|
+ TP_PM_ProductionDataIn.ProcedureID,
|
|
|
+ TP_PM_ProductionDataIn.ProcedureCode,
|
|
|
+ TP_PM_ProductionDataIn.ProcedureName,
|
|
|
+ TP_PM_ProductionDataIn.ProductionDataID
|
|
|
+ from TP_PM_ProductionDataIn
|
|
|
+ --left join TP_PC_Procedure
|
|
|
+ --on TP_PM_ProductionDataIn.ProcedureID=TP_PC_Procedure.ProcedureID
|
|
|
+ where TP_PM_ProductionDataIn.BarCode=:BarCode and TP_PM_ProductionDataIn.valueflag = '1'
|
|
|
+and (TP_PM_ProductionDataIn.modeltype <> 5 or (exists (select 1 from tp_pm_groutingdailydetail gdd where gdd.groutingdailydetailID=TP_PM_ProductionDataIn.groutingdailydetailID and gdd.SPECIALREPAIRFLAG='0')))
|
|
|
+ order by TP_PM_ProductionDataIn.ProductionDataID
|
|
|
+ ";
|
|
|
// 干补后 半检 不能选成型责任
|
|
|
OracleParameter[] paras = new OracleParameter[]{
|
|
|
new OracleParameter(":BarCode",OracleDbType.NVarchar2, barcode,ParameterDirection.Input),
|