Ejemplo n.º 1
0
        private void btnAdd_Click(object sender, EventArgs e)
        {
            AddNewEmployee addNewEmployee = new AddNewEmployee();

            addNewEmployee.ShowDialog(this);
            LoadTable(_employeesController.GetAllUsers());
        }
Ejemplo n.º 2
0
 public Employees()
 {
     InitializeComponent();
     txtSearchEMP.Text    = "*";
     _employeesController = new EmployeesController();
     LoadTable(_employeesController.GetAllUsers());
 }
Ejemplo n.º 3
0
        private void SearchEMPs()
        {
            if (txtSearchEMP.Text.Length > 0)
            {
                _employeesController = new EmployeesController();

                if (txtSearchEMP.Text == "*")
                {
                    LoadTable(_employeesController.GetAllUsers());
                }
                else
                {
                    LoadTable(_employeesController.SearchEmployeeByName(txtSearchEMP.Text));
                }
            }
        }