From ffb9c2a95cb412044a6bed7aa7cc73a437f5eac9 Mon Sep 17 00:00:00 2001
From: fei550 <1420031550@qq.com>
Date: Mon, 31 Aug 2026 15:11:03 +0800
Subject: [PATCH] =?UTF-8?q?=E4=BF=AE=E6=94=B9=E6=9D=90=E6=96=99=E7=BC=96?=
=?UTF-8?q?=E7=A0=81=E5=BA=93=E5=AF=BC=E5=85=A5=E5=8A=9F=E8=83=BD=EF=BC=8C?=
=?UTF-8?q?=E7=84=8A=E5=8F=A3=E5=8F=B0=E8=B4=A6=E5=A2=9E=E5=8A=A0=E7=84=8A?=
=?UTF-8?q?=E6=8E=A5=E6=97=A5=E6=9C=9F=E7=AD=9B=E9=80=89?=
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
---
.../WeldingManage/PipelineComponentService.cs | 39 ++++++++--
.../HJGL/WeldingManage/WeldJointService.cs | 3 +-
.../CQMS/PersonManage/WelderItemEdit.aspx.cs | 2 +-
.../HJGL/BaseInfo/MaterialCodeLib.aspx | 2 +-
.../HJGL/BaseInfo/MaterialCodeLibIn.aspx.cs | 4 ++
.../HJGL/InfoQuery/JointQuery.aspx | 5 +-
.../HJGL/InfoQuery/JointQuery.aspx.cs | 52 +++-----------
.../InfoQuery/JointQuery.aspx.designer.cs | 71 +++++++++++--------
.../HJGL/WeldingManage/PipelineMatIn.aspx.cs | 1 +
9 files changed, 97 insertions(+), 82 deletions(-)
diff --git a/SGGL/BLL/HJGL/WeldingManage/PipelineComponentService.cs b/SGGL/BLL/HJGL/WeldingManage/PipelineComponentService.cs
index a72bc895..f0ae5ad7 100644
--- a/SGGL/BLL/HJGL/WeldingManage/PipelineComponentService.cs
+++ b/SGGL/BLL/HJGL/WeldingManage/PipelineComponentService.cs
@@ -273,18 +273,36 @@ namespace BLL
///
public static void SyncPipelineComponentByMatId(string pipeLineMatId)
{
+ if (string.IsNullOrEmpty(pipeLineMatId))
+ {
+ return;
+ }
+
var model_mat = BLL.PipelineMatService.GetPipeLineMat(pipeLineMatId);
+ if (model_mat == null || string.IsNullOrEmpty(model_mat.PipelineId))
+ {
+ return;
+ }
+
var PipelineId = model_mat.PipelineId;
- var PipeArea = BLL.PipelineService.GetPipelineByPipelineId(PipelineId).PipeArea;
- if (PipeArea == "1" && !string.IsNullOrEmpty(model_mat.PrefabricatedComponents))
+ var pipelineModel = BLL.PipelineService.GetPipelineByPipelineId(PipelineId);
+ if (pipelineModel == null)
+ {
+ return;
+ }
+
+ var PipeArea = pipelineModel.PipeArea;
+ if (PipeArea == PipelineService.PipeArea_SHOP && !string.IsNullOrEmpty(model_mat.PrefabricatedComponents))
{
// var model = GetPipelineComponentByMatId(pipeLineMatId);
var model = GetPipelineComponentByCodeandpipelineId(model_mat.PrefabricatedComponents, PipelineId);
+ // 组件号可能来自导入数据,未包含分隔符时直接使用原值,避免截取时报错。
+ var drawingName = GetDrawingNameByComponentCode(model_mat.PrefabricatedComponents);
if (model != null)
{
model.PipelineId = PipelineId;
model.PipelineComponentCode = model_mat.PrefabricatedComponents;
- model.DrawingName = model_mat.PrefabricatedComponents.Substring(0, model_mat.PrefabricatedComponents.LastIndexOf('-')).Replace("\"", "");
+ model.DrawingName = drawingName;
model.State = State0;
model.ProductionState = 0;
UpdatePipelineComponent(model);
@@ -295,7 +313,7 @@ namespace BLL
model.PipelineComponentId = SQLHelper.GetNewID();
model.PipelineId = PipelineId;
model.PipelineComponentCode = model_mat.PrefabricatedComponents;
- model.DrawingName = model_mat.PrefabricatedComponents?.Substring(0, model_mat.PrefabricatedComponents.LastIndexOf('-')).Replace("\"", "");
+ model.DrawingName = drawingName;
model.State = State0;
model.ProductionState = 0;
model.IsPrint = false;
@@ -308,6 +326,19 @@ namespace BLL
}
+
+ private static string GetDrawingNameByComponentCode(string pipelineComponentCode)
+ {
+ if (string.IsNullOrEmpty(pipelineComponentCode))
+ {
+ return string.Empty;
+ }
+
+ int splitIndex = pipelineComponentCode.LastIndexOf('-');
+ string drawingName = splitIndex > 0 ? pipelineComponentCode.Substring(0, splitIndex) : pipelineComponentCode;
+ return drawingName.Replace("\"", "");
+ }
+
///
/// 添加管线预制组件
///
diff --git a/SGGL/BLL/HJGL/WeldingManage/WeldJointService.cs b/SGGL/BLL/HJGL/WeldingManage/WeldJointService.cs
index f566517d..765bf2af 100644
--- a/SGGL/BLL/HJGL/WeldingManage/WeldJointService.cs
+++ b/SGGL/BLL/HJGL/WeldingManage/WeldJointService.cs
@@ -510,7 +510,8 @@ namespace BLL
baseQuery = baseQuery.Where(x => x.WeldJointCode.Contains(model.WeldJointCode));
if (!string.IsNullOrEmpty(model.IsWeldOK))
baseQuery = baseQuery.Where(x => x.IsWeldOK == model.IsWeldOK);
-
+ if (!string.IsNullOrEmpty(model.WeldingDate))
+ baseQuery = baseQuery.Where(x => x.WeldingDate == model.WeldingDate);
// 阶段三:排序与分页控制(索引优化关键)
var orderedQuery = baseQuery.OrderBy(x => x.PipelineCode).ThenBy(x => x.WeldJointCode);
diff --git a/SGGL/FineUIPro.Web/CQMS/PersonManage/WelderItemEdit.aspx.cs b/SGGL/FineUIPro.Web/CQMS/PersonManage/WelderItemEdit.aspx.cs
index d4a85b95..248c070c 100644
--- a/SGGL/FineUIPro.Web/CQMS/PersonManage/WelderItemEdit.aspx.cs
+++ b/SGGL/FineUIPro.Web/CQMS/PersonManage/WelderItemEdit.aspx.cs
@@ -125,7 +125,7 @@ namespace FineUIPro.Web.CQMS.PersonManage
{
if (str == "不限")
{
- return 0;
+ return 0;
}
else
{
diff --git a/SGGL/FineUIPro.Web/HJGL/BaseInfo/MaterialCodeLib.aspx b/SGGL/FineUIPro.Web/HJGL/BaseInfo/MaterialCodeLib.aspx
index 95e5f521..7c409b4d 100644
--- a/SGGL/FineUIPro.Web/HJGL/BaseInfo/MaterialCodeLib.aspx
+++ b/SGGL/FineUIPro.Web/HJGL/BaseInfo/MaterialCodeLib.aspx
@@ -43,7 +43,7 @@
-
+
diff --git a/SGGL/FineUIPro.Web/HJGL/BaseInfo/MaterialCodeLibIn.aspx.cs b/SGGL/FineUIPro.Web/HJGL/BaseInfo/MaterialCodeLibIn.aspx.cs
index 8c4eea67..4e55678d 100644
--- a/SGGL/FineUIPro.Web/HJGL/BaseInfo/MaterialCodeLibIn.aspx.cs
+++ b/SGGL/FineUIPro.Web/HJGL/BaseInfo/MaterialCodeLibIn.aspx.cs
@@ -235,6 +235,7 @@ namespace FineUIPro.Web.HJGL.BaseInfo
select new HJGL_MaterialCodeLib
{
MaterialCode = x.MaterialCode,
+ Code = x.MaterialCode,
MaterialDef = x.MaterialDef,
MaterialSpec = x.MaterialSpec,
MaterialUnit = x.MaterialUnit,
@@ -244,6 +245,7 @@ namespace FineUIPro.Web.HJGL.BaseInfo
}).DistinctBy(temp => new
{
temp.MaterialCode,
+ temp.Code,
temp.MaterialDef,
temp.MaterialSpec,
temp.MaterialUnit,
@@ -254,6 +256,7 @@ namespace FineUIPro.Web.HJGL.BaseInfo
select new HJGL_MaterialCodeLib
{
MaterialCode = x.MaterialCode,
+ Code = x.MaterialCode,
MaterialDef = x.MaterialDef,
MaterialSpec = x.MaterialSpec,
MaterialUnit = x.MaterialUnit,
@@ -263,6 +266,7 @@ namespace FineUIPro.Web.HJGL.BaseInfo
}).DistinctBy(temp => new
{
temp.MaterialCode,
+ temp.Code,
temp.MaterialDef,
temp.MaterialSpec,
temp.MaterialUnit,
diff --git a/SGGL/FineUIPro.Web/HJGL/InfoQuery/JointQuery.aspx b/SGGL/FineUIPro.Web/HJGL/InfoQuery/JointQuery.aspx
index 7b30a9a4..01458a8a 100644
--- a/SGGL/FineUIPro.Web/HJGL/InfoQuery/JointQuery.aspx
+++ b/SGGL/FineUIPro.Web/HJGL/InfoQuery/JointQuery.aspx
@@ -58,7 +58,7 @@
@@ -73,6 +73,9 @@
+
+
weldjointcodes = new List();
- foreach (var item in Id)
- {
- var WeldJointCode = WeldJointService.GetViewWeldJointById(item).WeldJointCode;
- weldjointcodes.Add("/" + WeldJointCode);
- }
-
- //var q = WeldJointService.GetViewWeldJointById(Grid1.SelectedRowID).PipelineCode;
- //var pipecode = "/" + q;
- Model.Parameter3D parameter3D = new Model.Parameter3D();
- Model.ColorModel colorModel = new Model.ColorModel();
- colorModel = BLL.Project_SysSetService.GetColorModel(this.CurrUser.LoginProjectId);
- parameter3D.ColorModel = colorModel;
- parameter3D.TagNum = string.Join(",", weldjointcodes);
- parameter3D.ButtonType = "2.1";
- parameter3D.Crater_data = "1";
- if (this.tvControlItem.SelectedNode.CommandName.Split('|').Count() == 2)
- {
- parameter3D.ModelName = HJGL_DataImportService.Getlatest3DModelNameByUnitWorkId(tvControlItem.SelectedNodeID);
-
-
- }
- else if (this.tvControlItem.SelectedNode.CommandName == "管线")
- {
- var model = PipelineService.GetPipelineByPipelineId(tvControlItem.SelectedNodeID);
- if (model != null && !string.IsNullOrEmpty(model.UnitWorkId))
- {
- parameter3D.ModelName = HJGL_DataImportService.Getlatest3DModelNameByUnitWorkId(model.UnitWorkId);
-
- }
-
- }
- parameter3D.Transparency = colorModel.PipelineComplete;
- parameter3D.Finished_color = colorModel.JointCompleteColor;
- parameter3D.Incomplete_color = colorModel.JointNOCompleteColor;
- //ctlAuditFlow.Url_item = BLL.Project_SysSetService.GetAvevaNetUrl_Item(this.CurrUser.LoginProjectId) + parameter3D.ModelName;
- //ctlAuditFlow.data = parameter3D;
- //ctlAuditFlow.BindData();
- }
-
-
}
}
diff --git a/SGGL/FineUIPro.Web/HJGL/InfoQuery/JointQuery.aspx.designer.cs b/SGGL/FineUIPro.Web/HJGL/InfoQuery/JointQuery.aspx.designer.cs
index daa99b3d..c0a43e40 100644
--- a/SGGL/FineUIPro.Web/HJGL/InfoQuery/JointQuery.aspx.designer.cs
+++ b/SGGL/FineUIPro.Web/HJGL/InfoQuery/JointQuery.aspx.designer.cs
@@ -7,11 +7,13 @@
// 自动生成>
//------------------------------------------------------------------------------
-namespace FineUIPro.Web.HJGL.InfoQuery {
-
-
- public partial class JointQuery {
-
+namespace FineUIPro.Web.HJGL.InfoQuery
+{
+
+
+ public partial class JointQuery
+ {
+
///
/// form1 控件。
///
@@ -20,7 +22,7 @@ namespace FineUIPro.Web.HJGL.InfoQuery {
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
///
protected global::System.Web.UI.HtmlControls.HtmlForm form1;
-
+
///
/// PageManager1 控件。
///
@@ -29,7 +31,7 @@ namespace FineUIPro.Web.HJGL.InfoQuery {
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
///
protected global::FineUIPro.PageManager PageManager1;
-
+
///
/// Panel1 控件。
///
@@ -38,7 +40,7 @@ namespace FineUIPro.Web.HJGL.InfoQuery {
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
///
protected global::FineUIPro.Panel Panel1;
-
+
///
/// panelLeftRegion 控件。
///
@@ -47,7 +49,7 @@ namespace FineUIPro.Web.HJGL.InfoQuery {
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
///
protected global::FineUIPro.Panel panelLeftRegion;
-
+
///
/// Toolbar1 控件。
///
@@ -56,7 +58,7 @@ namespace FineUIPro.Web.HJGL.InfoQuery {
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
///
protected global::FineUIPro.Toolbar Toolbar1;
-
+
///
/// hdUnitWorkId 控件。
///
@@ -65,7 +67,7 @@ namespace FineUIPro.Web.HJGL.InfoQuery {
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
///
protected global::FineUIPro.HiddenField hdUnitWorkId;
-
+
///
/// tvPipeCode 控件。
///
@@ -74,7 +76,7 @@ namespace FineUIPro.Web.HJGL.InfoQuery {
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
///
protected global::FineUIPro.TextBox tvPipeCode;
-
+
///
/// Toolbar3 控件。
///
@@ -83,7 +85,7 @@ namespace FineUIPro.Web.HJGL.InfoQuery {
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
///
protected global::FineUIPro.Toolbar Toolbar3;
-
+
///
/// btnTreeFind 控件。
///
@@ -92,7 +94,7 @@ namespace FineUIPro.Web.HJGL.InfoQuery {
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
///
protected global::FineUIPro.Button btnTreeFind;
-
+
///
/// btnrefresh 控件。
///
@@ -101,7 +103,7 @@ namespace FineUIPro.Web.HJGL.InfoQuery {
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
///
protected global::FineUIPro.Button btnrefresh;
-
+
///
/// tvControlItem 控件。
///
@@ -110,7 +112,7 @@ namespace FineUIPro.Web.HJGL.InfoQuery {
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
///
protected global::FineUIPro.Tree tvControlItem;
-
+
///
/// Panel2 控件。
///
@@ -119,7 +121,7 @@ namespace FineUIPro.Web.HJGL.InfoQuery {
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
///
protected global::FineUIPro.Panel Panel2;
-
+
///
/// panelCenterRegion 控件。
///
@@ -128,7 +130,7 @@ namespace FineUIPro.Web.HJGL.InfoQuery {
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
///
protected global::FineUIPro.Panel panelCenterRegion;
-
+
///
/// Grid1 控件。
///
@@ -137,7 +139,7 @@ namespace FineUIPro.Web.HJGL.InfoQuery {
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
///
protected global::FineUIPro.Grid Grid1;
-
+
///
/// Toolbar2 控件。
///
@@ -146,7 +148,7 @@ namespace FineUIPro.Web.HJGL.InfoQuery {
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
///
protected global::FineUIPro.Toolbar Toolbar2;
-
+
///
/// txtWeldJointCode 控件。
///
@@ -165,6 +167,15 @@ namespace FineUIPro.Web.HJGL.InfoQuery {
///
protected global::FineUIPro.DropDownList ddlWeldState;
+ ///
+ /// txtWeldingDate 控件。
+ ///
+ ///
+ /// 自动生成的字段。
+ /// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
+ ///
+ protected global::FineUIPro.DatePicker txtWeldingDate;
+
///
/// ToolbarFill2 控件。
///
@@ -173,7 +184,7 @@ namespace FineUIPro.Web.HJGL.InfoQuery {
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
///
protected global::FineUIPro.ToolbarFill ToolbarFill2;
-
+
///
/// BtnAnalyse 控件。
///
@@ -182,7 +193,7 @@ namespace FineUIPro.Web.HJGL.InfoQuery {
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
///
protected global::FineUIPro.Button BtnAnalyse;
-
+
///
/// btnOut 控件。
///
@@ -191,7 +202,7 @@ namespace FineUIPro.Web.HJGL.InfoQuery {
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
///
protected global::FineUIPro.Button btnOut;
-
+
///
/// btnOutNoComPipeline 控件。
///
@@ -209,7 +220,7 @@ namespace FineUIPro.Web.HJGL.InfoQuery {
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
///
protected global::FineUIPro.Button btnPrintJointNameplate;
-
+
///
/// btnGetChart 控件。
///
@@ -218,7 +229,7 @@ namespace FineUIPro.Web.HJGL.InfoQuery {
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
///
protected global::FineUIPro.Button btnGetChart;
-
+
///
/// labNumber 控件。
///
@@ -227,7 +238,7 @@ namespace FineUIPro.Web.HJGL.InfoQuery {
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
///
protected global::System.Web.UI.WebControls.Label labNumber;
-
+
///
/// ToolbarSeparator1 控件。
///
@@ -236,7 +247,7 @@ namespace FineUIPro.Web.HJGL.InfoQuery {
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
///
protected global::FineUIPro.ToolbarSeparator ToolbarSeparator1;
-
+
///
/// ToolbarText1 控件。
///
@@ -245,7 +256,7 @@ namespace FineUIPro.Web.HJGL.InfoQuery {
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
///
protected global::FineUIPro.ToolbarText ToolbarText1;
-
+
///
/// ddlPageSize 控件。
///
@@ -254,7 +265,7 @@ namespace FineUIPro.Web.HJGL.InfoQuery {
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
///
protected global::FineUIPro.DropDownList ddlPageSize;
-
+
///
/// Window1 控件。
///
@@ -263,7 +274,7 @@ namespace FineUIPro.Web.HJGL.InfoQuery {
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
///
protected global::FineUIPro.Window Window1;
-
+
///
/// Window2 控件。
///
diff --git a/SGGL/FineUIPro.Web/HJGL/WeldingManage/PipelineMatIn.aspx.cs b/SGGL/FineUIPro.Web/HJGL/WeldingManage/PipelineMatIn.aspx.cs
index 24d7a11f..472eb940 100644
--- a/SGGL/FineUIPro.Web/HJGL/WeldingManage/PipelineMatIn.aspx.cs
+++ b/SGGL/FineUIPro.Web/HJGL/WeldingManage/PipelineMatIn.aspx.cs
@@ -533,6 +533,7 @@ namespace FineUIPro.Web.HJGL.WeldingManage
else
{
var oldPipeLineMat = pipeLineMat.First();
+ item.PipeLineMatId = oldPipeLineMat.PipeLineMatId;
oldPipeLineMat.Number=item.Number;
oldPipeLineMat.MaterialCode2 = item.MaterialCode2;
if (!string.IsNullOrEmpty(item.MaterialCode))