示例#1
0
        /// <summary>
        ///
        /// </summary>
        /// <param name="request"></param>
        /// <returns></returns>
        /// <exception>医院不存在</exception>
        public static GetHospitalResponse GetHospital(GetHospitalRequest request)
        {
            var hospital = HospitalRep.GetByID(request.HospitalID).ThrowIfNull("医院不存在");

            return(new GetHospitalResponse()
            {
                CreateUserItem = new ApiTranRequest.CreateUserItem()
                {
                    CreateTime = hospital.CreateTime,
                    CreateUserID = Guid.Empty,
                    Name = ""
                },
                UpdateUserItem = new ApiTranRequest.UpdateUserItem()
                {
                    UpdateUserID = Guid.Empty,
                    Name = "",
                    UpdateTime = hospital.UpdateTime,
                },
                HospitalItem = new ApiTranRequest.Hospital.GetHospital.HospitalItem()
                {
                    HospitalID = hospital.ID,
                    Name = hospital.Name
                }
            });
        }
示例#2
0
 public GetHospitalResponse GetHospital(GetHospitalRequest request)
 {
     return(HospitalService.GetHospital(request));
 }