扫材料码页面,固化时间,事件记录
This commit is contained in:
1 parent
083c4ec3ac
commit
d9a3f19678
10 files changed
+842
-94
No files matched your search
@@ -86,12 +86,10 @@ namespace WindowsFormsApp1.server
|
||||
var station = Init.t_Line.lineremark2.ToLower();
|
||||
switch (station)
|
||||
{
|
||||
case "Potting"://灌胶
|
||||
case "ThermalPaste"://点胶&CCD检测
|
||||
case "UVCoating"://三防漆涂覆
|
||||
case "Sealant"://点密封胶&CCD
|
||||
break;
|
||||
default:
|
||||
case "potting"://灌胶
|
||||
case "thermalpaste"://点胶&CCD检测
|
||||
case "uvcoating"://三防漆涂覆
|
||||
case "sealant"://点密封胶&CCD
|
||||
var power = Init.t_Keyvalues.First(x => x.key == "Power");
|
||||
power.value = DateTime.Now.Millisecond.ToString();
|
||||
SQLiteHelper<t_keyvalue> kvHelper = new db.SQLiteHelper<t_keyvalue>();
|
||||
@@ -327,10 +325,10 @@ namespace WindowsFormsApp1.server
|
||||
var locationindex = 1;
|
||||
switch (station)
|
||||
{
|
||||
case "Potting"://灌胶
|
||||
case "ThermalPaste"://点胶&CCD检测
|
||||
case "UVCoating"://三防漆涂覆
|
||||
case "Sealant"://点密封胶&CCD
|
||||
case "potting"://灌胶
|
||||
case "thermalpaste"://点胶&CCD检测
|
||||
case "uvcoating"://三防漆涂覆
|
||||
case "sealant"://点密封胶&CCD
|
||||
break;
|
||||
default:
|
||||
fixsn_1 = "CompPN";
|
||||
@@ -514,7 +512,7 @@ namespace WindowsFormsApp1.server
|
||||
{
|
||||
// 根据不同的lineCode构建不同的请求
|
||||
var lineCode = Init.t_Line.linecode;
|
||||
var stationid = Init.t_Line.lineremark2;
|
||||
var stationid = Init.t_Line.lineremark2.ToLower();
|
||||
|
||||
var result = PlcData.Read_Result == 1 ? "PASS" : "FAIL";
|
||||
var logresult = PlcData.Read_Result == 1 ? "OK" : "NG";
|
||||
@@ -550,7 +548,7 @@ namespace WindowsFormsApp1.server
|
||||
var compListItem = new CompListItem();
|
||||
|
||||
//气密
|
||||
if ("SWAT".Contains(stationid))
|
||||
if ("WAT,Leakage".Contains(stationid))
|
||||
{
|
||||
|
||||
sninfo.DC_INFO.Add(new DCInfoItem
|
||||
@@ -615,7 +613,33 @@ namespace WindowsFormsApp1.server
|
||||
//固化 时间
|
||||
if ("Curing".Contains(stationid))
|
||||
{
|
||||
SQLiteHelper<t_materialcall> materialHelper = new db.SQLiteHelper<t_materialcall>();
|
||||
var material = materialHelper.QuerySingle(x => x.materialid == PlcData.Read_MaterialCode0);
|
||||
if (material.Success)
|
||||
{
|
||||
// 计算加热时间
|
||||
var time = ((TimeSpan)(material.Data.checkin2 - material.Data.checkout2)).TotalMinutes;
|
||||
var jrTime = Convert.ToInt32(time).ToString();
|
||||
sninfo.DC_INFO.Add(new DCInfoItem
|
||||
{
|
||||
Item = OutItem.固化时间,
|
||||
Value = jrTime,
|
||||
Result = result
|
||||
});
|
||||
sninfo.DC_INFO.Add(new DCInfoItem
|
||||
{
|
||||
Item = OutItem.固化温度,
|
||||
Value = PlcData.Read_UploadData0.ToString(),
|
||||
Up = "85",
|
||||
Down = "75",
|
||||
Result = result
|
||||
});
|
||||
|
||||
}
|
||||
else
|
||||
{
|
||||
//报错,没有这个物料
|
||||
}
|
||||
}
|
||||
//胶重
|
||||
if ("Potting,ThermalPaste,Sealant".Contains(stationid))
|
||||
@@ -867,6 +891,8 @@ namespace WindowsFormsApp1.server
|
||||
{
|
||||
public string Item { get; set; }
|
||||
public string Value { get; set; }
|
||||
public string Up { get; set; } = "";
|
||||
public string Down { get; set; } = "";
|
||||
public string Result { get; set; }
|
||||
}
|
||||
|
||||
|
||||
Reference in new issue
Block a user