/// <summary> /// 获取一条仓库数据 /// </summary> /// <returns></returns> public CargoGetOneResponse GetOneCargo(CargoGetOneRequest request) { var info = cdal.GetOneCargo(request.pid); CargoGetOneResponse response = new CargoGetOneResponse() { CargoId = info.CargoId, CargoName = info.CargoName, CargoRemark = info.CargoRemark, CargoState = info.CargoState, CargoType = info.CargoType, CargoWeight = info.CargoWeight, ShippingOrder = info.ShippingOrder }; //判断pid是否存在 if (request.pid > 0) { response.IsRegistSuccess = true; response.Message = "获取成功"; } else { response.Status = false; response.Message = "未获取选中数据"; return(response); } return(response); }