public ActionResult <VHA_HandleGetListResModel> GetHandleInfo(SearchByContentIDModel idModel) { //查找到 最新的一条 结果记录 VHA_Sign sign = _VHelpAreaByVService.GetVHandleList(idModel.ContentID, "2"); VHA_HandleGetListResModel MyResModel = new VHA_HandleGetListResModel(); MyResModel.isSuccess = true; if (sign != null && sign.ID != null) { MyResModel.Signtime = DateTime.Parse(sign.CreateDate.ToString()); //获取 查看该互助信息对应的认领人 的具体信息 VHA_SignInfoMiddle infoMiddle = _VHelpAreaByVService.GetVDetail(sign.VID); MyResModel.middle = infoMiddle; MyResModel.List = _VHelpAreaByVService.GetMyHandleInfo(sign.VID, idModel.ContentID); MyResModel.TotalNum = MyResModel.List.Count(); } else { MyResModel.Signtime = DateTime.Now; } MyResModel.baseViewModel.Message = "请求正常"; MyResModel.baseViewModel.ResponseCode = 200; return(MyResModel); }
public ActionResult <VHA_SignInfoMiddle> GetVDetail(ContentIDandVIDModel vidModel) { VHA_SignInfoMiddle model = new VHA_SignInfoMiddle(); model = _VHelpAreaByVService.GetVDetail(vidModel.VID); //查找到 最新的一条 结果记录 VHA_Sign sign = _VHelpAreaByVService.GetVHandleList(vidModel.ContentID, "1"); if (sign != null && sign.ID != null) { model.Signtime = DateTime.Parse(sign.CreateDate.ToString()); } else { model.Signtime = DateTime.Now; } return(model); }
// 获取 查看该互助信息对应的认领人 的具体信息 public VHA_SignInfoMiddle GetVDetail(string VID) { VHA_SignInfoMiddle resModel = new VHA_SignInfoMiddle(); var user_Infos = _IVolunteerInfoRepository.SearchInfoByID(VID); resModel.VID = user_Infos.ID; resModel.Name = user_Infos.Name; resModel.VNO = user_Infos.VNO; resModel.Community = user_Infos.Community; resModel.Mobile = user_Infos.Mobile; resModel.RegisteTime = user_Infos.CreateDate.ToString(); //显示 服务领域 string Services = _ISQLRepository.GetVServices(VID); resModel.Services = Services.Substring(0, (Services.Length - 1)); //显示 擅长技能 string Skills = _ISQLRepository.GetVSkills(VID); resModel.Skills = Skills.Substring(0, (Skills.Length - 1)); //获取志愿者 擅长技能资质 List <VAttachment> VAttachmentList = _IVAttachmentRepository.GetMyList(VID); resModel.VAttachmentAddList = _IMapper.Map <List <VAttachment>, List <VAttachmentAddViewModel> >(VAttachmentList); resModel.SkillandFilelist = _ISQLRepository.GetSkillandFiles(VID); //参与活动时长 resModel.VA_SignHours = _ISQLRepository.GetVA_SignHours(VID); //参与活动时长 resModel.VA_SignTimes = _IVA_HandleRepository.GetMyInTimes(VID); //参与互助信息 resModel.MyVHASignList = _ISQLRepository.GetVHA_Signs(VID); return(resModel); }