public async Task <ApiJsonResultData> GetOutpatientDetailPerson() { return(await new ApiJsonResultData().RunWithTryAsync(async y => { var verificationCode = await GetUserBaseInfo(); if (verificationCode != null) { var outPatient = new OutpatientParam() { 验证码 = verificationCode.验证码, 机构编码 = verificationCode.机构编码, 身份证号码 = "511526199610225518", 开始时间 = "2019-04-27 11:09:00", 结束时间 = "2020-04-27 11:09:00", }; var inputInpatientInfoData = await _webServiceBasicService.GetOutpatientPerson(verificationCode, outPatient); if (inputInpatientInfoData.Any()) { var inputInpatientInfoFirst = inputInpatientInfoData.FirstOrDefault(); var outpatientDetailParam = new OutpatientDetailParam() { 验证码 = verificationCode.验证码, 门诊号 = inputInpatientInfoFirst.门诊号, 业务ID = inputInpatientInfoFirst.业务ID }; var inputInpatientInfoDatas = await _webServiceBasicService. GetOutpatientDetailPerson(verificationCode, outpatientDetailParam); y.Data = inputInpatientInfoDatas; } } //var data = await webService.ExecuteSp(param.Params); })); }
/// <summary> /// 获取门诊病人费用明细 /// </summary> /// <param name="param"></param> /// <returns></returns> public List <BaseOutpatientDetailDto> GetOutpatientDetailPerson(OutpatientDetailParam param) { var resultData = new List <BaseOutpatientDetailDto>(); var xmlData = new MedicalInsuranceXmlDto(); xmlData.BusinessId = param.BusinessId; xmlData.HealthInsuranceNo = "48";//42MZ xmlData.TransactionId = param.User.TransKey; xmlData.AuthCode = param.User.AuthCode; xmlData.UserId = param.User.UserId; xmlData.OrganizationCode = param.User.OrganizationCode; var jsonParam = JsonConvert.SerializeObject(xmlData); var data = _webServiceBasic.HIS_Interface("39", jsonParam); OutpatientPersonJsonDto dataValue = JsonConvert.DeserializeObject <OutpatientPersonJsonDto>(data.Msg); var detailInfo = dataValue.DetailInfo; foreach (var item in detailInfo) { var detail = AutoMapper.Mapper.Map <BaseOutpatientDetailDto>(item); detail.OrganizationCode = param.User.OrganizationCode; detail.OrganizationName = param.User.OrganizationName; detail.OutpatientNo = dataValue.OutpatientPersonBase.OutpatientNumber; resultData.Add(detail); } if (param.IsSave) { _hisSqlRepository.SaveOutpatientDetail(param.User, resultData); } return(resultData); }
/// <summary> /// 获取门诊病人费用明细 /// </summary> /// <param name="param"></param> /// <returns></returns> public async Task <List <OutpatientDetailDto> > GetOutpatientDetailPerson(UserInfoDto user, OutpatientDetailParam param) { List <OutpatientDetailDto> result; var init = new OutpatientDetailDto(); var data = await _webServiceBasic.HIS_InterfaceListAsync("16", JsonConvert.SerializeObject(param), user.职员ID); result = GetResultData(init, data); if (result.Any()) { await _dataBaseHelpService.GetOutpatientDetailPerson(user, result); } return(result); }