|
|
|
@ -496,9 +496,10 @@ namespace Khd.Core.Wcs.Wcs
|
|
|
|
{
|
|
|
|
{
|
|
|
|
using var scope = _host.Services.CreateScope();
|
|
|
|
using var scope = _host.Services.CreateScope();
|
|
|
|
using var dbContext = scope.ServiceProvider.GetRequiredService<DefaultDbContext>();
|
|
|
|
using var dbContext = scope.ServiceProvider.GetRequiredService<DefaultDbContext>();
|
|
|
|
using var transaction = dbContext.Database.BeginTransaction();
|
|
|
|
|
|
|
|
while (true)
|
|
|
|
while (true)
|
|
|
|
{
|
|
|
|
{
|
|
|
|
|
|
|
|
using var transaction = dbContext.Database.BeginTransaction();
|
|
|
|
try
|
|
|
|
try
|
|
|
|
{
|
|
|
|
{
|
|
|
|
var mesCloseValue = StaticData.PlcDic[0].Read(this.mesClose.plcpointAddress); //MES关闭状态 读
|
|
|
|
var mesCloseValue = StaticData.PlcDic[0].Read(this.mesClose.plcpointAddress); //MES关闭状态 读
|
|
|
|
|