protected void ApplicantLoad(int jobReq_Id) { try { // ddlJobReqCode.SelectedItem.Value = Convert.ToString (jobReq_Id); // Session["REFRESH_JOBREQ_ID"] = null; DataTable dt_Details = new DataTable(); _obj_Rec_JobRequisition = new RECRUITMENT_JOBREQUISITION(); _obj_Rec_JobRequisition.JOBREQ_ID = jobReq_Id; _obj_Rec_JobRequisition.OPERATION = operation.Empty; // Session["REFRESH_JOBREQ_ID"] = Convert.ToInt32(ddlJobReqCode.SelectedItem.Value); // string STR_TEST3 = Convert.ToString(Session["REFRESH_JOBREQ_ID"]); dt_Details = Recruitment_BLL.get_JobReqDetails(_obj_Rec_JobRequisition); if (dt_Details.Rows.Count != 0) { LoadJobRequisition(); GApplicants.Enabled = true; //lbl_JR.Text = Convert.ToString(dt_Details.Rows[0]["JOBREQ_ID"]); //txtDesc.Text = Convert.ToString(dt_Details.Rows[0]["JOBREQ_REQCODE"]); txtDOC.Text = Convert.ToString(dt_Details.Rows[0]["JOBREQ_REQDATE"]); txtDOE.Text = Convert.ToString(dt_Details.Rows[0]["JOBREQ_REQEXPIRY"]); txtBU.Text = Convert.ToString(dt_Details.Rows[0]["BUSINESSUNIT_CODE"]); txtRaisedBy.Text = Convert.ToString(dt_Details.Rows[0]["Empname"]); txtDesignation.Text = Convert.ToString(dt_Details.Rows[0]["JOBREQ_DESIGNATION"]); txtPositions.Text = Convert.ToString(dt_Details.Rows[0]["JOBREQ_POSITIONS"]) + "Members"; txtExp.Text = Convert.ToString(dt_Details.Rows[0]["JOBREQ_EXPYEARS"]); LoadList(Convert.ToString(dt_Details.Rows[0]["JOBREQ_REQCODE"]), Convert.ToString(dt_Details.Rows[0]["JOBREQ_ISYEARSREQ"]), Convert.ToString(dt_Details.Rows[0]["JOBREQ_ISQUALREQ"]), Convert.ToString(dt_Details.Rows[0]["JOBREQ_ISSKILLREQ"])); GApplicants.DataBind(); RMP_Applinat.Visible = true; RTS_ResumeShortList.Visible = true; //var tabNewYork1 = RTS_ResumeShortList.FindTabByText("Applicant"); //tabNewYork1.Enabled = false ; RMP_Applinat.SelectedIndex = 0; GApplicants.Visible = true; // btnShortList.Enabled = true; } else { LoadList(Convert.ToString(dt_Details.Rows[0]["JOBREQ_REQCODE"]), Convert.ToString(dt_Details.Rows[0]["JOBREQ_ISYEARSREQ"]), Convert.ToString(dt_Details.Rows[0]["JOBREQ_ISQUALREQ"]), Convert.ToString(dt_Details.Rows[0]["JOBREQ_ISSKILLREQ"])); GApplicants.DataBind(); RMP_Applinat.SelectedIndex = 0; GApplicants.Visible = true; GApplicants.Enabled = true; } } catch (Exception ex) { SMHR.BLL.Error_Log(Session["USER_ID"].ToString(), ex.TargetSite.ToString(), ex.Message.Replace("'", "''"), "frm_ResumeShortList", ex.StackTrace, DateTime.Now); Response.Redirect("~/Frm_ErrorPage.aspx"); return; } }
protected void btnShortList_Click(object sender, EventArgs e) { try { int index1; bool res1; int i = 0; CheckBox chk_Box = new CheckBox(); for (index1 = 0; index1 <= GApplicants.Items.Count - 1; index1++) { chk_Box = GApplicants.Items[index1].FindControl("chkChoose") as CheckBox; if (chk_Box.Checked) { chk_Box.Enabled = false; } else { i = i + 1; } } if (i == GApplicants.Items.Count) { BLL.ShowMessage(this, "Please Select atleast one Applicant for shortlisting"); return; } res1 = chkExisting(); if (res1 == true) { BLL.ShowMessage(this, "Applicant(s) have already been shortlisted"); return; } int index; CheckBox chkBox = new CheckBox(); Label lblApp = new Label(); Label lblJR = new Label(); bool res2 = false; for (index = 0; index <= GApplicants.Items.Count - 1; index++) { chkBox = GApplicants.Items[index].FindControl("chkChoose") as CheckBox; lblApp = GApplicants.Items[index].FindControl("lblAppID") as Label; lblJR = GApplicants.Items[index].FindControl("JOBREQ_ID") as Label; if (chkBox.Checked) { _obj_Rec_ResumeShortList = new RECRUITMENT_RESUMESHORTLIST(); _obj_Rec_ResumeShortList.RESSHT_JOBREQID = Convert.ToInt32(ddlJobReqCode.SelectedItem.Value); _obj_Rec_ResumeShortList.RESSHT_APPLID = Convert.ToInt32(lblApp.Text); _obj_Rec_ResumeShortList.RESSHT_ISSHORTLIST = true; _obj_Rec_ResumeShortList.ORGANISATION_ID = Convert.ToInt32(Session["ORG_ID"].ToString()); _obj_Rec_ResumeShortList.CREATEDBY = 0; _obj_Rec_ResumeShortList.CREATEDDATE = DateTime.Now; _obj_Rec_ResumeShortList.LASTMDFBY = 1; _obj_Rec_ResumeShortList.LASTMDFDATE = DateTime.Now; _obj_Rec_ResumeShortList.OPERATION = operation.Insert; res2 = Recruitment_BLL.set_ResumeShortList(_obj_Rec_ResumeShortList); } } if (res2 == true) { BLL.ShowMessage(this, "Selected Applicants are Short Listed"); try { Session["REFRESH_JOBREQ_ID"] = null; DataTable dt_Details = new DataTable(); _obj_Rec_JobRequisition = new RECRUITMENT_JOBREQUISITION(); _obj_Rec_JobRequisition.OPERATION = operation.Empty; string STR_TEST3 = Convert.ToString(Session["REFRESH_JOBREQ_ID"]); _obj_Rec_JobRequisition.JOBREQ_ID = Convert.ToInt32(ddlJobReqCode.SelectedItem.Value); dt_Details = Recruitment_BLL.get_JobReqDetails(_obj_Rec_JobRequisition); if (dt_Details.Rows.Count != 0) { GApplicants.Enabled = true; //lbl_JR.Text = Convert.ToString(dt_Details.Rows[0]["JOBREQ_ID"]); //txtDesc.Text = Convert.ToString(dt_Details.Rows[0]["JOBREQ_REQCODE"]); txtDOC.Text = Convert.ToString(dt_Details.Rows[0]["JOBREQ_REQDATE"]); txtDOE.Text = Convert.ToString(dt_Details.Rows[0]["JOBREQ_REQEXPIRY"]); txtBU.Text = Convert.ToString(dt_Details.Rows[0]["BUSINESSUNIT_CODE"]); txtRaisedBy.Text = Convert.ToString(dt_Details.Rows[0]["Empname"]); txtDesignation.Text = Convert.ToString(dt_Details.Rows[0]["JOBREQ_DESIGNATION"]); txtPositions.Text = Convert.ToString(dt_Details.Rows[0]["JOBREQ_POSITIONS"]) + "Members"; txtExp.Text = Convert.ToString(dt_Details.Rows[0]["JOBREQ_EXPYEARS"]); LoadList(Convert.ToString(dt_Details.Rows[0]["JOBREQ_REQCODE"]), Convert.ToString(dt_Details.Rows[0]["JOBREQ_ISYEARSREQ"]), Convert.ToString(dt_Details.Rows[0]["JOBREQ_ISQUALREQ"]), Convert.ToString(dt_Details.Rows[0]["JOBREQ_ISSKILLREQ"])); GApplicants.DataBind(); RMP_Applinat.Visible = true; RTS_ResumeShortList.Visible = true; //var tabNewYork1 = RTS_ResumeShortList.FindTabByText("Applicant"); //tabNewYork1.Enabled = false ; RMP_Applinat.SelectedIndex = 0; GApplicants.Visible = true; btnShortList.Visible = true; } else { LoadList(Convert.ToString(dt_Details.Rows[0]["JOBREQ_REQCODE"]), Convert.ToString(dt_Details.Rows[0]["JOBREQ_ISYEARSREQ"]), Convert.ToString(dt_Details.Rows[0]["JOBREQ_ISQUALREQ"]), Convert.ToString(dt_Details.Rows[0]["JOBREQ_ISSKILLREQ"])); GApplicants.DataBind(); RMP_Applinat.SelectedIndex = 0; GApplicants.Visible = true; GApplicants.Enabled = true; } DataTable dt_ShortListed = new DataTable(); _obj_Rec_ResumeShortList = new RECRUITMENT_RESUMESHORTLIST(); _obj_Rec_ResumeShortList.Mode = 10; _obj_Rec_ResumeShortList.RESSHT_JOBREQID = Convert.ToInt32(ddlJobReqCode.SelectedItem.Value); dt_ShortListed = Recruitment_BLL.getApplicants(_obj_Rec_ResumeShortList); rg_ShortListed.DataSource = dt_ShortListed; rg_ShortListed.DataBind(); rg_ShortListed.Visible = true; RTS_ResumeShortList.Visible = true; // btnShortList.Enabled = false; } catch (Exception ex) { SMHR.BLL.Error_Log(Session["USER_ID"].ToString(), ex.TargetSite.ToString(), ex.Message.Replace("'", "''"), "frm_ResumeShortList", ex.StackTrace, DateTime.Now); Response.Redirect("~/Frm_ErrorPage.aspx"); return; } return; } else { BLL.ShowMessage(this, "An Error Occured While doing the process"); return; } } catch (Exception ex) { SMHR.BLL.Error_Log(Session["USER_ID"].ToString(), ex.TargetSite.ToString(), ex.Message.Replace("'", "''"), "frm_ResumeShortList", ex.StackTrace, DateTime.Now); Response.Redirect("~/Frm_ErrorPage.aspx"); return; } }
protected void ddlJobReqCode_SelectedIndexChanged(object o, Telerik.Web.UI.RadComboBoxSelectedIndexChangedEventArgs e) { try { if (ddlJobReqCode.SelectedValue != "-1") { RTS_ResumeShortList.SelectedIndex = 0; //RTS_ResumeShortList.SelectedTab.Text = "Applicant"; Session["REFRESH_JOBREQ_ID"] = null; DataTable dt_Details = new DataTable(); _obj_Rec_JobRequisition = new RECRUITMENT_JOBREQUISITION(); _obj_Rec_JobRequisition.OPERATION = operation.Empty; string STR_TEST3 = Convert.ToString(Session["REFRESH_JOBREQ_ID"]); _obj_Rec_JobRequisition.JOBREQ_ID = Convert.ToInt32(ddlJobReqCode.SelectedItem.Value); dt_Details = Recruitment_BLL.get_JobReqDetails(_obj_Rec_JobRequisition); if (dt_Details.Rows.Count != 0) { GApplicants.Enabled = true; //lbl_JR.Text = Convert.ToString(dt_Details.Rows[0]["JOBREQ_ID"]); //txtDesc.Text = Convert.ToString(dt_Details.Rows[0]["JOBREQ_REQCODE"]); txtDOC.Text = Convert.ToString(dt_Details.Rows[0]["JOBREQ_REQDATE"]); txtDOE.Text = Convert.ToString(dt_Details.Rows[0]["JOBREQ_REQEXPIRY"]); txtBU.Text = Convert.ToString(dt_Details.Rows[0]["BUSINESSUNIT_CODE"]); txtRaisedBy.Text = Convert.ToString(dt_Details.Rows[0]["Empname"]); txtDesignation.Text = Convert.ToString(dt_Details.Rows[0]["JOBREQ_DESIGNATION"]); txtPositions.Text = Convert.ToString(dt_Details.Rows[0]["JOBREQ_POSITIONS"]) + "Members"; txtExp.Text = Convert.ToString(dt_Details.Rows[0]["JOBREQ_EXPYEARS"]); LoadList(Convert.ToString(dt_Details.Rows[0]["JOBREQ_REQCODE"]), Convert.ToString(dt_Details.Rows[0]["JOBREQ_ISYEARSREQ"]), Convert.ToString(dt_Details.Rows[0]["JOBREQ_ISQUALREQ"]), Convert.ToString(dt_Details.Rows[0]["JOBREQ_ISSKILLREQ"])); GApplicants.DataBind(); RMP_Applinat.Visible = true; RTS_ResumeShortList.Visible = true; //var tabNewYork1 = RTS_ResumeShortList.FindTabByText("Applicant"); //tabNewYork1.Enabled = false ; RMP_Applinat.SelectedIndex = 0; GApplicants.Visible = true; btnShortList.Visible = true; } else { LoadList(Convert.ToString(dt_Details.Rows[0]["JOBREQ_REQCODE"]), Convert.ToString(dt_Details.Rows[0]["JOBREQ_ISYEARSREQ"]), Convert.ToString(dt_Details.Rows[0]["JOBREQ_ISQUALREQ"]), Convert.ToString(dt_Details.Rows[0]["JOBREQ_ISSKILLREQ"])); DataTable dt = new DataTable(); GApplicants.DataSource = dt; GApplicants.DataBind(); RMP_Applinat.SelectedIndex = 0; GApplicants.Visible = true; GApplicants.Enabled = true; clearfields(); } DataTable dt_ShortListed = new DataTable(); _obj_Rec_ResumeShortList = new RECRUITMENT_RESUMESHORTLIST(); _obj_Rec_ResumeShortList.Mode = 10; _obj_Rec_ResumeShortList.RESSHT_JOBREQID = Convert.ToInt32(ddlJobReqCode.SelectedItem.Value); _obj_Rec_ResumeShortList.ORGANISATION_ID = Convert.ToInt32(Session["ORG_ID"].ToString()); dt_ShortListed = Recruitment_BLL.getApplicants(_obj_Rec_ResumeShortList); rg_ShortListed.DataSource = dt_ShortListed; rg_ShortListed.DataBind(); rg_ShortListed.Visible = true; RTS_ResumeShortList.Visible = true; // btnShortList.Enabled = false; } else { RMP_Applinat.Visible = false; RTS_ResumeShortList.Visible = false; //txtDesc.Text = ""; txtDOC.Text = ""; txtDOE.Text = ""; txtRaisedBy.Text = ""; txtBU.Text = ""; txtDesignation.Text = ""; txtPositions.Text = ""; txtExp.Text = ""; btnShortList.Visible = false; } } catch (Exception ex) { SMHR.BLL.Error_Log(Session["USER_ID"].ToString(), ex.TargetSite.ToString(), ex.Message.Replace("'", "''"), "frm_ResumeShortList", ex.StackTrace, DateTime.Now); Response.Redirect("~/Frm_ErrorPage.aspx"); return; } }