焊接修改
This commit is contained in:
@@ -142,6 +142,13 @@ namespace BLL
|
||||
db.SubmitChanges();
|
||||
}
|
||||
|
||||
public static List<Model.PTP_PipelineList> getPipelineListByPTP_ID(string PTP_ID)
|
||||
{
|
||||
Model.HJGLDB db = Funs.DB;
|
||||
var view = (from x in db.PTP_PipelineList where x.PTP_ID == PTP_ID select x).ToList();
|
||||
return view;
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// 根据主键删除试压信息明细
|
||||
/// </summary>
|
||||
@@ -156,7 +163,31 @@ namespace BLL
|
||||
db.SubmitChanges();
|
||||
}
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// 根据试压包和区域主键删除试压信息明细
|
||||
/// </summary>
|
||||
/// <param name="testPackageID"></param>
|
||||
/// <param name="workAreaId"></param>
|
||||
public static void DeletePipelineListByPTP_IDAndWorkAreaId(string testPackageID,string workAreaId)
|
||||
{
|
||||
Model.HJGLDB db = Funs.DB;
|
||||
var testPackage = from x in db.PTP_PipelineList where x.PTP_ID == testPackageID && x.WorkAreaId==workAreaId select x;
|
||||
if (testPackage != null)
|
||||
{
|
||||
db.PTP_PipelineList.DeleteAllOnSubmit(testPackage);
|
||||
db.SubmitChanges();
|
||||
}
|
||||
}
|
||||
public static void DeletePipelineListByPT_PipeId(string PT_PipeId)
|
||||
{
|
||||
Model.HJGLDB db = Funs.DB;
|
||||
var testPackage = from x in db.PTP_PipelineList where x.PT_PipeId == PT_PipeId select x;
|
||||
if (testPackage != null)
|
||||
{
|
||||
db.PTP_PipelineList.DeleteAllOnSubmit(testPackage);
|
||||
db.SubmitChanges();
|
||||
}
|
||||
}
|
||||
/// <summary>
|
||||
/// 增加试压信息明细
|
||||
/// </summary>
|
||||
@@ -176,7 +207,19 @@ namespace BLL
|
||||
db.PTP_PipelineList.InsertOnSubmit(newPipelineList);
|
||||
db.SubmitChanges();
|
||||
}
|
||||
|
||||
public static bool IsPipelineListExists(string PTP_ID, string PipelineId)
|
||||
{
|
||||
Model.HJGLDB db = Funs.DB;
|
||||
var pipelineList = from x in db.PTP_PipelineList where x.PTP_ID == PTP_ID && x.PipelineId == PipelineId select x;
|
||||
if (pipelineList.Count() > 0)
|
||||
{
|
||||
return true;
|
||||
}
|
||||
else
|
||||
{
|
||||
return false;
|
||||
}
|
||||
}
|
||||
/// <summary>
|
||||
/// 根据单位获取试压
|
||||
/// </summary>
|
||||
|
||||
Reference in New Issue
Block a user