|
|
|
@ -219,9 +219,15 @@ namespace SlnMesnac.TouchSocket
|
|
|
|
|
//_logger.LogInformation("扫描数据回传接口");
|
|
|
|
|
//_logger.LogInformation("{Data}", scanLog.ToJsonString());
|
|
|
|
|
|
|
|
|
|
_logger.LogInformation($"收到接口数据:{scanLog.ToJsonString()}");
|
|
|
|
|
DateTimeOffset dateTimeOffset = DateTimeOffset.FromUnixTimeMilliseconds(scanLog.timestamp);
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
_logger.LogInformation($"时间戳: {scanLog.timestamp};转换为时间:{dateTimeOffset.LocalDateTime};{dateTimeOffset.LocalDateTime}");
|
|
|
|
|
|
|
|
|
|
var model = new ScanLogModel()
|
|
|
|
|
{
|
|
|
|
|
CreateTime = scanLog.CreateTime,
|
|
|
|
|
CreateTime = dateTimeOffset.LocalDateTime,
|
|
|
|
|
DataType = scanLog.data_type,
|
|
|
|
|
Code = scanLog.code,
|
|
|
|
|
Rfid = scanLog.rfid,
|
|
|
|
@ -336,12 +342,13 @@ namespace SlnMesnac.TouchSocket
|
|
|
|
|
}
|
|
|
|
|
else
|
|
|
|
|
{
|
|
|
|
|
string mulRes = string.Empty;
|
|
|
|
|
string[] buffer = hk.code.Split(",");
|
|
|
|
|
|
|
|
|
|
if (buffer.Length > 1)
|
|
|
|
|
{
|
|
|
|
|
hk.code = "多条码";
|
|
|
|
|
|
|
|
|
|
//hk.code = "多条码";
|
|
|
|
|
mulRes = "多条码";
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
if (hk.rfid == hk.code && !string.IsNullOrEmpty(hk.rfid) && hk.rfid != "NoRead" && hk.rfid != "多条码")
|
|
|
|
@ -350,8 +357,16 @@ namespace SlnMesnac.TouchSocket
|
|
|
|
|
}
|
|
|
|
|
else
|
|
|
|
|
{
|
|
|
|
|
if(hk.code.Contains(hk.rfid))
|
|
|
|
|
{
|
|
|
|
|
hk.code = hk.rfid;
|
|
|
|
|
result = hk.code;
|
|
|
|
|
}
|
|
|
|
|
else
|
|
|
|
|
{
|
|
|
|
|
result = mulRes;
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
}
|
|
|
|
|