添加项目文件。
This commit is contained in:
44
WPFWCSDemo/Schedules/CircleRGV/CircleRGVSchedule.cs
Normal file
44
WPFWCSDemo/Schedules/CircleRGV/CircleRGVSchedule.cs
Normal file
@@ -0,0 +1,44 @@
|
||||
using Quartz;
|
||||
using Serilog;
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
using System.Diagnostics;
|
||||
using System.Linq;
|
||||
using System.Text;
|
||||
using System.Threading.Tasks;
|
||||
using System.Windows;
|
||||
using WPFWCSDemo.Utilities;
|
||||
|
||||
namespace WPFWCSDemo.Schedules.CircleRGV
|
||||
{
|
||||
[DisallowConcurrentExecution]
|
||||
public class CircleRGVSchedule : IJob
|
||||
{
|
||||
public async Task Execute(IJobExecutionContext context)
|
||||
{
|
||||
//Application.Current.Dispatcher.InvokeAsync(() =>
|
||||
//{
|
||||
await Task.Run(async () =>
|
||||
{
|
||||
bool b = await CommonTask.Common.GetPingForRGVStation("192.168.6.100");
|
||||
|
||||
if (b)
|
||||
{
|
||||
await Update.UpdateDeviceNumber();
|
||||
|
||||
await Update.UpdateScheduleState();
|
||||
|
||||
Excute.ExecuteTask();
|
||||
|
||||
Generate.GenerateTask();
|
||||
|
||||
// //Log.Information($"-----------------设备调度-----------------");
|
||||
}
|
||||
});
|
||||
|
||||
//});
|
||||
|
||||
//return Task.CompletedTask;
|
||||
}
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user