protected void btnApproved_Click(object sender, EventArgs e) { using (GridViewRow row = (GridViewRow)((LinkButton)sender).Parent.Parent) { string domesticID = (row.FindControl("lblDomesticID") as Label).Text.Trim(); string InsuredCode = row.Cells[1].Text.Trim(); var service = CommonMethods.GetLogedInService(); var request = new UpdateHIRStatusRequest(); request.HIRStatusCode = 9; request.InsuranceType = "DomesticInsurance"; request.ID = Convert.ToInt32(domesticID); var approvedresponse = service.PostData <BKIC.SellingPoint.DTO.RequestResponseWrappers.ApiResponseWrapper <BKIC.SellingPoint.DTO.RequestResponseWrappers.UpdateHIRStatusResponse>, BKIC.SellingPoint.DTO.RequestResponseWrappers.UpdateHIRStatusRequest> (BKIC.SellingPoint.DTO.Constants.InsurancePortalURI.UpdateHIRStatus, request); if (approvedresponse.Result.IsTransactionDone && approvedresponse.StatusCode == 200) { loadd(); } } }
protected void btnApproved_Click(object sender, EventArgs e) { try { master.IsSessionAvailable(); var userInfo = CommonMethods.GetUserDetails(); var service = CommonMethods.GetLogedInService(); using (GridViewRow row = (GridViewRow)((LinkButton)sender).Parent.Parent) { string travelID = (row.FindControl("lbltravelID") as Label).Text.Trim(); string InsuredCode = (row.FindControl("lblInsuredCode") as Label).Text.Trim(); string documentId = HttpUtility.HtmlDecode(row.Cells[2].Text.Trim()); var request = new UpdateHIRStatusRequest { HIRStatusCode = 8, InsuranceType = Constants.Travel, ID = Convert.ToInt32(travelID), InsuredCode = InsuredCode, DocumentNo = documentId }; request.InsuredCode = InsuredCode; request.LinkId = (row.FindControl("lblLinkID") as Label).Text.Trim(); var approvedresponse = service.PostData <BKIC.SellingPoint.DTO.RequestResponseWrappers.ApiResponseWrapper <BKIC.SellingPoint.DTO.RequestResponseWrappers.UpdateHIRStatusResponse>, BKIC.SellingPoint.DTO.RequestResponseWrappers.UpdateHIRStatusRequest> (BKIC.SellingPoint.DTO.Constants.InsurancePortalURI.UpdateHIRStatus, request); if (approvedresponse.Result.IsTransactionDone && approvedresponse.StatusCode == 200) { Response.Redirect(Request.RawUrl); } } } catch (Exception ex) { //throw ex; } finally { master.ShowLoading = false; } }
protected void btnApproved_Click(object sender, EventArgs e) { try { using (GridViewRow row = (GridViewRow)((LinkButton)sender).Parent.Parent) { string domesticID = (row.FindControl("lblDomesticID") as Label).Text.Trim(); string InsuredCode = (row.FindControl("lblInsuredCode") as Label).Text.Trim(); string documentId = row.Cells[2].Text.Trim(); string linkID = (row.FindControl("lblLinkID") as Label).Text.Trim(); var service = CommonMethods.GetLogedInService(); var request = new UpdateHIRStatusRequest { HIRStatusCode = Constants.ApproveHIRStatus, InsuranceType = Constants.DomesticHelp, ID = Convert.ToInt32(domesticID), DocumentNo = documentId, InsuredCode = InsuredCode, LinkId = linkID }; var approvedresponse = service.PostData <BKIC.SellingPoint.DTO.RequestResponseWrappers.ApiResponseWrapper <BKIC.SellingPoint.DTO.RequestResponseWrappers.UpdateHIRStatusResponse>, BKIC.SellingPoint.DTO.RequestResponseWrappers.UpdateHIRStatusRequest> (BKIC.SellingPoint.DTO.Constants.InsurancePortalURI.UpdateHIRStatus, request); if (approvedresponse.Result.IsTransactionDone && approvedresponse.StatusCode == 200) { Response.Redirect(Request.RawUrl); } } } catch (Exception ex) { ////throw ex; } finally { master.ShowLoading = false; } }