清理无用代码
This commit is contained in:
@@ -1,9 +1,7 @@
|
|||||||
|
|
||||||
using JinYuan.CommunicationLib.Enum;
|
using JinYuan.CommunicationLib.Enum;
|
||||||
using JinYuan.CommunicationLib.Helper;
|
|
||||||
using JinYuan.DataConvertLib;
|
using JinYuan.DataConvertLib;
|
||||||
using JinYuan.Helper;
|
using JinYuan.Helper;
|
||||||
using JinYuan.MES.Enums;
|
|
||||||
using JinYuan.MES.Models;
|
using JinYuan.MES.Models;
|
||||||
using JinYuan.Models;
|
using JinYuan.Models;
|
||||||
using JinYuan.VirtualDataLibrary;
|
using JinYuan.VirtualDataLibrary;
|
||||||
@@ -11,20 +9,14 @@ using Newtonsoft.Json;
|
|||||||
using PLCCommunication;
|
using PLCCommunication;
|
||||||
using SqlSugar;
|
using SqlSugar;
|
||||||
using System;
|
using System;
|
||||||
using System.Collections;
|
|
||||||
using System.Collections.Generic;
|
using System.Collections.Generic;
|
||||||
using System.Collections.ObjectModel;
|
using System.Collections.ObjectModel;
|
||||||
using System.Data.SqlTypes;
|
|
||||||
using System.Diagnostics;
|
using System.Diagnostics;
|
||||||
using System.IO;
|
using System.IO;
|
||||||
using System.Linq;
|
using System.Linq;
|
||||||
using System.Net.NetworkInformation;
|
|
||||||
using System.Runtime.InteropServices.ComTypes;
|
|
||||||
using System.Text;
|
|
||||||
using System.Threading;
|
using System.Threading;
|
||||||
using System.Threading.Tasks;
|
using System.Threading.Tasks;
|
||||||
using System.Windows.Forms;
|
using System.Windows.Forms;
|
||||||
using static System.Runtime.CompilerServices.RuntimeHelpers;
|
|
||||||
|
|
||||||
|
|
||||||
namespace JinYuan.ControlCenters
|
namespace JinYuan.ControlCenters
|
||||||
@@ -270,7 +262,7 @@ namespace JinYuan.ControlCenters
|
|||||||
if (resByte == null)
|
if (resByte == null)
|
||||||
{
|
{
|
||||||
CommonMethods.AddDataMonitorLog(0, $"上料工位:{pf.GroupName},起始地址:{pf.VarList[1].VarAddress},得到空字节数组");
|
CommonMethods.AddDataMonitorLog(0, $"上料工位:{pf.GroupName},起始地址:{pf.VarList[1].VarAddress},得到空字节数组");
|
||||||
LoggerHelp.WriteLog("循环读取PLC上料工位"+$"读取工位:{pf.GroupName},起始地址:{pf.VarList[1].VarAddress},得到空字节数组");
|
LoggerHelp.WriteLog("循环读取PLC上料工位" + $"读取工位:{pf.GroupName},起始地址:{pf.VarList[1].VarAddress},得到空字节数组");
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
|
|||||||
@@ -3,23 +3,14 @@ using JinYuan.CommunicationLib.Enum;
|
|||||||
using JinYuan.DataConvertLib;
|
using JinYuan.DataConvertLib;
|
||||||
using JinYuan.Helper;
|
using JinYuan.Helper;
|
||||||
using JinYuan.MES.Enums;
|
using JinYuan.MES.Enums;
|
||||||
using JinYuan.MES.Models;
|
|
||||||
using JinYuan.Models;
|
using JinYuan.Models;
|
||||||
using JinYuan.VirtualDataLibrary;
|
using JinYuan.VirtualDataLibrary;
|
||||||
using PLCCommunication;
|
using PLCCommunication;
|
||||||
using SqlSugar;
|
|
||||||
using System;
|
using System;
|
||||||
using System.Collections;
|
|
||||||
using System.Collections.Generic;
|
using System.Collections.Generic;
|
||||||
using System.Data;
|
|
||||||
using System.Diagnostics;
|
using System.Diagnostics;
|
||||||
using System.Diagnostics.Eventing.Reader;
|
|
||||||
using System.IO;
|
|
||||||
using System.Linq;
|
|
||||||
using System.Text;
|
|
||||||
using System.Threading;
|
using System.Threading;
|
||||||
using System.Threading.Tasks;
|
using System.Threading.Tasks;
|
||||||
using static System.Windows.Forms.VisualStyles.VisualStyleElement.TaskbarClock;
|
|
||||||
|
|
||||||
namespace JinYuan.ControlCenters
|
namespace JinYuan.ControlCenters
|
||||||
{
|
{
|
||||||
@@ -157,37 +148,112 @@ namespace JinYuan.ControlCenters
|
|||||||
// return Result;
|
// return Result;
|
||||||
//}
|
//}
|
||||||
/// <summary>
|
/// <summary>
|
||||||
/// 判断总结果 Code_NG
|
/// 判断总结果
|
||||||
/// </summary>
|
/// </summary>
|
||||||
private int JudgmentResult(int Code_NG, int[,] CCD_Data,int codeIndex)
|
private int JudgmentResult(int A, int B, int C, int D, int E, int F, int G, int H, int I, int J, int K, int L, int M, int N)
|
||||||
{
|
{
|
||||||
|
//条码,芯包重量,芯包侧厚,芯包CCD极性检测,电芯裁切粘连,电芯裁切毛刺,芯包铜焊印位置,
|
||||||
|
//芯包正面极耳撕裂H,芯包背面极耳撕裂,芯包正面极耳翻折J,芯包背面极耳翻折,测厚压力结果,
|
||||||
|
//焊前CCD检测结果,铝焊印位置判定结果
|
||||||
|
|
||||||
|
//目前先判断条码,芯包重量,芯包侧厚,芯包CCD极性检测,芯包正面极耳撕裂,芯包正面极耳翻折
|
||||||
int Result = 0;
|
int Result = 0;
|
||||||
OK_NG = "OK";
|
OK_NG = "OK";
|
||||||
//是否有条码NG 1 = OK 2 = NG
|
if (A == 2 || B == 2 || C == 2 || D == 2 || H == 2 || J == 2)
|
||||||
if (Code_NG == 2)
|
|
||||||
{
|
{
|
||||||
NG_Type += "无条码_";
|
//ed
|
||||||
OK_NG = "NG";
|
|
||||||
Result = 2;
|
Result = 2;
|
||||||
|
OK_NG = "NG";
|
||||||
}
|
}
|
||||||
//CCD 判定
|
else if (A == 1 && B == 1 && C == 1 && D == 1 && H == 1 && J == 1)
|
||||||
for (int i = 0; i < 27; i++)
|
|
||||||
{
|
{
|
||||||
//CCD 0 = OK 1 = NG 2 缺图NG
|
Result = 1;
|
||||||
if (CCD_Data[codeIndex, i] == 1)
|
OK_NG = "OK";
|
||||||
{
|
}
|
||||||
NG_Type += $"CCD{i}NG_";
|
else
|
||||||
OK_NG = "NG";
|
{
|
||||||
Result = 2;
|
Result = 1;
|
||||||
}
|
OK_NG = "OK";
|
||||||
if (CCD_Data[codeIndex, i] == 2)
|
|
||||||
{
|
|
||||||
NG_Type += $"CCD{i}缺图NG_";
|
|
||||||
OK_NG = "NG";
|
|
||||||
Result = 2;
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
|
|
||||||
|
if (A == 2)
|
||||||
|
{
|
||||||
|
NG_Type += "无条码_";
|
||||||
|
Result = 2;
|
||||||
|
}
|
||||||
|
if (B == 2)
|
||||||
|
{
|
||||||
|
NG_Type += "芯包重量1NG_";
|
||||||
|
//return 2;
|
||||||
|
Result = 2;
|
||||||
|
}
|
||||||
|
if (C == 2)
|
||||||
|
{
|
||||||
|
NG_Type += "芯包侧厚NG_";
|
||||||
|
//return 2;
|
||||||
|
Result = 2;
|
||||||
|
}
|
||||||
|
if (D == 2)
|
||||||
|
{
|
||||||
|
NG_Type += "芯包CCD极性检测NG_";
|
||||||
|
//return 2;
|
||||||
|
Result = 2;
|
||||||
|
}
|
||||||
|
|
||||||
|
//if (E == 2)
|
||||||
|
//{
|
||||||
|
// NG_Type += "电芯裁切粘连NG_";
|
||||||
|
// //return 2;
|
||||||
|
//}
|
||||||
|
//if (F == 2)
|
||||||
|
//{
|
||||||
|
// NG_Type += "电芯裁切毛刺NG_";
|
||||||
|
// //return 2;
|
||||||
|
//}
|
||||||
|
//if (G == 2)
|
||||||
|
//{
|
||||||
|
// NG_Type += "芯包铜焊印位置判定NG_";
|
||||||
|
// //return 2;
|
||||||
|
//}
|
||||||
|
if (H == 2)
|
||||||
|
{
|
||||||
|
NG_Type += "芯包正面极耳撕裂NG_";
|
||||||
|
//return 2;
|
||||||
|
}
|
||||||
|
//if (I == 2)
|
||||||
|
//{
|
||||||
|
// NG_Type += "芯包背面极耳撕裂NG_";
|
||||||
|
// //return 2;
|
||||||
|
//}
|
||||||
|
if (J == 2)
|
||||||
|
{
|
||||||
|
NG_Type += "芯包正面极耳翻折NG_";
|
||||||
|
//return 2;
|
||||||
|
}
|
||||||
|
//if (K == 2)
|
||||||
|
//{
|
||||||
|
// NG_Type += "芯包背面极耳翻折NG_";
|
||||||
|
// //return 2;
|
||||||
|
//}
|
||||||
|
if (L == 2)
|
||||||
|
{
|
||||||
|
NG_Type += "测厚压力NG_";
|
||||||
|
//return 2;
|
||||||
|
}
|
||||||
|
if (M == 2)
|
||||||
|
{
|
||||||
|
NG_Type += "焊前CCD检测NG_";
|
||||||
|
//return 2;
|
||||||
|
}
|
||||||
|
if (N == 2)
|
||||||
|
{
|
||||||
|
NG_Type += "铝焊印位置判定NG_";
|
||||||
|
//return 2;
|
||||||
|
}
|
||||||
|
if (Result == 1)
|
||||||
|
{
|
||||||
|
NG_Type += "OK_";
|
||||||
|
}
|
||||||
return Result;
|
return Result;
|
||||||
}
|
}
|
||||||
#region 上料工位(数据处理)
|
#region 上料工位(数据处理)
|
||||||
@@ -1674,22 +1740,17 @@ namespace JinYuan.ControlCenters
|
|||||||
AGearEntity TT = new AGearEntity();
|
AGearEntity TT = new AGearEntity();
|
||||||
//极限件标志
|
//极限件标志
|
||||||
int ChallengeFlag = 0;
|
int ChallengeFlag = 0;
|
||||||
//芯包信息1 D3300~D3327
|
//芯包信息1 D3300~D3326
|
||||||
//芯包信息2 D3330~D3357
|
//芯包信息2 D3330~D3356
|
||||||
//芯包信息3 D3360~D3387
|
//芯包信息3 D3360~D3386
|
||||||
for (int j = 0; j < 28; j++)
|
for (int j = 0; j < 27; j++)
|
||||||
{
|
{
|
||||||
m.CCD_Data[i,j] = ShortLib.GetShortFromByteArray(bArrays.Content, 200 + i * 30 * 2 + j * 2, DataFormat.CDAB);
|
m.CCD_Data[i, j] = ShortLib.GetShortFromByteArray(bArrays.Content, 200 + i * 30 * 2 + j * 2, DataFormat.CDAB);
|
||||||
}
|
}
|
||||||
//电芯1缺陷代码 D3400~D3427
|
for (int j = 0; j < 3; j++)
|
||||||
//电芯2缺陷代码 D3430~D3457
|
|
||||||
//电芯3缺陷代码 D3460~D3487
|
|
||||||
for (int j = 0; j < 28; j++)
|
|
||||||
{
|
{
|
||||||
m.list_Data1[i, j] = ShortLib.GetShortFromByteArray(bArrays.Content, 400 + i * 30 * 2 + j * 2, DataFormat.CDAB);
|
m.Thickness_Data[i, j] = FloatLib.GetFloatFromByteArray(bArrays.Content, 400 + i * 30 * 2 + j * 4, DataFormat.CDAB);
|
||||||
}
|
}
|
||||||
//电池厚度 D3500 D3502 D3504
|
|
||||||
m.Thickness_Data[i] = FloatLib.GetFloatFromByteArray(bArrays.Content, 600 + i * 4, DataFormat.CDAB);
|
|
||||||
|
|
||||||
//芯包扫码时间
|
//芯包扫码时间
|
||||||
//m.ScanTime[i] = DateTime.Now.ToString("yyyy-MM-dd HH:mm:ss");
|
//m.ScanTime[i] = DateTime.Now.ToString("yyyy-MM-dd HH:mm:ss");
|
||||||
@@ -1740,40 +1801,38 @@ namespace JinYuan.ControlCenters
|
|||||||
|
|
||||||
//不良代码判定
|
//不良代码判定
|
||||||
List<string> NGcodeList = new List<string>();
|
List<string> NGcodeList = new List<string>();
|
||||||
NGcodeList = NGWGcode(m.list_Data1,i);
|
NGcodeList = NGcode(m.list_Data1[i, 10], m.list_Data1[i, 11], m.list_Data1[i, 12], m.list_Data1[i, 15], m.list_Data1[i, 26], m.list_Data1[i, 16]
|
||||||
// NGcode(m.list_Data1[i, 10], m.list_Data1[i, 11], m.list_Data1[i, 12], m.list_Data1[i, 15], m.list_Data1[i, 26], m.list_Data1[i, 16]
|
, m.list_Data1[i, 17], m.list_Data1[i, 18], m.list_Data1[i, 19], m.list_Data1[i, 23], m.list_Data1[i, 24], m.list_Data1[i, 25], m.list_Data1[i, 27]);
|
||||||
//, m.list_Data1[i, 17], m.list_Data1[i, 18], m.list_Data1[i, 19], m.list_Data1[i, 23], m.list_Data1[i, 24], m.list_Data1[i, 25], m.list_Data1[i, 27]);
|
|
||||||
|
|
||||||
//电芯CCD判定结果
|
//电芯CCD判定结果
|
||||||
#region //电芯CCD判定结果
|
#region //电芯CCD判定结果
|
||||||
m.CCDResult1 = m.CCD_Data[i, 0] == 1 ? "OK" : (m.CCD_Data[i, 0] == 0 ? "NG" : "缺图");
|
m.CCDResult1 = m.CCD_Data[i, 0] == 0 ? "OK" : (m.CCD_Data[i, 0] == 1 ? "NG" : "缺图");
|
||||||
m.CCDResult2 = m.CCD_Data[i, 1] == 1 ? "OK" : (m.CCD_Data[i, 1] == 0 ? "NG" : "缺图");
|
m.CCDResult2 = m.CCD_Data[i, 1] == 0 ? "OK" : (m.CCD_Data[i, 1] == 1 ? "NG" : "缺图");
|
||||||
m.CCDResult3 = m.CCD_Data[i, 2] == 1 ? "OK" : (m.CCD_Data[i, 2] == 0 ? "NG" : "缺图");
|
m.CCDResult3 = m.CCD_Data[i, 2] == 0 ? "OK" : (m.CCD_Data[i, 2] == 1 ? "NG" : "缺图");
|
||||||
m.CCDResult4 = m.CCD_Data[i, 3] == 1 ? "OK" : (m.CCD_Data[i, 3] == 0 ? "NG" : "缺图");
|
m.CCDResult4 = m.CCD_Data[i, 3] == 0 ? "OK" : (m.CCD_Data[i, 3] == 1 ? "NG" : "缺图");
|
||||||
m.CCDResult5 = m.CCD_Data[i, 4] == 1 ? "OK" : (m.CCD_Data[i, 4] == 0 ? "NG" : "缺图");
|
m.CCDResult5 = m.CCD_Data[i, 4] == 0 ? "OK" : (m.CCD_Data[i, 4] == 1 ? "NG" : "缺图");
|
||||||
m.CCDResult6 = m.CCD_Data[i, 5] == 1 ? "OK" : (m.CCD_Data[i, 5] == 0 ? "NG" : "缺图");
|
m.CCDResult6 = m.CCD_Data[i, 5] == 0 ? "OK" : (m.CCD_Data[i, 5] == 1 ? "NG" : "缺图");
|
||||||
m.CCDResult7 = m.CCD_Data[i, 6] == 1 ? "OK" : (m.CCD_Data[i, 6] == 0 ? "NG" : "缺图");
|
m.CCDResult7 = m.CCD_Data[i, 6] == 0 ? "OK" : (m.CCD_Data[i, 6] == 1 ? "NG" : "缺图");
|
||||||
m.CCDResult8 = m.CCD_Data[i, 7] == 1 ? "OK" : (m.CCD_Data[i, 7] == 0 ? "NG" : "缺图");
|
m.CCDResult8 = m.CCD_Data[i, 7] == 0 ? "OK" : (m.CCD_Data[i, 7] == 1 ? "NG" : "缺图");
|
||||||
m.CCDResult9 = m.CCD_Data[i, 8] == 1 ? "OK" : (m.CCD_Data[i, 8] == 0 ? "NG" : "缺图");
|
m.CCDResult9 = m.CCD_Data[i, 8] == 0 ? "OK" : (m.CCD_Data[i, 8] == 1 ? "NG" : "缺图");
|
||||||
m.CCDResult10 = m.CCD_Data[i, 9] == 1 ? "OK" : (m.CCD_Data[i, 9] == 0 ? "NG" : "缺图");
|
m.CCDResult10 = m.CCD_Data[i, 9] == 0 ? "OK" : (m.CCD_Data[i, 9] == 1 ? "NG" : "缺图");
|
||||||
m.CCDResult11 = m.CCD_Data[i, 10] == 1 ? "OK" : (m.CCD_Data[i, 10] == 0 ? "NG" : "缺图");
|
m.CCDResult11 = m.CCD_Data[i, 10] == 0 ? "OK" : (m.CCD_Data[i, 10] == 1 ? "NG" : "缺图");
|
||||||
m.CCDResult12 = m.CCD_Data[i, 11] == 1 ? "OK" : (m.CCD_Data[i, 11] == 0 ? "NG" : "缺图");
|
m.CCDResult12 = m.CCD_Data[i, 11] == 0 ? "OK" : (m.CCD_Data[i, 11] == 1 ? "NG" : "缺图");
|
||||||
m.CCDResult13 = m.CCD_Data[i, 12] == 1 ? "OK" : (m.CCD_Data[i, 12] == 0 ? "NG" : "缺图");
|
m.CCDResult13 = m.CCD_Data[i, 12] == 0 ? "OK" : (m.CCD_Data[i, 12] == 1 ? "NG" : "缺图");
|
||||||
m.CCDResult14 = m.CCD_Data[i, 13] == 1 ? "OK" : (m.CCD_Data[i, 13] == 0 ? "NG" : "缺图");
|
m.CCDResult14 = m.CCD_Data[i, 13] == 0 ? "OK" : (m.CCD_Data[i, 13] == 1 ? "NG" : "缺图");
|
||||||
m.CCDResult15 = m.CCD_Data[i, 14] == 1 ? "OK" : (m.CCD_Data[i, 14] == 0 ? "NG" : "缺图");
|
m.CCDResult15 = m.CCD_Data[i, 14] == 0 ? "OK" : (m.CCD_Data[i, 14] == 1 ? "NG" : "缺图");
|
||||||
m.CCDResult16 = m.CCD_Data[i, 15] == 1 ? "OK" : (m.CCD_Data[i, 15] == 0 ? "NG" : "缺图");
|
m.CCDResult16 = m.CCD_Data[i, 15] == 0 ? "OK" : (m.CCD_Data[i, 15] == 1 ? "NG" : "缺图");
|
||||||
m.CCDResult17 = m.CCD_Data[i, 16] == 1 ? "OK" : (m.CCD_Data[i, 16] == 0 ? "NG" : "缺图");
|
m.CCDResult17 = m.CCD_Data[i, 16] == 0 ? "OK" : (m.CCD_Data[i, 16] == 1 ? "NG" : "缺图");
|
||||||
m.CCDResult18 = m.CCD_Data[i, 17] == 1 ? "OK" : (m.CCD_Data[i, 17] == 0 ? "NG" : "缺图");
|
m.CCDResult18 = m.CCD_Data[i, 17] == 0 ? "OK" : (m.CCD_Data[i, 17] == 1 ? "NG" : "缺图");
|
||||||
m.CCDResult19 = m.CCD_Data[i, 18] == 1 ? "OK" : (m.CCD_Data[i, 18] == 0 ? "NG" : "缺图");
|
m.CCDResult19 = m.CCD_Data[i, 18] == 0 ? "OK" : (m.CCD_Data[i, 18] == 1 ? "NG" : "缺图");
|
||||||
m.CCDResult20 = m.CCD_Data[i, 19] == 1 ? "OK" : (m.CCD_Data[i, 19] == 0 ? "NG" : "缺图");
|
m.CCDResult20 = m.CCD_Data[i, 19] == 0 ? "OK" : (m.CCD_Data[i, 19] == 1 ? "NG" : "缺图");
|
||||||
m.CCDResult21 = m.CCD_Data[i, 20] == 1 ? "OK" : (m.CCD_Data[i, 20] == 0 ? "NG" : "缺图");
|
m.CCDResult21 = m.CCD_Data[i, 20] == 0 ? "OK" : (m.CCD_Data[i, 20] == 1 ? "NG" : "缺图");
|
||||||
m.CCDResult22 = m.CCD_Data[i, 21] == 1 ? "OK" : (m.CCD_Data[i, 21] == 0 ? "NG" : "缺图");
|
m.CCDResult22 = m.CCD_Data[i, 21] == 0 ? "OK" : (m.CCD_Data[i, 21] == 1 ? "NG" : "缺图");
|
||||||
m.CCDResult23 = m.CCD_Data[i, 22] == 1 ? "OK" : (m.CCD_Data[i, 22] == 0 ? "NG" : "缺图");
|
m.CCDResult23 = m.CCD_Data[i, 22] == 0 ? "OK" : (m.CCD_Data[i, 22] == 1 ? "NG" : "缺图");
|
||||||
m.CCDResult24 = m.CCD_Data[i, 23] == 1 ? "OK" : (m.CCD_Data[i, 23] == 0 ? "NG" : "缺图");
|
m.CCDResult24 = m.CCD_Data[i, 23] == 0 ? "OK" : (m.CCD_Data[i, 23] == 1 ? "NG" : "缺图");
|
||||||
m.CCDResult25 = m.CCD_Data[i, 24] == 1 ? "OK" : (m.CCD_Data[i, 24] == 0 ? "NG" : "缺图");
|
m.CCDResult25 = m.CCD_Data[i, 24] == 0 ? "OK" : (m.CCD_Data[i, 24] == 1 ? "NG" : "缺图");
|
||||||
m.CCDResult26 = m.CCD_Data[i, 25] == 1 ? "OK" : (m.CCD_Data[i, 25] == 0 ? "NG" : "缺图");
|
m.CCDResult26 = m.CCD_Data[i, 25] == 0 ? "OK" : (m.CCD_Data[i, 25] == 1 ? "NG" : "缺图");
|
||||||
m.CCDResult27 = m.CCD_Data[i, 26] == 1 ? "OK" : (m.CCD_Data[i, 26] == 0 ? "NG" : "缺图");
|
m.CCDResult27 = m.CCD_Data[i, 26] == 0 ? "OK" : (m.CCD_Data[i, 26] == 1 ? "NG" : "缺图");
|
||||||
m.CCDResult28 = m.CCD_Data[i, 27] == 1 ? "OK" : (m.CCD_Data[i, 27] == 0 ? "NG" : "缺图");
|
|
||||||
#endregion
|
#endregion
|
||||||
|
|
||||||
m.CSBYHASCANNINGTIME = DateTime.Now.ToString("yyyy-MM-dd HH:mm:ss");
|
m.CSBYHASCANNINGTIME = DateTime.Now.ToString("yyyy-MM-dd HH:mm:ss");
|
||||||
@@ -1782,14 +1841,27 @@ namespace JinYuan.ControlCenters
|
|||||||
m.CSBYHINSTATIONTIME = m.ScanTime[0];
|
m.CSBYHINSTATIONTIME = m.ScanTime[0];
|
||||||
m.CSBYHOUTSTATIONTIME = m.ScanTime[1];
|
m.CSBYHOUTSTATIONTIME = m.ScanTime[1];
|
||||||
|
|
||||||
//电芯1厚度数据1,2,3 改为 电芯1厚度 ;3字段只需1字段
|
m.Thickness1 = SaveTwoNum(m.Thickness_Data[i, 0]);
|
||||||
m.Thickness1 = SaveTwoNum(m.Thickness_Data[i]);
|
m.Thickness2 = SaveTwoNum(m.Thickness_Data[i, 1]);
|
||||||
m.Thickness2 = SaveTwoNum(m.Thickness_Data[i]);
|
m.Thickness3 = SaveTwoNum(m.Thickness_Data[i, 2]);
|
||||||
m.Thickness3 = SaveTwoNum(m.Thickness_Data[i]);
|
|
||||||
|
|
||||||
|
//条码,芯包重量,芯包侧厚,芯包CCD极性检测,电芯裁切粘连,电芯裁切毛刺,芯包焊印位置,
|
||||||
|
//芯包正面极耳撕裂,芯包背面极耳撕裂,芯包正面极耳翻折,芯包背面极耳翻折
|
||||||
|
if (Code_NG == 1)
|
||||||
|
{
|
||||||
|
for (int ii = 0; ii < 27; ii++)
|
||||||
|
{
|
||||||
|
if (m.CCD_Data[i, ii] != 0)
|
||||||
|
{
|
||||||
|
MyRes[i] = m.CCD_Data[i, ii];
|
||||||
|
break;
|
||||||
|
}
|
||||||
|
|
||||||
//芯包OKNG结果值判定
|
}
|
||||||
MyRes[i] = JudgmentResult(Code_NG, m.CCD_Data,i);
|
}
|
||||||
|
else
|
||||||
|
MyRes[i] = 1;
|
||||||
|
//MyRes[i] = JudgmentResult(Code_NG, m.CCD_Data);
|
||||||
|
|
||||||
m.Result = MyRes[i];
|
m.Result = MyRes[i];
|
||||||
|
|
||||||
@@ -1841,7 +1913,12 @@ namespace JinYuan.ControlCenters
|
|||||||
{
|
{
|
||||||
//MES出站判定结果
|
//MES出站判定结果
|
||||||
m.Result = MyRes[i];
|
m.Result = MyRes[i];
|
||||||
|
////芯包重量1判定结果
|
||||||
|
//if (m.list_Data1[i, 10] == 2) { m.Remark += "芯包重量NG,"; }
|
||||||
|
////芯包侧厚判定结果
|
||||||
|
//if (m.list_Data1[i, 11] == 2) { m.Remark += "芯包侧厚NG,"; }
|
||||||
|
////芯包CCD极性检测结果
|
||||||
|
//if (m.list_Data1[i, 12] == 2) { m.Remark += "芯包CCD极性检测NG,"; }
|
||||||
m.Remark += MesMessage;
|
m.Remark += MesMessage;
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
@@ -1867,7 +1944,12 @@ namespace JinYuan.ControlCenters
|
|||||||
m.Result = MyRes[i] = 2;
|
m.Result = MyRes[i] = 2;
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
|
////芯包重量1判定结果
|
||||||
|
//if (m.list_Data1[i, 10] == 2) { m.Remark += "芯包重量NG,"; }
|
||||||
|
////芯包侧厚判定结果
|
||||||
|
//if (m.list_Data1[i, 11] == 2) { m.Remark += "芯包侧厚NG,"; }
|
||||||
|
////芯包CCD极性检测结果
|
||||||
|
//if (m.list_Data1[i, 12] == 2) { m.Remark += "芯包CCD极性检测NG,"; }
|
||||||
m.Remark += MesMessage;
|
m.Remark += MesMessage;
|
||||||
}
|
}
|
||||||
//发送产品结果参数给MES
|
//发送产品结果参数给MES
|
||||||
@@ -1896,6 +1978,12 @@ namespace JinYuan.ControlCenters
|
|||||||
{
|
{
|
||||||
m.Result = MyRes[i] = 2;
|
m.Result = MyRes[i] = 2;
|
||||||
m.Remark += "本地存储";
|
m.Remark += "本地存储";
|
||||||
|
//芯包重量1判定结果
|
||||||
|
if (m.list_Data1[i, 10] == 2) { m.Remark += ",芯包重量NG"; }
|
||||||
|
//芯包侧厚判定结果
|
||||||
|
if (m.list_Data1[i, 11] == 2) { m.Remark += ",芯包侧厚NG"; }
|
||||||
|
//芯包CCD极性检测结果
|
||||||
|
if (m.list_Data1[i, 12] == 2) { m.Remark += ",芯包CCD极性检测NG"; }
|
||||||
m.UpState = "未上传";
|
m.UpState = "未上传";
|
||||||
}
|
}
|
||||||
//极限件发3给PLC
|
//极限件发3给PLC
|
||||||
@@ -2124,31 +2212,9 @@ namespace JinYuan.ControlCenters
|
|||||||
|
|
||||||
return NGcodelist;
|
return NGcodelist;
|
||||||
}
|
}
|
||||||
/// <summary>
|
|
||||||
/// 下料外观检不良代码
|
|
||||||
/// </summary>
|
|
||||||
/// <returns></returns>
|
|
||||||
public List<string> NGWGcode(short[,] serialNum,int index)
|
|
||||||
{
|
|
||||||
|
|
||||||
List<string> NGcodelist = new List<string>();
|
|
||||||
var ngType = "A";
|
|
||||||
for (int i = 0; i < 28; i++)
|
|
||||||
{
|
|
||||||
if (serialNum[index,i] == 4 || serialNum[index,i] == 150 || serialNum[index, i] == 151)
|
|
||||||
ngType = "P";
|
|
||||||
if (serialNum[index, i] > 0)
|
|
||||||
{
|
|
||||||
var strserialNum = serialNum[index, i].ToString().PadLeft(3, '0');
|
|
||||||
NGcodelist.Add($"PFV{ngType}{strserialNum}");
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
return NGcodelist;
|
|
||||||
}
|
|
||||||
#endregion
|
#endregion
|
||||||
|
|
||||||
#region NG下料不良代码
|
#region NG下料不良代码
|
||||||
public List<string> NGCarcode(int a, int b, int c)
|
public List<string> NGCarcode(int a, int b, int c)
|
||||||
{
|
{
|
||||||
//芯包重量、测厚位移、极性
|
//芯包重量、测厚位移、极性
|
||||||
|
|||||||
@@ -1,19 +1,15 @@
|
|||||||
using JinYuan.CommunicationLib.Enum;
|
using HslCommunication.ModBus;
|
||||||
|
using JinYuan.CommunicationLib.Enum;
|
||||||
using JinYuan.DataConvertLib;
|
using JinYuan.DataConvertLib;
|
||||||
using JinYuan.Helper;
|
using JinYuan.Helper;
|
||||||
using JinYuan.MES.Enums;
|
|
||||||
using JinYuan.MES.Models;
|
using JinYuan.MES.Models;
|
||||||
using JinYuan.Models;
|
using JinYuan.Models;
|
||||||
using JinYuan.VirtualDataLibrary;
|
using JinYuan.VirtualDataLibrary;
|
||||||
using PLCCommunication;
|
using PLCCommunication;
|
||||||
using PLCCommunication.Language;
|
|
||||||
using System;
|
using System;
|
||||||
using System.Collections;
|
|
||||||
using System.Collections.Generic;
|
using System.Collections.Generic;
|
||||||
using System.Linq;
|
using System.Linq;
|
||||||
using System.Threading;
|
|
||||||
using System.Threading.Tasks;
|
using System.Threading.Tasks;
|
||||||
using HslCommunication.ModBus;
|
|
||||||
|
|
||||||
namespace JinYuan.ControlCenters
|
namespace JinYuan.ControlCenters
|
||||||
{
|
{
|
||||||
@@ -196,9 +192,9 @@ namespace JinYuan.ControlCenters
|
|||||||
//CommonMethods.Lst_DefectTypeQty.Add(new ChartDataType { DataType = "铜极耳剪切不良", DataCount = 0 });
|
//CommonMethods.Lst_DefectTypeQty.Add(new ChartDataType { DataType = "铜极耳剪切不良", DataCount = 0 });
|
||||||
//CommonMethods.Lst_DefectTypeQty.Add(new ChartDataType { DataType = "铝极耳剪切不良", DataCount = 0 });
|
//CommonMethods.Lst_DefectTypeQty.Add(new ChartDataType { DataType = "铝极耳剪切不良", DataCount = 0 });
|
||||||
|
|
||||||
CommonMethods.Lst_DefectTypeQty.Add(new ChartDataType { DataType = "扫码不良", DataCount = 0 });
|
CommonMethods.Lst_DefectTypeQty.Add(new ChartDataType { DataType = "扫码不良", DataCount = 0 });
|
||||||
CommonMethods.Lst_DefectTypeQty.Add(new ChartDataType { DataType = "MES不良", DataCount = 0 });
|
CommonMethods.Lst_DefectTypeQty.Add(new ChartDataType { DataType = "MES不良", DataCount = 0 });
|
||||||
CommonMethods.Lst_DefectTypeQty.Add(new ChartDataType { DataType = "其他不良" , DataCount = 0 });
|
CommonMethods.Lst_DefectTypeQty.Add(new ChartDataType { DataType = "其他不良", DataCount = 0 });
|
||||||
|
|
||||||
}
|
}
|
||||||
else //读取PLC数据
|
else //读取PLC数据
|
||||||
@@ -423,14 +419,14 @@ namespace JinYuan.ControlCenters
|
|||||||
string _anemometerAddress = "D15000";//风速仪起始地址
|
string _anemometerAddress = "D15000";//风速仪起始地址
|
||||||
if (CommonMethods.mesConfig.isUpMes)
|
if (CommonMethods.mesConfig.isUpMes)
|
||||||
{
|
{
|
||||||
JYResult<byte[]> jYResult = CommonMethods.PlcLink.ReadValue<JYResult<byte[]>>(_anemometerAddress, Data_Type.ArrByte,150);
|
JYResult<byte[]> jYResult = CommonMethods.PlcLink.ReadValue<JYResult<byte[]>>(_anemometerAddress, Data_Type.ArrByte, 150);
|
||||||
List<float> _anemograph = GetList<float>(_anemometerNumber, 0);//初始化列表
|
List<float> _anemograph = GetList<float>(_anemometerNumber, 0);//初始化列表
|
||||||
List<string> _anemometerName=new List<string>();
|
List<string> _anemometerName = new List<string>();
|
||||||
string _mesage = "";
|
string _mesage = "";
|
||||||
for (int i=0;i< _anemometerNumber;i++)
|
for (int i = 0; i < _anemometerNumber; i++)
|
||||||
{
|
{
|
||||||
//初始化风速仪名称
|
//初始化风速仪名称
|
||||||
int _temple = i+1;
|
int _temple = i + 1;
|
||||||
string _name = "风速仪" + _temple.ToString();
|
string _name = "风速仪" + _temple.ToString();
|
||||||
_anemometerName.Add(_name);
|
_anemometerName.Add(_name);
|
||||||
|
|
||||||
@@ -440,17 +436,17 @@ namespace JinYuan.ControlCenters
|
|||||||
//
|
//
|
||||||
// 写csv文件
|
// 写csv文件
|
||||||
string productName = string.Empty;
|
string productName = string.Empty;
|
||||||
string fileName=string.Empty;
|
string fileName = string.Empty;
|
||||||
string filePath=string.Empty;
|
string filePath = string.Empty;
|
||||||
DateTime nowDate = DateTime.Now;
|
DateTime nowDate = DateTime.Now;
|
||||||
string fileTitle= "工序名称,生产机台编号,拉线,型号,物料编号,操作人员,班次,采集时间,";
|
string fileTitle = "工序名称,生产机台编号,拉线,型号,物料编号,操作人员,班次,采集时间,";
|
||||||
string fileContent= $"预焊工序,{CommonMethods.mesConfig.equipNum},{CommonMethods.mesConfig.lineCode},{productName},{CommonMethods.mesConfig.MaterialCode},{CommonMethods.mesConfig.mesUserName},{CommonMethods.strClass},{nowDate.ToString("yyyy-MM-dd HH:mm:ss")},";
|
string fileContent = $"预焊工序,{CommonMethods.mesConfig.equipNum},{CommonMethods.mesConfig.lineCode},{productName},{CommonMethods.mesConfig.MaterialCode},{CommonMethods.mesConfig.mesUserName},{CommonMethods.strClass},{nowDate.ToString("yyyy-MM-dd HH:mm:ss")},";
|
||||||
filePath = $@"{CommonMethods.strAnemographpath}\{nowDate.Year}\{nowDate.Month}";
|
filePath = $@"{CommonMethods.strAnemographpath}\{nowDate.Year}\{nowDate.Month}";
|
||||||
fileName = $@"{nowDate.Day}.csv";
|
fileName = $@"{nowDate.Day}.csv";
|
||||||
|
|
||||||
for (int j = 0; j < _anemometerNumber; j++)
|
for (int j = 0; j < _anemometerNumber; j++)
|
||||||
{
|
{
|
||||||
fileTitle = fileTitle +","+ _anemometerName[j];
|
fileTitle = fileTitle + "," + _anemometerName[j];
|
||||||
fileContent = fileContent + "," + _anemograph[j];
|
fileContent = fileContent + "," + _anemograph[j];
|
||||||
}
|
}
|
||||||
CSVHelper<object>.WriterCSV(filePath, fileName, fileTitle, fileContent);
|
CSVHelper<object>.WriterCSV(filePath, fileName, fileTitle, fileContent);
|
||||||
|
|||||||
@@ -1,15 +1,12 @@
|
|||||||
using JinYuan.VirtualDataLibrary;
|
using JinYuan.Helper;
|
||||||
|
using JinYuan.MES;
|
||||||
|
using JinYuan.MES.Models;
|
||||||
|
using JinYuan.Models;
|
||||||
|
using JinYuan.VirtualDataLibrary;
|
||||||
using Newtonsoft.Json;
|
using Newtonsoft.Json;
|
||||||
using Newtonsoft.Json.Linq;
|
|
||||||
using System;
|
using System;
|
||||||
using System.Collections.Generic;
|
using System.Collections.Generic;
|
||||||
using System.Diagnostics;
|
using System.Diagnostics;
|
||||||
using JinYuan.Helper;
|
|
||||||
using JinYuan.MES;
|
|
||||||
using JinYuan.MES.Models;
|
|
||||||
using JinYuan.MES.Enums;
|
|
||||||
using JinYuan.Models;
|
|
||||||
using SqlSugar;
|
|
||||||
|
|
||||||
namespace JinYuan.ControlCenters
|
namespace JinYuan.ControlCenters
|
||||||
{
|
{
|
||||||
|
|||||||
@@ -1,5 +1,4 @@
|
|||||||
using System.Reflection;
|
using System.Reflection;
|
||||||
using System.Runtime.CompilerServices;
|
|
||||||
using System.Runtime.InteropServices;
|
using System.Runtime.InteropServices;
|
||||||
|
|
||||||
// 有关程序集的一般信息由以下
|
// 有关程序集的一般信息由以下
|
||||||
|
|||||||
@@ -1,10 +1,4 @@
|
|||||||
using System;
|
namespace JinYuan.DAL.Enums
|
||||||
using System.Collections.Generic;
|
|
||||||
using System.Linq;
|
|
||||||
using System.Text;
|
|
||||||
using System.Threading.Tasks;
|
|
||||||
|
|
||||||
namespace JinYuan.DAL.Enums
|
|
||||||
{
|
{
|
||||||
/// <summary>
|
/// <summary>
|
||||||
/// 查询条件枚举
|
/// 查询条件枚举
|
||||||
|
|||||||
@@ -3,14 +3,12 @@ using SqlSugar;
|
|||||||
using System;
|
using System;
|
||||||
using System.Collections.Generic;
|
using System.Collections.Generic;
|
||||||
using System.Data;
|
using System.Data;
|
||||||
using System.Linq;
|
|
||||||
using System.Linq.Expressions;
|
using System.Linq.Expressions;
|
||||||
using System.Text;
|
|
||||||
using System.Threading.Tasks;
|
using System.Threading.Tasks;
|
||||||
|
|
||||||
namespace JinYuan.DAL
|
namespace JinYuan.DAL
|
||||||
{
|
{
|
||||||
public interface ISugarHepler: IDisposable
|
public interface ISugarHepler : IDisposable
|
||||||
{
|
{
|
||||||
/// <summary>
|
/// <summary>
|
||||||
/// 初始化数据库连接
|
/// 初始化数据库连接
|
||||||
|
|||||||
@@ -1,9 +1,4 @@
|
|||||||
using JinYuan.DAL.Enums;
|
using JinYuan.DAL.Enums;
|
||||||
using System;
|
|
||||||
using System.Collections.Generic;
|
|
||||||
using System.Linq;
|
|
||||||
using System.Text;
|
|
||||||
using System.Threading.Tasks;
|
|
||||||
|
|
||||||
namespace JinYuan.DAL.Models
|
namespace JinYuan.DAL.Models
|
||||||
{
|
{
|
||||||
|
|||||||
@@ -1,9 +1,4 @@
|
|||||||
using JinYuan.DAL.Enums;
|
using JinYuan.DAL.Enums;
|
||||||
using System;
|
|
||||||
using System.Collections.Generic;
|
|
||||||
using System.Linq;
|
|
||||||
using System.Text;
|
|
||||||
using System.Threading.Tasks;
|
|
||||||
|
|
||||||
namespace JinYuan.DAL.Models
|
namespace JinYuan.DAL.Models
|
||||||
{
|
{
|
||||||
|
|||||||
@@ -1,8 +1,4 @@
|
|||||||
using System;
|
using System.Collections.Generic;
|
||||||
using System.Collections.Generic;
|
|
||||||
using System.Linq;
|
|
||||||
using System.Text;
|
|
||||||
using System.Threading.Tasks;
|
|
||||||
|
|
||||||
namespace JinYuan.DAL.Models
|
namespace JinYuan.DAL.Models
|
||||||
{
|
{
|
||||||
|
|||||||
@@ -1,5 +1,4 @@
|
|||||||
using System.Reflection;
|
using System.Reflection;
|
||||||
using System.Runtime.CompilerServices;
|
|
||||||
using System.Runtime.InteropServices;
|
using System.Runtime.InteropServices;
|
||||||
|
|
||||||
// 有关程序集的一般信息由以下
|
// 有关程序集的一般信息由以下
|
||||||
|
|||||||
@@ -3,11 +3,7 @@ using JinYuan.Helper;
|
|||||||
using SqlSugar;
|
using SqlSugar;
|
||||||
using System;
|
using System;
|
||||||
using System.Collections.Generic;
|
using System.Collections.Generic;
|
||||||
using System.Configuration;
|
|
||||||
using System.Linq;
|
using System.Linq;
|
||||||
using System.Runtime.Remoting.Contexts;
|
|
||||||
using System.Text;
|
|
||||||
using System.Threading.Tasks;
|
|
||||||
|
|
||||||
namespace JinYuan.DAL
|
namespace JinYuan.DAL
|
||||||
{
|
{
|
||||||
|
|||||||
@@ -1,8 +1,5 @@
|
|||||||
using JinYuan.DAL;
|
using JinYuan.DAL.Enums;
|
||||||
using JinYuan.DAL.Enums;
|
|
||||||
using JinYuan.DAL.Models;
|
using JinYuan.DAL.Models;
|
||||||
using NLog;
|
|
||||||
using Org.BouncyCastle.Asn1;
|
|
||||||
using SqlSugar;
|
using SqlSugar;
|
||||||
using System;
|
using System;
|
||||||
using System.Collections.Generic;
|
using System.Collections.Generic;
|
||||||
@@ -10,8 +7,6 @@ using System.Data;
|
|||||||
using System.Data.SqlClient;
|
using System.Data.SqlClient;
|
||||||
using System.Linq;
|
using System.Linq;
|
||||||
using System.Linq.Expressions;
|
using System.Linq.Expressions;
|
||||||
using System.Runtime.Remoting.Contexts;
|
|
||||||
using System.Text;
|
|
||||||
using System.Threading.Tasks;
|
using System.Threading.Tasks;
|
||||||
|
|
||||||
namespace JinYuan.DAL
|
namespace JinYuan.DAL
|
||||||
@@ -21,7 +16,7 @@ namespace JinYuan.DAL
|
|||||||
{
|
{
|
||||||
|
|
||||||
|
|
||||||
public void SetConnectionStr(string connectionStr, SqlSugar.DbType dbType= SqlSugar.DbType.SqlServer)
|
public void SetConnectionStr(string connectionStr, SqlSugar.DbType dbType = SqlSugar.DbType.SqlServer)
|
||||||
{
|
{
|
||||||
SQLSugarHelper.connString = connectionStr;
|
SQLSugarHelper.connString = connectionStr;
|
||||||
SqlSugarDb = SQLSugarHelper.SqlSugarClient;
|
SqlSugarDb = SQLSugarHelper.SqlSugarClient;
|
||||||
|
|||||||
@@ -2,7 +2,6 @@
|
|||||||
using System.Collections.Generic;
|
using System.Collections.Generic;
|
||||||
using System.Linq;
|
using System.Linq;
|
||||||
using System.Text;
|
using System.Text;
|
||||||
using System.Threading.Tasks;
|
|
||||||
|
|
||||||
namespace JinYuan.Helper
|
namespace JinYuan.Helper
|
||||||
{
|
{
|
||||||
|
|||||||
@@ -6,7 +6,6 @@ using System.Globalization;
|
|||||||
using System.IO;
|
using System.IO;
|
||||||
using System.Linq;
|
using System.Linq;
|
||||||
using System.Text;
|
using System.Text;
|
||||||
using System.Threading.Tasks;
|
|
||||||
|
|
||||||
namespace JinYuan.Helper
|
namespace JinYuan.Helper
|
||||||
{
|
{
|
||||||
|
|||||||
@@ -1,10 +1,6 @@
|
|||||||
using System;
|
using System;
|
||||||
using System.Collections.Generic;
|
|
||||||
using System.Drawing;
|
using System.Drawing;
|
||||||
using System.Drawing.Text;
|
using System.Drawing.Text;
|
||||||
using System.Linq;
|
|
||||||
using System.Text;
|
|
||||||
using System.Threading.Tasks;
|
|
||||||
using System.Windows.Forms.DataVisualization.Charting;
|
using System.Windows.Forms.DataVisualization.Charting;
|
||||||
|
|
||||||
namespace JinYuan.Helper
|
namespace JinYuan.Helper
|
||||||
|
|||||||
@@ -1,12 +1,8 @@
|
|||||||
using System;
|
using System.Linq;
|
||||||
using System.Collections.Generic;
|
|
||||||
using System.Linq;
|
|
||||||
using System.Text;
|
|
||||||
using System.Threading.Tasks;
|
|
||||||
|
|
||||||
namespace JinYuan.Helper
|
namespace JinYuan.Helper
|
||||||
{
|
{
|
||||||
public static class ConvertHelper
|
public static class ConvertHelper
|
||||||
{
|
{
|
||||||
/// <summary>
|
/// <summary>
|
||||||
/// 字节数组高低位转换
|
/// 字节数组高低位转换
|
||||||
|
|||||||
@@ -1,10 +1,6 @@
|
|||||||
using System;
|
using System;
|
||||||
using System.Collections.Generic;
|
|
||||||
using System.Drawing;
|
using System.Drawing;
|
||||||
using System.Linq;
|
|
||||||
using System.Reflection;
|
using System.Reflection;
|
||||||
using System.Text;
|
|
||||||
using System.Threading.Tasks;
|
|
||||||
using System.Windows.Forms;
|
using System.Windows.Forms;
|
||||||
|
|
||||||
namespace JinYuan.Helper
|
namespace JinYuan.Helper
|
||||||
@@ -41,7 +37,7 @@ namespace JinYuan.Helper
|
|||||||
/// </summary>
|
/// </summary>
|
||||||
/// <param name="dgv"></param>
|
/// <param name="dgv"></param>
|
||||||
/// <param name="e"></param>
|
/// <param name="e"></param>
|
||||||
public static void DgvRowPrePaint(DataGridView dgv,string Column, object sender, DataGridViewRowPrePaintEventArgs e)
|
public static void DgvRowPrePaint(DataGridView dgv, string Column, object sender, DataGridViewRowPrePaintEventArgs e)
|
||||||
{
|
{
|
||||||
|
|
||||||
if (e.RowIndex >= dgv.Rows.Count - 1)
|
if (e.RowIndex >= dgv.Rows.Count - 1)
|
||||||
@@ -50,7 +46,7 @@ namespace JinYuan.Helper
|
|||||||
|
|
||||||
try
|
try
|
||||||
{
|
{
|
||||||
if(dr.Cells[Column].Value != null)
|
if (dr.Cells[Column].Value != null)
|
||||||
{
|
{
|
||||||
if (dr.Cells[Column].Value.Equals("OK"))
|
if (dr.Cells[Column].Value.Equals("OK"))
|
||||||
{
|
{
|
||||||
|
|||||||
@@ -1,10 +1,7 @@
|
|||||||
using System;
|
using System;
|
||||||
using System.Collections.Generic;
|
using System.Collections.Generic;
|
||||||
using System.Data;
|
using System.Data;
|
||||||
using System.Linq;
|
|
||||||
using System.Reflection;
|
using System.Reflection;
|
||||||
using System.Text;
|
|
||||||
using System.Threading.Tasks;
|
|
||||||
|
|
||||||
namespace JinYuan.Helper
|
namespace JinYuan.Helper
|
||||||
{
|
{
|
||||||
|
|||||||
@@ -1,9 +1,6 @@
|
|||||||
using System;
|
using System;
|
||||||
using System.Collections.Generic;
|
|
||||||
using System.IO;
|
using System.IO;
|
||||||
using System.Linq;
|
|
||||||
using System.Runtime.InteropServices;
|
using System.Runtime.InteropServices;
|
||||||
using System.Text;
|
|
||||||
using System.Threading;
|
using System.Threading;
|
||||||
using System.Threading.Tasks;
|
using System.Threading.Tasks;
|
||||||
|
|
||||||
|
|||||||
@@ -1,4 +1,9 @@
|
|||||||
using System;
|
using NPOI.HSSF.UserModel;
|
||||||
|
using NPOI.SS.Formula.Eval;
|
||||||
|
using NPOI.SS.UserModel;
|
||||||
|
using NPOI.SS.Util;
|
||||||
|
using NPOI.XSSF.UserModel;
|
||||||
|
using System;
|
||||||
using System.Collections;
|
using System.Collections;
|
||||||
using System.Collections.Generic;
|
using System.Collections.Generic;
|
||||||
using System.Data;
|
using System.Data;
|
||||||
@@ -8,11 +13,6 @@ using System.Reflection;
|
|||||||
using System.Text;
|
using System.Text;
|
||||||
using System.Text.RegularExpressions;
|
using System.Text.RegularExpressions;
|
||||||
using System.Windows.Forms;
|
using System.Windows.Forms;
|
||||||
using NPOI.SS.UserModel;
|
|
||||||
using NPOI.HSSF.UserModel;
|
|
||||||
using NPOI.SS.Formula.Eval;
|
|
||||||
using NPOI.SS.Util;
|
|
||||||
using NPOI.XSSF.UserModel;
|
|
||||||
|
|
||||||
namespace JinYuan.Helper
|
namespace JinYuan.Helper
|
||||||
{
|
{
|
||||||
|
|||||||
@@ -1,11 +1,7 @@
|
|||||||
using System;
|
using System;
|
||||||
using System.Collections.Generic;
|
|
||||||
using System.IO;
|
using System.IO;
|
||||||
using System.Linq;
|
|
||||||
using System.Runtime.Serialization.Formatters.Binary;
|
|
||||||
using System.Runtime.Serialization;
|
using System.Runtime.Serialization;
|
||||||
using System.Text;
|
using System.Runtime.Serialization.Formatters.Binary;
|
||||||
using System.Threading.Tasks;
|
|
||||||
|
|
||||||
namespace JinYuan.Helper
|
namespace JinYuan.Helper
|
||||||
{
|
{
|
||||||
|
|||||||
@@ -1,10 +1,8 @@
|
|||||||
using System;
|
using System;
|
||||||
using System.Collections.Generic;
|
using System.Collections.Generic;
|
||||||
using System.IO;
|
using System.IO;
|
||||||
using System.Linq;
|
|
||||||
using System.Runtime.InteropServices;
|
using System.Runtime.InteropServices;
|
||||||
using System.Text;
|
using System.Text;
|
||||||
using System.Threading.Tasks;
|
|
||||||
|
|
||||||
namespace JinYuan.Helper
|
namespace JinYuan.Helper
|
||||||
{
|
{
|
||||||
|
|||||||
@@ -1,79 +1,75 @@
|
|||||||
using System;
|
using System.IO;
|
||||||
using System.Collections.Generic;
|
|
||||||
using System.IO;
|
|
||||||
using System.Linq;
|
|
||||||
using System.Runtime.InteropServices;
|
using System.Runtime.InteropServices;
|
||||||
using System.Text;
|
using System.Text;
|
||||||
using System.Threading.Tasks;
|
|
||||||
using System.Windows.Forms;
|
using System.Windows.Forms;
|
||||||
|
|
||||||
namespace JinYuan.Helper
|
namespace JinYuan.Helper
|
||||||
{
|
{
|
||||||
public class IniFileHelper
|
public class IniFileHelper
|
||||||
{
|
{
|
||||||
private static string iniFilePath = "Configure.ini";
|
private static string iniFilePath = "Configure.ini";
|
||||||
|
|
||||||
[DllImport("kernel32")]
|
[DllImport("kernel32")]
|
||||||
private static extern long WritePrivateProfileString(string section, string key, string val, string filePath);
|
private static extern long WritePrivateProfileString(string section, string key, string val, string filePath);
|
||||||
|
|
||||||
[DllImport("kernel32")]
|
[DllImport("kernel32")]
|
||||||
private static extern long GetPrivateProfileString(string section, string key, string def, StringBuilder retVal, int size, string filePath);
|
private static extern long GetPrivateProfileString(string section, string key, string def, StringBuilder retVal, int size, string filePath);
|
||||||
|
|
||||||
public static string ReadIniData(string Section, string Key)
|
public static string ReadIniData(string Section, string Key)
|
||||||
{
|
{
|
||||||
try
|
try
|
||||||
{
|
{
|
||||||
if (File.Exists(iniFilePath))
|
if (File.Exists(iniFilePath))
|
||||||
{
|
{
|
||||||
StringBuilder temp = new StringBuilder(1024);
|
StringBuilder temp = new StringBuilder(1024);
|
||||||
GetPrivateProfileString(Section, Key, "", temp, 1024, iniFilePath);
|
GetPrivateProfileString(Section, Key, "", temp, 1024, iniFilePath);
|
||||||
return temp.ToString();
|
return temp.ToString();
|
||||||
}
|
}
|
||||||
MessageBox.Show("节点:" + Section + ",键名:" + Key + ":读取配置文件错误!");
|
MessageBox.Show("节点:" + Section + ",键名:" + Key + ":读取配置文件错误!");
|
||||||
return null;
|
return null;
|
||||||
}
|
}
|
||||||
catch
|
catch
|
||||||
{
|
{
|
||||||
throw;
|
throw;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
public static bool WriteIniData(string Section, string Key, string Value)
|
public static bool WriteIniData(string Section, string Key, string Value)
|
||||||
{
|
{
|
||||||
try
|
try
|
||||||
{
|
{
|
||||||
if (File.Exists(iniFilePath))
|
if (File.Exists(iniFilePath))
|
||||||
{
|
{
|
||||||
if (WritePrivateProfileString(Section, Key, Value, iniFilePath) == 0L)
|
if (WritePrivateProfileString(Section, Key, Value, iniFilePath) == 0L)
|
||||||
{
|
{
|
||||||
return false;
|
return false;
|
||||||
}
|
}
|
||||||
return true;
|
return true;
|
||||||
}
|
}
|
||||||
File.Create(iniFilePath).Close();
|
File.Create(iniFilePath).Close();
|
||||||
if (WritePrivateProfileString(Section, Key, Value, iniFilePath) == 0L)
|
if (WritePrivateProfileString(Section, Key, Value, iniFilePath) == 0L)
|
||||||
{
|
{
|
||||||
return false;
|
return false;
|
||||||
}
|
}
|
||||||
return true;
|
return true;
|
||||||
}
|
}
|
||||||
catch
|
catch
|
||||||
{
|
{
|
||||||
throw;
|
throw;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
public static void CreateIniFile(string StartupPath, string AppName)
|
public static void CreateIniFile(string StartupPath, string AppName)
|
||||||
{
|
{
|
||||||
iniFilePath = StartupPath + AppName;
|
iniFilePath = StartupPath + AppName;
|
||||||
if (!Directory.Exists(StartupPath))
|
if (!Directory.Exists(StartupPath))
|
||||||
{
|
{
|
||||||
Directory.CreateDirectory(StartupPath);
|
Directory.CreateDirectory(StartupPath);
|
||||||
}
|
}
|
||||||
if (!File.Exists(iniFilePath))
|
if (!File.Exists(iniFilePath))
|
||||||
{
|
{
|
||||||
File.Create(iniFilePath).Close();
|
File.Create(iniFilePath).Close();
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -1,11 +1,8 @@
|
|||||||
using Newtonsoft.Json;
|
using Newtonsoft.Json;
|
||||||
using System;
|
using System;
|
||||||
using System.Collections.Generic;
|
|
||||||
using System.IO;
|
using System.IO;
|
||||||
using System.Linq;
|
|
||||||
using System.Runtime.Serialization.Json;
|
using System.Runtime.Serialization.Json;
|
||||||
using System.Text;
|
using System.Text;
|
||||||
using System.Threading.Tasks;
|
|
||||||
|
|
||||||
namespace JinYuan.Helper
|
namespace JinYuan.Helper
|
||||||
{
|
{
|
||||||
|
|||||||
@@ -1,7 +1,5 @@
|
|||||||
using NLog;
|
using NLog;
|
||||||
using System;
|
using System;
|
||||||
using System.IO;
|
|
||||||
using System.Linq;
|
|
||||||
|
|
||||||
public class LoggerHelp
|
public class LoggerHelp
|
||||||
{
|
{
|
||||||
|
|||||||
@@ -2,8 +2,6 @@
|
|||||||
using System;
|
using System;
|
||||||
using System.Collections.Generic;
|
using System.Collections.Generic;
|
||||||
using System.Linq;
|
using System.Linq;
|
||||||
using System.Text;
|
|
||||||
using System.Threading.Tasks;
|
|
||||||
|
|
||||||
namespace JinYuan.Helper
|
namespace JinYuan.Helper
|
||||||
{
|
{
|
||||||
|
|||||||
@@ -1,5 +1,4 @@
|
|||||||
using System.Reflection;
|
using System.Reflection;
|
||||||
using System.Runtime.CompilerServices;
|
|
||||||
using System.Runtime.InteropServices;
|
using System.Runtime.InteropServices;
|
||||||
|
|
||||||
// 有关程序集的一般信息由以下
|
// 有关程序集的一般信息由以下
|
||||||
|
|||||||
@@ -1,10 +1,8 @@
|
|||||||
using System;
|
using System;
|
||||||
using System.Collections.Generic;
|
using System.Collections.Generic;
|
||||||
using System.Diagnostics;
|
using System.Diagnostics;
|
||||||
using System.Linq;
|
|
||||||
using System.Runtime.InteropServices;
|
using System.Runtime.InteropServices;
|
||||||
using System.Text;
|
using System.Text;
|
||||||
using System.Threading.Tasks;
|
|
||||||
|
|
||||||
namespace JinYuan.Helper
|
namespace JinYuan.Helper
|
||||||
{
|
{
|
||||||
|
|||||||
@@ -1,15 +1,11 @@
|
|||||||
using HslCommunication.MQTT;
|
using HslCommunication;
|
||||||
using HslCommunication;
|
using HslCommunication.MQTT;
|
||||||
|
using JinYuan.Models;
|
||||||
using Newtonsoft.Json;
|
using Newtonsoft.Json;
|
||||||
using System;
|
using System;
|
||||||
using System.Collections.Generic;
|
using System.Collections.Generic;
|
||||||
using System.Collections.ObjectModel;
|
|
||||||
using System.Linq;
|
|
||||||
using System.Text;
|
|
||||||
using System.IO;
|
using System.IO;
|
||||||
using System.Threading.Tasks;
|
using System.Text;
|
||||||
using System.Security.Policy;
|
|
||||||
using JinYuan.Models;
|
|
||||||
|
|
||||||
namespace JinYuan.Helper
|
namespace JinYuan.Helper
|
||||||
{
|
{
|
||||||
@@ -96,7 +92,7 @@ namespace JinYuan.Helper
|
|||||||
/// <param name="IP"></param>
|
/// <param name="IP"></param>
|
||||||
/// <param name="Port"></param>
|
/// <param name="Port"></param>
|
||||||
/// <param name="cPQCPTDate"></param>
|
/// <param name="cPQCPTDate"></param>
|
||||||
public void EnterandExitSendMessge(int Station = 3)
|
public void EnterandExitSendMessge(int Station = 3)
|
||||||
{
|
{
|
||||||
try
|
try
|
||||||
{
|
{
|
||||||
@@ -121,7 +117,7 @@ namespace JinYuan.Helper
|
|||||||
}
|
}
|
||||||
catch (Exception err)
|
catch (Exception err)
|
||||||
{
|
{
|
||||||
LoggerHelp.WriteError($"发送进出站数据错误,{err.Message}",err);
|
LoggerHelp.WriteError($"发送进出站数据错误,{err.Message}", err);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
/// <summary>
|
/// <summary>
|
||||||
@@ -144,7 +140,7 @@ namespace JinYuan.Helper
|
|||||||
}
|
}
|
||||||
catch (Exception err)
|
catch (Exception err)
|
||||||
{
|
{
|
||||||
LoggerHelp.WriteError($"发送采集项数据错误,{err.Message}",err);
|
LoggerHelp.WriteError($"发送采集项数据错误,{err.Message}", err);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
@@ -1,9 +1,5 @@
|
|||||||
using System;
|
using System;
|
||||||
using System.Collections.Generic;
|
|
||||||
using System.IO;
|
using System.IO;
|
||||||
using System.Linq;
|
|
||||||
using System.Text;
|
|
||||||
using System.Threading.Tasks;
|
|
||||||
|
|
||||||
namespace JinYuan.Helper
|
namespace JinYuan.Helper
|
||||||
{
|
{
|
||||||
|
|||||||
@@ -1,10 +1,7 @@
|
|||||||
using System;
|
using System;
|
||||||
using System.Collections.Generic;
|
|
||||||
using System.IO;
|
using System.IO;
|
||||||
using System.Linq;
|
|
||||||
using System.Security.Cryptography;
|
using System.Security.Cryptography;
|
||||||
using System.Text;
|
using System.Text;
|
||||||
using System.Threading.Tasks;
|
|
||||||
|
|
||||||
namespace JinYuan.Helper
|
namespace JinYuan.Helper
|
||||||
{
|
{
|
||||||
|
|||||||
@@ -1,9 +1,5 @@
|
|||||||
using System;
|
using System;
|
||||||
using System.Collections.Generic;
|
|
||||||
using System.Linq;
|
|
||||||
using System.Text;
|
|
||||||
using System.Threading;
|
using System.Threading;
|
||||||
using System.Threading.Tasks;
|
|
||||||
|
|
||||||
namespace JinYuan.Helper
|
namespace JinYuan.Helper
|
||||||
{
|
{
|
||||||
|
|||||||
@@ -1,10 +1,7 @@
|
|||||||
using System;
|
using System;
|
||||||
using System.Collections.Generic;
|
|
||||||
using System.IO;
|
using System.IO;
|
||||||
using System.Linq;
|
|
||||||
using System.Text;
|
using System.Text;
|
||||||
using System.Threading;
|
using System.Threading;
|
||||||
using System.Threading.Tasks;
|
|
||||||
|
|
||||||
namespace JinYuan.Helper
|
namespace JinYuan.Helper
|
||||||
{
|
{
|
||||||
|
|||||||
@@ -1,13 +1,9 @@
|
|||||||
using System;
|
using System;
|
||||||
using System.Collections.Generic;
|
using System.Collections.Generic;
|
||||||
using System.IO;
|
using System.IO;
|
||||||
using System.Linq;
|
|
||||||
using System.Text;
|
|
||||||
using System.Threading.Tasks;
|
|
||||||
using System.Xml.Serialization;
|
|
||||||
using System.Xml;
|
|
||||||
using System.Runtime.Serialization.Formatters.Binary;
|
|
||||||
using System.Runtime.Serialization;
|
using System.Runtime.Serialization;
|
||||||
|
using System.Runtime.Serialization.Formatters.Binary;
|
||||||
|
using System.Xml.Serialization;
|
||||||
|
|
||||||
namespace JinYuan.Helper
|
namespace JinYuan.Helper
|
||||||
{
|
{
|
||||||
|
|||||||
@@ -1,9 +1,4 @@
|
|||||||
using System;
|
using System.ComponentModel;
|
||||||
using System.Collections.Generic;
|
|
||||||
using System.ComponentModel;
|
|
||||||
using System.Linq;
|
|
||||||
using System.Text;
|
|
||||||
using System.Threading.Tasks;
|
|
||||||
|
|
||||||
namespace JinYuan.MES.Enums
|
namespace JinYuan.MES.Enums
|
||||||
{
|
{
|
||||||
|
|||||||
@@ -1,9 +1,4 @@
|
|||||||
using System;
|
using System.ComponentModel;
|
||||||
using System.Collections.Generic;
|
|
||||||
using System.ComponentModel;
|
|
||||||
using System.Linq;
|
|
||||||
using System.Text;
|
|
||||||
using System.Threading.Tasks;
|
|
||||||
|
|
||||||
namespace JinYuan.MES.Enums
|
namespace JinYuan.MES.Enums
|
||||||
{
|
{
|
||||||
|
|||||||
+1
-5
@@ -1,11 +1,7 @@
|
|||||||
using JinYuan.MES.Enums;
|
using JinYuan.MES.Enums;
|
||||||
using JinYuan.MES.Models;
|
using JinYuan.MES.Models;
|
||||||
using JinYuan.Models;
|
using JinYuan.Models;
|
||||||
using System;
|
|
||||||
using System.Collections.Generic;
|
using System.Collections.Generic;
|
||||||
using System.Linq;
|
|
||||||
using System.Text;
|
|
||||||
using System.Threading.Tasks;
|
|
||||||
|
|
||||||
namespace JinYuan.MES
|
namespace JinYuan.MES
|
||||||
{
|
{
|
||||||
@@ -25,7 +21,7 @@ namespace JinYuan.MES
|
|||||||
/// <param name="passWord"></param>
|
/// <param name="passWord"></param>
|
||||||
/// <param name="msg"></param>
|
/// <param name="msg"></param>
|
||||||
/// <returns></returns>
|
/// <returns></returns>
|
||||||
bool LoginEnyity(string url, string siteCode, string lineCode, string equipNum, string userName, string passWord,string UserCardID, ref string resJson);
|
bool LoginEnyity(string url, string siteCode, string lineCode, string equipNum, string userName, string passWord, string UserCardID, ref string resJson);
|
||||||
/// <summary>
|
/// <summary>
|
||||||
/// 设备参数设定值请求接口
|
/// 设备参数设定值请求接口
|
||||||
/// </summary>
|
/// </summary>
|
||||||
|
|||||||
@@ -1,13 +1,10 @@
|
|||||||
using Newtonsoft.Json;
|
using JinYuan.MES.Models;
|
||||||
|
using Newtonsoft.Json;
|
||||||
using System;
|
using System;
|
||||||
using System.Collections.Generic;
|
|
||||||
using System.Linq;
|
|
||||||
using System.Net.Http.Headers;
|
|
||||||
using System.Net.Http;
|
|
||||||
using System.Net;
|
using System.Net;
|
||||||
|
using System.Net.Http;
|
||||||
|
using System.Net.Http.Headers;
|
||||||
using System.Text;
|
using System.Text;
|
||||||
using System.Threading.Tasks;
|
|
||||||
using JinYuan.MES.Models;
|
|
||||||
|
|
||||||
namespace JinYuan.MES
|
namespace JinYuan.MES
|
||||||
{
|
{
|
||||||
@@ -32,7 +29,7 @@ namespace JinYuan.MES
|
|||||||
try
|
try
|
||||||
{
|
{
|
||||||
StringContent stringContent = new StringContent(strJosnData, Encoding.UTF8, "application/json");
|
StringContent stringContent = new StringContent(strJosnData, Encoding.UTF8, "application/json");
|
||||||
string ResponseMessage= new HttpClient()
|
string ResponseMessage = new HttpClient()
|
||||||
{
|
{
|
||||||
Timeout = TimeSpan.FromSeconds(3.0)
|
Timeout = TimeSpan.FromSeconds(3.0)
|
||||||
}.PostAsync(url, (HttpContent)stringContent).Result.Content.ReadAsStringAsync().Result;
|
}.PostAsync(url, (HttpContent)stringContent).Result.Content.ReadAsStringAsync().Result;
|
||||||
@@ -97,7 +94,7 @@ namespace JinYuan.MES
|
|||||||
/// <param name="url"></param>
|
/// <param name="url"></param>
|
||||||
/// <param name="json"></param>
|
/// <param name="json"></param>
|
||||||
/// <returns></returns>
|
/// <returns></returns>
|
||||||
public static string WebApiPostTranafer(string url,string json)
|
public static string WebApiPostTranafer(string url, string json)
|
||||||
{
|
{
|
||||||
try
|
try
|
||||||
{
|
{
|
||||||
|
|||||||
@@ -7,11 +7,6 @@ using Newtonsoft.Json.Linq;
|
|||||||
using System;
|
using System;
|
||||||
using System.Collections.Generic;
|
using System.Collections.Generic;
|
||||||
using System.Diagnostics;
|
using System.Diagnostics;
|
||||||
using System.Linq;
|
|
||||||
using System.Reflection.Emit;
|
|
||||||
using System.Runtime.Remoting.Messaging;
|
|
||||||
using System.Text;
|
|
||||||
using System.Threading.Tasks;
|
|
||||||
|
|
||||||
namespace JinYuan.MES
|
namespace JinYuan.MES
|
||||||
{
|
{
|
||||||
@@ -45,7 +40,7 @@ namespace JinYuan.MES
|
|||||||
equipNum = equipNum,
|
equipNum = equipNum,
|
||||||
userName = userName,
|
userName = userName,
|
||||||
passWord = passWord,
|
passWord = passWord,
|
||||||
userCardID =null// UserCardID
|
userCardID = null// UserCardID
|
||||||
};
|
};
|
||||||
|
|
||||||
var nowDate = DateTime.Now;
|
var nowDate = DateTime.Now;
|
||||||
|
|||||||
@@ -1,8 +1,4 @@
|
|||||||
using System;
|
using System.Collections.Generic;
|
||||||
using System.Collections.Generic;
|
|
||||||
using System.Linq;
|
|
||||||
using System.Text;
|
|
||||||
using System.Threading.Tasks;
|
|
||||||
|
|
||||||
namespace JinYuan.MES.Models
|
namespace JinYuan.MES.Models
|
||||||
{
|
{
|
||||||
|
|||||||
@@ -1,10 +1,4 @@
|
|||||||
using System;
|
namespace JinYuan.MES.Models
|
||||||
using System.Collections.Generic;
|
|
||||||
using System.Linq;
|
|
||||||
using System.Text;
|
|
||||||
using System.Threading.Tasks;
|
|
||||||
|
|
||||||
namespace JinYuan.MES.Models
|
|
||||||
{
|
{
|
||||||
/// <summary>
|
/// <summary>
|
||||||
/// 登录
|
/// 登录
|
||||||
|
|||||||
@@ -1,8 +1,4 @@
|
|||||||
using System;
|
using System.Collections.Generic;
|
||||||
using System.Collections.Generic;
|
|
||||||
using System.Linq;
|
|
||||||
using System.Text;
|
|
||||||
using System.Threading.Tasks;
|
|
||||||
|
|
||||||
namespace JinYuan.MES.Models
|
namespace JinYuan.MES.Models
|
||||||
{
|
{
|
||||||
|
|||||||
@@ -1,8 +1,4 @@
|
|||||||
using System;
|
using System.Collections.Generic;
|
||||||
using System.Collections.Generic;
|
|
||||||
using System.Linq;
|
|
||||||
using System.Text;
|
|
||||||
using System.Threading.Tasks;
|
|
||||||
|
|
||||||
namespace JinYuan.MES.Models
|
namespace JinYuan.MES.Models
|
||||||
{
|
{
|
||||||
@@ -49,7 +45,7 @@ namespace JinYuan.MES.Models
|
|||||||
/// </summary>
|
/// </summary>
|
||||||
public int type { get; set; }
|
public int type { get; set; }
|
||||||
|
|
||||||
// public List<identiftyList> identiftyList { get; set; }
|
// public List<identiftyList> identiftyList { get; set; }
|
||||||
public List<assembleLineList> assembleLineList { get; set; }
|
public List<assembleLineList> assembleLineList { get; set; }
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -101,7 +97,7 @@ namespace JinYuan.MES.Models
|
|||||||
/// <summary>
|
/// <summary>
|
||||||
/// 原材料信息
|
/// 原材料信息
|
||||||
/// </summary>
|
/// </summary>
|
||||||
public List<string> materialLotList=new List<string>();
|
public List<string> materialLotList = new List<string>();
|
||||||
/// <summary>
|
/// <summary>
|
||||||
/// 原材料条码
|
/// 原材料条码
|
||||||
/// </summary>
|
/// </summary>
|
||||||
|
|||||||
@@ -1,8 +1,4 @@
|
|||||||
using System;
|
using System.Collections.Generic;
|
||||||
using System.Collections.Generic;
|
|
||||||
using System.Linq;
|
|
||||||
using System.Text;
|
|
||||||
using System.Threading.Tasks;
|
|
||||||
|
|
||||||
namespace JinYuan.MES.Models
|
namespace JinYuan.MES.Models
|
||||||
{
|
{
|
||||||
|
|||||||
@@ -1,8 +1,4 @@
|
|||||||
using System;
|
using System.Collections.Generic;
|
||||||
using System.Collections.Generic;
|
|
||||||
using System.Linq;
|
|
||||||
using System.Text;
|
|
||||||
using System.Threading.Tasks;
|
|
||||||
|
|
||||||
namespace JinYuan.MES.Models
|
namespace JinYuan.MES.Models
|
||||||
{
|
{
|
||||||
|
|||||||
@@ -1,8 +1,4 @@
|
|||||||
using System;
|
using System.Collections.Generic;
|
||||||
using System.Collections.Generic;
|
|
||||||
using System.Linq;
|
|
||||||
using System.Text;
|
|
||||||
using System.Threading.Tasks;
|
|
||||||
|
|
||||||
namespace JinYuan.MES.Models
|
namespace JinYuan.MES.Models
|
||||||
{
|
{
|
||||||
|
|||||||
@@ -1,10 +1,4 @@
|
|||||||
using System;
|
namespace JinYuan.MES.Models
|
||||||
using System.Collections.Generic;
|
|
||||||
using System.Linq;
|
|
||||||
using System.Text;
|
|
||||||
using System.Threading.Tasks;
|
|
||||||
|
|
||||||
namespace JinYuan.MES.Models
|
|
||||||
{
|
{
|
||||||
/// <summary>
|
/// <summary>
|
||||||
/// 产品过程加工参数
|
/// 产品过程加工参数
|
||||||
|
|||||||
@@ -1,8 +1,4 @@
|
|||||||
using System;
|
using System.Collections.Generic;
|
||||||
using System.Collections.Generic;
|
|
||||||
using System.Linq;
|
|
||||||
using System.Text;
|
|
||||||
using System.Threading.Tasks;
|
|
||||||
|
|
||||||
namespace JinYuan.MES.Models
|
namespace JinYuan.MES.Models
|
||||||
{
|
{
|
||||||
@@ -22,7 +18,7 @@ namespace JinYuan.MES.Models
|
|||||||
/// <summary>
|
/// <summary>
|
||||||
/// 设备数据
|
/// 设备数据
|
||||||
/// </summary>
|
/// </summary>
|
||||||
public string payload { get; set; }
|
public string payload { get; set; }
|
||||||
}
|
}
|
||||||
|
|
||||||
/// <summary>
|
/// <summary>
|
||||||
|
|||||||
@@ -1,10 +1,4 @@
|
|||||||
using System;
|
namespace JinYuan.MES.Models
|
||||||
using System.Collections.Generic;
|
|
||||||
using System.Linq;
|
|
||||||
using System.Text;
|
|
||||||
using System.Threading.Tasks;
|
|
||||||
|
|
||||||
namespace JinYuan.MES.Models
|
|
||||||
{
|
{
|
||||||
/// <summary>
|
/// <summary>
|
||||||
/// 单个电池进站
|
/// 单个电池进站
|
||||||
|
|||||||
@@ -1,8 +1,4 @@
|
|||||||
using System;
|
using System.Collections.Generic;
|
||||||
using System.Collections.Generic;
|
|
||||||
using System.Linq;
|
|
||||||
using System.Text;
|
|
||||||
using System.Threading.Tasks;
|
|
||||||
|
|
||||||
namespace JinYuan.MES.Models
|
namespace JinYuan.MES.Models
|
||||||
{
|
{
|
||||||
|
|||||||
@@ -1,8 +1,4 @@
|
|||||||
using System;
|
using System.Collections.Generic;
|
||||||
using System.Collections.Generic;
|
|
||||||
using System.Linq;
|
|
||||||
using System.Text;
|
|
||||||
using System.Threading.Tasks;
|
|
||||||
|
|
||||||
namespace JinYuan.MES.Models
|
namespace JinYuan.MES.Models
|
||||||
{
|
{
|
||||||
|
|||||||
@@ -1,8 +1,4 @@
|
|||||||
using System;
|
using System.Collections.Generic;
|
||||||
using System.Collections.Generic;
|
|
||||||
using System.Linq;
|
|
||||||
using System.Text;
|
|
||||||
using System.Threading.Tasks;
|
|
||||||
|
|
||||||
namespace JinYuan.MES.Models
|
namespace JinYuan.MES.Models
|
||||||
{
|
{
|
||||||
|
|||||||
@@ -1,10 +1,4 @@
|
|||||||
using System;
|
namespace JinYuan.MES.Models
|
||||||
using System.Collections.Generic;
|
|
||||||
using System.Linq;
|
|
||||||
using System.Text;
|
|
||||||
using System.Threading.Tasks;
|
|
||||||
|
|
||||||
namespace JinYuan.MES.Models
|
|
||||||
{
|
{
|
||||||
public class WattrMeter
|
public class WattrMeter
|
||||||
{
|
{
|
||||||
|
|||||||
@@ -1,5 +1,4 @@
|
|||||||
using System.Reflection;
|
using System.Reflection;
|
||||||
using System.Runtime.CompilerServices;
|
|
||||||
using System.Runtime.InteropServices;
|
using System.Runtime.InteropServices;
|
||||||
|
|
||||||
// 有关程序集的一般信息由以下
|
// 有关程序集的一般信息由以下
|
||||||
|
|||||||
@@ -1,10 +1,4 @@
|
|||||||
using PLCCommunication;
|
using SqlSugar;
|
||||||
using SqlSugar;
|
|
||||||
using System;
|
|
||||||
using System.Collections.Generic;
|
|
||||||
using System.Linq;
|
|
||||||
using System.Text;
|
|
||||||
using System.Threading.Tasks;
|
|
||||||
|
|
||||||
namespace JinYuan.Models
|
namespace JinYuan.Models
|
||||||
{
|
{
|
||||||
|
|||||||
@@ -1,9 +1,4 @@
|
|||||||
using CsvHelper.Configuration.Attributes;
|
using CsvHelper.Configuration.Attributes;
|
||||||
using System;
|
|
||||||
using System.Collections.Generic;
|
|
||||||
using System.Linq;
|
|
||||||
using System.Text;
|
|
||||||
using System.Threading.Tasks;
|
|
||||||
|
|
||||||
namespace JinYuan.Models
|
namespace JinYuan.Models
|
||||||
{
|
{
|
||||||
|
|||||||
@@ -1,10 +1,4 @@
|
|||||||
using System;
|
namespace JinYuan.Models
|
||||||
using System.Collections.Generic;
|
|
||||||
using System.Linq;
|
|
||||||
using System.Text;
|
|
||||||
using System.Threading.Tasks;
|
|
||||||
|
|
||||||
namespace JinYuan.Models
|
|
||||||
{
|
{
|
||||||
public class AlarmStatus
|
public class AlarmStatus
|
||||||
{
|
{
|
||||||
|
|||||||
@@ -1,8 +1,4 @@
|
|||||||
using System;
|
using System;
|
||||||
using System.Collections.Generic;
|
|
||||||
using System.Linq;
|
|
||||||
using System.Text;
|
|
||||||
using System.Threading.Tasks;
|
|
||||||
|
|
||||||
namespace JinYuan.Models
|
namespace JinYuan.Models
|
||||||
{
|
{
|
||||||
|
|||||||
@@ -1,9 +1,4 @@
|
|||||||
using CsvHelper.Configuration.Attributes;
|
using CsvHelper.Configuration.Attributes;
|
||||||
using System;
|
|
||||||
using System.Collections.Generic;
|
|
||||||
using System.Linq;
|
|
||||||
using System.Text;
|
|
||||||
using System.Threading.Tasks;
|
|
||||||
|
|
||||||
namespace JinYuan.Models
|
namespace JinYuan.Models
|
||||||
{
|
{
|
||||||
|
|||||||
+609
-612
File diff suppressed because it is too large
Load Diff
@@ -1,14 +1,4 @@
|
|||||||
using System;
|
namespace JinYuan.Models
|
||||||
using System.Collections.Generic;
|
|
||||||
using System.Linq;
|
|
||||||
using System.Text;
|
|
||||||
using System.Threading.Tasks;
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
namespace JinYuan.Models
|
|
||||||
{
|
{
|
||||||
//子组大小:这个与计算内的CPK值又非常打的关系,即是分组的样本个数,数据的分组在此处需要说明的是,必须
|
//子组大小:这个与计算内的CPK值又非常打的关系,即是分组的样本个数,数据的分组在此处需要说明的是,必须
|
||||||
//是根据实际情况来填写,比如每次抽样为5个,那么子组大小为5个,我们不能随心所欲的任意填写这个值,否则
|
//是根据实际情况来填写,比如每次抽样为5个,那么子组大小为5个,我们不能随心所欲的任意填写这个值,否则
|
||||||
|
|||||||
@@ -1,8 +1,4 @@
|
|||||||
using System;
|
using System.Collections.Generic;
|
||||||
using System.Collections.Generic;
|
|
||||||
using System.Linq;
|
|
||||||
using System.Text;
|
|
||||||
using System.Threading.Tasks;
|
|
||||||
|
|
||||||
namespace JinYuan.Models
|
namespace JinYuan.Models
|
||||||
{
|
{
|
||||||
@@ -14,19 +10,19 @@ namespace JinYuan.Models
|
|||||||
/// <summary>
|
/// <summary>
|
||||||
/// 注液前重量
|
/// 注液前重量
|
||||||
/// </summary>
|
/// </summary>
|
||||||
public string CTP_PreWeighing_Value { get; set; }
|
public string CTP_PreWeighing_Value { get; set; }
|
||||||
/// <summary>
|
/// <summary>
|
||||||
/// 保液量
|
/// 保液量
|
||||||
/// </summary>
|
/// </summary>
|
||||||
public string CTP_Liquid_Retention_Value { get; set; }
|
public string CTP_Liquid_Retention_Value { get; set; }
|
||||||
/// <summary>
|
/// <summary>
|
||||||
/// 注液量
|
/// 注液量
|
||||||
/// </summary>
|
/// </summary>
|
||||||
public string CTP_Filling_Value { get; set; }
|
public string CTP_Filling_Value { get; set; }
|
||||||
/// <summary>
|
/// <summary>
|
||||||
/// 失液量
|
/// 失液量
|
||||||
/// </summary>
|
/// </summary>
|
||||||
public string CTP_Liquid_Loss_Value { get; set; }
|
public string CTP_Liquid_Loss_Value { get; set; }
|
||||||
/// <summary>
|
/// <summary>
|
||||||
/// 充氦值
|
/// 充氦值
|
||||||
/// </summary>
|
/// </summary>
|
||||||
@@ -34,19 +30,19 @@ namespace JinYuan.Models
|
|||||||
/// <summary>
|
/// <summary>
|
||||||
/// 钟罩真空值
|
/// 钟罩真空值
|
||||||
/// </summary>
|
/// </summary>
|
||||||
public string CTP_Belljar_Vacuum_Value { get; set; }
|
public string CTP_Belljar_Vacuum_Value { get; set; }
|
||||||
/// <summary>
|
/// <summary>
|
||||||
/// 钟罩真空时间
|
/// 钟罩真空时间
|
||||||
/// </summary>
|
/// </summary>
|
||||||
public string CTP_Belljar_Vacuum_Time { get; set; }
|
public string CTP_Belljar_Vacuum_Time { get; set; }
|
||||||
/// <summary>
|
/// <summary>
|
||||||
/// 钟罩高压值
|
/// 钟罩高压值
|
||||||
/// </summary>
|
/// </summary>
|
||||||
public string CTP_Belljar_HighPressure_Value { get; set; }
|
public string CTP_Belljar_HighPressure_Value { get; set; }
|
||||||
/// <summary>
|
/// <summary>
|
||||||
/// 钟罩高压时间
|
/// 钟罩高压时间
|
||||||
/// </summary>
|
/// </summary>
|
||||||
public string CTP_Belljar_HighPressure_Time { get; set; }
|
public string CTP_Belljar_HighPressure_Time { get; set; }
|
||||||
/// <summary>
|
/// <summary>
|
||||||
/// 钟罩循环次数
|
/// 钟罩循环次数
|
||||||
/// </summary>
|
/// </summary>
|
||||||
@@ -54,7 +50,7 @@ namespace JinYuan.Models
|
|||||||
/// <summary>
|
/// <summary>
|
||||||
/// 回氦前真空值
|
/// 回氦前真空值
|
||||||
/// </summary>
|
/// </summary>
|
||||||
public string CTP_Pre_Helium_Value { get; set; }
|
public string CTP_Pre_Helium_Value { get; set; }
|
||||||
/// <summary>
|
/// <summary>
|
||||||
/// 回氦后真空值
|
/// 回氦后真空值
|
||||||
/// </summary>
|
/// </summary>
|
||||||
@@ -62,23 +58,23 @@ namespace JinYuan.Models
|
|||||||
/// <summary>
|
/// <summary>
|
||||||
/// 平压压力
|
/// 平压压力
|
||||||
/// </summary>
|
/// </summary>
|
||||||
public string CTP_Flat_Pressure { get; set; }
|
public string CTP_Flat_Pressure { get; set; }
|
||||||
/// <summary>
|
/// <summary>
|
||||||
/// 电芯测厚压力
|
/// 电芯测厚压力
|
||||||
/// </summary>
|
/// </summary>
|
||||||
public string CTP_Cell_Thickness_Pressure { get; set; }
|
public string CTP_Cell_Thickness_Pressure { get; set; }
|
||||||
/// <summary>
|
/// <summary>
|
||||||
/// 注液后重量
|
/// 注液后重量
|
||||||
/// </summary>
|
/// </summary>
|
||||||
public string CTQ_PostWeighing_Value { get; set; }
|
public string CTQ_PostWeighing_Value { get; set; }
|
||||||
/// <summary>
|
/// <summary>
|
||||||
/// 电芯厚度
|
/// 电芯厚度
|
||||||
/// </summary>
|
/// </summary>
|
||||||
public string CTQ_Cell_Thickness { get; set; }
|
public string CTQ_Cell_Thickness { get; set; }
|
||||||
/// <summary>
|
/// <summary>
|
||||||
/// 终压胶粒高度
|
/// 终压胶粒高度
|
||||||
/// </summary>
|
/// </summary>
|
||||||
public string CTQ_Finalpress_Rubber_Height { get; set; }
|
public string CTQ_Finalpress_Rubber_Height { get; set; }
|
||||||
/// <summary>
|
/// <summary>
|
||||||
/// 注液前负压压力
|
/// 注液前负压压力
|
||||||
/// </summary>
|
/// </summary>
|
||||||
@@ -104,9 +100,9 @@ namespace JinYuan.Models
|
|||||||
/// </summary>
|
/// </summary>
|
||||||
public string CTQ_Finalpress_Rubber_Thickness { get; set; }
|
public string CTQ_Finalpress_Rubber_Thickness { get; set; }
|
||||||
}
|
}
|
||||||
/// <summary>
|
/// <summary>
|
||||||
/// 进出站上传数据
|
/// 进出站上传数据
|
||||||
/// </summary>
|
/// </summary>
|
||||||
public class EnterandExit
|
public class EnterandExit
|
||||||
{
|
{
|
||||||
/// <summary>
|
/// <summary>
|
||||||
@@ -188,7 +184,7 @@ namespace JinYuan.Models
|
|||||||
/// <summary>
|
/// <summary>
|
||||||
/// 采集项数据列表
|
/// 采集项数据列表
|
||||||
/// </summary>
|
/// </summary>
|
||||||
public List<Collection> taglist { get; set; }
|
public List<Collection> taglist { get; set; }
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -197,7 +193,7 @@ namespace JinYuan.Models
|
|||||||
/// <summary>
|
/// <summary>
|
||||||
/// 时间
|
/// 时间
|
||||||
/// </summary>
|
/// </summary>
|
||||||
public string device_time { get; set; }
|
public string device_time { get; set; }
|
||||||
/// <summary>
|
/// <summary>
|
||||||
/// 采集项键值对
|
/// 采集项键值对
|
||||||
/// </summary>
|
/// </summary>
|
||||||
|
|||||||
@@ -1,10 +1,4 @@
|
|||||||
using System;
|
namespace JinYuan.Models
|
||||||
using System.Collections.Generic;
|
|
||||||
using System.Linq;
|
|
||||||
using System.Text;
|
|
||||||
using System.Threading.Tasks;
|
|
||||||
|
|
||||||
namespace JinYuan.Models
|
|
||||||
{
|
{
|
||||||
/// <summary>
|
/// <summary>
|
||||||
/// 24小时统计表数据
|
/// 24小时统计表数据
|
||||||
|
|||||||
@@ -1,10 +1,4 @@
|
|||||||
using System;
|
namespace JinYuan.Models
|
||||||
using System.Collections.Generic;
|
|
||||||
using System.Linq;
|
|
||||||
using System.Text;
|
|
||||||
using System.Threading.Tasks;
|
|
||||||
|
|
||||||
namespace JinYuan.Models
|
|
||||||
{
|
{
|
||||||
/// <summary>
|
/// <summary>
|
||||||
/// 不良統計
|
/// 不良統計
|
||||||
|
|||||||
@@ -1,9 +1,4 @@
|
|||||||
using SqlSugar;
|
using SqlSugar;
|
||||||
using System;
|
|
||||||
using System.Collections.Generic;
|
|
||||||
using System.Linq;
|
|
||||||
using System.Text;
|
|
||||||
using System.Threading.Tasks;
|
|
||||||
|
|
||||||
namespace JinYuan.Models
|
namespace JinYuan.Models
|
||||||
{
|
{
|
||||||
|
|||||||
@@ -1,8 +1,4 @@
|
|||||||
using System;
|
using System.Collections.Generic;
|
||||||
using System.Collections.Generic;
|
|
||||||
using System.Linq;
|
|
||||||
using System.Text;
|
|
||||||
using System.Threading.Tasks;
|
|
||||||
|
|
||||||
namespace JinYuan.Models
|
namespace JinYuan.Models
|
||||||
{
|
{
|
||||||
|
|||||||
@@ -1,10 +1,4 @@
|
|||||||
using System;
|
namespace JinYuan.Models
|
||||||
using System.Collections.Generic;
|
|
||||||
using System.Linq;
|
|
||||||
using System.Text;
|
|
||||||
using System.Threading.Tasks;
|
|
||||||
|
|
||||||
namespace JinYuan.Models
|
|
||||||
{
|
{
|
||||||
/// <summary>
|
/// <summary>
|
||||||
/// 智能电表
|
/// 智能电表
|
||||||
|
|||||||
@@ -1,9 +1,4 @@
|
|||||||
using SqlSugar;
|
using SqlSugar;
|
||||||
using System;
|
|
||||||
using System.Collections.Generic;
|
|
||||||
using System.Linq;
|
|
||||||
using System.Text;
|
|
||||||
using System.Threading.Tasks;
|
|
||||||
|
|
||||||
namespace JinYuan.Models
|
namespace JinYuan.Models
|
||||||
{
|
{
|
||||||
|
|||||||
@@ -1,5 +1,4 @@
|
|||||||
using System.Reflection;
|
using System.Reflection;
|
||||||
using System.Runtime.CompilerServices;
|
|
||||||
using System.Runtime.InteropServices;
|
using System.Runtime.InteropServices;
|
||||||
|
|
||||||
// 有关程序集的一般信息由以下
|
// 有关程序集的一般信息由以下
|
||||||
|
|||||||
@@ -1,9 +1,4 @@
|
|||||||
using SqlSugar;
|
using System;
|
||||||
using System;
|
|
||||||
using System.Collections.Generic;
|
|
||||||
using System.Linq;
|
|
||||||
using System.Text;
|
|
||||||
using System.Threading.Tasks;
|
|
||||||
|
|
||||||
namespace JinYuan.Models
|
namespace JinYuan.Models
|
||||||
{
|
{
|
||||||
|
|||||||
@@ -2,11 +2,7 @@
|
|||||||
using System;
|
using System;
|
||||||
using System.Collections.Generic;
|
using System.Collections.Generic;
|
||||||
using System.Diagnostics;
|
using System.Diagnostics;
|
||||||
using System.Linq;
|
|
||||||
using System.Security.Policy;
|
|
||||||
using System.Text;
|
|
||||||
using System.Threading;
|
using System.Threading;
|
||||||
using System.Threading.Tasks;
|
|
||||||
|
|
||||||
namespace JinYuan.Models
|
namespace JinYuan.Models
|
||||||
{
|
{
|
||||||
@@ -27,7 +23,7 @@ namespace JinYuan.Models
|
|||||||
/// <summary>
|
/// <summary>
|
||||||
/// PLC类型
|
/// PLC类型
|
||||||
/// </summary>
|
/// </summary>
|
||||||
public string PLCType { get; set; }
|
public string PLCType { get; set; }
|
||||||
/// <summary>
|
/// <summary>
|
||||||
/// 当前设备的连接状态
|
/// 当前设备的连接状态
|
||||||
/// </summary>
|
/// </summary>
|
||||||
@@ -106,7 +102,7 @@ namespace JinYuan.Models
|
|||||||
/// <summary>
|
/// <summary>
|
||||||
/// 定义报警触发和消除事件
|
/// 定义报警触发和消除事件
|
||||||
/// </summary>
|
/// </summary>
|
||||||
public event Action<bool,Variable> AlarmTrigEvent;
|
public event Action<bool, Variable> AlarmTrigEvent;
|
||||||
|
|
||||||
/// <summary>
|
/// <summary>
|
||||||
/// 变量初始化
|
/// 变量初始化
|
||||||
|
|||||||
@@ -1,10 +1,4 @@
|
|||||||
using System;
|
namespace JinYuan.Models
|
||||||
using System.Collections.Generic;
|
|
||||||
using System.Linq;
|
|
||||||
using System.Text;
|
|
||||||
using System.Threading.Tasks;
|
|
||||||
|
|
||||||
namespace JinYuan.Models
|
|
||||||
{
|
{
|
||||||
/// <summary>
|
/// <summary>
|
||||||
/// 所有窗体枚举,小于临界窗体的为固定窗体,不执行关闭
|
/// 所有窗体枚举,小于临界窗体的为固定窗体,不执行关闭
|
||||||
|
|||||||
@@ -1,9 +1,5 @@
|
|||||||
using MiniExcelLibs.Attributes;
|
using MiniExcelLibs.Attributes;
|
||||||
using System;
|
|
||||||
using System.Collections.Generic;
|
using System.Collections.Generic;
|
||||||
using System.Linq;
|
|
||||||
using System.Text;
|
|
||||||
using System.Threading.Tasks;
|
|
||||||
|
|
||||||
namespace JinYuan.Models
|
namespace JinYuan.Models
|
||||||
{
|
{
|
||||||
|
|||||||
@@ -1,9 +1,4 @@
|
|||||||
using SqlSugar;
|
using SqlSugar;
|
||||||
using System;
|
|
||||||
using System.Collections.Generic;
|
|
||||||
using System.Linq;
|
|
||||||
using System.Text;
|
|
||||||
using System.Threading.Tasks;
|
|
||||||
|
|
||||||
namespace JinYuan.Models
|
namespace JinYuan.Models
|
||||||
{
|
{
|
||||||
|
|||||||
@@ -1,9 +1,4 @@
|
|||||||
using SqlSugar;
|
using SqlSugar;
|
||||||
using System;
|
|
||||||
using System.Collections.Generic;
|
|
||||||
using System.Linq;
|
|
||||||
using System.Text;
|
|
||||||
using System.Threading.Tasks;
|
|
||||||
|
|
||||||
namespace JinYuan.Models
|
namespace JinYuan.Models
|
||||||
{
|
{
|
||||||
|
|||||||
@@ -1,9 +1,4 @@
|
|||||||
using SqlSugar;
|
using SqlSugar;
|
||||||
using System;
|
|
||||||
using System.Collections.Generic;
|
|
||||||
using System.Linq;
|
|
||||||
using System.Text;
|
|
||||||
using System.Threading.Tasks;
|
|
||||||
|
|
||||||
namespace JinYuan.Models
|
namespace JinYuan.Models
|
||||||
{
|
{
|
||||||
|
|||||||
@@ -1,10 +1,4 @@
|
|||||||
using System;
|
namespace JinYuan.Models
|
||||||
using System.Collections.Generic;
|
|
||||||
using System.Linq;
|
|
||||||
using System.Text;
|
|
||||||
using System.Threading.Tasks;
|
|
||||||
|
|
||||||
namespace JinYuan.Models
|
|
||||||
{
|
{
|
||||||
/// <summary>
|
/// <summary>
|
||||||
/// 产品型号参数范围
|
/// 产品型号参数范围
|
||||||
|
|||||||
@@ -1,9 +1,4 @@
|
|||||||
using SqlSugar;
|
using SqlSugar;
|
||||||
using System;
|
|
||||||
using System.Collections.Generic;
|
|
||||||
using System.Linq;
|
|
||||||
using System.Text;
|
|
||||||
using System.Threading.Tasks;
|
|
||||||
|
|
||||||
namespace JinYuan.Models
|
namespace JinYuan.Models
|
||||||
{
|
{
|
||||||
@@ -12,7 +7,7 @@ namespace JinYuan.Models
|
|||||||
/// </summary>
|
/// </summary>
|
||||||
public class SysAdmin
|
public class SysAdmin
|
||||||
{
|
{
|
||||||
[SugarColumn(IsPrimaryKey = true,IsIgnore =true)]
|
[SugarColumn(IsPrimaryKey = true, IsIgnore = true)]
|
||||||
public int LoginId { get; set; }
|
public int LoginId { get; set; }
|
||||||
public string LoginName { get; set; }
|
public string LoginName { get; set; }
|
||||||
public string LoginPwd { get; set; }
|
public string LoginPwd { get; set; }
|
||||||
|
|||||||
@@ -1,10 +1,4 @@
|
|||||||
using System;
|
namespace JinYuan.Models
|
||||||
using System.Collections.Generic;
|
|
||||||
using System.Linq;
|
|
||||||
using System.Text;
|
|
||||||
using System.Threading.Tasks;
|
|
||||||
|
|
||||||
namespace JinYuan.Models
|
|
||||||
{
|
{
|
||||||
public class SysConfig
|
public class SysConfig
|
||||||
{
|
{
|
||||||
@@ -46,7 +40,7 @@ namespace JinYuan.Models
|
|||||||
/// <summary>
|
/// <summary>
|
||||||
/// MES/非MES模式切换
|
/// MES/非MES模式切换
|
||||||
/// </summary>
|
/// </summary>
|
||||||
public bool MesModeSwitching { get; set;}
|
public bool MesModeSwitching { get; set; }
|
||||||
/// <summary>
|
/// <summary>
|
||||||
/// 切屏
|
/// 切屏
|
||||||
/// </summary>
|
/// </summary>
|
||||||
|
|||||||
@@ -1,10 +1,4 @@
|
|||||||
using System;
|
namespace JinYuan.Models
|
||||||
using System.Collections.Generic;
|
|
||||||
using System.Linq;
|
|
||||||
using System.Text;
|
|
||||||
using System.Threading.Tasks;
|
|
||||||
|
|
||||||
namespace JinYuan.Models
|
|
||||||
{
|
{
|
||||||
public class SysLog
|
public class SysLog
|
||||||
{
|
{
|
||||||
|
|||||||
@@ -1,10 +1,4 @@
|
|||||||
using MiniExcelLibs.Attributes;
|
using MiniExcelLibs.Attributes;
|
||||||
using Newtonsoft.Json;
|
|
||||||
using System;
|
|
||||||
using System.Collections.Generic;
|
|
||||||
using System.Linq;
|
|
||||||
using System.Text;
|
|
||||||
using System.Threading.Tasks;
|
|
||||||
|
|
||||||
namespace JinYuan.Models
|
namespace JinYuan.Models
|
||||||
{
|
{
|
||||||
@@ -29,7 +23,7 @@ namespace JinYuan.Models
|
|||||||
/// <summary>
|
/// <summary>
|
||||||
/// 数据类型
|
/// 数据类型
|
||||||
/// </summary>
|
/// </summary>
|
||||||
public string DataType { get; set; }
|
public string DataType { get; set; }
|
||||||
/// <summary>
|
/// <summary>
|
||||||
/// 偏移或长度
|
/// 偏移或长度
|
||||||
/// </summary>
|
/// </summary>
|
||||||
@@ -37,7 +31,7 @@ namespace JinYuan.Models
|
|||||||
/// <summary>
|
/// <summary>
|
||||||
/// 所属通信组名称
|
/// 所属通信组名称
|
||||||
/// </summary>
|
/// </summary>
|
||||||
public string GroupName { get; set; }
|
public string GroupName { get; set; }
|
||||||
/// <summary>
|
/// <summary>
|
||||||
/// 备注说明
|
/// 备注说明
|
||||||
/// </summary>
|
/// </summary>
|
||||||
@@ -49,7 +43,7 @@ namespace JinYuan.Models
|
|||||||
/// <summary>
|
/// <summary>
|
||||||
/// 是否下降沿报警
|
/// 是否下降沿报警
|
||||||
/// </summary>
|
/// </summary>
|
||||||
public bool NegAlarm { get; set;}
|
public bool NegAlarm { get; set; }
|
||||||
/// <summary>
|
/// <summary>
|
||||||
/// 转换系数
|
/// 转换系数
|
||||||
/// </summary>
|
/// </summary>
|
||||||
|
|||||||
@@ -1,18 +1,15 @@
|
|||||||
using JinYuan.DAL;
|
using JinYuan.CommunicationLib;
|
||||||
using JinYuan.CommunicationLib.Library;
|
using JinYuan.CommunicationLib.Base;
|
||||||
using JinYuan.DataConvertLib;
|
using JinYuan.CommunicationLib.Enum;
|
||||||
|
using JinYuan.DAL;
|
||||||
|
using JinYuan.Helper;
|
||||||
|
using JinYuan.MES;
|
||||||
using JinYuan.Models;
|
using JinYuan.Models;
|
||||||
using System;
|
using System;
|
||||||
using System.Collections.Generic;
|
using System.Collections.Generic;
|
||||||
using System.Text;
|
|
||||||
using System.Windows.Forms;
|
|
||||||
using System.IO;
|
using System.IO;
|
||||||
using System.Threading;
|
using System.Threading;
|
||||||
using JinYuan.Helper;
|
using System.Windows.Forms;
|
||||||
using JinYuan.MES;
|
|
||||||
using JinYuan.CommunicationLib.Enum;
|
|
||||||
using JinYuan.CommunicationLib;
|
|
||||||
using JinYuan.CommunicationLib.Base;
|
|
||||||
|
|
||||||
namespace JinYuan.VirtualDataLibrary
|
namespace JinYuan.VirtualDataLibrary
|
||||||
{
|
{
|
||||||
@@ -83,7 +80,7 @@ namespace JinYuan.VirtualDataLibrary
|
|||||||
/// <summary>
|
/// <summary>
|
||||||
///是否开启刷新
|
///是否开启刷新
|
||||||
/// </summary>
|
/// </summary>
|
||||||
public static bool isRefreshTimerWeeding=false;
|
public static bool isRefreshTimerWeeding = false;
|
||||||
|
|
||||||
/// <summary>
|
/// <summary>
|
||||||
/// SQL语句
|
/// SQL语句
|
||||||
@@ -230,7 +227,7 @@ namespace JinYuan.VirtualDataLibrary
|
|||||||
/// <summary>
|
/// <summary>
|
||||||
/// PLC开机/运行时间地址
|
/// PLC开机/运行时间地址
|
||||||
/// </summary>
|
/// </summary>
|
||||||
public static List<string> PlcOpenAndRunTimeAdress = new List<string> { "D50", "D52" , "D54" , "D56" , "D58" , "D60"};
|
public static List<string> PlcOpenAndRunTimeAdress = new List<string> { "D50", "D52", "D54", "D56", "D58", "D60" };
|
||||||
public static int ProdDRFIDNgQty = 0;//低托杯
|
public static int ProdDRFIDNgQty = 0;//低托杯
|
||||||
public static int ProdDXNgQty = 0;//卷心码
|
public static int ProdDXNgQty = 0;//卷心码
|
||||||
public static int ProdGRFIDNgQty = 0;//高托杯
|
public static int ProdGRFIDNgQty = 0;//高托杯
|
||||||
|
|||||||
@@ -1,8 +1,4 @@
|
|||||||
using System;
|
using System;
|
||||||
using System.Collections.Generic;
|
|
||||||
using System.Linq;
|
|
||||||
using System.Text;
|
|
||||||
using System.Threading.Tasks;
|
|
||||||
|
|
||||||
namespace JinYuan.VirtualDataLibrary
|
namespace JinYuan.VirtualDataLibrary
|
||||||
{
|
{
|
||||||
|
|||||||
@@ -1,11 +1,6 @@
|
|||||||
using JinYuan.DataConvertLib;
|
using JinYuan.Models;
|
||||||
using JinYuan.Models;
|
|
||||||
using PLCCommunication;
|
using PLCCommunication;
|
||||||
using System;
|
|
||||||
using System.Collections.Generic;
|
using System.Collections.Generic;
|
||||||
using System.Linq;
|
|
||||||
using System.Text;
|
|
||||||
using System.Threading.Tasks;
|
|
||||||
|
|
||||||
namespace JinYuan.VirtualDataLibrary
|
namespace JinYuan.VirtualDataLibrary
|
||||||
{
|
{
|
||||||
|
|||||||
@@ -1,8 +1,4 @@
|
|||||||
using System;
|
using System.Collections.Generic;
|
||||||
using System.Collections.Generic;
|
|
||||||
using System.Linq;
|
|
||||||
using System.Text;
|
|
||||||
using System.Threading.Tasks;
|
|
||||||
|
|
||||||
namespace JinYuan.VirtualDataLibrary
|
namespace JinYuan.VirtualDataLibrary
|
||||||
{
|
{
|
||||||
|
|||||||
@@ -1,5 +1,4 @@
|
|||||||
using System.Reflection;
|
using System.Reflection;
|
||||||
using System.Runtime.CompilerServices;
|
|
||||||
using System.Runtime.InteropServices;
|
using System.Runtime.InteropServices;
|
||||||
|
|
||||||
// 有关程序集的一般信息由以下
|
// 有关程序集的一般信息由以下
|
||||||
|
|||||||
@@ -49,7 +49,7 @@ namespace LargeSquareOne
|
|||||||
Operater = CommonMethods.currentAdmin.LoginName
|
Operater = CommonMethods.currentAdmin.LoginName
|
||||||
};
|
};
|
||||||
//存储到数据库
|
//存储到数据库
|
||||||
var b = CommonMethods.db.AddReturnBool(model);
|
var b = CommonMethods.db.AddReturnBool(model);
|
||||||
if (!b)
|
if (!b)
|
||||||
{
|
{
|
||||||
LoggerHelp.WriteError($"数据库记录失败. 表:SysLog,内容:{model.ToJsonString()}");
|
LoggerHelp.WriteError($"数据库记录失败. 表:SysLog,内容:{model.ToJsonString()}");
|
||||||
|
|||||||
@@ -1,16 +1,8 @@
|
|||||||
using JinYuan.Models;
|
using System;
|
||||||
using System;
|
|
||||||
using System.Collections.Generic;
|
using System.Collections.Generic;
|
||||||
using System.ComponentModel;
|
|
||||||
using System.Data;
|
|
||||||
using System.Drawing;
|
|
||||||
using System.Drawing.Drawing2D;
|
|
||||||
using System.Linq;
|
using System.Linq;
|
||||||
using System.Text;
|
|
||||||
using System.Threading.Tasks;
|
|
||||||
using System.Windows.Forms;
|
using System.Windows.Forms;
|
||||||
using System.Windows.Forms.DataVisualization.Charting;
|
using System.Windows.Forms.DataVisualization.Charting;
|
||||||
using System.Windows.Markup;
|
|
||||||
|
|
||||||
namespace LargeSquareOne
|
namespace LargeSquareOne
|
||||||
{
|
{
|
||||||
@@ -42,7 +34,7 @@ namespace LargeSquareOne
|
|||||||
private void btn_Add_Click(object sender, EventArgs e)
|
private void btn_Add_Click(object sender, EventArgs e)
|
||||||
{
|
{
|
||||||
|
|
||||||
List<double> data= GetSPCData();
|
List<double> data = GetSPCData();
|
||||||
// 计算Xbar和R
|
// 计算Xbar和R
|
||||||
double xbar = CalculateXbar(data);
|
double xbar = CalculateXbar(data);
|
||||||
double r = CalculateR(data);
|
double r = CalculateR(data);
|
||||||
@@ -98,7 +90,7 @@ namespace LargeSquareOne
|
|||||||
{
|
{
|
||||||
// 返回样本数据的List<double>
|
// 返回样本数据的List<double>
|
||||||
// 根据需要修改为实际的获取方法
|
// 根据需要修改为实际的获取方法
|
||||||
return new List<double>{1.2, 1.3, 1.0, 2.5, 2.2, 2.8, 0.8, 0.9, 1.1};
|
return new List<double> { 1.2, 1.3, 1.0, 2.5, 2.2, 2.8, 0.8, 0.9, 1.1 };
|
||||||
}
|
}
|
||||||
|
|
||||||
/// <summary>
|
/// <summary>
|
||||||
@@ -414,7 +406,7 @@ namespace LargeSquareOne
|
|||||||
double D3 = 0; // 控制系数
|
double D3 = 0; // 控制系数
|
||||||
|
|
||||||
// 根据样本大小确定控制系数D3
|
// 根据样本大小确定控制系数D3
|
||||||
D3=GetD3(sampleSize);
|
D3 = GetD3(sampleSize);
|
||||||
|
|
||||||
//对样本进行分组
|
//对样本进行分组
|
||||||
List<double> data = GetSPCData();
|
List<double> data = GetSPCData();
|
||||||
|
|||||||
@@ -11,9 +11,7 @@ using System.Collections.Generic;
|
|||||||
using System.ComponentModel;
|
using System.ComponentModel;
|
||||||
using System.Data;
|
using System.Data;
|
||||||
using System.Drawing;
|
using System.Drawing;
|
||||||
using System.Runtime.CompilerServices;
|
|
||||||
using System.Threading.Tasks;
|
using System.Threading.Tasks;
|
||||||
using System.Windows.Documents;
|
|
||||||
using System.Windows.Forms;
|
using System.Windows.Forms;
|
||||||
|
|
||||||
namespace LargeSquareOne
|
namespace LargeSquareOne
|
||||||
@@ -370,7 +368,7 @@ namespace LargeSquareOne
|
|||||||
{
|
{
|
||||||
listTA.Add(m);
|
listTA.Add(m);
|
||||||
}
|
}
|
||||||
if (listTA.Count >=500)
|
if (listTA.Count >= 500)
|
||||||
{
|
{
|
||||||
listTA.Clear();
|
listTA.Clear();
|
||||||
GC.Collect();
|
GC.Collect();
|
||||||
@@ -566,7 +564,7 @@ namespace LargeSquareOne
|
|||||||
|
|
||||||
btSatrt.Enabled = !b;
|
btSatrt.Enabled = !b;
|
||||||
btStop.Enabled = b;
|
btStop.Enabled = b;
|
||||||
cmbModelType.Enabled =true;
|
cmbModelType.Enabled = true;
|
||||||
txtMaterialCode.Enabled = !b;
|
txtMaterialCode.Enabled = !b;
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -3,15 +3,9 @@ using JinYuan.Models;
|
|||||||
using MiniExcelLibs;
|
using MiniExcelLibs;
|
||||||
using System;
|
using System;
|
||||||
using System.Collections.Generic;
|
using System.Collections.Generic;
|
||||||
using System.ComponentModel;
|
|
||||||
using System.Data;
|
|
||||||
using System.Drawing;
|
using System.Drawing;
|
||||||
using System.Linq;
|
using System.Linq;
|
||||||
using System.Text;
|
|
||||||
using System.Threading.Tasks;
|
|
||||||
using System.Web;
|
|
||||||
using System.Windows.Forms;
|
using System.Windows.Forms;
|
||||||
using System.Xml.Schema;
|
|
||||||
|
|
||||||
namespace LargeSquareOne
|
namespace LargeSquareOne
|
||||||
{
|
{
|
||||||
@@ -112,10 +106,10 @@ namespace LargeSquareOne
|
|||||||
/// <param name="e"></param>
|
/// <param name="e"></param>
|
||||||
private void btn_Add_Click(object sender, EventArgs e)
|
private void btn_Add_Click(object sender, EventArgs e)
|
||||||
{
|
{
|
||||||
string groupName =this.txt_GroupName.Text.Trim();
|
string groupName = this.txt_GroupName.Text.Trim();
|
||||||
if (groupName.Length==0)
|
if (groupName.Length == 0)
|
||||||
{
|
{
|
||||||
new FrmMsgBoxOutWithAck(2,"通信组名称不能为空!", "添加通信组").Show();
|
new FrmMsgBoxOutWithAck(2, "通信组名称不能为空!", "添加通信组").Show();
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -127,26 +121,26 @@ namespace LargeSquareOne
|
|||||||
|
|
||||||
TotalGroups.Add(new Group()
|
TotalGroups.Add(new Group()
|
||||||
{
|
{
|
||||||
GroupName=this.txt_GroupName.Text,
|
GroupName = this.txt_GroupName.Text,
|
||||||
Start=this.txtStart.Text,
|
Start = this.txtStart.Text,
|
||||||
Length = Convert.ToUInt16(this.num_Length.Value),
|
Length = Convert.ToUInt16(this.num_Length.Value),
|
||||||
IsTiggerRead = this.ckb_IsTiggerRead.Checked ?true : false,
|
IsTiggerRead = this.ckb_IsTiggerRead.Checked ? true : false,
|
||||||
IsFeedbackPlc= this.chk_IsFeedbackPlc.Checked ? true : false,
|
IsFeedbackPlc = this.chk_IsFeedbackPlc.Checked ? true : false,
|
||||||
IsActive = this.ckb_IsEnable.Checked ? true : false,
|
IsActive = this.ckb_IsEnable.Checked ? true : false,
|
||||||
Remark =this.txt_Remark.Text.Trim()
|
Remark = this.txt_Remark.Text.Trim()
|
||||||
});
|
});
|
||||||
|
|
||||||
try
|
try
|
||||||
{
|
{
|
||||||
MiniExcel.SaveAs(groupPath, TotalGroups, overwriteFile: true);
|
MiniExcel.SaveAs(groupPath, TotalGroups, overwriteFile: true);
|
||||||
new FrmMsgBoxOutWithAck(1,"添加通信组成功", "添加通信组").Show();
|
new FrmMsgBoxOutWithAck(1, "添加通信组成功", "添加通信组").Show();
|
||||||
|
|
||||||
//刷新数据
|
//刷新数据
|
||||||
RefreshGroup();
|
RefreshGroup();
|
||||||
}
|
}
|
||||||
catch (Exception ex)
|
catch (Exception ex)
|
||||||
{
|
{
|
||||||
new FrmMsgBoxOutWithAck(3,"添加通信组失败:"+ex.Message, "添加通信组").Show();
|
new FrmMsgBoxOutWithAck(3, "添加通信组失败:" + ex.Message, "添加通信组").Show();
|
||||||
}
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
@@ -196,11 +190,11 @@ namespace LargeSquareOne
|
|||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
|
||||||
var group =TotalGroups.Find(c=>c.GroupName == groupName);
|
var group = TotalGroups.Find(c => c.GroupName == groupName);
|
||||||
|
|
||||||
group.Start = this.txtStart.Text;
|
group.Start = this.txtStart.Text;
|
||||||
group.Length = Convert.ToUInt16(this.num_Length.Value);
|
group.Length = Convert.ToUInt16(this.num_Length.Value);
|
||||||
group.IsTiggerRead = this.ckb_IsTiggerRead.Checked ? true: false;
|
group.IsTiggerRead = this.ckb_IsTiggerRead.Checked ? true : false;
|
||||||
group.IsFeedbackPlc = this.chk_IsFeedbackPlc.Checked ? true : false;
|
group.IsFeedbackPlc = this.chk_IsFeedbackPlc.Checked ? true : false;
|
||||||
group.IsActive = this.ckb_IsEnable.Checked ? true : false;
|
group.IsActive = this.ckb_IsEnable.Checked ? true : false;
|
||||||
group.Remark = this.txt_Remark.Text.Trim();
|
group.Remark = this.txt_Remark.Text.Trim();
|
||||||
@@ -247,14 +241,15 @@ namespace LargeSquareOne
|
|||||||
/// <param name="e"></param>
|
/// <param name="e"></param>
|
||||||
private void dgv_Main_CellFormatting(object sender, DataGridViewCellFormattingEventArgs e)
|
private void dgv_Main_CellFormatting(object sender, DataGridViewCellFormattingEventArgs e)
|
||||||
{
|
{
|
||||||
if (e.ColumnIndex >= 0&&e.RowIndex>=0)
|
if (e.ColumnIndex >= 0 && e.RowIndex >= 0)
|
||||||
{
|
{
|
||||||
object value = this.dgv_Main.Rows[e.RowIndex].Cells[e.ColumnIndex].Value;
|
object value = this.dgv_Main.Rows[e.RowIndex].Cells[e.ColumnIndex].Value;
|
||||||
|
|
||||||
if (value == null||value.ToString().Length==0)
|
if (value == null || value.ToString().Length == 0)
|
||||||
{
|
{
|
||||||
e.Value = "---";
|
e.Value = "---";
|
||||||
};
|
}
|
||||||
|
;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -266,7 +261,7 @@ namespace LargeSquareOne
|
|||||||
/// <param name="e"></param>
|
/// <param name="e"></param>
|
||||||
private void dgv_Main_CellClick(object sender, DataGridViewCellEventArgs e)
|
private void dgv_Main_CellClick(object sender, DataGridViewCellEventArgs e)
|
||||||
{
|
{
|
||||||
if (e.RowIndex>=0)
|
if (e.RowIndex >= 0)
|
||||||
{
|
{
|
||||||
UpdateGroup(TotalGroups[e.RowIndex]);
|
UpdateGroup(TotalGroups[e.RowIndex]);
|
||||||
}
|
}
|
||||||
@@ -274,7 +269,7 @@ namespace LargeSquareOne
|
|||||||
|
|
||||||
private void UpdateGroup(Group group)
|
private void UpdateGroup(Group group)
|
||||||
{
|
{
|
||||||
if (group!=null)
|
if (group != null)
|
||||||
{
|
{
|
||||||
this.txt_GroupName.Text = group.GroupName;
|
this.txt_GroupName.Text = group.GroupName;
|
||||||
this.txtStart.Text = group.Start;
|
this.txtStart.Text = group.Start;
|
||||||
|
|||||||
@@ -1,11 +1,4 @@
|
|||||||
using System;
|
using System;
|
||||||
using System.Collections.Generic;
|
|
||||||
using System.ComponentModel;
|
|
||||||
using System.Data;
|
|
||||||
using System.Drawing;
|
|
||||||
using System.Linq;
|
|
||||||
using System.Text;
|
|
||||||
using System.Threading.Tasks;
|
|
||||||
using System.Windows.Forms;
|
using System.Windows.Forms;
|
||||||
|
|
||||||
namespace LargeSquareOne
|
namespace LargeSquareOne
|
||||||
|
|||||||
@@ -2,14 +2,8 @@
|
|||||||
using JinYuan.Models;
|
using JinYuan.Models;
|
||||||
using JinYuan.VirtualDataLibrary;
|
using JinYuan.VirtualDataLibrary;
|
||||||
using System;
|
using System;
|
||||||
using System.Collections.Generic;
|
|
||||||
using System.ComponentModel;
|
|
||||||
using System.Data;
|
|
||||||
using System.Drawing;
|
using System.Drawing;
|
||||||
using System.Linq;
|
|
||||||
using System.Runtime.InteropServices;
|
using System.Runtime.InteropServices;
|
||||||
using System.Text;
|
|
||||||
using System.Threading.Tasks;
|
|
||||||
using System.Windows.Forms;
|
using System.Windows.Forms;
|
||||||
|
|
||||||
namespace LargeSquareOne
|
namespace LargeSquareOne
|
||||||
@@ -44,13 +38,13 @@ namespace LargeSquareOne
|
|||||||
//数据验证
|
//数据验证
|
||||||
if (this.txt_LoginName.Text.Trim().Length == 0)
|
if (this.txt_LoginName.Text.Trim().Length == 0)
|
||||||
{
|
{
|
||||||
new FrmMsgBoxOutWithAck(2,"请填写登录用户名", "登录提示").ShowDialog();
|
new FrmMsgBoxOutWithAck(2, "请填写登录用户名", "登录提示").ShowDialog();
|
||||||
this.txt_LoginName.Focus();
|
this.txt_LoginName.Focus();
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
if (this.txt_LoginPwd.Text.Trim().Length == 0)
|
if (this.txt_LoginPwd.Text.Trim().Length == 0)
|
||||||
{
|
{
|
||||||
new FrmMsgBoxOutWithAck(2,"请填写登录用密码", "登录提示").ShowDialog();
|
new FrmMsgBoxOutWithAck(2, "请填写登录用密码", "登录提示").ShowDialog();
|
||||||
this.txt_LoginPwd.Focus();
|
this.txt_LoginPwd.Focus();
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
@@ -66,7 +60,7 @@ namespace LargeSquareOne
|
|||||||
sysAdmin = CommonMethods.db.Query<SysAdmin>(it => it.LoginName == sysAdmin.LoginName && it.LoginPwd == sysAdmin.LoginPwd);
|
sysAdmin = CommonMethods.db.Query<SysAdmin>(it => it.LoginName == sysAdmin.LoginName && it.LoginPwd == sysAdmin.LoginPwd);
|
||||||
if (sysAdmin == null)
|
if (sysAdmin == null)
|
||||||
{
|
{
|
||||||
new FrmMsgBoxOutWithAck(3,"登录用户或密码错误!!!", "登录提示").ShowDialog();
|
new FrmMsgBoxOutWithAck(3, "登录用户或密码错误!!!", "登录提示").ShowDialog();
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
|
|||||||
@@ -1,14 +1,7 @@
|
|||||||
using JinYuan.Models;
|
using JinYuan.VirtualDataLibrary;
|
||||||
using JinYuan.VirtualDataLibrary;
|
|
||||||
using System;
|
using System;
|
||||||
using System.Collections.Generic;
|
|
||||||
using System.ComponentModel;
|
|
||||||
using System.Data;
|
|
||||||
using System.Drawing;
|
using System.Drawing;
|
||||||
using System.Linq;
|
|
||||||
using System.Runtime.InteropServices;
|
using System.Runtime.InteropServices;
|
||||||
using System.Text;
|
|
||||||
using System.Threading.Tasks;
|
|
||||||
using System.Windows.Forms;
|
using System.Windows.Forms;
|
||||||
|
|
||||||
namespace LargeSquareOne
|
namespace LargeSquareOne
|
||||||
@@ -57,7 +50,7 @@ namespace LargeSquareOne
|
|||||||
CommonMethods.mesConfig.mesPwd = this.txt_LoginMesPwd.Text.Trim();
|
CommonMethods.mesConfig.mesPwd = this.txt_LoginMesPwd.Text.Trim();
|
||||||
string Mesage = "";
|
string Mesage = "";
|
||||||
string UserCardID = CommonMethods.currentAdmin.LoginUid;
|
string UserCardID = CommonMethods.currentAdmin.LoginUid;
|
||||||
bool Res = CommonMethods.hbgMes.LoginEnyity(CommonMethods.mesConfig.LoginMesUrl, CommonMethods.mesConfig.siteCode, CommonMethods.mesConfig.lineCode, CommonMethods.mesConfig.equipNum, CommonMethods.mesConfig.mesUserName, CommonMethods.mesConfig.mesPwd, UserCardID, ref Mesage);
|
bool Res = CommonMethods.hbgMes.LoginEnyity(CommonMethods.mesConfig.LoginMesUrl, CommonMethods.mesConfig.siteCode, CommonMethods.mesConfig.lineCode, CommonMethods.mesConfig.equipNum, CommonMethods.mesConfig.mesUserName, CommonMethods.mesConfig.mesPwd, UserCardID, ref Mesage);
|
||||||
if (!Res)
|
if (!Res)
|
||||||
{
|
{
|
||||||
new FrmMsgBoxOutWithAck(3, Mesage, "登录提示").ShowDialog();
|
new FrmMsgBoxOutWithAck(3, Mesage, "登录提示").ShowDialog();
|
||||||
|
|||||||
@@ -1,17 +1,17 @@
|
|||||||
using JinYuan.ControlLib;
|
using JinYuan.ControlCenters;
|
||||||
|
using JinYuan.ControlLib;
|
||||||
|
using JinYuan.Helper;
|
||||||
using JinYuan.Models;
|
using JinYuan.Models;
|
||||||
|
using JinYuan.VirtualDataLibrary;
|
||||||
using System;
|
using System;
|
||||||
using System.Collections.Generic;
|
using System.Collections.Generic;
|
||||||
using System.Drawing;
|
using System.Drawing;
|
||||||
using System.Drawing.Text;
|
using System.Drawing.Text;
|
||||||
using System.Linq;
|
using System.Linq;
|
||||||
using System.Threading;
|
|
||||||
using System.Windows.Forms;
|
|
||||||
using JinYuan.VirtualDataLibrary;
|
|
||||||
using JinYuan.ControlCenters;
|
|
||||||
using JinYuan.Helper;
|
|
||||||
using System.Runtime.InteropServices;
|
using System.Runtime.InteropServices;
|
||||||
|
using System.Threading;
|
||||||
using System.Threading.Tasks;
|
using System.Threading.Tasks;
|
||||||
|
using System.Windows.Forms;
|
||||||
|
|
||||||
namespace LargeSquareOne
|
namespace LargeSquareOne
|
||||||
{
|
{
|
||||||
|
|||||||
@@ -1,11 +1,6 @@
|
|||||||
using System;
|
using System;
|
||||||
using System.Collections.Generic;
|
|
||||||
using System.ComponentModel;
|
|
||||||
using System.Data;
|
using System.Data;
|
||||||
using System.Drawing;
|
using System.Drawing;
|
||||||
using System.Linq;
|
|
||||||
using System.Text;
|
|
||||||
using System.Threading.Tasks;
|
|
||||||
using System.Windows.Forms;
|
using System.Windows.Forms;
|
||||||
|
|
||||||
namespace LargeSquareOne
|
namespace LargeSquareOne
|
||||||
@@ -47,14 +42,14 @@ namespace LargeSquareOne
|
|||||||
private Point mPoint;
|
private Point mPoint;
|
||||||
private void Panel_MouseDown(object sender, MouseEventArgs e)
|
private void Panel_MouseDown(object sender, MouseEventArgs e)
|
||||||
{
|
{
|
||||||
mPoint=new Point(e.X, e.Y);
|
mPoint = new Point(e.X, e.Y);
|
||||||
}
|
}
|
||||||
|
|
||||||
private void Panel_MouseMove(object sender, MouseEventArgs e)
|
private void Panel_MouseMove(object sender, MouseEventArgs e)
|
||||||
{
|
{
|
||||||
if (e.Button == MouseButtons.Left)
|
if (e.Button == MouseButtons.Left)
|
||||||
{
|
{
|
||||||
this.Location=new Point(this.Location.X+e.X-mPoint.X,this.Location.Y+e.Y-mPoint.Y);
|
this.Location = new Point(this.Location.X + e.X - mPoint.X, this.Location.Y + e.Y - mPoint.Y);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
#endregion
|
#endregion
|
||||||
|
|||||||
@@ -1,18 +1,12 @@
|
|||||||
using System;
|
using System;
|
||||||
using System.Collections.Generic;
|
|
||||||
using System.ComponentModel;
|
|
||||||
using System.Data;
|
|
||||||
using System.Drawing;
|
using System.Drawing;
|
||||||
using System.Linq;
|
|
||||||
using System.Text;
|
|
||||||
using System.Threading.Tasks;
|
|
||||||
using System.Windows.Forms;
|
using System.Windows.Forms;
|
||||||
|
|
||||||
namespace LargeSquareOne
|
namespace LargeSquareOne
|
||||||
{
|
{
|
||||||
public partial class FrmMsgBoxOutWithAck : Form
|
public partial class FrmMsgBoxOutWithAck : Form
|
||||||
{
|
{
|
||||||
public FrmMsgBoxOutWithAck(int type,string content, string title)
|
public FrmMsgBoxOutWithAck(int type, string content, string title)
|
||||||
{
|
{
|
||||||
InitializeComponent();
|
InitializeComponent();
|
||||||
|
|
||||||
@@ -21,7 +15,7 @@ namespace LargeSquareOne
|
|||||||
this.lbl_Content.Text = content;
|
this.lbl_Content.Text = content;
|
||||||
this.lbl_Title.Text = title;
|
this.lbl_Title.Text = title;
|
||||||
|
|
||||||
switch(type)
|
switch (type)
|
||||||
{
|
{
|
||||||
case 1:
|
case 1:
|
||||||
this.pic_TitleImage.Image = LargeSquareOne.Properties.Resources.info;
|
this.pic_TitleImage.Image = LargeSquareOne.Properties.Resources.info;
|
||||||
@@ -42,14 +36,14 @@ namespace LargeSquareOne
|
|||||||
private Point mPoint;
|
private Point mPoint;
|
||||||
private void Panel_MouseDown(object sender, MouseEventArgs e)
|
private void Panel_MouseDown(object sender, MouseEventArgs e)
|
||||||
{
|
{
|
||||||
mPoint=new Point(e.X, e.Y);
|
mPoint = new Point(e.X, e.Y);
|
||||||
}
|
}
|
||||||
|
|
||||||
private void Panel_MouseMove(object sender, MouseEventArgs e)
|
private void Panel_MouseMove(object sender, MouseEventArgs e)
|
||||||
{
|
{
|
||||||
if (e.Button == MouseButtons.Left)
|
if (e.Button == MouseButtons.Left)
|
||||||
{
|
{
|
||||||
this.Location=new Point(this.Location.X+e.X-mPoint.X,this.Location.Y+e.Y-mPoint.Y);
|
this.Location = new Point(this.Location.X + e.X - mPoint.X, this.Location.Y + e.Y - mPoint.Y);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
#endregion
|
#endregion
|
||||||
|
|||||||
@@ -1,11 +1,5 @@
|
|||||||
using System;
|
using System;
|
||||||
using System.Collections.Generic;
|
|
||||||
using System.ComponentModel;
|
|
||||||
using System.Data;
|
|
||||||
using System.Drawing;
|
using System.Drawing;
|
||||||
using System.Linq;
|
|
||||||
using System.Text;
|
|
||||||
using System.Threading.Tasks;
|
|
||||||
using System.Windows.Forms;
|
using System.Windows.Forms;
|
||||||
|
|
||||||
namespace LargeSquareOne
|
namespace LargeSquareOne
|
||||||
@@ -41,14 +35,14 @@ namespace LargeSquareOne
|
|||||||
private Point mPoint;
|
private Point mPoint;
|
||||||
private void Panel_MouseDown(object sender, MouseEventArgs e)
|
private void Panel_MouseDown(object sender, MouseEventArgs e)
|
||||||
{
|
{
|
||||||
mPoint=new Point(e.X, e.Y);
|
mPoint = new Point(e.X, e.Y);
|
||||||
}
|
}
|
||||||
|
|
||||||
private void Panel_MouseMove(object sender, MouseEventArgs e)
|
private void Panel_MouseMove(object sender, MouseEventArgs e)
|
||||||
{
|
{
|
||||||
if (e.Button == MouseButtons.Left)
|
if (e.Button == MouseButtons.Left)
|
||||||
{
|
{
|
||||||
this.Location=new Point(this.Location.X+e.X-mPoint.X,this.Location.Y+e.Y-mPoint.Y);
|
this.Location = new Point(this.Location.X + e.X - mPoint.X, this.Location.Y + e.Y - mPoint.Y);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
#endregion
|
#endregion
|
||||||
|
|||||||
@@ -4,7 +4,6 @@ using JinYuan.VirtualDataLibrary;
|
|||||||
using Microsoft.Win32;
|
using Microsoft.Win32;
|
||||||
using System;
|
using System;
|
||||||
using System.IO;
|
using System.IO;
|
||||||
using System.Management.Instrumentation;
|
|
||||||
using System.Windows.Forms;
|
using System.Windows.Forms;
|
||||||
|
|
||||||
namespace LargeSquareOne
|
namespace LargeSquareOne
|
||||||
|
|||||||
@@ -1,18 +1,12 @@
|
|||||||
using JinYuan.CommunicationLib.Enum;
|
using JinYuan.CommunicationLib.Enum;
|
||||||
using JinYuan.CommunicationLib.Interface;
|
|
||||||
using PLCCommunication;
|
|
||||||
using JinYuan.Helper;
|
using JinYuan.Helper;
|
||||||
using JinYuan.Models;
|
using JinYuan.Models;
|
||||||
using JinYuan.VirtualDataLibrary;
|
using JinYuan.VirtualDataLibrary;
|
||||||
using SqlSugar;
|
using PLCCommunication;
|
||||||
using System;
|
using System;
|
||||||
using System.Collections.Generic;
|
using System.Collections.Generic;
|
||||||
using System.ComponentModel;
|
using System.ComponentModel;
|
||||||
using System.Data;
|
|
||||||
using System.Drawing;
|
|
||||||
using System.Linq;
|
|
||||||
using System.Text;
|
using System.Text;
|
||||||
using System.Threading.Tasks;
|
|
||||||
using System.Windows.Forms;
|
using System.Windows.Forms;
|
||||||
|
|
||||||
namespace LargeSquareOne
|
namespace LargeSquareOne
|
||||||
|
|||||||
Some files were not shown because too many files have changed in this diff Show More
Reference in New Issue
Block a user