| | |
| | | |
| | | if (response.resultCode != "0") |
| | | { |
| | | SendErrorToUpstream(8, "", response.resultMsg ?? "䏿¸¸æ¥å£è¿å失败", ""); |
| | | //SendErrorToUpstream(8, "", response.resultMsg ?? "䏿¸¸æ¥å£è¿å失败", ""); |
| | | return responseContent.Error(response.resultMsg ?? "䏿¸¸æ¥å£è¿å失败"); |
| | | } |
| | | |
| | |
| | | catch (Exception ex) |
| | | { |
| | | Db.Ado.RollbackTran(); |
| | | SendErrorToUpstream(8, "", ex.Message, ""); |
| | | //SendErrorToUpstream(8, "", ex.Message, ""); |
| | | return responseContent.Error("åæ¥å¤±è´¥: " + ex.Message); |
| | | } |
| | | } |
| | |
| | | #endregion |
| | | else |
| | | { |
| | | if (cabinOrder == null || cabinOrder.OdrderStatus == "已宿") |
| | | throw new Exception($"å
¥åºå已宿"); |
| | | if (cabinOrder.OdrderStatus == "已宿") |
| | | return new ApiResponse<Dt_InventoryInfo> |
| | | { |
| | | code = "0", |
| | | msg = "æå" |
| | | }; |
| | | Dt_CabinOrderDetail cabinOrderDetail = cabinOrder.Details.Where(x => x.Goods_no == detail.productCode && x.Batch_num == detail.batchNo && x.Status == 1).First(); |
| | | if (cabinOrderDetail == null || cabinOrderDetail.OrderDetailStatus == "已宿") |
| | | throw new Exception($"å
¥åºåæç»å·²å®æ"); |
| | |
| | | ProductionDate = detail.finishDate.ToString("yyyy-MM-dd"), |
| | | ShelfLife = 0, |
| | | ValidityPeriod = cabinOrderDetail.Exp_date, |
| | | Remark = "WCSåä¼ å建" |
| | | Remark = "æºè½ç«åº" |
| | | }; |
| | | BaseDal.Db.Insertable(inventoryInfo).ExecuteCommand(); |
| | | } |
| | |
| | | ERPStockQuantity = 0, |
| | | Status = false, |
| | | ProductionDate = detail.finishDate.ToString("yyyy-MM-dd"), |
| | | ValidityPeriod = inventoryInfo.ValidityPeriod, |
| | | ValidityPeriod = inventoryInfo.ValidityPeriod.ObjToDate(), |
| | | Remark = "èªå¨å建" |
| | | }; |
| | | BaseDal.Db.Insertable(inventory_Batch).ExecuteCommand(); |