Beispiel #1
0
    protected void btnSearch_Click(object sender, EventArgs e)
    {
        if (string.IsNullOrEmpty(txtEmpId.Text.Trim()) == false)
        {
            objEmpinfo = objEmpInfoMgr.getEmployeeInfo(txtEmpId.Text.Trim());

            if (objEmpinfo.Count == 0)
            {
                lblMsg2.Text = "Employee Code is not valid.";
                txtEmpId.Focus();
                lblName.Text = "";
                grCTOLeaveHistory.DataSource = null;
                grCTOLeaveHistory.DataBind();
                return;
            }
            else
            {
                lblMsg2.Text = "";
                lblMsg.Text  = "";
                this.FillEmpInfo();
                this.OpenRecord();
                this.FormatLeaveStatusGridNumber();
            }
        }
    }
Beispiel #2
0
    public List <EmpInfoDTO> GetEmployee(string empname)
    {
        DEmployee objEmpInfoMgr = new DEmployee();
        var       emplist       = objEmpInfoMgr.getEmployeeInfo("").Where(ee => ee.EmpNameWithId.ToLower().Contains(empname)).ToList();

        return(emplist);
    }