Ejemplo n.º 1
0
 private void btnLuu_Click(object sender, EventArgs e)
 {
     if (_isAddNew)
     {
         if (_DonViTinhDAO.Insert(txtMa.Text, txtTen.Text, txtGhiChu.Text, ckbConQuanLy.Checked))
         {
             MessageBox.Show(this, "Đã Thêm mới một Đơn Vị Tính", "thành công");
         }
         else
         {
             MessageBox.Show(this, "Có Lỗi xảy ra", "Lỗi");
         }
     }
     else
     {
         if (_DonViTinhDAO.Update(txtMa.Text, txtTen.Text, txtGhiChu.Text, ckbConQuanLy.Checked))
         {
             MessageBox.Show(this, "Đã Chỉnh Sửa thông tin một Đơn Vị Tính", "thành công");
         }
         else
         {
             MessageBox.Show(this, "Có Lỗi xảy ra", "Lỗi");
         }
     }
 }
Ejemplo n.º 2
0
 public int Update(DonViTinh obj)
 {
     return(dao.Update(obj));
 }
Ejemplo n.º 3
0
 public Int64 Update(DonViTinhDTO _nv)
 {
     return(nvDAO.Update(_nv));
 }
Ejemplo n.º 4
0
 /// <summary>
 /// Cập nhật đơn vị tính
 /// </summary>
 public static void Update(EDonViTinh eDonViTinh)
 {
     DonViTinhDAO.Update(eDonViTinh);
 }