试压包导入
This commit is contained in:
parent
abfad3c2af
commit
3d974eead4
Binary file not shown.
|
@ -4,6 +4,7 @@ using System.Linq;
|
|||
using System.Text;
|
||||
using System.Collections;
|
||||
using System.Web.UI.WebControls;
|
||||
using System.Data.SqlClient;
|
||||
|
||||
namespace BLL
|
||||
{
|
||||
|
@ -313,7 +314,32 @@ namespace BLL
|
|||
}
|
||||
return isoRate;
|
||||
}
|
||||
|
||||
public static int countBaseWeldJointCode(string pipelineId)
|
||||
{
|
||||
string sql = "select count(1) from Pipeline_WeldJoint where PipelineId=@PipelineId";
|
||||
SqlParameter[] parameters = new SqlParameter[] {
|
||||
new SqlParameter("@PipelineId",pipelineId)
|
||||
};
|
||||
int count = SQLHelper.getIntValue(sql, parameters);
|
||||
return count;
|
||||
}
|
||||
public static int countWeldJointCode(string pipelineId)
|
||||
{
|
||||
string sql = @"select WeldJointCode=(stuff((select ','+ WeldJonintCode from PTP_PipelineList where PipelineId=@PipelineId and isALL=0 for xml path('')),1,1,''))";
|
||||
SqlParameter[] parameters = new SqlParameter[] {
|
||||
new SqlParameter("@PipelineId",pipelineId)
|
||||
};
|
||||
string strCode = SQLHelper.GetStr(sql, parameters);
|
||||
if (!string.IsNullOrEmpty(strCode))
|
||||
{
|
||||
string[] arr = strCode.Split(',');
|
||||
return arr == null ? 0 : arr.Length;
|
||||
}
|
||||
else
|
||||
{
|
||||
return 0;
|
||||
}
|
||||
}
|
||||
|
||||
}
|
||||
}
|
||||
|
|
Binary file not shown.
|
@ -1239,6 +1239,7 @@
|
|||
<Content Include="WeldingProcess\PMI\PMISelectList.aspx" />
|
||||
<Content Include="WeldingProcess\TestPackageManage\AItemEndCheck.aspx" />
|
||||
<Content Include="WeldingProcess\TestPackageManage\BItemEndCheck.aspx" />
|
||||
<Content Include="WeldingProcess\TestPackageManage\ImportError.aspx" />
|
||||
<Content Include="WeldingProcess\TestPackageManage\selectJointCode.aspx" />
|
||||
<Content Include="WeldingProcess\TestPackageManage\TestPackageManageAudit.aspx" />
|
||||
<Content Include="WeldingProcess\TestPackageManage\TestPackageManageEdit.aspx" />
|
||||
|
@ -5449,6 +5450,13 @@
|
|||
<Compile Include="WeldingProcess\TestPackageManage\BItemEndCheck.aspx.designer.cs">
|
||||
<DependentUpon>BItemEndCheck.aspx</DependentUpon>
|
||||
</Compile>
|
||||
<Compile Include="WeldingProcess\TestPackageManage\ImportError.aspx.cs">
|
||||
<DependentUpon>ImportError.aspx</DependentUpon>
|
||||
<SubType>ASPXCodeBehind</SubType>
|
||||
</Compile>
|
||||
<Compile Include="WeldingProcess\TestPackageManage\ImportError.aspx.designer.cs">
|
||||
<DependentUpon>ImportError.aspx</DependentUpon>
|
||||
</Compile>
|
||||
<Compile Include="WeldingProcess\TestPackageManage\selectJointCode.aspx.cs">
|
||||
<DependentUpon>selectJointCode.aspx</DependentUpon>
|
||||
<SubType>ASPXCodeBehind</SubType>
|
||||
|
|
|
@ -0,0 +1,37 @@
|
|||
<%@ Page Language="C#" AutoEventWireup="true" CodeBehind="ImportError.aspx.cs" Inherits="FineUIPro.Web.WeldingProcess.TestPackageManage.ImportError" %>
|
||||
|
||||
<!DOCTYPE html>
|
||||
|
||||
<html xmlns="http://www.w3.org/1999/xhtml">
|
||||
<head runat="server">
|
||||
<meta http-equiv="Content-Type" content="text/html; charset=utf-8"/>
|
||||
<title>试压包导入错误日志</title>
|
||||
</head>
|
||||
<body>
|
||||
<form id="form1" runat="server">
|
||||
<f:PageManager ID="PageManager1" AutoSizePanelID="Grid1" runat="server" />
|
||||
<f:Grid ID="Grid1" ShowBorder="true" ShowHeader="false" Title="试压包导入错误日志" runat="server" EnableCollapse="false"
|
||||
DataKeyNames="ID" EnableCheckBoxSelect="true" EnableMultiSelect="true" PageSize="100" AllowPaging="true" >
|
||||
<Columns>
|
||||
<f:RowNumberField />
|
||||
<f:RenderField ColumnID="batchNo" Width="160px" DataField="BatchNo" HeaderText="批次号" />
|
||||
<f:RenderField ColumnID="TestPackageNo" MinWidth="80" DataField="TestPackageNo" HeaderText="试压包编号" />
|
||||
<f:RenderField ColumnID="UnitCode" MinWidth="80" DataField="UnitCode" HeaderText="单位代码" />
|
||||
<f:RenderField ColumnID="InstallCode" MinWidth="80" DataField="InstallCode" HeaderText="装置编号" />
|
||||
<f:RenderField ColumnID="AreaCode" MinWidth="80" DataField="AreaCode" HeaderText="区域" />
|
||||
<f:RenderField ColumnID="PiplineCode" MinWidth="160" DataField="PiplineCode" HeaderText="管线号" />
|
||||
<f:RenderField ColumnID="IsAll" MinWidth="80" DataField="IsAll" HeaderText="是否全部焊口" />
|
||||
<f:RenderField ColumnID="JointCode" MinWidth="200" DataField="JointCode" HeaderText="焊口编号" />
|
||||
|
||||
<f:TemplateField MinWidth="200" HeaderText="错误原因" >
|
||||
<ItemTemplate>
|
||||
<asp:Label ID="lablRemark" runat="server" Text='<%#Eval("Remark") %>' ForeColor="Red"></asp:Label>
|
||||
</ItemTemplate>
|
||||
</f:TemplateField>
|
||||
<f:RenderField ColumnID="CreatedTime" MinWidth="150" DataField="CreatedTime" HeaderText="导入时间" />
|
||||
</Columns>
|
||||
|
||||
</f:Grid>
|
||||
</form>
|
||||
</body>
|
||||
</html>
|
|
@ -0,0 +1,29 @@
|
|||
using BLL;
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
using System.Linq;
|
||||
using System.Web;
|
||||
using System.Web.UI;
|
||||
using System.Web.UI.WebControls;
|
||||
|
||||
namespace FineUIPro.Web.WeldingProcess.TestPackageManage
|
||||
{
|
||||
public partial class ImportError : PageBase
|
||||
{
|
||||
string batchNo = string.Empty;
|
||||
protected void Page_Load(object sender, EventArgs e)
|
||||
{
|
||||
this.batchNo = Request.Params["batchNo"];
|
||||
if (!IsPostBack)
|
||||
{
|
||||
BindGrid();
|
||||
}
|
||||
}
|
||||
void BindGrid()
|
||||
{
|
||||
var list=Funs.DB.PTP_TestPackage_ImportErrorLog.Where(t=>t.BatchNo == batchNo).OrderBy(t=>t.TestPackageNo).ToList();
|
||||
this.Grid1.DataSource = list;
|
||||
this.Grid1.DataBind();
|
||||
}
|
||||
}
|
||||
}
|
53
HJGL/FineUIPro.Web/WeldingProcess/TestPackageManage/ImportError.aspx.designer.cs
generated
Normal file
53
HJGL/FineUIPro.Web/WeldingProcess/TestPackageManage/ImportError.aspx.designer.cs
generated
Normal file
|
@ -0,0 +1,53 @@
|
|||
//------------------------------------------------------------------------------
|
||||
// <自动生成>
|
||||
// 此代码由工具生成。
|
||||
//
|
||||
// 对此文件的更改可能导致不正确的行为,如果
|
||||
// 重新生成代码,则所做更改将丢失。
|
||||
// </自动生成>
|
||||
//------------------------------------------------------------------------------
|
||||
|
||||
namespace FineUIPro.Web.WeldingProcess.TestPackageManage
|
||||
{
|
||||
|
||||
|
||||
public partial class ImportError
|
||||
{
|
||||
|
||||
/// <summary>
|
||||
/// form1 控件。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自动生成的字段。
|
||||
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
|
||||
/// </remarks>
|
||||
protected global::System.Web.UI.HtmlControls.HtmlForm form1;
|
||||
|
||||
/// <summary>
|
||||
/// PageManager1 控件。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自动生成的字段。
|
||||
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
|
||||
/// </remarks>
|
||||
protected global::FineUIPro.PageManager PageManager1;
|
||||
|
||||
/// <summary>
|
||||
/// Grid1 控件。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自动生成的字段。
|
||||
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
|
||||
/// </remarks>
|
||||
protected global::FineUIPro.Grid Grid1;
|
||||
|
||||
/// <summary>
|
||||
/// lablRemark 控件。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自动生成的字段。
|
||||
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
|
||||
/// </remarks>
|
||||
protected global::System.Web.UI.WebControls.Label lablRemark;
|
||||
}
|
||||
}
|
|
@ -217,6 +217,10 @@
|
|||
Target="Self" EnableResize="true" runat="server" IsModal="true" Width="1024px"
|
||||
Height="620px">
|
||||
</f:Window>
|
||||
<f:Window ID="Window4" Hidden="true" EnableIFrame="true" EnableMaximize="true"
|
||||
Target="Self" EnableResize="true" runat="server" IsModal="true" Width="1024px"
|
||||
Height="620px">
|
||||
</f:Window>
|
||||
</form>
|
||||
<script type="text/javascript">
|
||||
// 返回false,来阻止浏览器右键菜单
|
||||
|
|
|
@ -7,6 +7,8 @@ using System.IO;
|
|||
using System.Web;
|
||||
using BLL;
|
||||
using Newtonsoft.Json.Linq;
|
||||
using Model;
|
||||
using NPOI.HSSF.EventUserModel;
|
||||
|
||||
namespace FineUIPro.Web.WeldingProcess.TestPackageManage
|
||||
{
|
||||
|
@ -49,10 +51,10 @@ namespace FineUIPro.Web.WeldingProcess.TestPackageManage
|
|||
protected void Page_Load(object sender, EventArgs e)
|
||||
{
|
||||
if (!IsPostBack)
|
||||
{
|
||||
{
|
||||
this.ddlPageSize.SelectedValue = this.Grid1.PageSize.ToString();
|
||||
this.PTP_ID = string.Empty;
|
||||
this.txtSearchDate.Text = string.Format("{0:yyyy-MM}", System.DateTime.Now);
|
||||
this.txtSearchDate.Text = string.Format("{0:yyyy-MM}", System.DateTime.Now);
|
||||
this.InitTreeMenu();//加载树
|
||||
}
|
||||
}
|
||||
|
@ -64,7 +66,7 @@ namespace FineUIPro.Web.WeldingProcess.TestPackageManage
|
|||
/// </summary>
|
||||
private void InitTreeMenu()
|
||||
{
|
||||
this.tvControlItem.Nodes.Clear();
|
||||
this.tvControlItem.Nodes.Clear();
|
||||
TreeNode rootNode = new TreeNode();
|
||||
rootNode.Text = "单位-装置-月份";
|
||||
rootNode.NodeID = "0";
|
||||
|
@ -89,7 +91,7 @@ namespace FineUIPro.Web.WeldingProcess.TestPackageManage
|
|||
|
||||
List<Model.PTP_TestPackage> testPackageLists = (from x in Funs.DB.PTP_TestPackage
|
||||
where x.ProjectId == this.CurrUser.LoginProjectId && x.TableDate >= startTime && x.TableDate < endTime
|
||||
select x).ToList();
|
||||
select x).ToList();
|
||||
if (units != null)
|
||||
{
|
||||
foreach (var unit in units)
|
||||
|
@ -126,8 +128,10 @@ namespace FineUIPro.Web.WeldingProcess.TestPackageManage
|
|||
select x.InstallationId).Distinct();
|
||||
if (installId.Count() > 0)
|
||||
{
|
||||
var install = from x in Funs.DB.Project_Installation
|
||||
where installId.Contains(x.InstallationId) orderby x.InstallationCode select x;
|
||||
var install = from x in Funs.DB.Project_Installation
|
||||
where installId.Contains(x.InstallationId)
|
||||
orderby x.InstallationCode
|
||||
select x;
|
||||
foreach (var q in install)
|
||||
{
|
||||
TreeNode newNode = new TreeNode();
|
||||
|
@ -142,7 +146,7 @@ namespace FineUIPro.Web.WeldingProcess.TestPackageManage
|
|||
}
|
||||
else if (node.ToolTip == "装置")
|
||||
{
|
||||
string installationId = Funs.GetStrListByStr(node.NodeID, '|')[0];
|
||||
string installationId = Funs.GetStrListByStr(node.NodeID, '|')[0];
|
||||
var pointListMonth = (from x in testPackageUnitList
|
||||
where x.InstallationId == installationId
|
||||
select string.Format("{0:yyyy-MM}", x.TableDate)).Distinct();
|
||||
|
@ -177,10 +181,10 @@ namespace FineUIPro.Web.WeldingProcess.TestPackageManage
|
|||
{
|
||||
DateTime startTime = Convert.ToDateTime(this.txtSearchDate.Text.Trim() + "-01");
|
||||
DateTime endTime = startTime.AddMonths(1);
|
||||
string installationId = Funs.GetStrListByStr(node.ParentNode.NodeID, '|')[0];
|
||||
string installationId = Funs.GetStrListByStr(node.ParentNode.NodeID, '|')[0];
|
||||
var dReports = from x in testPackageUnitList
|
||||
where x.InstallationId == installationId
|
||||
&& x.TableDate>= startTime && x.TableDate< endTime
|
||||
&& x.TableDate >= startTime && x.TableDate < endTime
|
||||
orderby x.TestPackageNo descending
|
||||
select x;
|
||||
foreach (var item in dReports)
|
||||
|
@ -516,7 +520,7 @@ namespace FineUIPro.Web.WeldingProcess.TestPackageManage
|
|||
BLL.Sys_LogService.AddLog(BLL.Const.System_3, this.CurrUser.LoginProjectId, this.CurrUser.UserId, Const.TestPackageManageEditMenuId, Const.BtnDelete, this.PTP_ID);
|
||||
Alert.ShowInTop("删除成功!", MessageBoxIcon.Success);
|
||||
this.InitTreeMenu();
|
||||
this.BindGrid();
|
||||
this.BindGrid();
|
||||
}
|
||||
else
|
||||
{
|
||||
|
@ -545,7 +549,7 @@ namespace FineUIPro.Web.WeldingProcess.TestPackageManage
|
|||
this.InitTreeMenu();
|
||||
this.hdPTP_ID.Text = string.Empty;
|
||||
}
|
||||
|
||||
|
||||
/// <summary>
|
||||
/// 查询
|
||||
/// </summary>
|
||||
|
@ -651,7 +655,7 @@ namespace FineUIPro.Web.WeldingProcess.TestPackageManage
|
|||
}
|
||||
}
|
||||
|
||||
var qq = from x in Funs.DB.View_CheckResultSummary where x.PTP_ID==this.PTP_ID select x;
|
||||
var qq = from x in Funs.DB.View_CheckResultSummary where x.PTP_ID == this.PTP_ID select x;
|
||||
|
||||
// 合格
|
||||
var rt = qq.Where(x => x.DetectionTypeCode == "RT" && x.CheckResult == "合格");
|
||||
|
@ -661,7 +665,7 @@ namespace FineUIPro.Web.WeldingProcess.TestPackageManage
|
|||
bRt = rt.Count().ToString() + "/" + rt.Sum(x => x.TotalFilm).ToString();
|
||||
}
|
||||
|
||||
var jpt = qq.Where(x => x.DetectionTypeCode == "PT" && x.CheckResult == "合格" && x.WeldType=="2");
|
||||
var jpt = qq.Where(x => x.DetectionTypeCode == "PT" && x.CheckResult == "合格" && x.WeldType == "2");
|
||||
string ptj = "/";
|
||||
if (jpt.Count() > 0)
|
||||
{
|
||||
|
@ -719,7 +723,7 @@ namespace FineUIPro.Web.WeldingProcess.TestPackageManage
|
|||
if (drpPrintTypeList.SelectedValue == "3")
|
||||
{
|
||||
Window2.Title = "管道无损检测比例统计表";
|
||||
varValue = varValue + "|" + "试压包号:"+pip.TestPackageNo.Trim();
|
||||
varValue = varValue + "|" + "试压包号:" + pip.TestPackageNo.Trim();
|
||||
if (!string.IsNullOrEmpty(unitName))
|
||||
{
|
||||
varValue = varValue + "|" + unitName;
|
||||
|
@ -812,153 +816,58 @@ namespace FineUIPro.Web.WeldingProcess.TestPackageManage
|
|||
|
||||
if (ds.Tables.Count > 0)
|
||||
{
|
||||
var units = from x in Funs.DB.Base_Unit
|
||||
join y in Funs.DB.Project_Unit on x.UnitId equals y.UnitId
|
||||
where y.ProjectId == this.CurrUser.LoginProjectId
|
||||
select x;//单位
|
||||
|
||||
List<Model.PTP_TestPackage> testPackageList = new List<Model.PTP_TestPackage>();
|
||||
List<Model.PTP_PipelineList> pipelineList = new List<Model.PTP_PipelineList>();
|
||||
|
||||
DataTable dt = ds.Tables[0];
|
||||
|
||||
for (int i = 0; i < ds.Tables[0].Rows.Count; i++)
|
||||
//定义错误集合实体类
|
||||
var data = ValidateFieldsExcelData(ds.Tables[0]);
|
||||
Funs.DB.PTP_TestPackage_ImportErrorLog.InsertAllOnSubmit(data.Item2);
|
||||
Funs.DB.SubmitChanges();
|
||||
//验证错误集合
|
||||
if (data.Item1)
|
||||
{
|
||||
var isExitTestPage = from x in Funs.DB.PTP_TestPackage
|
||||
join y in Funs.DB.Project_Installation on x.InstallationId equals y.InstallationId
|
||||
join z in Funs.DB.Base_Unit on x.UnitId equals z.UnitId
|
||||
where x.ProjectId == this.CurrUser.LoginProjectId
|
||||
&& x.TestPackageNo == ds.Tables[0].Rows[i]["试压包编号"].ToString()
|
||||
&& y.InstallationCode == ds.Tables[0].Rows[i]["装置编号"].ToString()
|
||||
&& z.UnitCode == ds.Tables[0].Rows[i]["单位代码"].ToString()
|
||||
select x;
|
||||
|
||||
string error = string.Empty;
|
||||
|
||||
#region 数据验证 全新导入
|
||||
if (isExitTestPage.Count() == 0)
|
||||
{
|
||||
Model.PTP_PipelineList pipeline = new Model.PTP_PipelineList();
|
||||
string ptpId = string.Empty;
|
||||
|
||||
string installationId = string.Empty;
|
||||
if (ds.Tables[0].Rows[i]["装置编号"] != null && !string.IsNullOrEmpty(ds.Tables[0].Rows[i]["装置编号"].ToString()))
|
||||
{
|
||||
var ins = Funs.DB.Project_Installation.FirstOrDefault(x => x.ProjectId == CurrUser.LoginProjectId && x.InstallationCode == ds.Tables[0].Rows[i]["装置编号"].ToString());
|
||||
if (ins == null)
|
||||
{
|
||||
error += "装置编号不存在!";
|
||||
}
|
||||
else
|
||||
{
|
||||
installationId = ins.InstallationId; ;
|
||||
}
|
||||
}
|
||||
else
|
||||
{
|
||||
error += "区域编号不能为空!";
|
||||
}
|
||||
|
||||
string unitId = string.Empty;
|
||||
if (ds.Tables[0].Rows[i]["单位代码"] != null && !string.IsNullOrEmpty(ds.Tables[0].Rows[i]["单位代码"].ToString()))
|
||||
{
|
||||
var unit = units.FirstOrDefault(x => x.UnitCode == ds.Tables[0].Rows[i]["单位代码"].ToString());
|
||||
if (unit == null)
|
||||
{
|
||||
error += "单位代码不存在!";
|
||||
}
|
||||
else
|
||||
{
|
||||
unitId = unit.UnitId;
|
||||
}
|
||||
}
|
||||
else
|
||||
{
|
||||
error += "单位代码不能为空!";
|
||||
}
|
||||
|
||||
string pipelineId = string.Empty;
|
||||
if (ds.Tables[0].Rows[i]["管线号"] != null && !string.IsNullOrEmpty(ds.Tables[0].Rows[i]["管线号"].ToString()))
|
||||
{
|
||||
var isExitPipeline = Funs.DB.Pipeline_Pipeline.FirstOrDefault(x => x.ProjectId == this.CurrUser.LoginProjectId
|
||||
&& x.UnitId == unitId
|
||||
&& x.InstallationId == installationId
|
||||
&& x.PipelineCode == ds.Tables[0].Rows[i]["管线号"].ToString());
|
||||
if (isExitPipeline != null)
|
||||
{
|
||||
pipeline.PipelineId = isExitPipeline.PipelineId;
|
||||
}
|
||||
else
|
||||
{
|
||||
error += "管线号不存在!";
|
||||
}
|
||||
}
|
||||
else
|
||||
{
|
||||
error += "管线号不能为空!";
|
||||
}
|
||||
|
||||
if (ds.Tables[0].Rows[i]["试压包编号"] != null && !string.IsNullOrEmpty(ds.Tables[0].Rows[i]["试压包编号"].ToString()))
|
||||
{
|
||||
var cc = from x in testPackageList where x.TestPackageNo == ds.Tables[0].Rows[i]["试压包编号"].ToString() select x;
|
||||
if (cc.Count() == 0)
|
||||
{
|
||||
Model.PTP_TestPackage package = new Model.PTP_TestPackage();
|
||||
ptpId = Funs.GetNewID();
|
||||
package.PTP_ID = ptpId;
|
||||
package.ProjectId = CurrUser.LoginProjectId;
|
||||
package.UnitId = unitId;
|
||||
package.InstallationId = installationId;
|
||||
package.TestPackageNo = ds.Tables[0].Rows[i]["试压包编号"].ToString();
|
||||
package.TableDate = DateTime.Now;
|
||||
package.Tabler = this.CurrUser.UserId;
|
||||
testPackageList.Add(package);
|
||||
|
||||
pipeline.PT_PipeId = Funs.GetNewID();
|
||||
pipeline.PTP_ID = ptpId;
|
||||
}
|
||||
else
|
||||
{
|
||||
pipeline.PT_PipeId = Funs.GetNewID();
|
||||
pipeline.PTP_ID = cc.First().PTP_ID;
|
||||
}
|
||||
}
|
||||
else
|
||||
{
|
||||
error += "试压包编号不能为空!";
|
||||
}
|
||||
|
||||
if (!string.IsNullOrEmpty(error))
|
||||
{
|
||||
errorInfos += "第" + (i + 2) + "行:" + error + " </br>";
|
||||
}
|
||||
pipelineList.Add(pipeline);
|
||||
}
|
||||
#endregion
|
||||
}
|
||||
|
||||
// 数据验证错误,返回
|
||||
if (!string.IsNullOrEmpty(errorInfos))
|
||||
{
|
||||
ShowNotify(errorInfos, MessageBoxIcon.Warning, 30000);
|
||||
string batchNo = data.Item2.Select(t => t.BatchNo).Distinct().First();
|
||||
PageContext.RegisterStartupScript(Window4.GetShowReference(String.Format("ImportError.aspx?batchNo={0}", batchNo),"试压包导入错误日志"));
|
||||
return;
|
||||
}
|
||||
else
|
||||
//导入数据
|
||||
List<PTP_TestPackage> listPtpPackgeData = new List<PTP_TestPackage>();
|
||||
List<Model.PTP_PipelineList> listDetailData = new List<PTP_PipelineList>();
|
||||
foreach (var item in data.Item2)
|
||||
{
|
||||
// 不更新,新数据插入
|
||||
if (testPackageList.Count > 0 && pipelineList.Count() > 0)
|
||||
if (!listPtpPackgeData.Any(t => t.TestPackageNo == item.TestPackageNo))
|
||||
{
|
||||
Funs.DB.PTP_TestPackage.InsertAllOnSubmit(testPackageList);
|
||||
|
||||
Funs.DB.PTP_PipelineList.InsertAllOnSubmit(pipelineList);
|
||||
Funs.DB.SubmitChanges();
|
||||
List<PTP_PipelineList> ptpItemListData = new List<PTP_PipelineList>();
|
||||
Model.PTP_TestPackage model = new PTP_TestPackage();
|
||||
model.PTP_ID = SQLHelper.GetNewID(typeof(PTP_TestPackage));
|
||||
model.TestPackageNo = item.TestPackageNo;
|
||||
model.UnitId = item.UnitId;
|
||||
model.ProjectId = item.ProjectId;
|
||||
model.InstallationId = item.InstallId;
|
||||
model.TableDate = DateTime.Now;
|
||||
model.Tabler = this.CurrUser.UserId;
|
||||
listPtpPackgeData.Add(model);
|
||||
var itemData=data.Item2.Where(t=>t.TestPackageNo==item.TestPackageNo).ToList();
|
||||
foreach (var item2 in itemData)
|
||||
{
|
||||
var model2=new PTP_PipelineList();
|
||||
model2.PTP_ID = model.PTP_ID;
|
||||
model2.PipelineId = item2.PipelineId;
|
||||
model2.WorkAreaId = item2.WorkAreaId;
|
||||
model2.WeldJonintCode = item2.JointCode;
|
||||
model2.PT_PipeId = SQLHelper.GetNewID(typeof(PTP_PipelineList));
|
||||
model2.IsAll= item2.IsAll == "是" ? true : false;
|
||||
listDetailData.Add(model2);
|
||||
}
|
||||
}
|
||||
|
||||
ShowNotify("试压包信息导入成功!", MessageBoxIcon.Success);
|
||||
this.BindGrid();
|
||||
}
|
||||
}
|
||||
Funs.DB.PTP_TestPackage.InsertAllOnSubmit(listPtpPackgeData);
|
||||
Funs.DB.PTP_PipelineList.InsertAllOnSubmit(listDetailData);
|
||||
//绑定表格
|
||||
Funs.DB.SubmitChanges();
|
||||
|
||||
this.BindGrid();
|
||||
|
||||
ShowNotify("导入成功!", MessageBoxIcon.Success);
|
||||
PageContext.RegisterStartupScript(ActiveWindow.GetWriteBackValueReference(this.PTP_ID)+ ActiveWindow.GetHidePostBackReference());
|
||||
}
|
||||
else
|
||||
{
|
||||
ShowAlert("没有数据!", MessageBoxIcon.Warning);
|
||||
|
@ -972,5 +881,180 @@ namespace FineUIPro.Web.WeldingProcess.TestPackageManage
|
|||
}
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// 验证Excle中的数据列是否符合要求
|
||||
/// </summary>
|
||||
private (bool, List<PTP_TestPackage_ImportErrorLog>) ValidateFieldsExcelData(DataTable dt)
|
||||
{
|
||||
var listData = new List<PTP_TestPackage_ImportErrorLog>();
|
||||
bool flag = false;
|
||||
int k = 0;
|
||||
string batchNo = DateTime.Now.ToString("yyyyMMddHHmmss");
|
||||
foreach (DataRow dr in dt.Rows)
|
||||
{
|
||||
var model = new PTP_TestPackage_ImportErrorLog();
|
||||
k++;
|
||||
string testpackNo = dr[0].ToString(); //试压包编号
|
||||
string untiCode = dr[1].ToString(); //单位编号
|
||||
string installCode = dr[2].ToString(); //装置编号
|
||||
string areaCode = dr[3].ToString(); //区域编号
|
||||
string pipelineCode = dr[4].ToString(); //管线编号
|
||||
string isALL = dr[5].ToString(); //是否全部焊口
|
||||
string jointCode = dr[6].ToString(); //焊口列表逗号
|
||||
model.Id = SQLHelper.GetNewID(typeof(PTP_TestPackage_ImportErrorLog));
|
||||
model.TestPackageNo = testpackNo;
|
||||
model.UnitCode = untiCode;
|
||||
model.InstallCode = installCode;
|
||||
model.AreaCode = areaCode;
|
||||
model.PiplineCode = pipelineCode;
|
||||
model.IsAll = isALL;
|
||||
model.JointCode = jointCode;
|
||||
model.CreatedTime = DateTime.Now;
|
||||
model.RowId = k;
|
||||
model.BatchNo = batchNo;
|
||||
string errorMsg = string.Empty;
|
||||
//验证是否为空
|
||||
if (string.IsNullOrEmpty(model.TestPackageNo))
|
||||
{
|
||||
errorMsg += "试压包编号未填写 |";
|
||||
|
||||
}
|
||||
if (string.IsNullOrEmpty(model.UnitCode))
|
||||
{
|
||||
errorMsg += "试单位编号未填写 | ";
|
||||
}
|
||||
if (string.IsNullOrEmpty(installCode))
|
||||
{
|
||||
errorMsg += "装置编号未填写 | ";
|
||||
}
|
||||
if (string.IsNullOrEmpty(areaCode))
|
||||
{
|
||||
errorMsg += "区域编号未填写 | ";
|
||||
}
|
||||
if (string.IsNullOrEmpty(pipelineCode))
|
||||
{
|
||||
errorMsg += "管线号未填写 | ";
|
||||
}
|
||||
if (string.IsNullOrEmpty(isALL))
|
||||
{
|
||||
errorMsg += "是否全部焊口未填写 | ";
|
||||
}
|
||||
//检查单位编号是否存在
|
||||
var unitInfo = Funs.DB.Base_Unit.FirstOrDefault(t => t.UnitCode == model.UnitCode);
|
||||
if (unitInfo == null)
|
||||
{
|
||||
errorMsg += "未知的单位编号 | ";
|
||||
}
|
||||
var installInfo = Funs.DB.Project_Installation.FirstOrDefault(t => t.InstallationCode == model.InstallCode);
|
||||
if (installInfo == null)
|
||||
{
|
||||
errorMsg += "未知的装置编号 | ";
|
||||
}
|
||||
var areaInfo = Funs.DB.Project_WorkArea.FirstOrDefault(t => t.WorkAreaCode == model.AreaCode);
|
||||
if (areaInfo == null)
|
||||
{
|
||||
errorMsg += "未知的区域编号 | ";
|
||||
}
|
||||
var isAnypipeline = Funs.DB.Pipeline_Pipeline.Any(t => t.PipelineCode == model.PiplineCode);
|
||||
if (!isAnypipeline)
|
||||
{
|
||||
errorMsg += "未知的管线号 | ";
|
||||
}
|
||||
if (isALL != "是" && isALL != "否")
|
||||
{
|
||||
errorMsg += "是否部分焊口值不正确,只能为是或否 | ";
|
||||
}
|
||||
if (isALL == "否" && string.IsNullOrEmpty(model.JointCode))
|
||||
{
|
||||
errorMsg += "部分焊口请填写焊口编号 | ";
|
||||
}
|
||||
var isPackNoAny = Funs.DB.PTP_TestPackage.Any(t => t.TestPackageCode == model.TestPackageNo);
|
||||
if (isPackNoAny)
|
||||
{
|
||||
errorMsg += "该试压包编号已存在 | ";
|
||||
}
|
||||
if (unitInfo != null && installInfo != null && areaInfo != null )
|
||||
{
|
||||
model.ProjectId=this.CurrUser.LoginProjectId;
|
||||
model.UnitId = unitInfo.UnitId;
|
||||
model.WorkAreaId = areaInfo.WorkAreaId;
|
||||
model.InstallId = installInfo.InstallationId;
|
||||
var newPipelineInfo = Funs.DB.Pipeline_Pipeline.FirstOrDefault(t => t.UnitId == unitInfo.UnitId &&
|
||||
t.InstallationId == installInfo.InstallationId && t.WorkAreaId == areaInfo.WorkAreaId &&
|
||||
t.PipelineCode==model.PiplineCode);
|
||||
if (newPipelineInfo != null)
|
||||
{
|
||||
model.PipelineId =newPipelineInfo.PipelineId;
|
||||
|
||||
var ptpDetailList = Funs.DB.PTP_PipelineList
|
||||
.Where(t => t.PipelineId == newPipelineInfo.PipelineId);
|
||||
//查询当前的管线是否被使用了
|
||||
if (isALL == "是")
|
||||
{
|
||||
var isAnyPipeline = ptpDetailList.Where(t => t.IsAll == true).Any();
|
||||
if (isAnyPipeline)
|
||||
{
|
||||
errorMsg += "该管线已被使用 | ";
|
||||
}
|
||||
var isExcelPipline= listData.Where(t=>t.PipelineId== newPipelineInfo.PipelineId).Any();
|
||||
if (isExcelPipline)
|
||||
{
|
||||
errorMsg += "该管线已被使用 | ";
|
||||
}
|
||||
}
|
||||
|
||||
//查询当前的焊口是否被使用了
|
||||
if (isALL == "否")
|
||||
{
|
||||
var dict = GetJointCodeDic(newPipelineInfo.PipelineId);
|
||||
string[] modelCodes = model.JointCode.Split(',');
|
||||
for (int i = 0; i < modelCodes.Length; i++)
|
||||
{
|
||||
if (dict.ContainsKey(modelCodes[i]))
|
||||
{
|
||||
errorMsg += $"焊口【{modelCodes[i]}】已被使用 | ";
|
||||
}
|
||||
}
|
||||
int baseCount = BLL.TestPackageManageEditService.countBaseWeldJointCode(newPipelineInfo.PipelineId);
|
||||
if (dict.Count == baseCount)
|
||||
{
|
||||
errorMsg += $"当前管线【{newPipelineInfo.PipelineId}】已被使用 | ";
|
||||
}
|
||||
}
|
||||
}
|
||||
model.Remark = errorMsg;
|
||||
}
|
||||
if(!string.IsNullOrEmpty(model.Remark))
|
||||
flag = true;
|
||||
|
||||
listData.Add(model);
|
||||
}
|
||||
|
||||
return (flag, listData);
|
||||
}
|
||||
|
||||
private Dictionary<string, int> GetJointCodeDic(string piplineId)
|
||||
{
|
||||
var dict = new Dictionary<string, int>();
|
||||
var dataList = Funs.DB.PTP_PipelineList.Where(t => t.PipelineId == piplineId && t.IsAll == false)
|
||||
.Select(t => t.WeldJonintCode).ToList();
|
||||
int k = 0;
|
||||
foreach (var item in dataList)
|
||||
{
|
||||
k++;
|
||||
if (!string.IsNullOrEmpty(item))
|
||||
{
|
||||
string[] arr = item.Split(',');
|
||||
for (int i = 0; i < arr.Length; i++)
|
||||
{
|
||||
if (!dict.ContainsKey(arr[i]))
|
||||
{
|
||||
dict.Add(arr[i], k);
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
return dict;
|
||||
}
|
||||
}
|
||||
}
|
|
@ -7,11 +7,13 @@
|
|||
// </自动生成>
|
||||
//------------------------------------------------------------------------------
|
||||
|
||||
namespace FineUIPro.Web.WeldingProcess.TestPackageManage {
|
||||
|
||||
|
||||
public partial class TestPackageManageEdit {
|
||||
|
||||
namespace FineUIPro.Web.WeldingProcess.TestPackageManage
|
||||
{
|
||||
|
||||
|
||||
public partial class TestPackageManageEdit
|
||||
{
|
||||
|
||||
/// <summary>
|
||||
/// Head1 控件。
|
||||
/// </summary>
|
||||
|
@ -20,7 +22,7 @@ namespace FineUIPro.Web.WeldingProcess.TestPackageManage {
|
|||
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
|
||||
/// </remarks>
|
||||
protected global::System.Web.UI.HtmlControls.HtmlHead Head1;
|
||||
|
||||
|
||||
/// <summary>
|
||||
/// form1 控件。
|
||||
/// </summary>
|
||||
|
@ -29,7 +31,7 @@ namespace FineUIPro.Web.WeldingProcess.TestPackageManage {
|
|||
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
|
||||
/// </remarks>
|
||||
protected global::System.Web.UI.HtmlControls.HtmlForm form1;
|
||||
|
||||
|
||||
/// <summary>
|
||||
/// PageManager1 控件。
|
||||
/// </summary>
|
||||
|
@ -38,7 +40,7 @@ namespace FineUIPro.Web.WeldingProcess.TestPackageManage {
|
|||
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
|
||||
/// </remarks>
|
||||
protected global::FineUIPro.PageManager PageManager1;
|
||||
|
||||
|
||||
/// <summary>
|
||||
/// Panel1 控件。
|
||||
/// </summary>
|
||||
|
@ -47,7 +49,7 @@ namespace FineUIPro.Web.WeldingProcess.TestPackageManage {
|
|||
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
|
||||
/// </remarks>
|
||||
protected global::FineUIPro.Panel Panel1;
|
||||
|
||||
|
||||
/// <summary>
|
||||
/// panelLeftRegion 控件。
|
||||
/// </summary>
|
||||
|
@ -56,7 +58,7 @@ namespace FineUIPro.Web.WeldingProcess.TestPackageManage {
|
|||
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
|
||||
/// </remarks>
|
||||
protected global::FineUIPro.Panel panelLeftRegion;
|
||||
|
||||
|
||||
/// <summary>
|
||||
/// Toolbar1 控件。
|
||||
/// </summary>
|
||||
|
@ -65,7 +67,7 @@ namespace FineUIPro.Web.WeldingProcess.TestPackageManage {
|
|||
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
|
||||
/// </remarks>
|
||||
protected global::FineUIPro.Toolbar Toolbar1;
|
||||
|
||||
|
||||
/// <summary>
|
||||
/// txtSearchDate 控件。
|
||||
/// </summary>
|
||||
|
@ -74,7 +76,7 @@ namespace FineUIPro.Web.WeldingProcess.TestPackageManage {
|
|||
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
|
||||
/// </remarks>
|
||||
protected global::FineUIPro.DatePicker txtSearchDate;
|
||||
|
||||
|
||||
/// <summary>
|
||||
/// tvControlItem 控件。
|
||||
/// </summary>
|
||||
|
@ -83,7 +85,7 @@ namespace FineUIPro.Web.WeldingProcess.TestPackageManage {
|
|||
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
|
||||
/// </remarks>
|
||||
protected global::FineUIPro.Tree tvControlItem;
|
||||
|
||||
|
||||
/// <summary>
|
||||
/// panelCenterRegion 控件。
|
||||
/// </summary>
|
||||
|
@ -92,7 +94,7 @@ namespace FineUIPro.Web.WeldingProcess.TestPackageManage {
|
|||
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
|
||||
/// </remarks>
|
||||
protected global::FineUIPro.Panel panelCenterRegion;
|
||||
|
||||
|
||||
/// <summary>
|
||||
/// Toolbar2 控件。
|
||||
/// </summary>
|
||||
|
@ -101,7 +103,7 @@ namespace FineUIPro.Web.WeldingProcess.TestPackageManage {
|
|||
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
|
||||
/// </remarks>
|
||||
protected global::FineUIPro.Toolbar Toolbar2;
|
||||
|
||||
|
||||
/// <summary>
|
||||
/// hidFileName 控件。
|
||||
/// </summary>
|
||||
|
@ -110,7 +112,7 @@ namespace FineUIPro.Web.WeldingProcess.TestPackageManage {
|
|||
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
|
||||
/// </remarks>
|
||||
protected global::FineUIPro.HiddenField hidFileName;
|
||||
|
||||
|
||||
/// <summary>
|
||||
/// hdPTP_ID 控件。
|
||||
/// </summary>
|
||||
|
@ -119,7 +121,7 @@ namespace FineUIPro.Web.WeldingProcess.TestPackageManage {
|
|||
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
|
||||
/// </remarks>
|
||||
protected global::FineUIPro.HiddenField hdPTP_ID;
|
||||
|
||||
|
||||
/// <summary>
|
||||
/// fileUpload 控件。
|
||||
/// </summary>
|
||||
|
@ -128,7 +130,7 @@ namespace FineUIPro.Web.WeldingProcess.TestPackageManage {
|
|||
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
|
||||
/// </remarks>
|
||||
protected global::FineUIPro.FileUpload fileUpload;
|
||||
|
||||
|
||||
/// <summary>
|
||||
/// btnImport 控件。
|
||||
/// </summary>
|
||||
|
@ -137,7 +139,7 @@ namespace FineUIPro.Web.WeldingProcess.TestPackageManage {
|
|||
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
|
||||
/// </remarks>
|
||||
protected global::FineUIPro.Button btnImport;
|
||||
|
||||
|
||||
/// <summary>
|
||||
/// btnDownLoad 控件。
|
||||
/// </summary>
|
||||
|
@ -146,7 +148,7 @@ namespace FineUIPro.Web.WeldingProcess.TestPackageManage {
|
|||
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
|
||||
/// </remarks>
|
||||
protected global::FineUIPro.Button btnDownLoad;
|
||||
|
||||
|
||||
/// <summary>
|
||||
/// btnNew 控件。
|
||||
/// </summary>
|
||||
|
@ -155,7 +157,7 @@ namespace FineUIPro.Web.WeldingProcess.TestPackageManage {
|
|||
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
|
||||
/// </remarks>
|
||||
protected global::FineUIPro.Button btnNew;
|
||||
|
||||
|
||||
/// <summary>
|
||||
/// btnEdit 控件。
|
||||
/// </summary>
|
||||
|
@ -164,7 +166,7 @@ namespace FineUIPro.Web.WeldingProcess.TestPackageManage {
|
|||
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
|
||||
/// </remarks>
|
||||
protected global::FineUIPro.Button btnEdit;
|
||||
|
||||
|
||||
/// <summary>
|
||||
/// btnDelete 控件。
|
||||
/// </summary>
|
||||
|
@ -173,7 +175,7 @@ namespace FineUIPro.Web.WeldingProcess.TestPackageManage {
|
|||
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
|
||||
/// </remarks>
|
||||
protected global::FineUIPro.Button btnDelete;
|
||||
|
||||
|
||||
/// <summary>
|
||||
/// ToolbarFill1 控件。
|
||||
/// </summary>
|
||||
|
@ -182,7 +184,7 @@ namespace FineUIPro.Web.WeldingProcess.TestPackageManage {
|
|||
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
|
||||
/// </remarks>
|
||||
protected global::FineUIPro.ToolbarFill ToolbarFill1;
|
||||
|
||||
|
||||
/// <summary>
|
||||
/// drpPrintTypeList 控件。
|
||||
/// </summary>
|
||||
|
@ -191,7 +193,7 @@ namespace FineUIPro.Web.WeldingProcess.TestPackageManage {
|
|||
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
|
||||
/// </remarks>
|
||||
protected global::FineUIPro.DropDownList drpPrintTypeList;
|
||||
|
||||
|
||||
/// <summary>
|
||||
/// btnPrint 控件。
|
||||
/// </summary>
|
||||
|
@ -200,7 +202,7 @@ namespace FineUIPro.Web.WeldingProcess.TestPackageManage {
|
|||
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
|
||||
/// </remarks>
|
||||
protected global::FineUIPro.Button btnPrint;
|
||||
|
||||
|
||||
/// <summary>
|
||||
/// SimpleForm1 控件。
|
||||
/// </summary>
|
||||
|
@ -209,7 +211,7 @@ namespace FineUIPro.Web.WeldingProcess.TestPackageManage {
|
|||
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
|
||||
/// </remarks>
|
||||
protected global::FineUIPro.Form SimpleForm1;
|
||||
|
||||
|
||||
/// <summary>
|
||||
/// txtTestPackageNo 控件。
|
||||
/// </summary>
|
||||
|
@ -218,7 +220,7 @@ namespace FineUIPro.Web.WeldingProcess.TestPackageManage {
|
|||
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
|
||||
/// </remarks>
|
||||
protected global::FineUIPro.Label txtTestPackageNo;
|
||||
|
||||
|
||||
/// <summary>
|
||||
/// drpInstallation 控件。
|
||||
/// </summary>
|
||||
|
@ -227,7 +229,7 @@ namespace FineUIPro.Web.WeldingProcess.TestPackageManage {
|
|||
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
|
||||
/// </remarks>
|
||||
protected global::FineUIPro.Label drpInstallation;
|
||||
|
||||
|
||||
/// <summary>
|
||||
/// txtTestPackageName 控件。
|
||||
/// </summary>
|
||||
|
@ -236,7 +238,7 @@ namespace FineUIPro.Web.WeldingProcess.TestPackageManage {
|
|||
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
|
||||
/// </remarks>
|
||||
protected global::FineUIPro.Label txtTestPackageName;
|
||||
|
||||
|
||||
/// <summary>
|
||||
/// drpTestType 控件。
|
||||
/// </summary>
|
||||
|
@ -245,7 +247,7 @@ namespace FineUIPro.Web.WeldingProcess.TestPackageManage {
|
|||
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
|
||||
/// </remarks>
|
||||
protected global::FineUIPro.Label drpTestType;
|
||||
|
||||
|
||||
/// <summary>
|
||||
/// txtTestService 控件。
|
||||
/// </summary>
|
||||
|
@ -254,7 +256,7 @@ namespace FineUIPro.Web.WeldingProcess.TestPackageManage {
|
|||
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
|
||||
/// </remarks>
|
||||
protected global::FineUIPro.Label txtTestService;
|
||||
|
||||
|
||||
/// <summary>
|
||||
/// txtTestHeat 控件。
|
||||
/// </summary>
|
||||
|
@ -263,7 +265,7 @@ namespace FineUIPro.Web.WeldingProcess.TestPackageManage {
|
|||
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
|
||||
/// </remarks>
|
||||
protected global::FineUIPro.Label txtTestHeat;
|
||||
|
||||
|
||||
/// <summary>
|
||||
/// txtTestAmbientTemp 控件。
|
||||
/// </summary>
|
||||
|
@ -272,7 +274,7 @@ namespace FineUIPro.Web.WeldingProcess.TestPackageManage {
|
|||
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
|
||||
/// </remarks>
|
||||
protected global::FineUIPro.Label txtTestAmbientTemp;
|
||||
|
||||
|
||||
/// <summary>
|
||||
/// txtTestMediumTemp 控件。
|
||||
/// </summary>
|
||||
|
@ -281,7 +283,7 @@ namespace FineUIPro.Web.WeldingProcess.TestPackageManage {
|
|||
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
|
||||
/// </remarks>
|
||||
protected global::FineUIPro.Label txtTestMediumTemp;
|
||||
|
||||
|
||||
/// <summary>
|
||||
/// txtVacuumTestService 控件。
|
||||
/// </summary>
|
||||
|
@ -290,7 +292,7 @@ namespace FineUIPro.Web.WeldingProcess.TestPackageManage {
|
|||
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
|
||||
/// </remarks>
|
||||
protected global::FineUIPro.Label txtVacuumTestService;
|
||||
|
||||
|
||||
/// <summary>
|
||||
/// txtVacuumTestPressure 控件。
|
||||
/// </summary>
|
||||
|
@ -299,7 +301,7 @@ namespace FineUIPro.Web.WeldingProcess.TestPackageManage {
|
|||
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
|
||||
/// </remarks>
|
||||
protected global::FineUIPro.Label txtVacuumTestPressure;
|
||||
|
||||
|
||||
/// <summary>
|
||||
/// txtTightnessTestTime 控件。
|
||||
/// </summary>
|
||||
|
@ -308,7 +310,7 @@ namespace FineUIPro.Web.WeldingProcess.TestPackageManage {
|
|||
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
|
||||
/// </remarks>
|
||||
protected global::FineUIPro.Label txtTightnessTestTime;
|
||||
|
||||
|
||||
/// <summary>
|
||||
/// txtTightnessTestTemp 控件。
|
||||
/// </summary>
|
||||
|
@ -317,7 +319,7 @@ namespace FineUIPro.Web.WeldingProcess.TestPackageManage {
|
|||
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
|
||||
/// </remarks>
|
||||
protected global::FineUIPro.Label txtTightnessTestTemp;
|
||||
|
||||
|
||||
/// <summary>
|
||||
/// txtTightnessTest 控件。
|
||||
/// </summary>
|
||||
|
@ -326,7 +328,7 @@ namespace FineUIPro.Web.WeldingProcess.TestPackageManage {
|
|||
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
|
||||
/// </remarks>
|
||||
protected global::FineUIPro.Label txtTightnessTest;
|
||||
|
||||
|
||||
/// <summary>
|
||||
/// txtTestPressure 控件。
|
||||
/// </summary>
|
||||
|
@ -335,7 +337,7 @@ namespace FineUIPro.Web.WeldingProcess.TestPackageManage {
|
|||
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
|
||||
/// </remarks>
|
||||
protected global::FineUIPro.Label txtTestPressure;
|
||||
|
||||
|
||||
/// <summary>
|
||||
/// txtTestPressureTemp 控件。
|
||||
/// </summary>
|
||||
|
@ -344,7 +346,7 @@ namespace FineUIPro.Web.WeldingProcess.TestPackageManage {
|
|||
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
|
||||
/// </remarks>
|
||||
protected global::FineUIPro.Label txtTestPressureTemp;
|
||||
|
||||
|
||||
/// <summary>
|
||||
/// txtTestPressureTime 控件。
|
||||
/// </summary>
|
||||
|
@ -353,7 +355,7 @@ namespace FineUIPro.Web.WeldingProcess.TestPackageManage {
|
|||
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
|
||||
/// </remarks>
|
||||
protected global::FineUIPro.Label txtTestPressureTime;
|
||||
|
||||
|
||||
/// <summary>
|
||||
/// txtOperationMedium 控件。
|
||||
/// </summary>
|
||||
|
@ -362,7 +364,7 @@ namespace FineUIPro.Web.WeldingProcess.TestPackageManage {
|
|||
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
|
||||
/// </remarks>
|
||||
protected global::FineUIPro.Label txtOperationMedium;
|
||||
|
||||
|
||||
/// <summary>
|
||||
/// txtPurgingMedium 控件。
|
||||
/// </summary>
|
||||
|
@ -371,7 +373,7 @@ namespace FineUIPro.Web.WeldingProcess.TestPackageManage {
|
|||
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
|
||||
/// </remarks>
|
||||
protected global::FineUIPro.Label txtPurgingMedium;
|
||||
|
||||
|
||||
/// <summary>
|
||||
/// txtCleaningMedium 控件。
|
||||
/// </summary>
|
||||
|
@ -380,7 +382,7 @@ namespace FineUIPro.Web.WeldingProcess.TestPackageManage {
|
|||
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
|
||||
/// </remarks>
|
||||
protected global::FineUIPro.Label txtCleaningMedium;
|
||||
|
||||
|
||||
/// <summary>
|
||||
/// txtLeakageTestService 控件。
|
||||
/// </summary>
|
||||
|
@ -389,7 +391,7 @@ namespace FineUIPro.Web.WeldingProcess.TestPackageManage {
|
|||
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
|
||||
/// </remarks>
|
||||
protected global::FineUIPro.Label txtLeakageTestService;
|
||||
|
||||
|
||||
/// <summary>
|
||||
/// txtLeakageTestPressure 控件。
|
||||
/// </summary>
|
||||
|
@ -398,7 +400,7 @@ namespace FineUIPro.Web.WeldingProcess.TestPackageManage {
|
|||
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
|
||||
/// </remarks>
|
||||
protected global::FineUIPro.Label txtLeakageTestPressure;
|
||||
|
||||
|
||||
/// <summary>
|
||||
/// txtAllowSeepage 控件。
|
||||
/// </summary>
|
||||
|
@ -407,7 +409,7 @@ namespace FineUIPro.Web.WeldingProcess.TestPackageManage {
|
|||
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
|
||||
/// </remarks>
|
||||
protected global::FineUIPro.Label txtAllowSeepage;
|
||||
|
||||
|
||||
/// <summary>
|
||||
/// txtFactSeepage 控件。
|
||||
/// </summary>
|
||||
|
@ -416,7 +418,7 @@ namespace FineUIPro.Web.WeldingProcess.TestPackageManage {
|
|||
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
|
||||
/// </remarks>
|
||||
protected global::FineUIPro.Label txtFactSeepage;
|
||||
|
||||
|
||||
/// <summary>
|
||||
/// drpModifier 控件。
|
||||
/// </summary>
|
||||
|
@ -425,7 +427,7 @@ namespace FineUIPro.Web.WeldingProcess.TestPackageManage {
|
|||
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
|
||||
/// </remarks>
|
||||
protected global::FineUIPro.Label drpModifier;
|
||||
|
||||
|
||||
/// <summary>
|
||||
/// txtModifyDate 控件。
|
||||
/// </summary>
|
||||
|
@ -434,7 +436,7 @@ namespace FineUIPro.Web.WeldingProcess.TestPackageManage {
|
|||
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
|
||||
/// </remarks>
|
||||
protected global::FineUIPro.Label txtModifyDate;
|
||||
|
||||
|
||||
/// <summary>
|
||||
/// drpTabler 控件。
|
||||
/// </summary>
|
||||
|
@ -443,7 +445,7 @@ namespace FineUIPro.Web.WeldingProcess.TestPackageManage {
|
|||
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
|
||||
/// </remarks>
|
||||
protected global::FineUIPro.Label drpTabler;
|
||||
|
||||
|
||||
/// <summary>
|
||||
/// txtTableDate 控件。
|
||||
/// </summary>
|
||||
|
@ -452,7 +454,7 @@ namespace FineUIPro.Web.WeldingProcess.TestPackageManage {
|
|||
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
|
||||
/// </remarks>
|
||||
protected global::FineUIPro.Label txtTableDate;
|
||||
|
||||
|
||||
/// <summary>
|
||||
/// txtRemark 控件。
|
||||
/// </summary>
|
||||
|
@ -461,7 +463,7 @@ namespace FineUIPro.Web.WeldingProcess.TestPackageManage {
|
|||
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
|
||||
/// </remarks>
|
||||
protected global::FineUIPro.Label txtRemark;
|
||||
|
||||
|
||||
/// <summary>
|
||||
/// drpAuditer 控件。
|
||||
/// </summary>
|
||||
|
@ -470,7 +472,7 @@ namespace FineUIPro.Web.WeldingProcess.TestPackageManage {
|
|||
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
|
||||
/// </remarks>
|
||||
protected global::FineUIPro.Label drpAuditer;
|
||||
|
||||
|
||||
/// <summary>
|
||||
/// txtAduditDate 控件。
|
||||
/// </summary>
|
||||
|
@ -479,7 +481,7 @@ namespace FineUIPro.Web.WeldingProcess.TestPackageManage {
|
|||
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
|
||||
/// </remarks>
|
||||
protected global::FineUIPro.Label txtAduditDate;
|
||||
|
||||
|
||||
/// <summary>
|
||||
/// Grid1 控件。
|
||||
/// </summary>
|
||||
|
@ -488,7 +490,7 @@ namespace FineUIPro.Web.WeldingProcess.TestPackageManage {
|
|||
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
|
||||
/// </remarks>
|
||||
protected global::FineUIPro.Grid Grid1;
|
||||
|
||||
|
||||
/// <summary>
|
||||
/// ToolbarSeparator1 控件。
|
||||
/// </summary>
|
||||
|
@ -497,7 +499,7 @@ namespace FineUIPro.Web.WeldingProcess.TestPackageManage {
|
|||
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
|
||||
/// </remarks>
|
||||
protected global::FineUIPro.ToolbarSeparator ToolbarSeparator1;
|
||||
|
||||
|
||||
/// <summary>
|
||||
/// ToolbarText1 控件。
|
||||
/// </summary>
|
||||
|
@ -506,7 +508,7 @@ namespace FineUIPro.Web.WeldingProcess.TestPackageManage {
|
|||
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
|
||||
/// </remarks>
|
||||
protected global::FineUIPro.ToolbarText ToolbarText1;
|
||||
|
||||
|
||||
/// <summary>
|
||||
/// ddlPageSize 控件。
|
||||
/// </summary>
|
||||
|
@ -515,7 +517,7 @@ namespace FineUIPro.Web.WeldingProcess.TestPackageManage {
|
|||
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
|
||||
/// </remarks>
|
||||
protected global::FineUIPro.DropDownList ddlPageSize;
|
||||
|
||||
|
||||
/// <summary>
|
||||
/// Window1 控件。
|
||||
/// </summary>
|
||||
|
@ -524,7 +526,7 @@ namespace FineUIPro.Web.WeldingProcess.TestPackageManage {
|
|||
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
|
||||
/// </remarks>
|
||||
protected global::FineUIPro.Window Window1;
|
||||
|
||||
|
||||
/// <summary>
|
||||
/// Window2 控件。
|
||||
/// </summary>
|
||||
|
@ -533,7 +535,7 @@ namespace FineUIPro.Web.WeldingProcess.TestPackageManage {
|
|||
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
|
||||
/// </remarks>
|
||||
protected global::FineUIPro.Window Window2;
|
||||
|
||||
|
||||
/// <summary>
|
||||
/// Window3 控件。
|
||||
/// </summary>
|
||||
|
@ -542,5 +544,14 @@ namespace FineUIPro.Web.WeldingProcess.TestPackageManage {
|
|||
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
|
||||
/// </remarks>
|
||||
protected global::FineUIPro.Window Window3;
|
||||
|
||||
/// <summary>
|
||||
/// Window4 控件。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自动生成的字段。
|
||||
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
|
||||
/// </remarks>
|
||||
protected global::FineUIPro.Window Window4;
|
||||
}
|
||||
}
|
||||
|
|
|
@ -324,8 +324,8 @@ namespace FineUIPro.Web.WeldingProcess.TestPackageManage
|
|||
{
|
||||
string pipelineId = dr["PipelineId"].ToString();
|
||||
string joinCodeList = dr["WeldJointCode"].ToString();
|
||||
int count = countWeldJointCode(pipelineId);
|
||||
int baseCount = countBaseWeldJointCode(pipelineId);
|
||||
int count =BLL.TestPackageManageEditService.countWeldJointCode(pipelineId);
|
||||
int baseCount = BLL.TestPackageManageEditService.countBaseWeldJointCode(pipelineId);
|
||||
if (count == baseCount)
|
||||
{
|
||||
dr.Delete();
|
||||
|
@ -341,32 +341,7 @@ namespace FineUIPro.Web.WeldingProcess.TestPackageManage
|
|||
Grid1.DataBind();
|
||||
|
||||
}
|
||||
private int countBaseWeldJointCode(string pipelineId)
|
||||
{
|
||||
string sql = "select count(1) from Pipeline_WeldJoint where PipelineId=@PipelineId";
|
||||
SqlParameter[] parameters = new SqlParameter[] {
|
||||
new SqlParameter("@PipelineId",pipelineId)
|
||||
};
|
||||
int count = SQLHelper.getIntValue(sql, parameters);
|
||||
return count;
|
||||
}
|
||||
private int countWeldJointCode(string pipelineId)
|
||||
{
|
||||
string sql = @"select WeldJointCode=(stuff((select ','+ WeldJonintCode from PTP_PipelineList where PipelineId=@PipelineId and isALL=0 for xml path('')),1,1,''))";
|
||||
SqlParameter[] parameters = new SqlParameter[] {
|
||||
new SqlParameter("@PipelineId",pipelineId)
|
||||
};
|
||||
string strCode = SQLHelper.GetStr(sql, parameters);
|
||||
if(!string.IsNullOrEmpty(strCode) )
|
||||
{
|
||||
string[] arr=strCode.Split(',');
|
||||
return arr==null?0:arr.Length;
|
||||
}
|
||||
else
|
||||
{
|
||||
return 0;
|
||||
}
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// 对GV 赋值
|
||||
/// </summary>
|
||||
|
|
|
@ -29,10 +29,6 @@ namespace Model
|
|||
|
||||
#region 可扩展性方法定义
|
||||
partial void OnCreated();
|
||||
partial void OnCreated()
|
||||
{
|
||||
this.CommandTimeout = 600;
|
||||
}
|
||||
partial void InsertAttachFile(AttachFile instance);
|
||||
partial void UpdateAttachFile(AttachFile instance);
|
||||
partial void DeleteAttachFile(AttachFile instance);
|
||||
|
@ -225,6 +221,9 @@ namespace Model
|
|||
partial void InsertPTP_TestPackage(PTP_TestPackage instance);
|
||||
partial void UpdatePTP_TestPackage(PTP_TestPackage instance);
|
||||
partial void DeletePTP_TestPackage(PTP_TestPackage instance);
|
||||
partial void InsertPTP_TestPackage_ImportErrorLog(PTP_TestPackage_ImportErrorLog instance);
|
||||
partial void UpdatePTP_TestPackage_ImportErrorLog(PTP_TestPackage_ImportErrorLog instance);
|
||||
partial void DeletePTP_TestPackage_ImportErrorLog(PTP_TestPackage_ImportErrorLog instance);
|
||||
partial void InsertRepair_RepairRecord(Repair_RepairRecord instance);
|
||||
partial void UpdateRepair_RepairRecord(Repair_RepairRecord instance);
|
||||
partial void DeleteRepair_RepairRecord(Repair_RepairRecord instance);
|
||||
|
@ -817,6 +816,14 @@ namespace Model
|
|||
}
|
||||
}
|
||||
|
||||
public System.Data.Linq.Table<PTP_TestPackage_ImportErrorLog> PTP_TestPackage_ImportErrorLog
|
||||
{
|
||||
get
|
||||
{
|
||||
return this.GetTable<PTP_TestPackage_ImportErrorLog>();
|
||||
}
|
||||
}
|
||||
|
||||
public System.Data.Linq.Table<Repair_RepairRecord> Repair_RepairRecord
|
||||
{
|
||||
get
|
||||
|
@ -22492,12 +22499,12 @@ namespace Model
|
|||
|
||||
private string _DetectionStandard;
|
||||
|
||||
private string _Tabler;
|
||||
|
||||
private string _Remark;
|
||||
|
||||
private System.Nullable<System.DateTime> _CreatedTime;
|
||||
|
||||
private string _Tabler;
|
||||
|
||||
#region 可扩展性方法定义
|
||||
partial void OnLoaded();
|
||||
partial void OnValidate(System.Data.Linq.ChangeAction action);
|
||||
|
@ -22516,12 +22523,12 @@ namespace Model
|
|||
partial void OnUnitIdChanged();
|
||||
partial void OnDetectionStandardChanging(string value);
|
||||
partial void OnDetectionStandardChanged();
|
||||
partial void OnTablerChanging(string value);
|
||||
partial void OnTablerChanged();
|
||||
partial void OnRemarkChanging(string value);
|
||||
partial void OnRemarkChanged();
|
||||
partial void OnCreatedTimeChanging(System.Nullable<System.DateTime> value);
|
||||
partial void OnCreatedTimeChanged();
|
||||
partial void OnTablerChanging(string value);
|
||||
partial void OnTablerChanged();
|
||||
#endregion
|
||||
|
||||
public PMI_Delegation()
|
||||
|
@ -22589,7 +22596,7 @@ namespace Model
|
|||
}
|
||||
}
|
||||
|
||||
[global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_ProjectId", DbType="NVarChar(50) NOT NULL", CanBeNull=false)]
|
||||
[global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_ProjectId", DbType="NVarChar(50)")]
|
||||
public string ProjectId
|
||||
{
|
||||
get
|
||||
|
@ -22669,26 +22676,6 @@ namespace Model
|
|||
}
|
||||
}
|
||||
|
||||
[global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_Tabler", DbType="NVarChar(50)")]
|
||||
public string Tabler
|
||||
{
|
||||
get
|
||||
{
|
||||
return this._Tabler;
|
||||
}
|
||||
set
|
||||
{
|
||||
if ((this._Tabler != value))
|
||||
{
|
||||
this.OnTablerChanging(value);
|
||||
this.SendPropertyChanging();
|
||||
this._Tabler = value;
|
||||
this.SendPropertyChanged("Tabler");
|
||||
this.OnTablerChanged();
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
[global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_Remark", DbType="NVarChar(255)")]
|
||||
public string Remark
|
||||
{
|
||||
|
@ -22729,6 +22716,26 @@ namespace Model
|
|||
}
|
||||
}
|
||||
|
||||
[global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_Tabler", DbType="NVarChar(50)")]
|
||||
public string Tabler
|
||||
{
|
||||
get
|
||||
{
|
||||
return this._Tabler;
|
||||
}
|
||||
set
|
||||
{
|
||||
if ((this._Tabler != value))
|
||||
{
|
||||
this.OnTablerChanging(value);
|
||||
this.SendPropertyChanging();
|
||||
this._Tabler = value;
|
||||
this.SendPropertyChanged("Tabler");
|
||||
this.OnTablerChanged();
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
public event PropertyChangingEventHandler PropertyChanging;
|
||||
|
||||
public event PropertyChangedEventHandler PropertyChanged;
|
||||
|
@ -22768,10 +22775,10 @@ namespace Model
|
|||
|
||||
private int _Status;
|
||||
|
||||
private System.Nullable<System.DateTime> _CheckTime;
|
||||
|
||||
private string _ReportNo;
|
||||
|
||||
private System.Nullable<System.DateTime> _CheckTime;
|
||||
|
||||
private System.Nullable<System.DateTime> _ReportTime;
|
||||
|
||||
#region 可扩展性方法定义
|
||||
|
@ -22790,10 +22797,10 @@ namespace Model
|
|||
partial void OnAcceptanceChanged();
|
||||
partial void OnStatusChanging(int value);
|
||||
partial void OnStatusChanged();
|
||||
partial void OnCheckTimeChanging(System.Nullable<System.DateTime> value);
|
||||
partial void OnCheckTimeChanged();
|
||||
partial void OnReportNoChanging(string value);
|
||||
partial void OnReportNoChanged();
|
||||
partial void OnCheckTimeChanging(System.Nullable<System.DateTime> value);
|
||||
partial void OnCheckTimeChanged();
|
||||
partial void OnReportTimeChanging(System.Nullable<System.DateTime> value);
|
||||
partial void OnReportTimeChanged();
|
||||
#endregion
|
||||
|
@ -22903,7 +22910,7 @@ namespace Model
|
|||
}
|
||||
}
|
||||
|
||||
[global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_Status", DbType="Int NOT NULL")]
|
||||
[global::System.Data.Linq.Mapping.ColumnAttribute(Name="status", Storage="_Status", DbType="Int NOT NULL")]
|
||||
public int Status
|
||||
{
|
||||
get
|
||||
|
@ -22923,26 +22930,6 @@ namespace Model
|
|||
}
|
||||
}
|
||||
|
||||
[global::System.Data.Linq.Mapping.ColumnAttribute(Name="checkTime", Storage="_CheckTime", DbType="DateTime")]
|
||||
public System.Nullable<System.DateTime> CheckTime
|
||||
{
|
||||
get
|
||||
{
|
||||
return this._CheckTime;
|
||||
}
|
||||
set
|
||||
{
|
||||
if ((this._CheckTime != value))
|
||||
{
|
||||
this.OnCheckTimeChanging(value);
|
||||
this.SendPropertyChanging();
|
||||
this._CheckTime = value;
|
||||
this.SendPropertyChanged("CheckTime");
|
||||
this.OnCheckTimeChanged();
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
[global::System.Data.Linq.Mapping.ColumnAttribute(Name="reportNo", Storage="_ReportNo", DbType="NVarChar(50)")]
|
||||
public string ReportNo
|
||||
{
|
||||
|
@ -22963,6 +22950,26 @@ namespace Model
|
|||
}
|
||||
}
|
||||
|
||||
[global::System.Data.Linq.Mapping.ColumnAttribute(Name="checkTime", Storage="_CheckTime", DbType="DateTime")]
|
||||
public System.Nullable<System.DateTime> CheckTime
|
||||
{
|
||||
get
|
||||
{
|
||||
return this._CheckTime;
|
||||
}
|
||||
set
|
||||
{
|
||||
if ((this._CheckTime != value))
|
||||
{
|
||||
this.OnCheckTimeChanging(value);
|
||||
this.SendPropertyChanging();
|
||||
this._CheckTime = value;
|
||||
this.SendPropertyChanged("CheckTime");
|
||||
this.OnCheckTimeChanged();
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
[global::System.Data.Linq.Mapping.ColumnAttribute(Name="reportTime", Storage="_ReportTime", DbType="DateTime")]
|
||||
public System.Nullable<System.DateTime> ReportTime
|
||||
{
|
||||
|
@ -26739,6 +26746,452 @@ namespace Model
|
|||
}
|
||||
}
|
||||
|
||||
[global::System.Data.Linq.Mapping.TableAttribute(Name="dbo.PTP_TestPackage_ImportErrorLog")]
|
||||
public partial class PTP_TestPackage_ImportErrorLog : INotifyPropertyChanging, INotifyPropertyChanged
|
||||
{
|
||||
|
||||
private static PropertyChangingEventArgs emptyChangingEventArgs = new PropertyChangingEventArgs(String.Empty);
|
||||
|
||||
private string _Id;
|
||||
|
||||
private string _BatchNo;
|
||||
|
||||
private System.Nullable<int> _RowId;
|
||||
|
||||
private string _TestPackageNo;
|
||||
|
||||
private string _UnitCode;
|
||||
|
||||
private string _InstallCode;
|
||||
|
||||
private string _AreaCode;
|
||||
|
||||
private string _PiplineCode;
|
||||
|
||||
private string _IsAll;
|
||||
|
||||
private string _JointCode;
|
||||
|
||||
private string _ProjectId;
|
||||
|
||||
private string _UnitId;
|
||||
|
||||
private string _InstallId;
|
||||
|
||||
private string _WorkAreaId;
|
||||
|
||||
private string _PipelineId;
|
||||
|
||||
private string _Remark;
|
||||
|
||||
private System.Nullable<System.DateTime> _CreatedTime;
|
||||
|
||||
#region 可扩展性方法定义
|
||||
partial void OnLoaded();
|
||||
partial void OnValidate(System.Data.Linq.ChangeAction action);
|
||||
partial void OnCreated();
|
||||
partial void OnIdChanging(string value);
|
||||
partial void OnIdChanged();
|
||||
partial void OnBatchNoChanging(string value);
|
||||
partial void OnBatchNoChanged();
|
||||
partial void OnRowIdChanging(System.Nullable<int> value);
|
||||
partial void OnRowIdChanged();
|
||||
partial void OnTestPackageNoChanging(string value);
|
||||
partial void OnTestPackageNoChanged();
|
||||
partial void OnUnitCodeChanging(string value);
|
||||
partial void OnUnitCodeChanged();
|
||||
partial void OnInstallCodeChanging(string value);
|
||||
partial void OnInstallCodeChanged();
|
||||
partial void OnAreaCodeChanging(string value);
|
||||
partial void OnAreaCodeChanged();
|
||||
partial void OnPiplineCodeChanging(string value);
|
||||
partial void OnPiplineCodeChanged();
|
||||
partial void OnIsAllChanging(string value);
|
||||
partial void OnIsAllChanged();
|
||||
partial void OnJointCodeChanging(string value);
|
||||
partial void OnJointCodeChanged();
|
||||
partial void OnProjectIdChanging(string value);
|
||||
partial void OnProjectIdChanged();
|
||||
partial void OnUnitIdChanging(string value);
|
||||
partial void OnUnitIdChanged();
|
||||
partial void OnInstallIdChanging(string value);
|
||||
partial void OnInstallIdChanged();
|
||||
partial void OnWorkAreaIdChanging(string value);
|
||||
partial void OnWorkAreaIdChanged();
|
||||
partial void OnPipelineIdChanging(string value);
|
||||
partial void OnPipelineIdChanged();
|
||||
partial void OnRemarkChanging(string value);
|
||||
partial void OnRemarkChanged();
|
||||
partial void OnCreatedTimeChanging(System.Nullable<System.DateTime> value);
|
||||
partial void OnCreatedTimeChanged();
|
||||
#endregion
|
||||
|
||||
public PTP_TestPackage_ImportErrorLog()
|
||||
{
|
||||
OnCreated();
|
||||
}
|
||||
|
||||
[global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_Id", DbType="NVarChar(50) NOT NULL", CanBeNull=false, IsPrimaryKey=true)]
|
||||
public string Id
|
||||
{
|
||||
get
|
||||
{
|
||||
return this._Id;
|
||||
}
|
||||
set
|
||||
{
|
||||
if ((this._Id != value))
|
||||
{
|
||||
this.OnIdChanging(value);
|
||||
this.SendPropertyChanging();
|
||||
this._Id = value;
|
||||
this.SendPropertyChanged("Id");
|
||||
this.OnIdChanged();
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
[global::System.Data.Linq.Mapping.ColumnAttribute(Name="batchNo", Storage="_BatchNo", DbType="NVarChar(50) NOT NULL", CanBeNull=false)]
|
||||
public string BatchNo
|
||||
{
|
||||
get
|
||||
{
|
||||
return this._BatchNo;
|
||||
}
|
||||
set
|
||||
{
|
||||
if ((this._BatchNo != value))
|
||||
{
|
||||
this.OnBatchNoChanging(value);
|
||||
this.SendPropertyChanging();
|
||||
this._BatchNo = value;
|
||||
this.SendPropertyChanged("BatchNo");
|
||||
this.OnBatchNoChanged();
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
[global::System.Data.Linq.Mapping.ColumnAttribute(Name="rowId", Storage="_RowId", DbType="Int")]
|
||||
public System.Nullable<int> RowId
|
||||
{
|
||||
get
|
||||
{
|
||||
return this._RowId;
|
||||
}
|
||||
set
|
||||
{
|
||||
if ((this._RowId != value))
|
||||
{
|
||||
this.OnRowIdChanging(value);
|
||||
this.SendPropertyChanging();
|
||||
this._RowId = value;
|
||||
this.SendPropertyChanged("RowId");
|
||||
this.OnRowIdChanged();
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
[global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_TestPackageNo", DbType="NVarChar(50)")]
|
||||
public string TestPackageNo
|
||||
{
|
||||
get
|
||||
{
|
||||
return this._TestPackageNo;
|
||||
}
|
||||
set
|
||||
{
|
||||
if ((this._TestPackageNo != value))
|
||||
{
|
||||
this.OnTestPackageNoChanging(value);
|
||||
this.SendPropertyChanging();
|
||||
this._TestPackageNo = value;
|
||||
this.SendPropertyChanged("TestPackageNo");
|
||||
this.OnTestPackageNoChanged();
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
[global::System.Data.Linq.Mapping.ColumnAttribute(Name="unitCode", Storage="_UnitCode", DbType="NVarChar(50)")]
|
||||
public string UnitCode
|
||||
{
|
||||
get
|
||||
{
|
||||
return this._UnitCode;
|
||||
}
|
||||
set
|
||||
{
|
||||
if ((this._UnitCode != value))
|
||||
{
|
||||
this.OnUnitCodeChanging(value);
|
||||
this.SendPropertyChanging();
|
||||
this._UnitCode = value;
|
||||
this.SendPropertyChanged("UnitCode");
|
||||
this.OnUnitCodeChanged();
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
[global::System.Data.Linq.Mapping.ColumnAttribute(Name="installCode", Storage="_InstallCode", DbType="NVarChar(50)")]
|
||||
public string InstallCode
|
||||
{
|
||||
get
|
||||
{
|
||||
return this._InstallCode;
|
||||
}
|
||||
set
|
||||
{
|
||||
if ((this._InstallCode != value))
|
||||
{
|
||||
this.OnInstallCodeChanging(value);
|
||||
this.SendPropertyChanging();
|
||||
this._InstallCode = value;
|
||||
this.SendPropertyChanged("InstallCode");
|
||||
this.OnInstallCodeChanged();
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
[global::System.Data.Linq.Mapping.ColumnAttribute(Name="areaCode", Storage="_AreaCode", DbType="NVarChar(50)")]
|
||||
public string AreaCode
|
||||
{
|
||||
get
|
||||
{
|
||||
return this._AreaCode;
|
||||
}
|
||||
set
|
||||
{
|
||||
if ((this._AreaCode != value))
|
||||
{
|
||||
this.OnAreaCodeChanging(value);
|
||||
this.SendPropertyChanging();
|
||||
this._AreaCode = value;
|
||||
this.SendPropertyChanged("AreaCode");
|
||||
this.OnAreaCodeChanged();
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
[global::System.Data.Linq.Mapping.ColumnAttribute(Name="piplineCode", Storage="_PiplineCode", DbType="NVarChar(50)")]
|
||||
public string PiplineCode
|
||||
{
|
||||
get
|
||||
{
|
||||
return this._PiplineCode;
|
||||
}
|
||||
set
|
||||
{
|
||||
if ((this._PiplineCode != value))
|
||||
{
|
||||
this.OnPiplineCodeChanging(value);
|
||||
this.SendPropertyChanging();
|
||||
this._PiplineCode = value;
|
||||
this.SendPropertyChanged("PiplineCode");
|
||||
this.OnPiplineCodeChanged();
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
[global::System.Data.Linq.Mapping.ColumnAttribute(Name="isAll", Storage="_IsAll", DbType="NVarChar(50)")]
|
||||
public string IsAll
|
||||
{
|
||||
get
|
||||
{
|
||||
return this._IsAll;
|
||||
}
|
||||
set
|
||||
{
|
||||
if ((this._IsAll != value))
|
||||
{
|
||||
this.OnIsAllChanging(value);
|
||||
this.SendPropertyChanging();
|
||||
this._IsAll = value;
|
||||
this.SendPropertyChanged("IsAll");
|
||||
this.OnIsAllChanged();
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
[global::System.Data.Linq.Mapping.ColumnAttribute(Name="jointCode", Storage="_JointCode", DbType="NVarChar(MAX)", UpdateCheck=UpdateCheck.Never)]
|
||||
public string JointCode
|
||||
{
|
||||
get
|
||||
{
|
||||
return this._JointCode;
|
||||
}
|
||||
set
|
||||
{
|
||||
if ((this._JointCode != value))
|
||||
{
|
||||
this.OnJointCodeChanging(value);
|
||||
this.SendPropertyChanging();
|
||||
this._JointCode = value;
|
||||
this.SendPropertyChanged("JointCode");
|
||||
this.OnJointCodeChanged();
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
[global::System.Data.Linq.Mapping.ColumnAttribute(Name="projectId", Storage="_ProjectId", DbType="NVarChar(50) NOT NULL", CanBeNull=false)]
|
||||
public string ProjectId
|
||||
{
|
||||
get
|
||||
{
|
||||
return this._ProjectId;
|
||||
}
|
||||
set
|
||||
{
|
||||
if ((this._ProjectId != value))
|
||||
{
|
||||
this.OnProjectIdChanging(value);
|
||||
this.SendPropertyChanging();
|
||||
this._ProjectId = value;
|
||||
this.SendPropertyChanged("ProjectId");
|
||||
this.OnProjectIdChanged();
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
[global::System.Data.Linq.Mapping.ColumnAttribute(Name="unitId", Storage="_UnitId", DbType="NVarChar(50) NOT NULL", CanBeNull=false)]
|
||||
public string UnitId
|
||||
{
|
||||
get
|
||||
{
|
||||
return this._UnitId;
|
||||
}
|
||||
set
|
||||
{
|
||||
if ((this._UnitId != value))
|
||||
{
|
||||
this.OnUnitIdChanging(value);
|
||||
this.SendPropertyChanging();
|
||||
this._UnitId = value;
|
||||
this.SendPropertyChanged("UnitId");
|
||||
this.OnUnitIdChanged();
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
[global::System.Data.Linq.Mapping.ColumnAttribute(Name="installId", Storage="_InstallId", DbType="NVarChar(50) NOT NULL", CanBeNull=false)]
|
||||
public string InstallId
|
||||
{
|
||||
get
|
||||
{
|
||||
return this._InstallId;
|
||||
}
|
||||
set
|
||||
{
|
||||
if ((this._InstallId != value))
|
||||
{
|
||||
this.OnInstallIdChanging(value);
|
||||
this.SendPropertyChanging();
|
||||
this._InstallId = value;
|
||||
this.SendPropertyChanged("InstallId");
|
||||
this.OnInstallIdChanged();
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
[global::System.Data.Linq.Mapping.ColumnAttribute(Name="workAreaId", Storage="_WorkAreaId", DbType="NVarChar(50) NOT NULL", CanBeNull=false)]
|
||||
public string WorkAreaId
|
||||
{
|
||||
get
|
||||
{
|
||||
return this._WorkAreaId;
|
||||
}
|
||||
set
|
||||
{
|
||||
if ((this._WorkAreaId != value))
|
||||
{
|
||||
this.OnWorkAreaIdChanging(value);
|
||||
this.SendPropertyChanging();
|
||||
this._WorkAreaId = value;
|
||||
this.SendPropertyChanged("WorkAreaId");
|
||||
this.OnWorkAreaIdChanged();
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
[global::System.Data.Linq.Mapping.ColumnAttribute(Name="pipelineId", Storage="_PipelineId", DbType="NVarChar(50) NOT NULL", CanBeNull=false)]
|
||||
public string PipelineId
|
||||
{
|
||||
get
|
||||
{
|
||||
return this._PipelineId;
|
||||
}
|
||||
set
|
||||
{
|
||||
if ((this._PipelineId != value))
|
||||
{
|
||||
this.OnPipelineIdChanging(value);
|
||||
this.SendPropertyChanging();
|
||||
this._PipelineId = value;
|
||||
this.SendPropertyChanged("PipelineId");
|
||||
this.OnPipelineIdChanged();
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
[global::System.Data.Linq.Mapping.ColumnAttribute(Name="remark", Storage="_Remark", DbType="NVarChar(MAX)", UpdateCheck=UpdateCheck.Never)]
|
||||
public string Remark
|
||||
{
|
||||
get
|
||||
{
|
||||
return this._Remark;
|
||||
}
|
||||
set
|
||||
{
|
||||
if ((this._Remark != value))
|
||||
{
|
||||
this.OnRemarkChanging(value);
|
||||
this.SendPropertyChanging();
|
||||
this._Remark = value;
|
||||
this.SendPropertyChanged("Remark");
|
||||
this.OnRemarkChanged();
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
[global::System.Data.Linq.Mapping.ColumnAttribute(Name="createdTime", Storage="_CreatedTime", DbType="DateTime")]
|
||||
public System.Nullable<System.DateTime> CreatedTime
|
||||
{
|
||||
get
|
||||
{
|
||||
return this._CreatedTime;
|
||||
}
|
||||
set
|
||||
{
|
||||
if ((this._CreatedTime != value))
|
||||
{
|
||||
this.OnCreatedTimeChanging(value);
|
||||
this.SendPropertyChanging();
|
||||
this._CreatedTime = value;
|
||||
this.SendPropertyChanged("CreatedTime");
|
||||
this.OnCreatedTimeChanged();
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
public event PropertyChangingEventHandler PropertyChanging;
|
||||
|
||||
public event PropertyChangedEventHandler PropertyChanged;
|
||||
|
||||
protected virtual void SendPropertyChanging()
|
||||
{
|
||||
if ((this.PropertyChanging != null))
|
||||
{
|
||||
this.PropertyChanging(this, emptyChangingEventArgs);
|
||||
}
|
||||
}
|
||||
|
||||
protected virtual void SendPropertyChanged(String propertyName)
|
||||
{
|
||||
if ((this.PropertyChanged != null))
|
||||
{
|
||||
this.PropertyChanged(this, new PropertyChangedEventArgs(propertyName));
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
[global::System.Data.Linq.Mapping.TableAttribute(Name="dbo.Repair_RepairRecord")]
|
||||
public partial class Repair_RepairRecord : INotifyPropertyChanging, INotifyPropertyChanged
|
||||
{
|
||||
|
@ -35503,6 +35956,8 @@ namespace Model
|
|||
|
||||
private System.Nullable<bool> _IsCompletedPoint;
|
||||
|
||||
private string _TrustBatchItemId;
|
||||
|
||||
private string _JLAudit;
|
||||
|
||||
private string _GLGSAudit;
|
||||
|
@ -36029,6 +36484,22 @@ namespace Model
|
|||
}
|
||||
}
|
||||
|
||||
[global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_TrustBatchItemId", DbType="NVarChar(50)")]
|
||||
public string TrustBatchItemId
|
||||
{
|
||||
get
|
||||
{
|
||||
return this._TrustBatchItemId;
|
||||
}
|
||||
set
|
||||
{
|
||||
if ((this._TrustBatchItemId != value))
|
||||
{
|
||||
this._TrustBatchItemId = value;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
[global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_JLAudit", DbType="NVarChar(20)")]
|
||||
public string JLAudit
|
||||
{
|
||||
|
@ -38675,6 +39146,8 @@ namespace Model
|
|||
|
||||
private string _ProjectId;
|
||||
|
||||
private System.Nullable<bool> _IsPMI;
|
||||
|
||||
private string _PipelineCode;
|
||||
|
||||
private string _PipelineId;
|
||||
|
@ -38805,6 +39278,22 @@ namespace Model
|
|||
}
|
||||
}
|
||||
|
||||
[global::System.Data.Linq.Mapping.ColumnAttribute(Name="isPMI", Storage="_IsPMI", DbType="Bit")]
|
||||
public System.Nullable<bool> IsPMI
|
||||
{
|
||||
get
|
||||
{
|
||||
return this._IsPMI;
|
||||
}
|
||||
set
|
||||
{
|
||||
if ((this._IsPMI != value))
|
||||
{
|
||||
this._IsPMI = value;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
[global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_PipelineCode", DbType="NVarChar(100)")]
|
||||
public string PipelineCode
|
||||
{
|
||||
|
@ -40813,8 +41302,6 @@ namespace Model
|
|||
|
||||
private string _PipingClassCode;
|
||||
|
||||
private string _PIPClassCode;
|
||||
|
||||
private string _WeldingDate;
|
||||
|
||||
private System.Nullable<bool> _IsCancel;
|
||||
|
@ -40829,6 +41316,8 @@ namespace Model
|
|||
|
||||
private string _DetectionType;
|
||||
|
||||
private string _PIPClassCode;
|
||||
|
||||
private string _PageNum;
|
||||
|
||||
public View_Pipeline_WeldJoint()
|
||||
|
@ -41923,22 +42412,6 @@ namespace Model
|
|||
}
|
||||
}
|
||||
|
||||
[global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_PIPClassCode", DbType="NVarChar(50)")]
|
||||
public string PIPClassCode
|
||||
{
|
||||
get
|
||||
{
|
||||
return this._PIPClassCode;
|
||||
}
|
||||
set
|
||||
{
|
||||
if ((this._PIPClassCode != value))
|
||||
{
|
||||
this._PIPClassCode = value;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
[global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_WeldingDate", DbType="VarChar(100)")]
|
||||
public string WeldingDate
|
||||
{
|
||||
|
@ -42051,6 +42524,22 @@ namespace Model
|
|||
}
|
||||
}
|
||||
|
||||
[global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_PIPClassCode", DbType="NVarChar(50)")]
|
||||
public string PIPClassCode
|
||||
{
|
||||
get
|
||||
{
|
||||
return this._PIPClassCode;
|
||||
}
|
||||
set
|
||||
{
|
||||
if ((this._PIPClassCode != value))
|
||||
{
|
||||
this._PIPClassCode = value;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
[global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_PageNum", DbType="NVarChar(10)")]
|
||||
public string PageNum
|
||||
{
|
||||
|
@ -46614,7 +47103,7 @@ namespace Model
|
|||
}
|
||||
}
|
||||
|
||||
[global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_WelderIds", DbType="NVarChar(MAX)", UpdateCheck=UpdateCheck.Never)]
|
||||
[global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_WelderIds", DbType="VarChar(1000)")]
|
||||
public string WelderIds
|
||||
{
|
||||
get
|
||||
|
|
BIN
HJGLPackFile.rar
BIN
HJGLPackFile.rar
Binary file not shown.
|
@ -1,312 +0,0 @@
|
|||
-- 管线焊工 增加是否 PMI处理
|
||||
alter table Pipeline_WeldJoint add isPMI bit NULL
|
||||
GO
|
||||
update Pipeline_WeldJoint set isPMI=0
|
||||
GO
|
||||
|
||||
ALTER VIEW [dbo].[View_Pipeline_WeldJoint]
|
||||
AS
|
||||
/************焊口信息视图*****************/
|
||||
SELECT WeldJoint.WeldJointId,
|
||||
WeldJoint.ProjectId,
|
||||
WeldJoint.PipelineId,
|
||||
WeldJoint.WeldJointCode,
|
||||
dbo.Fun_GetParseInt(WeldJoint.WeldJointCode) AS ConvertWeldJoint,
|
||||
WeldJoint.WeldTypeId,
|
||||
WeldJoint.Material1Id,
|
||||
WeldJoint.Material2Id,
|
||||
WeldJoint.ANSISCH,
|
||||
WeldJoint.Thickness,
|
||||
WeldJoint.Dia,
|
||||
WeldJoint.Size,
|
||||
WeldJoint.JointAttribute,
|
||||
WeldJoint.JointArea,
|
||||
WeldJoint.WeldingMethodId,
|
||||
WeldJoint.IsHotProess,
|
||||
WeldJoint.WeldingLocationId,
|
||||
WeldJoint.WeldMatId,
|
||||
WeldJoint.WeldSilkId,
|
||||
WeldJoint.GrooveTypeId,
|
||||
WeldJoint.PipeSegment,
|
||||
WeldJoint.PipeAssembly1Id,
|
||||
WeldJoint.PipeAssembly2Id,
|
||||
WeldJoint.PipeAssemblyCount,
|
||||
WeldJoint.HeartNo1,
|
||||
WeldJoint.HeartNo2,
|
||||
WeldJoint.LastTemp,
|
||||
WeldJoint.CellTemp,
|
||||
WeldJoint.PrepareTemp,
|
||||
WeldJoint.Electricity,
|
||||
WeldJoint.SystemNumber,
|
||||
WeldJoint.Remark,
|
||||
WeldJoint.DoneDin,
|
||||
WeldJoint.Voltage,
|
||||
WeldJoint.TestPackageNo,
|
||||
WeldJoint.WeldingDailyCode,
|
||||
WeldJoint.WeldingDailyId,
|
||||
WeldJoint.BackingWelderId,
|
||||
WeldJoint.CoverWelderId,
|
||||
WeldJoint.PipingClassId,
|
||||
WeldJoint.Specification,
|
||||
WeldJoint.CancelResult,
|
||||
Project.ProjectCode,
|
||||
Project.ProjectName,
|
||||
Pipeline.PipelineCode,
|
||||
Pipeline.InstallationId,
|
||||
Pipeline.UnitId,
|
||||
Pipeline.SingleNumber,
|
||||
Pipeline.WorkAreaId,
|
||||
WeldType.WeldTypeCode,
|
||||
Material1.MaterialCode AS Material1Code,
|
||||
Material2.MaterialCode AS Material2Code,
|
||||
WeldingMethod.WeldingMethodCode,
|
||||
WeldingLocation.WeldingLocationCode,
|
||||
WeldMat.ConsumablesCode AS WeldMatCode,
|
||||
--WeldSilk.ConsumablesCode AS WeldSilkCode,
|
||||
'' AS WeldSilkCode,
|
||||
GrooveType.GrooveTypeCode,
|
||||
CASE WHEN WeldJoint.WeldingDailyId IS NULL THEN '否' ELSE '是' END AS Is_hjName,
|
||||
CASE WHEN WeldJoint.IsHotProess=1 THEN '是' ELSE '否' END AS IsHotProessStr,
|
||||
Components1.ComponentsCode AS ComponentsCode1,
|
||||
Components2.ComponentsCode AS ComponentsCode2,
|
||||
BackingWelder.WelderCode AS BackingWelderCode,
|
||||
BackingWelder.WelderName AS BackingWelderName,
|
||||
CoverWelder.WelderCode AS CoverWelderCode,
|
||||
CoverWelder.WelderName AS CoverWelderName,
|
||||
(CASE WHEN CoverWelder.WelderCode IS NOT NULL AND BackingWelder.WelderCode IS NOT NULL
|
||||
THEN CoverWelder.WelderCode + '/' + BackingWelder.WelderCode
|
||||
ELSE (ISNULL(CoverWelder.WelderCode,'') + ISNULL(BackingWelder.WelderCode,'')) END) AS WelderCode, --焊工
|
||||
(CASE WHEN Material1.MaterialCode IS NOT NULL AND Material2.MaterialCode IS NOT NULL
|
||||
THEN Material1.MaterialCode + '/' + Material2.MaterialCode
|
||||
ELSE (ISNULL(Material1.MaterialCode,'') + ISNULL(Material2.MaterialCode,'')) END) AS MaterialCode, --材质
|
||||
pipingClass.PipingClassCode,pip.PIPClassCode,
|
||||
CONVERT(VARCHAR(100), WeldingDaily.WeldingDate, 23) AS WeldingDate,
|
||||
WeldJoint.IsCancel,
|
||||
WeldJoint.IsPMI,
|
||||
WeldJoint.IsGoldJoint,
|
||||
WeldJoint.WPQId,wps.WPQCode,
|
||||
WeldJoint.DetectionType,
|
||||
WeldJoint.PageNum
|
||||
FROM Pipeline_WeldJoint AS WeldJoint
|
||||
LEFT JOIN Base_Project AS Project ON Project.ProjectId=WeldJoint.ProjectId
|
||||
LEFT JOIN Pipeline_Pipeline AS Pipeline ON Pipeline.PipelineId = WeldJoint.PipelineId
|
||||
LEFT JOIN Base_WeldType AS WeldType ON WeldType.WeldTypeId=WeldJoint.WeldTypeId
|
||||
LEFT JOIN Base_Material AS Material1 ON Material1.MaterialId = WeldJoint.Material1Id
|
||||
LEFT JOIN Base_Material AS Material2 ON Material2.MaterialId = WeldJoint.Material2Id
|
||||
LEFT JOIN Base_WeldingMethod AS WeldingMethod ON WeldingMethod.WeldingMethodId=WeldJoint.WeldingMethodId
|
||||
LEFT JOIN Base_WeldingLocation AS WeldingLocation ON WeldingLocation.WeldingLocationId=WeldJoint.WeldingLocationId
|
||||
LEFT JOIN Base_Consumables AS WeldMat ON WeldMat.ConsumablesId=WeldJoint.WeldMatId
|
||||
--LEFT JOIN Base_Consumables AS WeldSilk ON WeldSilk.ConsumablesId=WeldJoint.WeldSilkId
|
||||
LEFT JOIN Base_GrooveType AS GrooveType ON GrooveType.GrooveTypeId=WeldJoint.GrooveTypeId
|
||||
LEFT JOIN Base_Components AS Components1 ON Components1.ComponentsId = WeldJoint.PipeAssembly1Id
|
||||
LEFT JOIN Base_Components AS Components2 ON Components2.ComponentsId = WeldJoint.PipeAssembly2Id
|
||||
LEFT JOIN Welder_Welder AS BackingWelder ON BackingWelder.WelderId=WeldJoint.BackingWelderId
|
||||
LEFT JOIN Welder_Welder AS CoverWelder ON CoverWelder.WelderId=WeldJoint.CoverWelderId
|
||||
LEFT JOIN Pipeline_WeldingDaily AS WeldingDaily ON WeldingDaily.WeldingDailyId=WeldJoint.WeldingDailyId
|
||||
LEFT JOIN Base_PipingClass AS pipingClass ON pipingClass.PipingClassId=WeldJoint.PipingClassId
|
||||
LEFT JOIN dbo.Base_PIPClass pip ON pip.PIPClassId = Pipeline.PIPClassId
|
||||
LEFT JOIN dbo.WPQ_WPQList wps ON wps.WPQId=WeldJoint.WPQId
|
||||
|
||||
|
||||
|
||||
GO
|
||||
|
||||
|
||||
|
||||
|
||||
ALTER PROC [dbo].[sp_rpt_JointComprehensive]
|
||||
@projectId NVARCHAR(50),
|
||||
@workAreaId NVARCHAR(50)=NULL,
|
||||
@pipelineIds NVARCHAR(MAX) = NULL
|
||||
|
||||
AS
|
||||
/**********焊口综合信息**********/
|
||||
SELECT
|
||||
weldJoint.WeldJointId,
|
||||
weldJoint.ProjectId,
|
||||
WorkArea.WorkAreaId,
|
||||
WorkArea.WorkAreaCode,
|
||||
weldJoint.SystemNumber,
|
||||
weldJoint.TestPackageNo,
|
||||
pipeline.SingleNumber,
|
||||
pipeline.PipelineCode,
|
||||
pipeline.DrawingsNum,
|
||||
pipingClass.PipingClassCode,pip.PIPClassCode,
|
||||
weldJoint.PageNum,
|
||||
weldJoint.PipeSegment,--所属管段
|
||||
weldJoint.WeldJointCode,
|
||||
weldType.WeldTypeCode,
|
||||
weldJoint.JointAttribute,
|
||||
wl.WeldingLocationCode,
|
||||
weldJoint.Dia,
|
||||
weldJoint.Thickness,--壁厚
|
||||
weldJoint.HeartNo1,
|
||||
weldJoint.HeartNo2,
|
||||
com1.ComponentsName AS PipeAssembly1,
|
||||
com2.ComponentsName AS PipeAssembly2,
|
||||
--material.MaterialCode,
|
||||
mat1.MaterialCode AS MaterialCode1,
|
||||
mat2.MaterialCode AS MaterialCode2,
|
||||
cw.WelderCode AS CoverWelderCode,
|
||||
fw.WelderCode AS BackingWelderCode,
|
||||
WeldMethod.WeldingMethodName,
|
||||
medium.MediumName,
|
||||
weldingDaily.WeldingDate,
|
||||
weldingDaily.WeldingDailyCode,
|
||||
trust.TrustBatchCode,
|
||||
--TrustBatchCode.DetectionRateCode,
|
||||
--TrustBatchCode.AcceptLevel,
|
||||
(CASE WHEN weldJoint.IsHotProess=1 THEN '是' ELSE '否' END) AS IsHotProess,
|
||||
null as TrustBatchCode,
|
||||
null as DetectionRateCode,
|
||||
null as AcceptLevel,
|
||||
nde.NDEDate AS CHT_CHECKDATE,
|
||||
ndeItem.NDEReportNo,
|
||||
CAST(CAST(ISNULL(weldJoint.Size,0) AS REAL) AS NVARCHAR(8)) AS JOT_Size,
|
||||
WeldMaterialMat.ConsumablesCode AS WMT_MatCode,
|
||||
WeldMaterialMat.ConsumablesName AS WMT_Matname,
|
||||
weldJoint.WeldSilkId,
|
||||
--WeldMaterialSilk.ConsumablesCode AS hsCode,
|
||||
--WeldMaterialSilk.ConsumablesName AS hsname,
|
||||
--WeldMaterialSilk.UserFlux,
|
||||
weldJoint.Specification,
|
||||
wps.WPQCode,ndttype.DetectionTypeCode,NULL AS HotReportCode,
|
||||
(CASE WHEN (PointBatchItem.PointState='1' OR PointBatchItem.PointState='2')
|
||||
THEN (CASE WHEN PointBatchItem.IsWelderFirst=1 THEN '是首三口' ELSE '是' END) ELSE '否' END) AS if_dk
|
||||
FROM Pipeline_WeldJoint AS weldJoint
|
||||
LEFT JOIN Pipeline_Pipeline AS pipeline ON pipeline.PipelineId = weldJoint.PipelineId
|
||||
LEFT JOIN Project_WorkArea AS WorkArea ON WorkArea.WorkAreaId = pipeline.WorkAreaId
|
||||
LEFT JOIN Base_Material AS mat1 ON mat1.MaterialId = weldJoint.Material1Id
|
||||
LEFT JOIN Base_Material AS mat2 ON mat2.MaterialId = weldJoint.Material2Id
|
||||
LEFT JOIN Base_WeldingMethod AS WeldMethod ON WeldMethod.WeldingMethodId = weldJoint.WeldingMethodId
|
||||
LEFT JOIN dbo.Base_WeldType weldType ON weldType.WeldTypeId = weldJoint.WeldTypeId
|
||||
LEFT JOIN dbo.Base_WeldingLocation wl ON wl.WeldingLocationId = weldJoint.WeldingLocationId
|
||||
LEFT JOIN Base_Medium AS medium ON medium.MediumId = pipeline.MediumId
|
||||
LEFT JOIN Base_Components com1 ON com1.ComponentsId=weldJoint.PipeAssembly1Id
|
||||
LEFT JOIN Base_Components com2 ON com2.ComponentsId=weldJoint.PipeAssembly2Id
|
||||
LEFT JOIN Base_PipingClass AS pipingClass ON pipingClass.PipingClassId=WeldJoint.PipingClassId
|
||||
LEFT JOIN dbo.Base_PIPClass pip ON pip.PIPClassId = Pipeline.PIPClassId
|
||||
LEFT JOIN Pipeline_WeldingDaily AS weldingDaily ON weldingDaily.WeldingDailyId = weldJoint.WeldingDailyId
|
||||
LEFT JOIN dbo.WPQ_WPQList wps ON wps.WPQId = weldJoint.WPQId
|
||||
left join Welder_Welder AS fw on weldJoint.BackingWelderId = fw.WelderId
|
||||
left join Welder_Welder AS cw on weldJoint.CoverWelderId = cw.WelderId
|
||||
LEFT JOIN Base_Consumables AS WeldMaterialMat ON WeldMaterialMat.ConsumablesId =weldJoint.WeldMatId
|
||||
--LEFT JOIN Base_Consumables AS WeldMaterialSilk ON WeldMaterialSilk.ConsumablesId =weldJoint.WeldSilkId
|
||||
LEFT JOIN Batch_PointBatchItem AS PointBatchItem ON PointBatchItem.WeldJointId =weldJoint.WeldJointId
|
||||
LEFT JOIN dbo.Batch_PointBatch point ON point.PointBatchId = PointBatchItem.PointBatchId
|
||||
LEFT JOIN dbo.Base_DetectionType ndttype ON ndttype.DetectionTypeId = point.DetectionTypeId
|
||||
LEFT JOIN dbo.Batch_BatchTrustItem trustItem ON trustItem.PointBatchItemId = PointBatchItem.PointBatchItemId
|
||||
LEFT JOIN dbo.Batch_BatchTrust trust ON trust.TrustBatchId = trustItem.TrustBatchId
|
||||
LEFT JOIN dbo.Batch_NDEItem ndeItem ON ndeItem.TrustBatchItemId = trustItem.TrustBatchItemId
|
||||
LEFT JOIN dbo.Batch_NDE nde ON nde.NDEID = ndeItem.NDEID
|
||||
|
||||
WHERE weldJoint.ProjectId=@projectId
|
||||
AND(pipeline.WorkAreaId=@workAreaId OR @workAreaId IS NULL)
|
||||
AND (CHARINDEX(weldJoint.PipelineId,@pipelineIds)>0 or @pipelineIds IS NULl)
|
||||
--AND(pipeline.PipelineCode=@pipelineCode OR @pipelineCode IS NULl)
|
||||
|
||||
GO
|
||||
|
||||
UPDATE dbo.Template_Files SET title=REPLACE(title,cast(sortindex as nvarchar(50))+'-','')
|
||||
GO
|
||||
|
||||
UPDATE dbo.Template_Files SET SortIndex=SortIndex+1 where SortIndex>24
|
||||
GO
|
||||
|
||||
INSERT INTO [dbo].[Template_Files]([id],[title],[filePath],[SortIndex])
|
||||
VALUES('95125974-3DD4-4E16-B4F0-A9D9C9A1406D','管道焊接接头PMI检测比例确认表','',25)
|
||||
GO
|
||||
|
||||
-- PMI处理委托
|
||||
create table PMI_Delegation
|
||||
(
|
||||
Id nvarchar(50) not null primary key,
|
||||
DelegationNo nvarchar(50) not null,
|
||||
DelegationDate datetime,
|
||||
ProjectId nvarchar(50) not null,
|
||||
InstallationId nvarchar(50),
|
||||
UnitId nvarchar(50),
|
||||
DetectionStandard nvarchar(50),
|
||||
Tabler nvarchar(50),
|
||||
Remark nvarchar(255),
|
||||
CreatedTime datetime default getdate()
|
||||
)
|
||||
go
|
||||
---- PMI处理委托 明细
|
||||
create table PMI_DelegationDetails
|
||||
(
|
||||
Id nvarchar(50) not null primary key,
|
||||
PMIId nvarchar(50) not null,
|
||||
JointId nvarchar(50) not null,
|
||||
QualityNo nvarchar(255),
|
||||
Acceptance nvarchar(255),
|
||||
Status int not null,
|
||||
CreatedTime datetime default getdate()
|
||||
)
|
||||
go
|
||||
|
||||
|
||||
-- 插入PMI委托菜单
|
||||
insert into Sys_Menu values('A6FB44C3-0920-4F77-862F-D814FD5E5D23','PMI检测管理','PMI detection management','',21,0,3,NUll,1)
|
||||
insert into Sys_Menu values(NEWID(),'PMI委托','PMI delegation','/WeldingProcess/PMI/PMIDelegation.aspx',1,'A6FB44C3-0920-4F77-862F-D814FD5E5D23',3,NULL,1)
|
||||
insert into Sys_Menu values(NEWID(),'PMI检测录入','PMI detection entry','/WeldingProcess/PMI/PMIDetectionEntry.aspx',2,'A6FB44C3-0920-4F77-862F-D814FD5E5D23',3,NULL,1)
|
||||
GO
|
||||
|
||||
|
||||
/*******PMI委托明细视图***********/
|
||||
|
||||
USE [HJGLDB_ZJBSF]
|
||||
GO
|
||||
|
||||
/****** Object: View [dbo].[View_PMI_DelegationDetails] Script Date: 2024-5-13 9:06:44 ******/
|
||||
SET ANSI_NULLS ON
|
||||
GO
|
||||
|
||||
SET QUOTED_IDENTIFIER ON
|
||||
GO
|
||||
|
||||
|
||||
|
||||
|
||||
-- 增加报告编号
|
||||
ALTER TABLE dbo.PMI_DelegationDetails ADD reportNo NVARCHAR(50)
|
||||
-- 增加报告日期
|
||||
ALTER TABLE dbo.PMI_DelegationDetails ADD reportTime datetime
|
||||
GO
|
||||
|
||||
|
||||
ALTER VIEW [dbo].[View_PMI_DelegationDetails]
|
||||
AS
|
||||
/********PMI处理明细********/
|
||||
SELECT
|
||||
TrustItem.Id,
|
||||
TrustItem.Acceptance,
|
||||
TrustItem.checkTime,
|
||||
TrustItem.reportTime,
|
||||
TrustItem.JointId as WeldJointId,
|
||||
TrustItem.status,
|
||||
TrustItem.QualityNo,
|
||||
TrustItem.PMIId,
|
||||
Trust.ProjectId,
|
||||
Trust.DelegationNo,
|
||||
Trust.DelegationDate,
|
||||
ISNULL(TrustItem.reportNo,Trust.DelegationNo) as reportNo,
|
||||
WeldJoint.WeldJointCode,
|
||||
Pipeline.PipelineCode,
|
||||
WeldJoint.Specification,
|
||||
Material.MaterialCode,
|
||||
Pipeline.WorkAreaId
|
||||
FROM PMI_DelegationDetails AS TrustItem
|
||||
LEFT JOIN PMI_Delegation AS Trust ON Trust.Id=TrustItem.PMIId
|
||||
LEFT JOIN Pipeline_WeldJoint AS WeldJoint ON WeldJoint.WeldJointId=TrustItem.JointId
|
||||
LEFT JOIN Pipeline_Pipeline AS Pipeline ON Pipeline.PipelineId=WeldJoint.PipelineId
|
||||
LEFT JOIN Base_Material AS Material ON Material.MaterialId=WeldJoint.Material1Id
|
||||
GO
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
|
@ -1,193 +0,0 @@
|
|||
USE [HJGLDB_ZJBSF]
|
||||
GO
|
||||
/****** Object: Table [dbo].[Email_Params] Script Date: 2024-5-17 15:35:13 ******/
|
||||
SET ANSI_NULLS ON
|
||||
GO
|
||||
SET QUOTED_IDENTIFIER ON
|
||||
GO
|
||||
CREATE TABLE [dbo].[Email_Params](
|
||||
[ID] [varchar](50) NOT NULL,
|
||||
[MailClassName] [varchar](100) NULL,
|
||||
[MailClassID] [varchar](50) NOT NULL,
|
||||
[CreateName] [varchar](100) NOT NULL,
|
||||
[CreateTime] [datetime] NOT NULL,
|
||||
[UpdateName] [nchar](10) NULL,
|
||||
[UpdateTime] [datetime] NULL,
|
||||
CONSTRAINT [PK_Email_Params] PRIMARY KEY CLUSTERED
|
||||
(
|
||||
[ID] ASC
|
||||
)WITH (PAD_INDEX = OFF, STATISTICS_NORECOMPUTE = OFF, IGNORE_DUP_KEY = OFF, ALLOW_ROW_LOCKS = ON, ALLOW_PAGE_LOCKS = ON) ON [PRIMARY]
|
||||
) ON [PRIMARY]
|
||||
GO
|
||||
/****** Object: Table [dbo].[Email_Pop] Script Date: 2024-5-17 15:35:13 ******/
|
||||
SET ANSI_NULLS ON
|
||||
GO
|
||||
SET QUOTED_IDENTIFIER ON
|
||||
GO
|
||||
CREATE TABLE [dbo].[Email_Pop](
|
||||
[EmailID] [varchar](50) NOT NULL,
|
||||
[EmailFwq] [varchar](50) NULL,
|
||||
[EmailDk] [varchar](50) NULL,
|
||||
[EmailYx] [varchar](50) NULL,
|
||||
[EmailUsername] [varchar](50) NULL,
|
||||
[EmailPass] [varchar](50) NULL,
|
||||
[CreateTime] [varchar](50) NULL,
|
||||
[CreateName] [varchar](50) NULL,
|
||||
[UpdateTime] [varchar](50) NULL,
|
||||
[UpdateName] [varchar](50) NULL,
|
||||
CONSTRAINT [PK_Email_Pop] PRIMARY KEY CLUSTERED
|
||||
(
|
||||
[EmailID] ASC
|
||||
)WITH (PAD_INDEX = OFF, STATISTICS_NORECOMPUTE = OFF, IGNORE_DUP_KEY = OFF, ALLOW_ROW_LOCKS = ON, ALLOW_PAGE_LOCKS = ON) ON [PRIMARY]
|
||||
) ON [PRIMARY]
|
||||
GO
|
||||
/****** Object: Table [dbo].[Email_SendLog] Script Date: 2024-5-17 15:35:13 ******/
|
||||
SET ANSI_NULLS ON
|
||||
GO
|
||||
SET QUOTED_IDENTIFIER ON
|
||||
GO
|
||||
CREATE TABLE [dbo].[Email_SendLog](
|
||||
[EmailId] [varchar](50) NOT NULL,
|
||||
[EmailTile] [varchar](255) NULL,
|
||||
[EmailContent] [text] NULL,
|
||||
[EmailURL] [varchar](50) NULL,
|
||||
[EmailName] [varchar](50) NULL,
|
||||
[EmailStatus] [varchar](10) NULL,
|
||||
[CreateTime] [datetime] NULL,
|
||||
[CreateName] [varchar](50) NULL,
|
||||
CONSTRAINT [PK_Email_Send] PRIMARY KEY CLUSTERED
|
||||
(
|
||||
[EmailId] ASC
|
||||
)WITH (PAD_INDEX = OFF, STATISTICS_NORECOMPUTE = OFF, IGNORE_DUP_KEY = OFF, ALLOW_ROW_LOCKS = ON, ALLOW_PAGE_LOCKS = ON) ON [PRIMARY]
|
||||
) ON [PRIMARY] TEXTIMAGE_ON [PRIMARY]
|
||||
GO
|
||||
/****** Object: Table [dbo].[Email_SendTemplate] Script Date: 2024-5-17 15:35:13 ******/
|
||||
SET ANSI_NULLS ON
|
||||
GO
|
||||
SET QUOTED_IDENTIFIER ON
|
||||
GO
|
||||
CREATE TABLE [dbo].[Email_SendTemplate](
|
||||
[EmailId] [varchar](50) NOT NULL,
|
||||
[EmailParamsID] [varchar](50) NOT NULL,
|
||||
[EailTiaoJian] [varchar](500) NULL,
|
||||
[EmailUserYN] [int] NULL,
|
||||
[EmailTitle] [varchar](500) NULL,
|
||||
[EmailContext] [text] NULL,
|
||||
[CreateName] [varchar](500) NULL,
|
||||
[CreateTime] [datetime] NULL,
|
||||
[UpdateName] [varchar](500) NULL,
|
||||
[UpdateTime] [datetime] NULL,
|
||||
[EmailDesc] [varchar](500) NULL,
|
||||
CONSTRAINT [PK_Email_SendTemplate] PRIMARY KEY CLUSTERED
|
||||
(
|
||||
[EmailId] ASC
|
||||
)WITH (PAD_INDEX = OFF, STATISTICS_NORECOMPUTE = OFF, IGNORE_DUP_KEY = OFF, ALLOW_ROW_LOCKS = ON, ALLOW_PAGE_LOCKS = ON) ON [PRIMARY]
|
||||
) ON [PRIMARY] TEXTIMAGE_ON [PRIMARY]
|
||||
GO
|
||||
/****** Object: Table [dbo].[Email_ToPeople] Script Date: 2024-5-17 15:35:13 ******/
|
||||
SET ANSI_NULLS ON
|
||||
GO
|
||||
SET QUOTED_IDENTIFIER ON
|
||||
GO
|
||||
CREATE TABLE [dbo].[Email_ToPeople](
|
||||
[EmID] [varchar](50) NOT NULL,
|
||||
[EmtempID] [varchar](50) NOT NULL,
|
||||
[EmuserID] [varchar](50) NULL,
|
||||
[EmuserName] [varchar](50) NULL,
|
||||
[EmuaerEmailAddress] [varchar](100) NULL,
|
||||
[EMPeopleType] [varchar](5) NULL,
|
||||
CONSTRAINT [PK_Email_ToPeople] PRIMARY KEY CLUSTERED
|
||||
(
|
||||
[EmID] ASC
|
||||
)WITH (PAD_INDEX = OFF, STATISTICS_NORECOMPUTE = OFF, IGNORE_DUP_KEY = OFF, ALLOW_ROW_LOCKS = ON, ALLOW_PAGE_LOCKS = ON) ON [PRIMARY]
|
||||
) ON [PRIMARY]
|
||||
GO
|
||||
INSERT [dbo].[Email_Params] ([ID], [MailClassName], [MailClassID], [CreateName], [CreateTime], [UpdateName], [UpdateTime]) VALUES (N'1a800170-48e2-4b41-a2af-20258aa74907', N'监理审核', N'监理', N'管理员', CAST(N'2024-05-16T14:53:01.747' AS DateTime), N'管理员 ', CAST(N'2024-05-16T17:05:42.987' AS DateTime))
|
||||
GO
|
||||
INSERT [dbo].[Email_Params] ([ID], [MailClassName], [MailClassID], [CreateName], [CreateTime], [UpdateName], [UpdateTime]) VALUES (N'859e5eaf-6a9e-46a8-8eb1-f3ba61f3be79', N'管理公司审核', N'管理公司', N'管理员', CAST(N'2024-05-14T17:39:53.640' AS DateTime), N'管理员 ', CAST(N'2024-05-16T17:05:48.370' AS DateTime))
|
||||
GO
|
||||
INSERT [dbo].[Email_Pop] ([EmailID], [EmailFwq], [EmailDk], [EmailYx], [EmailUsername], [EmailPass], [CreateTime], [CreateName], [UpdateTime], [UpdateName]) VALUES (N'7EC5E991-B7A0-495A-90ED-2BE15370C959', N'smtp.163.com', N'25', N'Scs13965090560@163.com', N'scs', N'CLXGLMKBGQBEXSSW', N'2024-5-16 14:46:25', N'管理员', NULL, NULL)
|
||||
GO
|
||||
INSERT [dbo].[Email_SendLog] ([EmailId], [EmailTile], [EmailContent], [EmailURL], [EmailName], [EmailStatus], [CreateTime], [CreateName]) VALUES (N'3cfa3bbf-e73a-494b-bb60-f682b52dad84', N'监理—点口未审核的焊口', N'<p style="text-wrap: wrap;">尊敬的各位领导,</p><p style="text-wrap: wrap;"> </p><p style="text-wrap: wrap;"> 您有<span style="color:#ff0000">2105</span>条点口记录待审核!</p><p><br/></p>', N'jackchenyang@sina.cn', N'jackchenyang@sina.cn', N'发送成功', CAST(N'2024-05-17T14:32:14.573' AS DateTime), N'sys')
|
||||
GO
|
||||
INSERT [dbo].[Email_SendLog] ([EmailId], [EmailTile], [EmailContent], [EmailURL], [EmailName], [EmailStatus], [CreateTime], [CreateName]) VALUES (N'3f61427f-2b6f-42cb-8028-27726807f8e8', N'测试再发送一个邮件', N'这是一个邮件内容,请查收!', N'408299694@qq.com', N'408299694@qq.com', N'发送成功', CAST(N'2024-05-16T14:51:03.117' AS DateTime), N'sys')
|
||||
GO
|
||||
INSERT [dbo].[Email_SendLog] ([EmailId], [EmailTile], [EmailContent], [EmailURL], [EmailName], [EmailStatus], [CreateTime], [CreateName]) VALUES (N'632f4c12-08c6-4f19-88a1-5ed760486ae0', N'测试发邮件', N'这个是一个测试的发送邮件内容。。。。', N'874821510@qq.com', N'874821510@qq.com', N'发送失败', CAST(N'2024-05-16T14:45:45.350' AS DateTime), N'sys')
|
||||
GO
|
||||
INSERT [dbo].[Email_SendLog] ([EmailId], [EmailTile], [EmailContent], [EmailURL], [EmailName], [EmailStatus], [CreateTime], [CreateName]) VALUES (N'6488713b-86f4-4dc2-989c-32152fe53727', N'管理公司—点口未审核的焊口', N'<p style="text-wrap: wrap;">尊敬的各位领导,</p><p style="text-wrap: wrap;"> </p><p style="text-wrap: wrap;"> 您有<span style="color:#ff0000">2176</span>条点口记录待审核!</p><p><br style="text-wrap: wrap;"/></p><p><br/></p>', N'jackchenyang@sina.cn', N'jackchenyang@sina.cn', N'发送成功', CAST(N'2024-05-17T14:32:16.627' AS DateTime), N'sys')
|
||||
GO
|
||||
INSERT [dbo].[Email_SendLog] ([EmailId], [EmailTile], [EmailContent], [EmailURL], [EmailName], [EmailStatus], [CreateTime], [CreateName]) VALUES (N'709cb7de-0564-4ab9-84e6-0b0b2f6732d8', N'测试再发送一个邮件', N'这是一个邮件内容,请查收!', N'874821510@qq.com', N'874821510@qq.com', N'发送成功', CAST(N'2024-05-16T14:51:03.113' AS DateTime), N'sys')
|
||||
GO
|
||||
INSERT [dbo].[Email_SendLog] ([EmailId], [EmailTile], [EmailContent], [EmailURL], [EmailName], [EmailStatus], [CreateTime], [CreateName]) VALUES (N'9857506c-83a4-4b79-b09a-d6e061376f17', N'点口未审核的焊口', N'<p style="text-wrap: wrap;">尊敬的各位领导,</p><p style="text-wrap: wrap;"> </p><p style="text-wrap: wrap;"> 您有<span style="color:#ff0000">2176</span>条点口记录待审核!</p><p><br style="text-wrap: wrap;"/></p><p><br/></p>', N'jackchenyang@sina.cn', N'jackchenyang@sina.cn', N'发送成功', CAST(N'2024-05-17T14:26:32.310' AS DateTime), N'sys')
|
||||
GO
|
||||
INSERT [dbo].[Email_SendLog] ([EmailId], [EmailTile], [EmailContent], [EmailURL], [EmailName], [EmailStatus], [CreateTime], [CreateName]) VALUES (N'd349818c-9434-4ff9-ab73-c868c81de870', N'点口未审核的焊口', N'<p style="text-wrap: wrap;">尊敬的各位领导,</p><p style="text-wrap: wrap;"> </p><p style="text-wrap: wrap;"> 您有<span style="color:#ff0000">2105</span>条点口记录待审核!</p><p><br/></p>', N'jackchenyang@sina.cn', N'jackchenyang@sina.cn', N'发送成功', CAST(N'2024-05-17T14:26:10.880' AS DateTime), N'sys')
|
||||
GO
|
||||
INSERT [dbo].[Email_SendLog] ([EmailId], [EmailTile], [EmailContent], [EmailURL], [EmailName], [EmailStatus], [CreateTime], [CreateName]) VALUES (N'd8740146-2ce5-4582-baa0-45063e967f02', N'测试发邮件', N'这个是一个测试的发送邮件内容。。。。', N'874821510@qq.com', N'874821510@qq.com', N'发送成功', CAST(N'2024-05-16T14:46:31.487' AS DateTime), N'sys')
|
||||
GO
|
||||
INSERT [dbo].[Email_SendTemplate] ([EmailId], [EmailParamsID], [EailTiaoJian], [EmailUserYN], [EmailTitle], [EmailContext], [CreateName], [CreateTime], [UpdateName], [UpdateTime], [EmailDesc]) VALUES (N'1a605eaf-6e0a-49d2-a0db-9e1238b65e8a', N'监理', N'点口未审核的焊口', 1, N'监理点口审核', N'<p style="text-wrap: wrap;">尊敬的各位领导,</p><p style="text-wrap: wrap;"> </p><p style="text-wrap: wrap;"> 您有<span style="color:#ff0000">{{totalCount}}</span>条点口记录待审核!</p><p><br/></p>', N'管理员', CAST(N'2024-05-16T17:04:30.020' AS DateTime), N'管理员', CAST(N'2024-05-17T14:16:54.980' AS DateTime), NULL)
|
||||
GO
|
||||
INSERT [dbo].[Email_SendTemplate] ([EmailId], [EmailParamsID], [EailTiaoJian], [EmailUserYN], [EmailTitle], [EmailContext], [CreateName], [CreateTime], [UpdateName], [UpdateTime], [EmailDesc]) VALUES (N'ad5201c3-0398-4316-a880-0a285e0f06fa', N'管理公司', N'点口未审核的焊口', 1, N'管理公司点口审核', N'<p style="text-wrap: wrap;">尊敬的各位领导,</p><p style="text-wrap: wrap;"> </p><p style="text-wrap: wrap;"> 您有<span style="color:#ff0000">{{totalCount}}</span>条点口记录待审核!</p><p><br style="text-wrap: wrap;"/></p><p><br/></p>', N'管理员', CAST(N'2024-05-16T14:54:15.743' AS DateTime), N'管理员', CAST(N'2024-05-17T14:16:58.267' AS DateTime), NULL)
|
||||
GO
|
||||
INSERT [dbo].[Email_ToPeople] ([EmID], [EmtempID], [EmuserID], [EmuserName], [EmuaerEmailAddress], [EMPeopleType]) VALUES (N'33e99721-b831-46f5-83b6-039be6a89050', N'1a605eaf-6e0a-49d2-a0db-9e1238b65e8a', N'29188391-731e-4645-ad09-c99c2a9fc6ce', N'李庆华', N'jackchenyang@sina.cn', N'0')
|
||||
GO
|
||||
INSERT [dbo].[Email_ToPeople] ([EmID], [EmtempID], [EmuserID], [EmuserName], [EmuaerEmailAddress], [EMPeopleType]) VALUES (N'6144c9f6-6e91-4e88-ae3a-fe9f99bc78af', N'ad5201c3-0398-4316-a880-0a285e0f06fa', N'29188391-731e-4645-ad09-c99c2a9fc6ce', N'李庆华', N'jackchenyang@sina.cn', N'0')
|
||||
GO
|
||||
INSERT [dbo].[Email_ToPeople] ([EmID], [EmtempID], [EmuserID], [EmuserName], [EmuaerEmailAddress], [EMPeopleType]) VALUES (N'd78fa8fb-b675-4264-8040-8a0cf3d9649d', N'1a605eaf-6e0a-49d2-a0db-9e1238b65e8a', N'18485804-501b-4123-9e9a-1afb3c53aed0', N'陈阳', N'874821510@qq.com', N'1')
|
||||
GO
|
||||
INSERT [dbo].[Email_ToPeople] ([EmID], [EmtempID], [EmuserID], [EmuserName], [EmuaerEmailAddress], [EMPeopleType]) VALUES (N'ff5fefa1-2ab8-4643-b3f7-b38fd049597a', N'ad5201c3-0398-4316-a880-0a285e0f06fa', N'18485804-501b-4123-9e9a-1afb3c53aed0', N'陈阳', N'874821510@qq.com', N'1')
|
||||
GO
|
||||
SET ANSI_PADDING ON
|
||||
GO
|
||||
/****** Object: Index [IX_Email_Params] Script Date: 2024-5-17 15:35:13 ******/
|
||||
ALTER TABLE [dbo].[Email_Params] ADD CONSTRAINT [IX_Email_Params] UNIQUE NONCLUSTERED
|
||||
(
|
||||
[MailClassID] ASC
|
||||
)WITH (PAD_INDEX = OFF, STATISTICS_NORECOMPUTE = OFF, SORT_IN_TEMPDB = OFF, IGNORE_DUP_KEY = OFF, ONLINE = OFF, ALLOW_ROW_LOCKS = ON, ALLOW_PAGE_LOCKS = ON) ON [PRIMARY]
|
||||
GO
|
||||
SET ANSI_PADDING ON
|
||||
GO
|
||||
/****** Object: Index [IX_Email_SendTemplate] Script Date: 2024-5-17 15:35:13 ******/
|
||||
ALTER TABLE [dbo].[Email_SendTemplate] ADD CONSTRAINT [IX_Email_SendTemplate] UNIQUE NONCLUSTERED
|
||||
(
|
||||
[EmailParamsID] ASC
|
||||
)WITH (PAD_INDEX = OFF, STATISTICS_NORECOMPUTE = OFF, SORT_IN_TEMPDB = OFF, IGNORE_DUP_KEY = OFF, ONLINE = OFF, ALLOW_ROW_LOCKS = ON, ALLOW_PAGE_LOCKS = ON) ON [PRIMARY]
|
||||
GO
|
||||
ALTER TABLE [dbo].[Email_Params] ADD CONSTRAINT [DF_Email_Params_CreateName] DEFAULT ('sys') FOR [CreateName]
|
||||
GO
|
||||
ALTER TABLE [dbo].[Email_Params] ADD CONSTRAINT [DF_Email_Params_CreateTime] DEFAULT (getdate()) FOR [CreateTime]
|
||||
GO
|
||||
ALTER TABLE [dbo].[Email_ToPeople] ADD CONSTRAINT [DF_Email_ToPeople_EMPeopleType] DEFAULT ((0)) FOR [EMPeopleType]
|
||||
GO
|
||||
EXEC sys.sp_addextendedproperty @name=N'MS_Description', @value=N'邮件分类名称' , @level0type=N'SCHEMA',@level0name=N'dbo', @level1type=N'TABLE',@level1name=N'Email_Params', @level2type=N'COLUMN',@level2name=N'MailClassName'
|
||||
GO
|
||||
EXEC sys.sp_addextendedproperty @name=N'MS_Description', @value=N'邮件分类ID' , @level0type=N'SCHEMA',@level0name=N'dbo', @level1type=N'TABLE',@level1name=N'Email_Params', @level2type=N'COLUMN',@level2name=N'MailClassID'
|
||||
GO
|
||||
EXEC sys.sp_addextendedproperty @name=N'MS_Description', @value=N'参数MailClassID' , @level0type=N'SCHEMA',@level0name=N'dbo', @level1type=N'TABLE',@level1name=N'Email_SendTemplate', @level2type=N'COLUMN',@level2name=N'EmailParamsID'
|
||||
GO
|
||||
EXEC sys.sp_addextendedproperty @name=N'MS_Description', @value=N'内容条件说明' , @level0type=N'SCHEMA',@level0name=N'dbo', @level1type=N'TABLE',@level1name=N'Email_SendTemplate', @level2type=N'COLUMN',@level2name=N'EailTiaoJian'
|
||||
GO
|
||||
EXEC sys.sp_addextendedproperty @name=N'MS_Description', @value=N'邮件标题' , @level0type=N'SCHEMA',@level0name=N'dbo', @level1type=N'TABLE',@level1name=N'Email_SendTemplate', @level2type=N'COLUMN',@level2name=N'EmailTitle'
|
||||
GO
|
||||
EXEC sys.sp_addextendedproperty @name=N'MS_Description', @value=N'邮件具体内容' , @level0type=N'SCHEMA',@level0name=N'dbo', @level1type=N'TABLE',@level1name=N'Email_SendTemplate', @level2type=N'COLUMN',@level2name=N'EmailContext'
|
||||
GO
|
||||
EXEC sys.sp_addextendedproperty @name=N'MS_Description', @value=N'备注' , @level0type=N'SCHEMA',@level0name=N'dbo', @level1type=N'TABLE',@level1name=N'Email_SendTemplate', @level2type=N'COLUMN',@level2name=N'EmailDesc'
|
||||
GO
|
||||
EXEC sys.sp_addextendedproperty @name=N'MS_Description', @value=N'发送人类型 0-发送人 1-抄送人' , @level0type=N'SCHEMA',@level0name=N'dbo', @level1type=N'TABLE',@level1name=N'Email_ToPeople', @level2type=N'COLUMN',@level2name=N'EMPeopleType'
|
||||
GO
|
||||
|
||||
--- 插入菜单
|
||||
INSERT [dbo].[Sys_Menu] ([MenuId], [MenuName], [MenuEnName], [Url], [SortIndex], [SuperMenu], [MenuModule], [IsAudiFlow], [IsUse]) VALUES (N'97143EDB-6A32-4BBA-9F49-E33E87912BC8', N'发送邮件', N'Send Email', N'Email_Send/Email_Send_Edit.aspx', 10, N'D05CSEAC-2854-4822-A7E9-24AD3EAF0A6E', N'2 ', NULL, 1)
|
||||
GO
|
||||
INSERT [dbo].[Sys_Menu] ([MenuId], [MenuName], [MenuEnName], [Url], [SortIndex], [SuperMenu], [MenuModule], [IsAudiFlow], [IsUse]) VALUES (N'9E9DD8E3-D91B-4FD4-B922-2F5CC23D2745', N'邮件配置', N'Send Email Pop', N'Email_Send/Email_Pop_Edit.aspx', 20, N'D05CSEAC-2854-4822-A7E9-24AD3EAF0A6E', N'2 ', NULL, 1)
|
||||
GO
|
||||
INSERT [dbo].[Sys_Menu] ([MenuId], [MenuName], [MenuEnName], [Url], [SortIndex], [SuperMenu], [MenuModule], [IsAudiFlow], [IsUse]) VALUES (N'D05CSEAC-2854-4822-A7E9-24AD3EAF0A6E', N'发送邮件', N'Send Email', N'', 60, N'0', N'2 ', NULL, 1)
|
||||
GO
|
||||
INSERT [dbo].[Sys_Menu] ([MenuId], [MenuName], [MenuEnName], [Url], [SortIndex], [SuperMenu], [MenuModule], [IsAudiFlow], [IsUse]) VALUES (N'F19A6438-C757-4BC2-ADC2-72AAF02089E5', N'邮件类型', N'Mail Parameters', N'Email_Send/Email_Params_List.aspx', 60, N'D05CSEAC-2854-4822-A7E9-24AD3EAF0A6E', N'2 ', NULL, 1)
|
||||
GO
|
||||
INSERT [dbo].[Sys_Menu] ([MenuId], [MenuName], [MenuEnName], [Url], [SortIndex], [SuperMenu], [MenuModule], [IsAudiFlow], [IsUse]) VALUES (N'06EB7C08-6F6E-433B-91A7-579BFC435A0C', N'邮件模板设置', N'Send Email Template', N'Email_Send/Email_SendTemplate_List.aspx', 40, N'D05CSEAC-2854-4822-A7E9-24AD3EAF0A6E', N'2 ', NULL, 1)
|
||||
GO
|
||||
INSERT [dbo].[Sys_Menu] ([MenuId], [MenuName], [MenuEnName], [Url], [SortIndex], [SuperMenu], [MenuModule], [IsAudiFlow], [IsUse]) VALUES (N'5941BE0C-C262-48C7-899F-F0BE5A779926', N'发送邮件日志', N'Send Email Log', N'Email_Send/Email_SendLog_List.aspx', 30, N'D05CSEAC-2854-4822-A7E9-24AD3EAF0A6E', N'2 ', NULL, 1)
|
||||
GO
|
||||
|
||||
|
||||
SELECT * FROM dbo.Sys_Menu WHERE MenuName LIKE '%邮件%'
|
|
@ -1,106 +0,0 @@
|
|||
UPDATE dbo.Batch_PointBatchItem SET PointState=NULL,PointDate=NULL,
|
||||
JLAudit=NULL,GLGSAudit=NULL,QTAudit=NULL
|
||||
WHERE PointState='1' AND
|
||||
PointBatchItemId NOT IN(SELECT PointBatchItemId FROM dbo.Batch_BatchTrustItem)
|
||||
GO
|
||||
|
||||
UPDATE dbo.Batch_PointBatchItem SET IsCompletedPoint=1
|
||||
GO
|
||||
|
||||
alter table PTP_PipelineList add WorkAreaId nvarchar(50)
|
||||
alter table PTP_PipelineList add isAll bit
|
||||
alter table PTP_PipelineList add WeldJonintCode nvarchar(max)
|
||||
GO
|
||||
|
||||
|
||||
ALTER VIEW [dbo].[View_Batch_PointBatchItem]
|
||||
AS
|
||||
/*************点口明细表*************/
|
||||
SELECT PointBatchItem.PointBatchItemId,
|
||||
PointBatchItem.PointBatchId,
|
||||
PointBatch.ProjectId,
|
||||
PointBatch.InstallationId,
|
||||
PointBatch.UnitId,
|
||||
PointBatch.PointBatchCode,
|
||||
PointBatch.DetectionTypeId,
|
||||
Pipeline.WorkAreaId,
|
||||
PointBatchItem.WeldJointId,
|
||||
PointBatchItem.PointState AS PState,
|
||||
(CASE PointBatchItem.PointState WHEN '1' THEN '点口' WHEN '2' THEN '扩透' END) AS PointState,
|
||||
--(CASE PointBatchItem.IsAudit WHEN 1 THEN '是' ELSE '否' END) AS PointIsAudit,
|
||||
--(CASE WHEN PointBatchItem.IsAudit=1 THEN '是'
|
||||
-- WHEN (PointBatchItem.IsAudit IS NULL OR PointBatchItem.IsAudit=0) AND PointBatchItem.PointState IS NOT NULL THEN '否'
|
||||
-- WHEN (PointBatchItem.IsAudit IS NULL OR PointBatchItem.IsAudit=0) AND PointBatchItem.PointState IS NULL THEN '' END) AS PointIsAudit,
|
||||
PointBatchItem.PointDate,--点口日期
|
||||
PointBatchItem.RepairDate,--返修日期
|
||||
PointBatchItem.CutDate,--切除日期
|
||||
PointBatchItem.RepairRecordId,
|
||||
PointBatchItem.IsBuildTrust,--是否委托
|
||||
WorkArea.WorkAreaCode,--工区号
|
||||
jot.WeldJointCode,--焊口号
|
||||
jot.BackingWelderId AS WelderId, --焊工ID
|
||||
jot.JointArea,--焊接区域
|
||||
jot.Dia,
|
||||
jot.Size,--实际寸径
|
||||
WeldingDaily.WeldingDate,--焊接日期
|
||||
jot.PipelineId, --管线ID
|
||||
jot.Material1Id AS Mat, --材质
|
||||
jot.Specification, --规格
|
||||
jot.JointAttribute,
|
||||
weldType.Flag, --焊缝类型
|
||||
Pipeline.PipelineCode, --管线号
|
||||
PipingClass.PipingClassName, --管道等级
|
||||
PointBatchItem.IsWelderFirst,
|
||||
PointBatchItem.IsCompletedPoint,
|
||||
trust.TrustBatchItemId,
|
||||
(CASE WHEN PointBatchItem.JLAudit IS NOT NULL THEN userJL.UserName ELSE (CASE WHEN PointBatchItem.PointState IS NOT NULL THEN '未审核' ELSE '' END) END) AS JLAudit,
|
||||
(CASE WHEN PointBatchItem.GLGSAudit IS NOT NULL THEN userGLGS.UserName ELSE (CASE WHEN PointBatchItem.PointState IS NOT NULL THEN '未审核' ELSE '' END) END) AS GLGSAudit,
|
||||
(CASE WHEN PointBatchItem.QTAudit IS NOT NULL THEN userQT.UserName ELSE (CASE WHEN PointBatchItem.PointState IS NOT NULL THEN '未审核' ELSE '' END) END) AS QTAudit,
|
||||
(CASE WHEN jot.BackingWelderId!=jot.CoverWelderId THEN backingWelder.WelderCode+'/'+coverWelder.WelderCode ELSE backingWelder.WelderCode END) AS WelderCode, --焊工号
|
||||
(CASE WHEN PointBatchItem.JLAudit IS NOT NULL AND PointBatchItem.GLGSAudit IS NOT NULL THEN 1 ELSE 0 END) AS IsPointAudit
|
||||
FROM Batch_PointBatchItem AS PointBatchItem
|
||||
LEFT JOIN Batch_PointBatch AS PointBatch ON PointBatch.PointBatchId=PointBatchItem.PointBatchId
|
||||
LEFT JOIN dbo.Batch_BatchTrustItem trust ON trust.PointBatchItemId = PointBatchItem.PointBatchItemId
|
||||
LEFT JOIN Pipeline_WeldJoint AS jot ON jot.WeldJointId=PointBatchItem.WeldJointId
|
||||
LEFT JOIN Pipeline_Pipeline AS Pipeline ON Pipeline.PipelineId=jot.PipelineId
|
||||
LEFT JOIN dbo.Base_WeldType weldType ON weldType.WeldTypeId = jot.WeldTypeId
|
||||
LEFT JOIN dbo.Welder_Welder backingWelder ON backingWelder.WelderId = jot.BackingWelderId
|
||||
LEFT JOIN dbo.Welder_Welder coverWelder ON coverWelder.WelderId = jot.CoverWelderId
|
||||
LEFT JOIN Project_WorkArea AS WorkArea ON WorkArea.WorkAreaId=Pipeline.WorkAreaId
|
||||
LEFT JOIN Pipeline_WeldingDaily AS WeldingDaily ON WeldingDaily.WeldingDailyId=jot.WeldingDailyId
|
||||
LEFT JOIN Base_PipingClass AS PipingClass ON PipingClass.PipingClassId=Pipeline.PipingClassId
|
||||
LEFT JOIN dbo.Sys_User userJL ON userJL.UserId = PointBatchItem.JLAudit
|
||||
LEFT JOIN dbo.Sys_User userGLGS ON userGLGS.UserId = PointBatchItem.GLGSAudit
|
||||
LEFT JOIN dbo.Sys_User userQT ON userQT.UserId = PointBatchItem.QTAudit
|
||||
|
||||
|
||||
GO
|
||||
|
||||
|
||||
|
||||
|
||||
CREATE VIEW [dbo].[View_TrustBathcIn]
|
||||
AS
|
||||
/*用于导入数据时,查询焊口信息*/
|
||||
SELECT
|
||||
pitem.PointBatchItemId,pitem.PointBatchId,jot.ProjectId
|
||||
,pipeline.InstallationId,ins.InstallationCode
|
||||
,pipeline.WorkAreaId,workArea.WorkAreaCode
|
||||
,jot.PipelineId,pipeline.PipelineCode
|
||||
,pitem.WeldJointId,jot.WeldJointCode
|
||||
,point.DetectionTypeId,nde.DetectionTypeCode
|
||||
,pitem.IsWelderFirst,trust.TrustBatchItemId
|
||||
FROM dbo.Batch_PointBatchItem AS pitem
|
||||
LEFT JOIN dbo.Batch_PointBatch point ON point.PointBatchId = pitem.PointBatchId
|
||||
LEFT JOIN Pipeline_WeldJoint jot ON jot.WeldJointId = pitem.WeldJointId
|
||||
LEFT JOIN Pipeline_Pipeline AS pipeline ON jot.PipelineId = pipeline.PipelineId
|
||||
LEFT JOIN dbo.Project_WorkArea AS workArea ON workArea.WorkAreaId=pipeline.WorkAreaId
|
||||
LEFT JOIN dbo.Project_Installation ins ON ins.InstallationId = workArea.InstallationId
|
||||
LEFT JOIN dbo.Base_DetectionType nde ON nde.DetectionTypeId = point.DetectionTypeId
|
||||
LEFT JOIN dbo.Batch_BatchTrustItem trust ON trust.PointBatchItemId = pitem.PointBatchItemId
|
||||
|
||||
|
||||
|
||||
GO
|
||||
|
||||
|
Loading…
Reference in New Issue