Esempio n. 1
0
        public void LoadDanhSachGiangVien()
        {
            gcDanhSach.DataSource = null;
            gcDanhSach.Controls.Clear();
            var dao = new GiangVienDAO();
            var lst = new List <GiangVien>();
            var ids = string.Join(",", cbbDanhSachKhoa.Properties.Items.GetCheckedValues());
            var ser = txtSearch.Text;

            if (string.IsNullOrEmpty(ids))
            {
                lst = dao.GetAll(ser);
            }
            else
            {
                lst = dao.GetAllByMaKhoa(ids, ser);
            }

            gcDanhSach.DataSource = lst;
        }