public List <PrePNDTCounselling> GetScheduledForCounselling(PNDTSchedulingRequest psData) { _pndtData.AutomaticPrePNDTCousellingUpdate(); var counsellingData = _pndtData.GetScheduledForCounselling(psData); return(counsellingData); }
public List <PostPNDTScheduled> GetSubjectsPostPNDTScheduled(PNDTSchedulingRequest psData) { string stProc = FetchSubjectsPostPNDTScheduled; var pList = new List <SqlParameter>() { new SqlParameter("@UserId", psData.userId), new SqlParameter("@DistrictId", psData.districtId), new SqlParameter("@CHCId", psData.chcId), new SqlParameter("@PHCId", psData.phcId), new SqlParameter("@ANMId", psData.anmId) }; var scheduledData = UtilityDL.FillData <PostPNDTScheduled>(stProc, pList); return(scheduledData); }
public List <PrePNDTCounselled> GetSubjectsCounselledYes(PNDTSchedulingRequest pcData) { string stProc = FetchSubjectsPrePNDTCounseledYes; var pList = new List <SqlParameter>() { new SqlParameter("@UserId", pcData.userId), new SqlParameter("@DistrictId", pcData.districtId), new SqlParameter("@CHCId", pcData.chcId), new SqlParameter("@PHCId", pcData.phcId), new SqlParameter("@ANMId", pcData.anmId) }; var counseledYesData = UtilityDL.FillData <PrePNDTCounselled>(stProc, pList); return(counseledYesData); }
public async Task <IActionResult> GetScheduledForPostPNDTCounselledPending(PNDTSchedulingRequest pcData) { _logger.LogInformation($"Invoking endpoint: {this.HttpContext.Request.GetDisplayUrl()}"); var postPNDTCounselled = await _pndtService.GetSubjectsPostPNDTCounselledPending(pcData); _logger.LogInformation($"Retrieve subjects for the counselled MTP agree pending {postPNDTCounselled}"); _logger.LogDebug($"Retrieve subjects for the counselled MTP agree pending - {JsonConvert.SerializeObject(postPNDTCounselled)}"); return(Ok(new PostPNDTCounselledResponse { Status = postPNDTCounselled.Status, Message = postPNDTCounselled.Message, data = postPNDTCounselled.data, })); }
public PostPNDTCounselledDetail GetSubjectsPostPNDTCounselledPending(PNDTSchedulingRequest pcData) { string stProc = FetchSubjectsPostPNDTCounselledPending; var pList = new List <SqlParameter>() { new SqlParameter("@UserId", pcData.userId), new SqlParameter("@DistrictId", pcData.districtId), new SqlParameter("@CHCId", pcData.chcId), new SqlParameter("@PHCId", pcData.phcId), new SqlParameter("@ANMId", pcData.anmId) }; var allANWDetail = UtilityDL.FillData <PostPNDTCounselled>(stProc, pList); var allFoetusDetail = UtilityDL.FillData <PNDTFoetusDetail>(stProc, pList); var counseledPendingData = new PostPNDTCounselledDetail(); counseledPendingData.anwDetail = allANWDetail; counseledPendingData.foetusDetail = allFoetusDetail; return(counseledPendingData); }
public PrePNDTScheduledResponse GetSubjectsScheduled(PNDTSchedulingRequest psData) { try { _logger.LogInformation($"Invoking endpoint: {this.HttpContext.Request.GetDisplayUrl()}"); _logger.LogDebug($"Retrieve positive couple subjects for scheduled the counselling - {JsonConvert.SerializeObject(psData)}"); var prePNDTScheduling = _pndtService.GetSubjectsScheduled(psData); return(prePNDTScheduling.Count == 0 ? new PrePNDTScheduledResponse { Status = "true", Message = "No subjects found", data = new List <PrePNDTScheduled>() } : new PrePNDTScheduledResponse { Status = "true", Message = string.Empty, data = prePNDTScheduling }); } catch (Exception e) { return(new PrePNDTScheduledResponse { Status = "false", Message = e.Message, data = null }); } }
public List <PrePNDTScheduled> GetSubjectsScheduled(PNDTSchedulingRequest psData) { var scheduledData = _pndtData.GetSubjectsScheduled(psData); return(scheduledData); }
public async Task <PostPNDTCounselledResponse> GetSubjectsPostPNDTCounselledYes(PNDTSchedulingRequest pcData) { var counselledData = _pndtData.GetSubjectsPostPNDTCounselledYes(pcData); var postPNDTCounselledResponse = new PostPNDTCounselledResponse(); var postPNDTCounselledANWDetail = new List <PostPNDTCounselledANWDetail>(); try { int pndTestId = 0; foreach (var cd in counselledData.anwDetail) { if (pndTestId != cd.pndTestId) { var anwDetail = new PostPNDTCounselledANWDetail(); var foetusDetail = counselledData.foetusDetail.Where(sd => sd.pndTestId == cd.pndTestId).ToList(); anwDetail.anwSubjectId = cd.anwSubjectId; anwDetail.subjectName = cd.subjectName; anwDetail.spouseSubjectId = cd.spouseSubjectId; anwDetail.spouseName = cd.spouseName; anwDetail.rchId = cd.rchId; anwDetail.contactNo = cd.contactNo; anwDetail.age = cd.age; anwDetail.spouseAge = cd.spouseAge; anwDetail.ecNumber = cd.ecNumber; anwDetail.ga = cd.ga; anwDetail.obstetricScore = cd.obstetricScore; anwDetail.lmpDate = cd.lmpDate; anwDetail.anwCBCTestResult = cd.anwCBCTestResult; anwDetail.anwSSTestResult = cd.anwSSTestResult; anwDetail.anwHPLCTestResult = cd.anwHPLCTestResult; anwDetail.spouseCBCTestResult = cd.spouseCBCTestResult; anwDetail.spouseSSTestResult = cd.spouseSSTestResult; anwDetail.spouseHPLCTestResult = cd.spouseHPLCTestResult; anwDetail.prePNDTCounsellingDateTime = cd.prePNDTCounsellingDateTime; anwDetail.prePNDTCounsellorName = cd.prePNDTCounsellorName; anwDetail.prePNDTCounsellingRemarks = cd.prePNDTCounsellingRemarks; anwDetail.prePNDTCounsellingStatus = cd.prePNDTCounsellingStatus; anwDetail.schedulePrePNDTDate = cd.schedulePrePNDTDate; anwDetail.schedulePrePNDTTime = cd.schedulePrePNDTTime; anwDetail.pndTestId = cd.pndTestId; anwDetail.pndtDateTime = cd.pndtDateTime; anwDetail.pndtObstetrician = cd.pndtObstetrician; anwDetail.pndtCounsellorName = cd.pndtCounsellorName; anwDetail.postPNDTCounsellorId = cd.postPNDTCounsellorId; anwDetail.postPNDTCounsellorName = cd.postPNDTCounsellorName; anwDetail.postPNDTSchedulingId = cd.postPNDTSchedulingId; anwDetail.postPNDTCounsellingId = cd.postPNDTCounsellingId; anwDetail.postPNDTObstetricianId = cd.postPNDTObstetricianId; anwDetail.postPNDTCounsellingDateTime = cd.postPNDTCounsellingDateTime; anwDetail.mtpScheduleDate = cd.mtpScheduleDate; anwDetail.mtpScheduleTime = cd.mtpScheduleTime; anwDetail.postPNDTCounsellingRemarks = cd.postPNDTCounsellingRemarks; anwDetail.fileName = cd.fileName; anwDetail.fileLocation = cd.fileLocation; anwDetail.isMTPAgreeYes = cd.isMTPAgreeYes; anwDetail.isMTPAgreeNo = cd.isMTPAgreeNo; anwDetail.isMTPAgreePending = cd.isMTPAgreePending; anwDetail.anwMCV = cd.anwMCV; anwDetail.anwMCV = cd.anwMCV; anwDetail.anwRDW = cd.anwRDW; anwDetail.anwRBC = cd.anwRBC; anwDetail.anwHbA0 = cd.anwHbA0; anwDetail.anwHbA2 = cd.anwHbA2; anwDetail.anwHbF = cd.anwHbF; anwDetail.anwHbS = cd.anwHbS; anwDetail.anwHbD = cd.anwHbD; anwDetail.spouseMCV = cd.spouseMCV; anwDetail.spouseRDW = cd.spouseRDW; anwDetail.spouseRBC = cd.spouseRBC; anwDetail.spouseHbA0 = cd.spouseHbA0; anwDetail.spouseHbA2 = cd.spouseHbA2; anwDetail.spouseHbF = cd.spouseHbF; anwDetail.spouseHbS = cd.spouseHbS; anwDetail.spouseHbD = cd.spouseHbD; anwDetail.foetusDetail = foetusDetail; pndTestId = cd.pndTestId; postPNDTCounselledANWDetail.Add(anwDetail); } } postPNDTCounselledResponse.data = postPNDTCounselledANWDetail; postPNDTCounselledResponse.Status = "true"; postPNDTCounselledResponse.Message = string.Empty; return(postPNDTCounselledResponse); } catch (Exception e) { postPNDTCounselledResponse.Status = "false"; postPNDTCounselledResponse.Message = e.Message; return(postPNDTCounselledResponse); } }
public List <PrePNDTCounselled> GetSubjectsCounselledYes(PNDTSchedulingRequest pcData) { var counseledYesData = _pndtData.GetSubjectsCounselledYes(pcData); return(counseledYesData); }
public List <PostPNDTScheduling> GetPostPNDTScheduling(PNDTSchedulingRequest psData) { var schedulingData = _pndtData.GetPostPNDTScheduling(psData); return(schedulingData); }
public List <PrePNDTScheduling> GetPositiveSubjectsScheduling(PNDTSchedulingRequest psData) { var schedulingData = _pndtData.GetPositiveSubjectsScheduling(psData); return(schedulingData); }