|  |  |  | 
|---|
|  |  |  | { | 
|---|
|  |  |  | var task = wmsDB.wms_rbline_task.Where(x => | 
|---|
|  |  |  | x.TaskNo == obj.R_Outbound_TaskID.ToString() | 
|---|
|  |  |  | && x.RbTaskType == (int)RbTaskTypeEnum.åºåºä»»å¡ | 
|---|
|  |  |  | && (x.RbTaskType == (int)RbTaskTypeEnum.é½å
åºåºä»»å¡ || x.RbTaskType == (int)RbTaskTypeEnum.强å¶åºåºä»»å¡) | 
|---|
|  |  |  | ).OrderByDescending(x => x.Id).FirstOrDefault(); | 
|---|
|  |  |  | if (task == null) | 
|---|
|  |  |  | { | 
|---|
|  |  |  | 
|---|
|  |  |  | SystemWarningMsg._lbl_Alert_DataProcess_RobotBuffer_FinishTaskForOutbound = $"{rgvLocation.ToString()},æ ¹æ®UPI:{upiCode}æ²¡ææ¾å°å¯¹è±¡ "; | 
|---|
|  |  |  | continue; | 
|---|
|  |  |  | } | 
|---|
|  |  |  | //æ´æ°æ¿ä»¶çç¶æååºå | 
|---|
|  |  |  | if (task.RbTaskType == (int)RbTaskTypeEnum.é½å
åºåºä»»å¡) | 
|---|
|  |  |  | { | 
|---|
|  |  |  | upiObj.UpiStatus = (int)UpiStatusEnum.å·²é½å
; | 
|---|
|  |  |  | upiObj.AreaCode = (int)AreaCodeEnum.ç ååºå; | 
|---|
|  |  |  | } | 
|---|
|  |  |  | else if (task.RbTaskType == (int)RbTaskTypeEnum.强å¶åºåºä»»å¡) | 
|---|
|  |  |  | { | 
|---|
|  |  |  | upiObj.UpiStatus = (int)UpiStatusEnum.å·²ä¸çº¿; | 
|---|
|  |  |  | upiObj.AreaCode = (int)AreaCodeEnum.ä¸çº¿åºå; | 
|---|
|  |  |  | } | 
|---|
|  |  |  |  | 
|---|
|  |  |  | //åºååå° | 
|---|
|  |  |  | wms_stock_quan qun = wmsDB.wms_stock_quan.Where(x => x.PlaceCode == task.PlaceCode).FirstOrDefault(); | 
|---|
|  |  |  | wmsDB.wms_stock_quan.Remove(qun); | 
|---|
|  |  |  | 
|---|
|  |  |  | } | 
|---|
|  |  |  | } | 
|---|
|  |  |  |  | 
|---|
|  |  |  | WmsRecordUpiProcessHandler.SaveWmsRecordUpiProcess(wmsDB, upiObj, task.PlaceCode, $"åºç¼ååºï¼{task.PlaceCode},"+task.TaskMsg); | 
|---|
|  |  |  | WmsRecordUpiProcessHandler.SaveWmsRecordUpiProcess(wmsDB, upiObj, task.PlaceCode, $"åºç¼ååºï¼{task.PlaceCode}," + task.TaskMsg); | 
|---|
|  |  |  |  | 
|---|
|  |  |  | wmsDB.SaveChanges(); | 
|---|
|  |  |  | } | 
|---|