Merge branch 'dep_yangw' of http://175.27.215.92:3000/yangw/ProductionSystem into dep_yangw

dep_yangw
frankiecao 11 months ago
commit 1cee34ecf5

@ -1575,7 +1575,7 @@ namespace ProductionSystem.Forms
string plcTiaoMa=readM248.val.ToString().Replace("\r", "").Replace("\n", ""); string plcTiaoMa=readM248.val.ToString().Replace("\r", "").Replace("\n", "");
string tiaoma = txtProductCode.Text.Replace("\r", "").Replace("\n", ""); string tiaoma = txtProductCode.Text.Replace("\r", "").Replace("\n", "");
//彻底解决页面闪烁的问题 //彻底解决页面闪烁的问题
if (string.IsNullOrEmpty(plcTiaoMa) || tiaoma.Contains("暂无条码") || tiaoma == "" || tiaoma.Contains("暂")) if (string.IsNullOrEmpty(plcTiaoMa) || tiaoma.Contains("暂无条码") || tiaoma.Contains("暂"))
{ {
for (int i = 1; i < 9; i++) for (int i = 1; i < 9; i++)
{ {
@ -1636,8 +1636,6 @@ namespace ProductionSystem.Forms
{ {
string productBarCode = GetCode(); string productBarCode = GetCode();
var value = OmronHelper.GetPlcVal(entity.DataType, entity.Address); var value = OmronHelper.GetPlcVal(entity.DataType, entity.Address);
if (value.Item2.ToDouble().ToInt() == 1) if (value.Item2.ToDouble().ToInt() == 1)
{ {
@ -1658,51 +1656,77 @@ namespace ProductionSystem.Forms
{ {
t.Electricity = GetPlcValue("D1202"); t.Electricity = GetPlcValue("D1202");
t.Voltage = GetPlcValue("D1200"); t.Voltage = GetPlcValue("D1200");
if (t.Electricity != "0.000" || t.Voltage != "0.0000")
{
_result2Service.AddTResult2(t); _result2Service.AddTResult2(t);
} }
}
if (par == "BZ2") if (par == "BZ2")
{ {
t.Electricity = GetPlcValue("D1206"); t.Electricity = GetPlcValue("D1206");
t.Voltage = GetPlcValue("D1204"); t.Voltage = GetPlcValue("D1204");
if (t.Electricity != "0.000" || t.Voltage != "0.0000")
{
_result2Service.AddTResult2(t); _result2Service.AddTResult2(t);
} }
}
if (par == "BZ3") if (par == "BZ3")
{ {
t.Electricity = GetPlcValue("D1210"); t.Electricity = GetPlcValue("D1210");
t.Voltage = GetPlcValue("D1208"); t.Voltage = GetPlcValue("D1208");
if (t.Electricity != "0.000" || t.Voltage != "0.0000")
{
_result2Service.AddTResult2(t); _result2Service.AddTResult2(t);
} }
}
//高压 //高压
if (par == "BZ4") if (par == "BZ4")
{ {
t.Xll = GetPlcValue("D1224"); t.Xll = GetPlcValue("D1224");
t.Xllzt = GetPlcValue("D1226"); t.Xllzt = GetPlcValue("D1226");
if (t.Xll != "0.000" || t.Xllzt != "0.0000")
{
_result2Service.AddTResult2(t); _result2Service.AddTResult2(t);
} }
}
//内1 //内1
if (par == "BZ5") if (par == "BZ5")
{ {
t.Xll = GetPlcValue("D1212");
t.Xllzt = GetPlcValue("D1112"); t.Xll = GetPlcValue("D1214");
t.Xllzt = GetPlcValue("D1114");
if (t.Xll != "0.000" || t.Xllzt != "0.0000")
{
_result2Service.AddTResult2(t); _result2Service.AddTResult2(t);
} }
}
//内2 //内2
if (par == "BZ6") if (par == "BZ6")
{ {
t.Xll = GetPlcValue("D1214"); t.Xll = GetPlcValue("D1216");
t.Xllzt = GetPlcValue("D1114"); t.Xllzt = GetPlcValue("D1116");
if (t.Xll != "0.000" || t.Xllzt != "0.0000")
{
_result2Service.AddTResult2(t); _result2Service.AddTResult2(t);
} }
}
//外漏 //外漏
if (par == "BZ7") if (par == "BZ7")
{ {
t.Xll = GetPlcValue("D1216"); t.Xll = GetPlcValue("D1212");
t.Xllzt = GetPlcValue("D1116"); t.Xllzt = GetPlcValue("D1112");
if (t.Xll != "0.000" || t.Xllzt != "0.0000")
{
_result2Service.AddTResult2(t); _result2Service.AddTResult2(t);
} }
}

Loading…
Cancel
Save