//个人信息(不可编辑) public static List <PatientDetailInfo> GetPatientDetailInfo(ServicesSoapClient _ServicesSoapClient, string UserId, string Category) { List <PatientDetailInfo> ItemInfo = new List <PatientDetailInfo>(); DataSet ItemInfoSet = _ServicesSoapClient.GetItemInfoByPIdAndModule(UserId, Category); foreach (DataTable item in ItemInfoSet.Tables) { foreach (DataRow row in item.Rows) { if (row[3].ToString() != "InvalidFlag" && row[3].ToString() != "Patient") { if (row[3].ToString() == "Doctor") { PatientDetailInfo NewLine = new PatientDetailInfo() { CategoryCode = row[1].ToString(), CategoryName = row[2].ToString(), ItemCode = row[3].ToString(), ItemName = row[4].ToString(), ParentCode = row[5].ToString(), ItemSeq = Convert.ToInt32(row[6]), Value = row[7].ToString(), Content = _ServicesSoapClient.GetUserName(row[7].ToString()) }; ItemInfo.Add(NewLine); } else { PatientDetailInfo NewLine = new PatientDetailInfo() { ItemCode = row[3].ToString(), ItemName = row[4].ToString(), ParentCode = row[5].ToString(), ControlType = row[11].ToString(), OptionCategory = row[12].ToString(), ItemSeq = Convert.ToInt32(row[6]), Value = row[7].ToString(), Content = row[8].ToString(), GroupHeaderFlag = Convert.ToInt32(row[13]) }; if (NewLine.ControlType != "7") { NewLine.OptionList = GetTypeList(_ServicesSoapClient, NewLine.OptionCategory, NewLine.Value); //通过yesornoh和value,结合字典表,生成有值的下拉框 } ItemInfo.Add(NewLine); } } } } return(ItemInfo); }
//个人信息(可编辑) public static List <List <PatientDetailInfo> > GetPatientDetailInfoEdit(ServicesSoapClient _ServicesSoapClient, string UserId, string DoctorId) { DataSet set = _ServicesSoapClient.GetPatBasicInfoDtlList(UserId); //获取关注的详细信息 List <List <PatientDetailInfo> > zong1 = new List <List <PatientDetailInfo> >(); foreach (DataTable ta in set.Tables) { List <PatientDetailInfo> items1 = new List <PatientDetailInfo>(); foreach (System.Data.DataRow row in ta.Rows) { if (row[3].ToString() != "InvalidFlag") { if (row[3].ToString() == "Doctor") { PatientDetailInfo one = new PatientDetailInfo { //PatientId = row[0].ToString(), //CategoryCode = row[1].ToString(), //主键 之后来自数据库(因为改变的只有value) CategoryName = row[2].ToString(), //界面 ItemCode = row[3].ToString(), //界面 //主键 ItemName = row[4].ToString(), //界面 ParentCode = row[5].ToString(), //界面 ControlType = row[11].ToString(), //界面 //控制是下拉框还是自由文本(放在value里,description?) OptionCategory = row[12].ToString(), //yesorno //OptionList = row[],? //下拉框(需选中) ItemSeq = Convert.ToInt32(row[6]), //主键 Value = row[7].ToString(), Content = _ServicesSoapClient.GetUserName(row[7].ToString()), //界面 Description = row[9].ToString() //int SortNo = Convert.ToInt32(row[10]); }; one.OptionList = GetTypeList(_ServicesSoapClient, one.OptionCategory, one.Value); //通过yesornoh和value,结合字典表,生成有值的下拉框 if (one.Value == DoctorId) { one.EditDeleteFlag = "true"; } else { one.EditDeleteFlag = "false"; } items1.Add(one); } else { PatientDetailInfo one = new PatientDetailInfo { //PatientId = row[0].ToString(), //CategoryCode = row[1].ToString(), //主键 之后来自数据库(因为改变的只有value) CategoryName = row[2].ToString(), //界面 ItemCode = row[3].ToString(), //界面 //主键 ItemName = row[4].ToString(), //界面 ParentCode = row[5].ToString(), //界面 ControlType = row[11].ToString(), //界面 //控制是下拉框还是自由文本(放在value里,description?) OptionCategory = row[12].ToString(), //yesorno //OptionList = row[],? //下拉框(需选中) ItemSeq = Convert.ToInt32(row[6]), //主键 Value = row[7].ToString(), Content = row[8].ToString(), //界面 Description = row[9].ToString() //int SortNo = Convert.ToInt32(row[10]); }; one.OptionList = GetTypeList(_ServicesSoapClient, one.OptionCategory, one.Value); //通过yesornoh和value,结合字典表,生成有值的下拉框 items1.Add(one); } } } zong1.Add(items1); } return(zong1); }
//个人信息(不可编辑) public static List <List <PatientDetailInfo> > GetPatientDetailInfo(ServicesSoapClient _ServicesSoapClient, string UserId) { DataSet set = _ServicesSoapClient.GetPatBasicInfoDtlList(UserId); //获取关注的详细信息 List <List <PatientDetailInfo> > zong1 = new List <List <PatientDetailInfo> >(); foreach (DataTable ta in set.Tables) { List <PatientDetailInfo> items1 = new List <PatientDetailInfo>(); foreach (System.Data.DataRow row in ta.Rows) { if (row[3].ToString() != "InvalidFlag") { PatientDetailInfo one = new PatientDetailInfo(); if (row[3].ToString() == "Doctor") { one = new PatientDetailInfo { //PatientId = row[0].ToString(), // CategoryCode = row[1].ToString(), CategoryName = row[2].ToString(), ItemCode = row[3].ToString(), ItemName = row[4].ToString(), ParentCode = row[5].ToString(), //ControlType = row[11].ToString(), // OptionCategory = row[12].ToString(), //OptionSelected = row[0].ToString(), //OptionList = row[0], //ItemSeq = Convert.ToInt32(row[6]), //Value = row[7].ToString(), Content = _ServicesSoapClient.GetUserName(row[7].ToString()) //Description = row[9].ToString() }; } else { one = new PatientDetailInfo { //PatientId = row[0].ToString(), // CategoryCode = row[1].ToString(), CategoryName = row[2].ToString(), ItemCode = row[3].ToString(), ItemName = row[4].ToString(), ParentCode = row[5].ToString(), //ControlType = row[11].ToString(), // OptionCategory = row[12].ToString(), //OptionSelected = row[0].ToString(), //OptionList = row[0], //ItemSeq = Convert.ToInt32(row[6]), //Value = row[7].ToString(), Content = row[8].ToString(), //Description = row[9].ToString() }; } items1.Add(one); } } zong1.Add(items1); } return(zong1); }
public PatientDetailInfo GetPatientDetailInfo(string UserId) { PatientDetailInfo ret = repository.GetPatientDetailInfo(pclsCache, UserId); return(ret); }
public PatientDetailInfo GetPatientDetailInfo(DataConnection pclsCache, string UserId) { try { string module = ""; PatientDetailInfo PatientDetailInfo = new PatientDetailInfo(); PatDetailInfo GetPatientDetailInfoList = moduleInfoMethod.PsBasicInfoDetailGetPatientDetailInfo(pclsCache, UserId); PatientDetailInfo.UserId = UserId; if (GetPatientDetailInfoList != null) { PatientDetailInfo.PhoneNumber = GetPatientDetailInfoList.PhoneNumber; if (PatientDetailInfo.PhoneNumber == null) { PatientDetailInfo.PhoneNumber = ""; } PatientDetailInfo.HomeAddress = GetPatientDetailInfoList.HomeAddress; if (PatientDetailInfo.HomeAddress == null) { PatientDetailInfo.HomeAddress = ""; } PatientDetailInfo.Occupation = GetPatientDetailInfoList.Occupation; if (PatientDetailInfo.Occupation == null) { PatientDetailInfo.Occupation = ""; } PatientDetailInfo.Nationality = GetPatientDetailInfoList.Nationality; if (PatientDetailInfo.Nationality == null) { PatientDetailInfo.Nationality = ""; } PatientDetailInfo.EmergencyContact = GetPatientDetailInfoList.EmergencyContact; if (PatientDetailInfo.EmergencyContact == null) { PatientDetailInfo.EmergencyContact = ""; } PatientDetailInfo.EmergencyContactPhoneNumber = GetPatientDetailInfoList.EmergencyContactPhoneNumber; if (PatientDetailInfo.EmergencyContactPhoneNumber == null) { PatientDetailInfo.EmergencyContactPhoneNumber = ""; } PatientDetailInfo.PhotoAddress = GetPatientDetailInfoList.PhotoAddress; if (PatientDetailInfo.PhotoAddress == null) { PatientDetailInfo.PhotoAddress = ""; } PatientDetailInfo.IDNo = GetPatientDetailInfoList.IDNo; if (PatientDetailInfo.IDNo == null) { PatientDetailInfo.IDNo = ""; } PatientDetailInfo.Height = GetPatientDetailInfoList.Height; if (PatientDetailInfo.Height == null) { PatientDetailInfo.Height = ""; } PatientDetailInfo.Weight = GetPatientDetailInfoList.Weight; if (PatientDetailInfo.Weight == null) { PatientDetailInfo.Weight = ""; } } List <TypeAndName> modules = moduleInfoMethod.PsBasicInfoDetailGetModulesByPID(pclsCache, UserId); for (int i = 0; i < modules.Count; i++) { module = module + "|" + modules[i].Name; } if (module != "") { module = module.Substring(1, module.Length - 1); } PatientDetailInfo.Module = module; return(PatientDetailInfo); } catch (Exception ex) { HygeiaComUtility.WriteClientLog(HygeiaEnum.LogType.ErrorLog, "Ps.BasicInfoDetail.GetPatientDetailInfo", "WebService调用异常! error information : " + ex.Message + Environment.NewLine + ex.StackTrace); return(null); throw (ex); } }