数据库变更CNPC_XJYJ

This commit is contained in:
2025-08-04 18:04:41 +08:00
parent bafbf97359
commit 79a7f35e22
679 changed files with 5590 additions and 3465 deletions
@@ -9,7 +9,7 @@ namespace BLL
{
public class InspectionManagementDetailService
{
public static Model.SGGLDB db = Funs.DB;
public static Model.CNPCDB db = Funs.DB;
/// <summary>
/// 获取共检记录明细
@@ -37,7 +37,7 @@ namespace BLL
/// <param name="InspectionDetail"></param>
public static void AddInspectionDetail(Model.ProcessControl_InspectionManagementDetail InspectionDetail)
{
Model.SGGLDB db = Funs.DB;
Model.CNPCDB db = Funs.DB;
Model.ProcessControl_InspectionManagementDetail newInspectionDetail = new Model.ProcessControl_InspectionManagementDetail();
newInspectionDetail.InspectionDetailId = InspectionDetail.InspectionDetailId;
newInspectionDetail.InspectionId = InspectionDetail.InspectionId;
@@ -51,7 +51,7 @@ namespace BLL
}
public static void AddInspectionDetailForApi(Model.ProcessControl_InspectionManagementDetail InspectionDetail)
{
using (var db = new Model.SGGLDB(Funs.ConnString))
using (var db = new Model.CNPCDB(Funs.ConnString))
{
Model.ProcessControl_InspectionManagementDetail newInspectionDetail = new Model.ProcessControl_InspectionManagementDetail();
newInspectionDetail.InspectionDetailId = InspectionDetail.InspectionDetailId;
@@ -71,7 +71,7 @@ namespace BLL
/// <param name="InspectionDetail"></param>
public static void UpdateInspectionDetail(Model.ProcessControl_InspectionManagementDetail InspectionDetail)
{
Model.SGGLDB db = Funs.DB;
Model.CNPCDB db = Funs.DB;
Model.ProcessControl_InspectionManagementDetail newInspectionDetail = db.ProcessControl_InspectionManagementDetail.First(e => e.InspectionDetailId == InspectionDetail.InspectionDetailId);
newInspectionDetail.UnitWorkId = InspectionDetail.UnitWorkId;
newInspectionDetail.Branch = InspectionDetail.Branch;
@@ -87,14 +87,14 @@ namespace BLL
/// <param name="InspectionDetailId"></param>
public static void DeleteInspectionDetail(string InspectionDetailId)
{
Model.SGGLDB db = Funs.DB;
Model.CNPCDB db = Funs.DB;
Model.ProcessControl_InspectionManagementDetail InspectionDetail = db.ProcessControl_InspectionManagementDetail.First(e => e.InspectionDetailId == InspectionDetailId);
db.ProcessControl_InspectionManagementDetail.DeleteOnSubmit(InspectionDetail);
db.SubmitChanges();
}
public static void DeleteInspectionDetailForApi(string InspectionDetailId)
{
using (var db = new Model.SGGLDB(Funs.ConnString))
using (var db = new Model.CNPCDB(Funs.ConnString))
{
Model.ProcessControl_InspectionManagementDetail InspectionDetail = db.ProcessControl_InspectionManagementDetail.First(e => e.InspectionDetailId == InspectionDetailId);
db.ProcessControl_InspectionManagementDetail.DeleteOnSubmit(InspectionDetail);
@@ -107,7 +107,7 @@ namespace BLL
/// <param name="DrawingAuditId"></param>
public static void DeleteAllInspectionDetail(string InspectionId)
{
Model.SGGLDB db = Funs.DB;
Model.CNPCDB db = Funs.DB;
var q = (from x in db.ProcessControl_InspectionManagementDetail where x.InspectionId == InspectionId select x).ToList();
db.ProcessControl_InspectionManagementDetail.DeleteAllOnSubmit(q);
db.SubmitChanges();
@@ -137,7 +137,7 @@ namespace BLL
/// <param name="InspectionId"></param>
public static List<Model.ProcessControl_InspectionManagementDetail> GetInspectionDetails(string InspectionId)
{
using (Model.SGGLDB db = new Model.SGGLDB(Funs.ConnString))
using (Model.CNPCDB db = new Model.CNPCDB(Funs.ConnString))
{
return (from x in db.ProcessControl_InspectionManagementDetail
where x.InspectionId == InspectionId
@@ -146,7 +146,7 @@ namespace BLL
}
public static List<Model.ProcessControl_InspectionManagementDetail> GetInspectionDetailsForApi(string InspectionId)
{
using (var db = new Model.SGGLDB(Funs.ConnString))
using (var db = new Model.CNPCDB(Funs.ConnString))
{
return (from x in db.ProcessControl_InspectionManagementDetail
where x.InspectionId == InspectionId
@@ -160,7 +160,7 @@ namespace BLL
/// <param name="InspectionId"></param>
public static List<Model.ProcessControl_InspectionManagementDetail> GetOKInspectionDetails(string InspectionId)
{
using (Model.SGGLDB db = new Model.SGGLDB(Funs.ConnString))
using (Model.CNPCDB db = new Model.CNPCDB(Funs.ConnString))
{
return (from x in db.ProcessControl_InspectionManagementDetail
join y in db.ProcessControl_InspectionManagement on x.InspectionId equals y.InspectionId
@@ -170,7 +170,7 @@ namespace BLL
}
public static List<Model.ProcessControl_InspectionManagementDetail> GetOKInspectionDetailsForApi(string InspectionId)
{
using (var db = new Model.SGGLDB(Funs.ConnString))
using (var db = new Model.CNPCDB(Funs.ConnString))
{
return (from x in db.ProcessControl_InspectionManagementDetail
join y in db.ProcessControl_InspectionManagement on x.InspectionId equals y.InspectionId