protected void gridDanhSach_RowUpdating(object sender, DevExpress.Web.Data.ASPxDataUpdatingEventArgs e)
        {
            string ID       = e.Keys[0].ToString();
            string TenBan   = e.NewValues["TenBan"].ToString();
            string IDKhuVuc = e.NewValues["IDKhuVuc"].ToString();

            data = new dtBan();
            data.Sua(ID, TenBan, IDKhuVuc);
            e.Cancel = true;
            gridDanhSach.CancelEdit();
            LoadGrid();
        }
示例#2
0
        protected void gridDanhSach_RowUpdating(object sender, DevExpress.Web.Data.ASPxDataUpdatingEventArgs e)
        {
            string ID       = e.Keys[0].ToString();
            string TenBan   = e.NewValues["TenBan"].ToString();
            string IDKhuVuc = e.NewValues["IDKhuVuc"].ToString();

            if (dtSetting.IsNumber(TenBan) == true)
            {
                data = new dtBan();
                data.Sua(ID, TenBan, IDKhuVuc);
            }
            else
            {
                throw new Exception("Lỗi:Tên bàn phải là số?");
            }
            e.Cancel = true;
            gridDanhSach.CancelEdit();
            LoadGrid();
            dtLichSuTruyCap.ThemLichSu(Session["IDChiNhanh"].ToString(), Session["IDNhom"].ToString(), Session["IDNhanVien"].ToString(), "Quản lý bàn", "Cập nhật bàn: " + ID);
        }