diff --git a/SGGL/BLL/HJGL/DataImport/DataImportService.cs b/SGGL/BLL/HJGL/DataImport/DataImportService.cs index d3ad796c..548fb438 100644 --- a/SGGL/BLL/HJGL/DataImport/DataImportService.cs +++ b/SGGL/BLL/HJGL/DataImport/DataImportService.cs @@ -166,6 +166,26 @@ namespace BLL var newVersion = MaxVersion + 0.1m; return newVersion; } + public static string Getlatest3DModelNameByUnitWorkId(string UnitWorkId ) + { + string result = ""; + var q = (from x in Funs.DB.HJGL_DataImport + where x.UnitWorkId == UnitWorkId && x.ImportType == "1" + group x by x.UnitWorkId into tt + from t in tt.DefaultIfEmpty() + select new + { + FileName = (from x2 in tt where x2.Version == tt.Max(x => x.Version ) select x2.FileName).FirstOrDefault() + } + ).FirstOrDefault(); + //where t.Key == UnitWorkId & x.FileType == "1" select x.Version).Distinct().ToList(); + if (!string.IsNullOrEmpty(q.FileName)) + { + result=q.FileName.Substring (0,q.FileName.LastIndexOf('.')); + + } + return result; + } public static void InitVersionDownList(FineUIPro.DropDownList dropName, string UnitWorkId) { diff --git a/SGGL/FineUIPro.Web/Controls/_3DLook.ascx b/SGGL/FineUIPro.Web/Controls/_3DLook.ascx index ab9ea8c0..5b127caf 100644 --- a/SGGL/FineUIPro.Web/Controls/_3DLook.ascx +++ b/SGGL/FineUIPro.Web/Controls/_3DLook.ascx @@ -22,6 +22,7 @@ function BindData(dataList, Url_item,Url) { receiver.src = Url_item; // var newdatalist = dataList.split(","); + // console.log(dataList); receiver.contentWindow.postMessage(dataList, Url); } function iFrameHeight() { diff --git a/SGGL/FineUIPro.Web/File/Excel/DataIn/组件管理二维码信息导入.xlsx b/SGGL/FineUIPro.Web/File/Excel/DataIn/组件管理二维码信息导入.xlsx index ec2e63a9..2b9badb3 100644 Binary files a/SGGL/FineUIPro.Web/File/Excel/DataIn/组件管理二维码信息导入.xlsx and b/SGGL/FineUIPro.Web/File/Excel/DataIn/组件管理二维码信息导入.xlsx differ diff --git a/SGGL/FineUIPro.Web/File/Fastreport/组件打印.frx b/SGGL/FineUIPro.Web/File/Fastreport/组件打印.frx index 734cba38..6ee8779c 100644 --- a/SGGL/FineUIPro.Web/File/Fastreport/组件打印.frx +++ b/SGGL/FineUIPro.Web/File/Fastreport/组件打印.frx @@ -1,5 +1,5 @@  - + using System; using System.Collections; using System.Collections.Generic; @@ -99,7 +99,7 @@ namespace FastReport } - + diff --git a/SGGL/FineUIPro.Web/HJGL/InfoQuery/PipelineQuery.aspx b/SGGL/FineUIPro.Web/HJGL/InfoQuery/PipelineQuery.aspx index 4a272a97..7220bc2e 100644 --- a/SGGL/FineUIPro.Web/HJGL/InfoQuery/PipelineQuery.aspx +++ b/SGGL/FineUIPro.Web/HJGL/InfoQuery/PipelineQuery.aspx @@ -83,7 +83,7 @@ - - - + --%> diff --git a/SGGL/FineUIPro.Web/HJGL/PreDesign/PrePipelineQRCodeIn.aspx.cs b/SGGL/FineUIPro.Web/HJGL/PreDesign/PrePipelineQRCodeIn.aspx.cs index 937fa07f..c0386ee6 100644 --- a/SGGL/FineUIPro.Web/HJGL/PreDesign/PrePipelineQRCodeIn.aspx.cs +++ b/SGGL/FineUIPro.Web/HJGL/PreDesign/PrePipelineQRCodeIn.aspx.cs @@ -169,17 +169,17 @@ namespace FineUIPro.Web.HJGL.PreDesign Model.HJGL_Pipeline pipeline = new Model.HJGL_Pipeline(); Model.HJGL_Pipeline_Component hJGL_Pipeline_Component = new Model.HJGL_Pipeline_Component(); - string pioelinecode = pds.Rows[i]["管线号"].ToString(); + string pipelinecode = pds.Rows[i]["管线号"].ToString(); string PipelineComponentCode = pds.Rows[i]["预制组件"].ToString(); string QRCode = pds.Rows[i]["二维码信息"].ToString(); - if (string.IsNullOrEmpty(pioelinecode)) + if (string.IsNullOrEmpty(pipelinecode)) { result += "第" + (i + 2).ToString() + "行," + "管线号" + "," + "此项为必填项!" + "|"; } else { - pipeline = getPipeline.FirstOrDefault(x => x.PipelineCode == pioelinecode); + pipeline = getPipeline.FirstOrDefault(x => x.PipelineCode == pipelinecode); if (pipeline == null) { result += "第" + (i + 2).ToString() + "行," + "不存在此管线号" + "|"; @@ -194,9 +194,9 @@ namespace FineUIPro.Web.HJGL.PreDesign else { hJGL_Pipeline_Component = HJGL_PipelineComponentService.GetPipelineComponentByCodeandpipelineId(PipelineComponentCode, pipeline.PipelineId); - if (pipeline == null) + if (hJGL_Pipeline_Component == null) { - result += "第" + (i + 2).ToString() + "行," + "不存在此预制组件" + "|"; + result += "第" + (i + 2).ToString() + "行," + "不存在此预制组件 " + PipelineComponentCode + " |"; continue; } @@ -222,32 +222,35 @@ namespace FineUIPro.Web.HJGL.PreDesign .GroupBy(x => new { pipelinecode = x.Field("管线号"), PipelineComponentCode = x.Field("预制组件"), - DrawingName = x.Field("预制图纸名称"), + // DrawingName = x.Field("预制图纸名称"), }) .Select(x => new { pipelinecode = x.Key.pipelinecode, PipelineComponentCode = x.Key.PipelineComponentCode, - DrawingName = x.Key.DrawingName, + // DrawingName = x.Key.DrawingName, QRCode = String.Join("&", x.Select(z => z.Field("二维码信息"))) }); foreach (var item in dt) { var pipeline = PipelineService.GetPipelineByPipelineCode(item.pipelinecode.Replace("\n", "").Replace(" ", "").Replace("\t", "").Replace("\r", "")); var hJGL_Pipeline_Component = HJGL_PipelineComponentService.GetPipelineComponentByCodeandpipelineId(item.PipelineComponentCode.Replace("\n", "").Replace(" ", "").Replace("\t", "").Replace("\r", ""), pipeline.PipelineId); - - model.Pipeline_ComponentQRCodeRootName rootName = new model.Pipeline_ComponentQRCodeRootName(); - rootName.QRCode = new List(); - var elementlist = item.QRCode.Split('&'); - foreach (var element in elementlist) + if (hJGL_Pipeline_Component!=null) { - model.Pipeline_ComponentQRCodeQRCodeItem qRCodeQRCodeItem = new model.Pipeline_ComponentQRCodeQRCodeItem(); - qRCodeQRCodeItem.element = element; - rootName.QRCode.Add(qRCodeQRCodeItem); + model.Pipeline_ComponentQRCodeRootName rootName = new model.Pipeline_ComponentQRCodeRootName(); + rootName.QRCode = new List(); + var elementlist = item.QRCode.Split('&'); + foreach (var element in elementlist) + { + model.Pipeline_ComponentQRCodeQRCodeItem qRCodeQRCodeItem = new model.Pipeline_ComponentQRCodeQRCodeItem(); + qRCodeQRCodeItem.element = element; + rootName.QRCode.Add(qRCodeQRCodeItem); + } + hJGL_Pipeline_Component.QRCode = JsonConvert.SerializeObject(rootName); + //hJGL_Pipeline_Component.DrawingName = item.DrawingName; + Pipeline_ComponentList.Add(hJGL_Pipeline_Component); } - hJGL_Pipeline_Component.QRCode = JsonConvert.SerializeObject(rootName); - hJGL_Pipeline_Component.DrawingName = item.DrawingName; - Pipeline_ComponentList.Add(hJGL_Pipeline_Component); + } errorInfos = string.Empty; diff --git a/SGGL/FineUIPro.Web/common/mainMenu_HJGL_AVEVA.aspx b/SGGL/FineUIPro.Web/common/mainMenu_HJGL_AVEVA.aspx index 2a957146..3cfdee14 100644 --- a/SGGL/FineUIPro.Web/common/mainMenu_HJGL_AVEVA.aspx +++ b/SGGL/FineUIPro.Web/common/mainMenu_HJGL_AVEVA.aspx @@ -13,22 +13,15 @@
- - - - - diff --git a/SGGL/Model/HJGL/3DParameter.cs b/SGGL/Model/HJGL/3DParameter.cs index 1e1c3af4..3646d2a3 100644 --- a/SGGL/Model/HJGL/3DParameter.cs +++ b/SGGL/Model/HJGL/3DParameter.cs @@ -12,6 +12,8 @@ namespace Model /// 按钮类别 /// public string ButtonType { get; set; } + + public string ModelName { get; set; } /// /// 颜色模型 ///