| | |
| | | _supplyTaskService.AddData(supplyTasks); |
| | | _inventory_BatchServices.UpdateData(batchesUp); |
| | | _inventoryInfoService.UpdateData(inventoryInfosUp); |
| | | BaseDal.Db.CopyNew().InsertNav(entityOrder).Include(x => x.Details).ExecuteCommand(); |
| | | BaseDal.Db.InsertNav(entityOrder).Include(x => x.Details).ExecuteCommand(); |
| | | _unitOfWorkManage.CommitTran(); |
| | | #endregion |
| | | } |
| | |
| | | _inventory_BatchServices.UpdateData(batchesUp); |
| | | _inventoryInfoService.UpdateData(inventoryInfosUp); |
| | | if (entityOrder.Details.Count > 0) |
| | | BaseDal.Db.CopyNew().InsertNav(entityOrder).Include(x => x.Details).ExecuteCommand(); |
| | | BaseDal.Db.InsertNav(entityOrder).Include(x => x.Details).ExecuteCommand(); |
| | | if (entityOrderLK.Details.Count > 0) |
| | | BaseDal.Db.CopyNew().InsertNav(entityOrderLK).Include(x => x.Details).ExecuteCommand(); |
| | | BaseDal.Db.InsertNav(entityOrderLK).Include(x => x.Details).ExecuteCommand(); |
| | | _unitOfWorkManage.CommitTran(); |
| | | } |
| | | catch (Exception ex) |
| | |
| | | try |
| | | { |
| | | // 1ï¸â£ æ¥æ¾æå®æ¹æ¬¡ä¸ç©æçåºåä¿¡æ¯ |
| | | var batchInfo = BaseDal.Db.CopyNew().Queryable<Dt_Inventory_Batch>() |
| | | .Where(x => x.BatchNo == batchNo && x.MaterielCode == goodsNo) |
| | | .First(); |
| | | var batchInfo = _inventory_BatchServices.Repository.QueryFirst(x => x.BatchNo == batchNo && x.MaterielCode == goodsNo); |
| | | |
| | | if (batchInfo == null) |
| | | return response.Error($"æªæ¾å°è¯¥ç©æ [{goodsNo}] æ¹æ¬¡ [{batchNo}] çåºåä¿¡æ¯"); |
| | |
| | | WebResponseContent content = new WebResponseContent(); |
| | | try |
| | | { |
| | | Dt_DeliveryOrder? cabinOrder = BaseDal.Db.CopyNew().Queryable<Dt_DeliveryOrder>().Where(x => x.Out_no == supplyTask.OrderNo && x.Warehouse_no == supplyTask.WarehouseCode).Includes(x => x.Details).First(); |
| | | Dt_DeliveryOrder? cabinOrder = BaseDal.Db.Queryable<Dt_DeliveryOrder>().Where(x => x.Out_no == supplyTask.OrderNo && x.Warehouse_no == supplyTask.WarehouseCode).Includes(x => x.Details).First(); |
| | | if (cabinOrder == null) return WebResponseContent.Instance.OK($"åºåºå已宿"); |
| | | |
| | | Dt_DeliveryOrderDetail? cabinOrderDetail = cabinOrder.Details.Where(x => x.Batch_num == supplyTask.BatchNo && x.Reservoirarea == supplyTask.WarehouseCode && x.Goods_no == supplyTask.MaterielCode).FirstOrDefault(); |
| | |
| | | //_deliveryOrderDetailServices.Repository.DeleteAndMoveIntoHty(cabinOrderDetail, OperateTypeEnum.èªå¨å®æ); |
| | | } |
| | | _deliveryOrderDetailServices.Repository.UpdateData(cabinOrderDetail); |
| | | var cabinOrder1 = BaseDal.Db.CopyNew().Queryable<Dt_DeliveryOrder>().Where(x => x.Out_no == cabinOrder.Out_no && x.Warehouse_no == supplyTask.WarehouseCode && x.Out_type != "20").Includes(x => x.Details).First(); |
| | | var cabinOrder1 = BaseDal.Db.Queryable<Dt_DeliveryOrder>().Where(x => x.Out_no == cabinOrder.Out_no && x.Warehouse_no == supplyTask.WarehouseCode && x.Out_type != "20").Includes(x => x.Details).First(); |
| | | if (!cabinOrder1.Details.Where(x => x.OotDetailStatus != "已宿").Any()) |
| | | cabinOrder.OutStatus = "已宿"; |
| | | Repository.UpdateData(cabinOrder); |