dengjunjie
2024-11-06 36230cd4dd0ebe5d21eede3eff6216908f7f7a8e
项目代码/WCS/WIDESEAWCS_Server/WIDESEAWCS_Tasks/ConveyorLineJob/CommonConveyorLineJob.cs
@@ -40,7 +40,7 @@
namespace WIDESEAWCS_Tasks
{
    [DisallowConcurrentExecution]
    public class CommonConveyorLineJob : IJob
    public class CommonConveyorLineJob : JobBase, IJob
    {
        private readonly ITaskService _taskService;
        private readonly ITaskExecuteDetailService _taskExecuteDetailService;
@@ -77,16 +77,16 @@
                                case "104":
                                    ConveyorLineInFinish(conveyorLine, command, childDeviceCode);
                                    break;
                                case "105":
                                    RequestOutbound(conveyorLine, command, childDeviceCode);
                                    break;
                                //case "105":
                                //    RequestOutbound(conveyorLine, command, childDeviceCode);
                                //    break;
                                case "108":
                                    ConveyorLineOutFinish(conveyorLine, command, childDeviceCode);
                                    break;
                                default:
                                    RequestInNextAddress(conveyorLine, command, childDeviceCode);
                                    RequestOutNextAddress(conveyorLine, command, childDeviceCode);
                                    break;
                                    //default:
                                    //    RequestInNextAddress(conveyorLine, command, childDeviceCode);
                                    //    RequestOutNextAddress(conveyorLine, command, childDeviceCode);
                                    //    break;
                            }
                        }
                    }
@@ -117,7 +117,7 @@
            {
                ConveyorLineDTO lineDTO = new ConveyorLineDTO()
                {
                    TaskNum = task.TaskNum,
                    //TaskNum = task.TaskNum,
                    stationCode = childDeviceCode,
                    Barcode = command.Barcode,
                    Spec = command.Spec,
@@ -127,8 +127,8 @@
                if (content.Status)
                {
                    task.TargetAddress = "104";
                    task.NextAddress = "103";
                    task.TargetAddress = AppSettings.Configuration["OKAddress"];
                    task.NextAddress = task.TargetAddress;
                    ConveyorLineTaskCommandW taskCommand = _mapper.Map<ConveyorLineTaskCommandW>(task);
                    if (conveyorLine.SendCommand(taskCommand, childDeviceCode))
@@ -138,8 +138,8 @@
                {
                    if (content.Code == 404)//淇敼缁堢偣鍦板潃
                    {
                        task.TargetAddress = "101";
                        task.NextAddress = "101";
                        task.TargetAddress = AppSettings.Configuration["NGAddress"];
                        task.NextAddress = task.TargetAddress;
                        task.ExceptionMessage = content.Message;
                        task.TaskState = (int)TaskInStatusEnum.InException;
                        ConveyorLineTaskCommandW taskCommand = _mapper.Map<ConveyorLineTaskCommandW>(task);