This commit is contained in:
parent
2e16ebb9d3
commit
c31c70a828
|
|
@ -280,16 +280,27 @@ namespace FineUIPro.Web.CLGL
|
||||||
}
|
}
|
||||||
string planId = Grid1.SelectedRowID;
|
string planId = Grid1.SelectedRowID;
|
||||||
var planMaster = BLL.TwInOutplanmasterService.GetById(planId);
|
var planMaster = BLL.TwInOutplanmasterService.GetById(planId);
|
||||||
if (planMaster.State != (int)TwConst.State.已完成)
|
switch (planMaster.State)
|
||||||
{
|
{
|
||||||
Alert.ShowInTop("请选择有效的计划!", MessageBoxIcon.Warning);
|
case (int)TwConst.State.已审核:
|
||||||
return;
|
planMaster.State= (int)TwConst.State.待审核;
|
||||||
}
|
planMaster.AuditMan = null;
|
||||||
else
|
planMaster.AuditDate = null;
|
||||||
{
|
TwInOutplanmasterService.Update(planMaster);
|
||||||
TwInputmasterService.RevokeGenInMasterByPlanId(planId);
|
BindGrid();
|
||||||
BindGrid();
|
ShowNotify("撤销审核成功!", MessageBoxIcon.Success);
|
||||||
ShowNotify("撤销入库单成功!", MessageBoxIcon.Success);
|
|
||||||
|
break;
|
||||||
|
case (int)TwConst.State.已完成:
|
||||||
|
TwInputmasterService.RevokeGenInMasterByPlanId(planId);
|
||||||
|
BindGrid();
|
||||||
|
ShowNotify("撤销入库单成功!", MessageBoxIcon.Success);
|
||||||
|
break;
|
||||||
|
|
||||||
|
|
||||||
|
default:
|
||||||
|
Alert.ShowInTop("请选择有效的计划!", MessageBoxIcon.Warning);
|
||||||
|
break;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -78,11 +78,10 @@ namespace FineUIPro.Web.common
|
||||||
{
|
{
|
||||||
// 优化:从内存字典中获取管线数量,避免数据库查询
|
// 优化:从内存字典中获取管线数量,避免数据库查询
|
||||||
int a = pipelineCountByUnitWork.ContainsKey(q.UnitWorkId) ? pipelineCountByUnitWork[q.UnitWorkId].Count : 0;
|
int a = pipelineCountByUnitWork.ContainsKey(q.UnitWorkId) ? pipelineCountByUnitWork[q.UnitWorkId].Count : 0;
|
||||||
decimal totalDia = pipelineCountByUnitWork.ContainsKey(q.UnitWorkId) ? pipelineCountByUnitWork[q.UnitWorkId].TotalDin ?? 0 : 0;
|
|
||||||
var unitNamesUnitIds = BLL.UnitService.getUnitNamesUnitIds(q.UnitId);
|
var unitNamesUnitIds = BLL.UnitService.getUnitNamesUnitIds(q.UnitId);
|
||||||
TreeNode tn1 = new TreeNode();
|
TreeNode tn1 = new TreeNode();
|
||||||
tn1.NodeID = q.UnitWorkId;
|
tn1.NodeID = q.UnitWorkId;
|
||||||
tn1.Text = q.UnitWorkName + "【" + a.ToString() + "】" + "管线" + "(总达因:" + totalDia.ToString() + ")";
|
tn1.Text = q.UnitWorkName + "【" + a.ToString() + "】" + "管线" ;
|
||||||
tn1.ToolTip = "施工单位:" + unitNamesUnitIds;
|
tn1.ToolTip = "施工单位:" + unitNamesUnitIds;
|
||||||
tn1.EnableClickEvent = true;
|
tn1.EnableClickEvent = true;
|
||||||
rootNode1.Nodes.Add(tn1);
|
rootNode1.Nodes.Add(tn1);
|
||||||
|
|
@ -94,12 +93,10 @@ namespace FineUIPro.Web.common
|
||||||
{
|
{
|
||||||
// 优化:从内存字典中获取管线数量,避免数据库查询
|
// 优化:从内存字典中获取管线数量,避免数据库查询
|
||||||
int a = pipelineCountByUnitWork.ContainsKey(q.UnitWorkId) ? pipelineCountByUnitWork[q.UnitWorkId].Count : 0;
|
int a = pipelineCountByUnitWork.ContainsKey(q.UnitWorkId) ? pipelineCountByUnitWork[q.UnitWorkId].Count : 0;
|
||||||
decimal totalDia = pipelineCountByUnitWork.ContainsKey(q.UnitWorkId) ? pipelineCountByUnitWork[q.UnitWorkId].TotalDin??0 : 0;
|
|
||||||
|
|
||||||
var unitNamesUnitIds = BLL.UnitService.getUnitNamesUnitIds(q.UnitId);
|
var unitNamesUnitIds = BLL.UnitService.getUnitNamesUnitIds(q.UnitId);
|
||||||
TreeNode tn2 = new TreeNode();
|
TreeNode tn2 = new TreeNode();
|
||||||
tn2.NodeID = q.UnitWorkId;
|
tn2.NodeID = q.UnitWorkId;
|
||||||
tn2.Text = q.UnitWorkName + "【" + a.ToString() + "】" + "管线" + "(总达因:" + totalDia.ToString() + ")";
|
tn2.Text = q.UnitWorkName + "【" + a.ToString() + "】" + "管线" ;
|
||||||
tn2.ToolTip = "施工单位:" + unitNamesUnitIds;
|
tn2.ToolTip = "施工单位:" + unitNamesUnitIds;
|
||||||
tn2.EnableClickEvent = true;
|
tn2.EnableClickEvent = true;
|
||||||
rootNode2.Nodes.Add(tn2);
|
rootNode2.Nodes.Add(tn2);
|
||||||
|
|
@ -260,6 +257,7 @@ JointData AS (
|
||||||
j.Size,
|
j.Size,
|
||||||
j.WeldingDailyId,
|
j.WeldingDailyId,
|
||||||
j.JointAttribute,
|
j.JointAttribute,
|
||||||
|
j.PipelineId,
|
||||||
p.PipeArea,
|
p.PipeArea,
|
||||||
p.UnitWorkId
|
p.UnitWorkId
|
||||||
FROM dbo.HJGL_WeldJoint j
|
FROM dbo.HJGL_WeldJoint j
|
||||||
|
|
@ -326,6 +324,7 @@ JointData AS (
|
||||||
j.Size,
|
j.Size,
|
||||||
j.WeldingDailyId,
|
j.WeldingDailyId,
|
||||||
j.JointAttribute,
|
j.JointAttribute,
|
||||||
|
j.PipelineId,
|
||||||
p.PipeArea,
|
p.PipeArea,
|
||||||
p.UnitWorkId
|
p.UnitWorkId
|
||||||
FROM dbo.HJGL_WeldJoint j
|
FROM dbo.HJGL_WeldJoint j
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue