change -添加开始工单日志记录

master
启龙 曹 6 months ago
parent 9ea2ab0b5c
commit 3115dbe28e

@ -1210,11 +1210,12 @@ namespace XGLFinishPro.Views
plc.Connection(PlcIp);
if (pointsDt != null && pointsDt.Rows.Count > 0)
{
bool writeResult = false;
foreach (DataRow row in pointsDt.Rows)
{
if (row["plc_point_no"].ToString() == height)
{
plc.Write(new PlcSetting()
writeResult = plc.Write(new PlcSetting()
{
PlcAddress = row["plc_point_address"].ToString(),
PlcValueLength = "2"
@ -1222,7 +1223,7 @@ namespace XGLFinishPro.Views
}
else if (row["plc_point_no"].ToString() == width1)
{
plc.Write(new PlcSetting()
writeResult = plc.Write(new PlcSetting()
{
PlcAddress = row["plc_point_address"].ToString(),
PlcValueLength = "2"
@ -1230,15 +1231,23 @@ namespace XGLFinishPro.Views
}
else if (row["plc_point_no"].ToString() == length1)
{
plc.Write(new PlcSetting()
writeResult = plc.Write(new PlcSetting()
{
PlcAddress = row["plc_point_address"].ToString(),
PlcValueLength = "2"
}, l);
}
LogHelper.instance.log.Info($"写入PLC尺寸信息成功新高度{h},新宽度{w},新长度{l}");
if (writeResult)
{
LogHelper.instance.log.Info($"写入PLC尺寸信息成功新高度{h},新宽度{w},新长度{l}");
}
else
{
LogHelper.instance.log.Info($"写入PLC尺寸信息失败");
}
}
isSuccess = true;
isSuccess = writeResult;
break;
}
}

@ -504,7 +504,7 @@ namespace XGLFinishPro.Views
}
if (i == 1)
{
width = 2.0;
width = 1.5;
}
if (i == 2)
{
@ -512,11 +512,11 @@ namespace XGLFinishPro.Views
}
if (i == 3)
{
width = 1.0;
width = 0.8;
}
if (i == 4)
{
width = 1.0;
width = 0.8;
}
this.MainGrid.ColumnDefinitions.Add(new ColumnDefinition()
{

Loading…
Cancel
Save