| | |
| | | [MapHub("/hubs/PlcDevice")] |
| | | public class PlcDeviceHub : Hub<IPlcDeviceHub> |
| | | { |
| | | private static readonly IHubContext<PlcDeviceHub, IPlcDeviceHub> _plcDeviceHubContext = App.GetService<IHubContext<PlcDeviceHub, IPlcDeviceHub>>(); |
| | | private static readonly SysCacheService _sysCacheService = App.GetRequiredService<SysCacheService>(); |
| | | private static bool boRunningState = false; |
| | | private static CancellationTokenSource cts;//取消线程标识 |
| | |
| | | modDevice.PickStorey != initialState.PickStorey))) |
| | | { |
| | | // 通知用户变更 |
| | | _plcDeviceHubContext.Clients.All.PublicPlcDevice(modDevice); |
| | | HubUtil.PublicPlcDevice(modDevice); |
| | | } |
| | | } |
| | | initialStates[modDevice.Id] = modDevice.Adapt<WcsDeviceOutput>(); |