2022-10-31 焊接三维参数修改

This commit is contained in:
2022-10-31 17:03:08 +08:00
parent 93492e7b02
commit f5334e6ae6
4 changed files with 49 additions and 60 deletions
@@ -184,6 +184,7 @@ namespace FineUIPro.Web.HJGL.InfoQuery
tn2.ToolTip = "施工单位:" + u.UnitName;
tn2.CommandName = "单位工程";
tn2.EnableExpandEvent = true;
tn2.EnableClickEvent = true;
rootNode2.Nodes.Add(tn2);
if (a > 0)
{
@@ -177,6 +177,7 @@ namespace FineUIPro.Web.HJGL.WeldingManage
protected void tvControlItem_TreeNodeExpanded(object sender, TreeNodeEventArgs e)
{
e.Node.Nodes.Clear();
if (e.Node.CommandName == "单位工程")
{
var pipeline = (from x in Funs.DB.HJGL_Pipeline
@@ -131,6 +131,7 @@ namespace FineUIPro.Web.HJGL.WeldingManage
tn2.ToolTip = "施工单位:" + u.UnitName;
tn2.CommandName = "单位工程";
tn2.EnableExpandEvent = true;
tn2.EnableClickEvent= true;
rootNode2.Nodes.Add(tn2);
if (a > 0)
{
@@ -206,84 +207,70 @@ namespace FineUIPro.Web.HJGL.WeldingManage
{
if (!string.IsNullOrEmpty(this.tvControlItem.SelectedNodeID))
{
Model.HJGL_Pipeline pipeline = BLL.PipelineService.GetPipelineByPipelineId(this.tvControlItem.SelectedNodeID);
this.hdUnitWorkId.Text = string.Empty;
if (pipeline != null)
{
this.hdUnitWorkId.Text = this.tvControlItem.SelectedNode.ParentNode.NodeID;
this.BindGrid();
}
if (PipeArea == PipelineService.PipeArea_SHOP)
{
var list= BLL.HJGL_PipelineComponentService.GetComponentByPipelineId(pipeline.PipelineId);
if (list!=null&&list.Count()>0)
{
lbPlanStartDate.Text = list.First().PlanStartDate.ToString () ;
}
}
else if (PipeArea == PipelineService.PipeArea_FIELD)
{
lbPlanStartDate.Text = pipeline.PlanStartDate.HasValue ? pipeline.PlanStartDate.Value.ToShortDateString() : "";
}
//if (pipeline.PlanStartDate.HasValue && pipeline.ActStartDate.HasValue)
//{
// if (pipeline.ActStartDate < pipeline.PlanStartDate)
// {
// lbIsFinished.Text = "超前";
// }
// else if (pipeline.ActStartDate > pipeline.PlanStartDate)
// {
// lbIsFinished.Text = "延误";
// }
// else
// {
// lbIsFinished.Text = "正常";
// }
//}
//if (pipeline.PlanStartDate.HasValue && !pipeline.ActStartDate.HasValue)
//{
// if (pipeline.PlanStartDate >= DateTime.Now)
// {
// lbIsFinished.Text = "正常";
// }
// else
// {
// lbIsFinished.Text = "延误";
// }
//}
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 = "";
parameter3D.ButtonType = "0,3";
if (this.tvControlItem.SelectedNode.CommandName == "单位工程")
{
parameter3D.ModelName = HJGL_DataImportService.Getlatest3DModelNameByUnitWorkId(tvControlItem.SelectedNodeID);
var pipeline = (from x in Funs.DB.HJGL_Pipeline
where x.ProjectId == this.CurrUser.LoginProjectId && x.UnitWorkId == e.Node.NodeID && x.PipeArea == PipeArea
orderby x.PipelineCode
select x).ToList();
List<string> pipelineList = new List<string>();
foreach (var item in pipeline)
{
bool istrue = BLL.HJGL_MaterialService.isInStockByPipeline(item.PipelineId, this.CurrUser.LoginProjectId);
if (istrue)
{
pipelineList.Add("/" + item.PipelineCode);
}
}
parameter3D.Line_No = string.Join(",", pipelineList);
}
else if (this.tvControlItem.SelectedNode.CommandName == "管线")
{
var model = PipelineService.GetPipelineByPipelineId(tvControlItem.SelectedNodeID);
if (model != null && !string.IsNullOrEmpty(model.UnitWorkId))
Model.HJGL_Pipeline pipeline = BLL.PipelineService.GetPipelineByPipelineId(this.tvControlItem.SelectedNodeID);
this.hdUnitWorkId.Text = string.Empty;
if (pipeline != null)
{
this.hdUnitWorkId.Text = this.tvControlItem.SelectedNode.ParentNode.NodeID;
this.BindGrid();
}
if (PipeArea == PipelineService.PipeArea_SHOP)
{
var list = BLL.HJGL_PipelineComponentService.GetComponentByPipelineId(pipeline.PipelineId);
if (list != null && list.Count() > 0)
{
lbPlanStartDate.Text = list.First().PlanStartDate.ToString();
}
}
else if (PipeArea == PipelineService.PipeArea_FIELD)
{
lbPlanStartDate.Text = pipeline.PlanStartDate.HasValue ? pipeline.PlanStartDate.Value.ToShortDateString() : "";
}
if (pipeline != null && !string.IsNullOrEmpty(pipeline.UnitWorkId))
{
bool istrue = BLL.HJGL_MaterialService.isInStockByPipeline(tvControlItem.SelectedNodeID, this.CurrUser.LoginProjectId);
if (istrue)
{
Line_No = model.PipelineCode;
Line_No = "/" + pipeline.PipelineCode;
}
parameter3D.Line_No = Line_No;
parameter3D.ModelName = HJGL_DataImportService.Getlatest3DModelNameByUnitWorkId(model.UnitWorkId);
var pipecode = "/" + model.PipelineCode;
parameter3D.ModelName = HJGL_DataImportService.Getlatest3DModelNameByUnitWorkId(pipeline.UnitWorkId);
var pipecode = "/" + pipeline.PipelineCode;
parameter3D.TagNum = pipecode;
}
}
}
ctlAuditFlow.Url_item = BLL.Project_SysSetService.GetAvevaNetUrl(this.CurrUser.LoginProjectId) + "item/IPE%7CVPD%7C" + parameter3D.ModelName;
ctlAuditFlow.data = parameter3D;
ctlAuditFlow.BindData();
@@ -378,7 +365,7 @@ namespace FineUIPro.Web.HJGL.WeldingManage
bool istrue = BLL.HJGL_MaterialService.isInStockByPipeline(tvControlItem.SelectedNodeID, this.CurrUser.LoginProjectId);
if (istrue)
{
Line_No = modelpipe.PipelineCode;
Line_No ="/"+ modelpipe.PipelineCode;
}
parameter3D.Line_No = Line_No;
parameter3D.ModelName = HJGL_DataImportService.Getlatest3DModelNameByUnitWorkId(modelpipe.UnitWorkId);
@@ -94,7 +94,7 @@
</f:Form>
</Items>
</f:GroupPanel>
<f:GroupPanel ID="GroupPanel3" Layout="Anchor" Title="颜色模型设置" runat="server">
<f:GroupPanel ID="GroupPanel3" Layout="Anchor" Title="模型颜色设置" runat="server">
<Items>
<f:Form ID="Form3" ShowBorder="false" ShowHeader="false" AutoScroll="true"
Layout="VBox" BodyPadding="10px" runat="server" RedStarPosition="BeforeText"
@@ -102,10 +102,10 @@
<Rows>
<f:FormRow runat="server">
<Items>
<f:NumberBox ID="txtPipelineNOComplete" Label="未完成(透明显示)" runat="server" MaxValue="100"
<f:NumberBox ID="txtPipelineNOComplete" Label="未完成(透明显示)" runat="server" MaxValue="100" Hidden="true"
LabelWidth="180px" NoNegative="true" NoDecimal="true">
</f:NumberBox>
<f:NumberBox ID="txtPipelineComplete" Label="已完成(透明显示)" runat="server" MaxValue="100"
<f:NumberBox ID="txtPipelineComplete" Label="已完成(透明显示)" runat="server" MaxValue="100" Hidden="true"
LabelWidth="180px" NoNegative="true" NoDecimal="true">
</f:NumberBox>
</Items>