diff --git a/ProductionMgr/Tnb.ProductionMgr.Entities/Entity/PrdVisionResultRecord.cs b/ProductionMgr/Tnb.ProductionMgr.Entities/Entity/PrdVisionResultRecord.cs
new file mode 100644
index 00000000..09faf2bf
--- /dev/null
+++ b/ProductionMgr/Tnb.ProductionMgr.Entities/Entity/PrdVisionResultRecord.cs
@@ -0,0 +1,15 @@
+using JNPF.Common.Contracts;
+
+namespace Tnb.ProductionMgr.Entities
+{
+ ///
+ /// 视觉设备判定结果记录表
+ ///
+ public class PrdVisionResultRecord : BaseEntity
+ {
+ public string info { get; set; }
+ public string result { get; set; }
+ public int num { get; set; }
+ public DateTime create_time { get; set; }
+ }
+}
\ No newline at end of file
diff --git a/ProductionMgr/Tnb.ProductionMgr/PrdMoTaskService.cs b/ProductionMgr/Tnb.ProductionMgr/PrdMoTaskService.cs
index f40d69df..150a5537 100644
--- a/ProductionMgr/Tnb.ProductionMgr/PrdMoTaskService.cs
+++ b/ProductionMgr/Tnb.ProductionMgr/PrdMoTaskService.cs
@@ -3356,6 +3356,13 @@ namespace Tnb.ProductionMgr
public async Task VisionResult(MarkingLabelInput input)
{
Log.Information($"视觉设备判定参数:{JsonConvert.SerializeObject(input)}");
+ PrdVisionResultRecord reocrd = new PrdVisionResultRecord();
+ reocrd.id = SnowflakeIdHelper.NextId();
+ reocrd.info = input.mark_code;
+ reocrd.result = input.result;
+ reocrd.create_time = DateTime.Now;
+ reocrd.num = int.Parse(input.station_id);
+ await _db.Insertable(reocrd).ExecuteCommandAsync();
return $"接收到参数:{JsonConvert.SerializeObject(input)}";
}
diff --git a/apihost/Tnb.API.Entry/Startup.cs b/apihost/Tnb.API.Entry/Startup.cs
index 692e0d5a..ee57504c 100644
--- a/apihost/Tnb.API.Entry/Startup.cs
+++ b/apihost/Tnb.API.Entry/Startup.cs
@@ -64,7 +64,7 @@ public class Startup : AppStartup
services.AddSingleton(sp => new TimedTaskBackgroundService());
//var bgSvc = App.GetRequiredService();
//bgSvc.StartAsync(CancellationToken.None);
- services.AddHostedService();
+ // services.AddHostedService();
}