1
schangxiang@126.com
2024-12-02 607fa9a9dec5ff4fe780231d635bbd62e1740f37
CC/iWareCC_ASRS/ThreadService/02_BZ39¹¤Î»£¨²¹°åºó¹¤Î»£©/Inbound/1¡¢DataProcess_BZ39.cs
@@ -34,7 +34,7 @@
                SystemWarningMsg._lbl_alert_DataProcess_BZ39 = string.Empty;
                try
                {
                    if (SystemValue.isAllowRuning_DataProcess_BZ39 && SystemValue.isStartedModel)
                    if (SystemValue.isStartedModel)//SystemValue.isAllowRuning_DataProcess_BZ39 &&
                    {
                        var rgvLocation = StationLocationEnum.BZ39.ToString();
                        /*
@@ -55,15 +55,15 @@
                            using (WmsDBModel wmsDB = new WmsDBModel())
                            {
                                //不再拦截 
                                /*
                                //要是有已下发的任务,就不要执行
                                var isValidate = TaskHandler.ValidateIssueTaskForRobotBuffer(wmsDB);
                                var isValidate = TaskHandler.ValidateIssueTaskForRobotBuffer(wmsDB, upiCode);
                                if (!isValidate)
                                {
                                    SystemWarningMsg._lbl_alert_DataProcess_BZ39 = $"{rgvLocation.ToString()}-有‘已下发’的任务,不能处理,此次循环结束";
                                    continue;
                                }
                                //*/
                                //
                                var upiObj = wmsDB.mes_batchOrderUPI_new.Where(x => x.UPI == upiCode).FirstOrDefault();
                                if (upiObj == null)
                                {
@@ -86,7 +86,6 @@
                                {
                                    Id = _id,
                                    TaskNo = plcTaskNo,
                                    UPI = upiObj.UPI,
                                    Length = upiObj.Length,
                                    Width = upiObj.Width,
@@ -113,20 +112,6 @@
                                using (StationServiceClient client = new StationServiceClient())
                                {
                                    //不再拦截
                                    /*
                                    //首先先清理
                                    var res = await client.InboundFinishConfirmAsync((int)EDevice.Station, false, rgvLocation);
                                    if (!res.result)
                                    {
                                        SystemWarningMsg._lbl_alert_DataProcess_BZ39 = $"{rgvLocation.ToString()}-下发入库任务 å¤±è´¥,InboundFinishConfirmAsync è¿”回:{res.resMsg}";
                                        continue;
                                    }
                                    else
                                    {
                                        Log4NetHelper.WriteInfoLog(logType, $"{rgvLocation.ToString()}-下发入库任务 æˆåŠŸ,InboundFinishConfirmAsync,参数: ç«™ç‚¹{rgvLocation}");
                                    }
                                    //*/
                                    var res = await client.WriteInStoreTaskInfoAsync((int)EDevice.Station, rgvLocation, place.PlaceCode,
                                       (short)upiObj.Length,
@@ -146,6 +131,8 @@
                                place.PlaceStatus = (int)PlaceStatusEnum.锁定;
                                WmsRecordUpiProcessHandler.SaveWmsRecordUpiProcess(wmsDB, upiObj, "BZ39", "缓存入库");
                                wmsDB.SaveChanges();
                            }
                        }