コード例 #1
0
 //xóa theo id chung tu
 private void btnXoaPhieu_Click(object sender, EventArgs e)
 {
     if (MessageBox.Show("Bạn có chắc chắn xóa bản ghi này?", "Thông báo", MessageBoxButtons.YesNo) == DialogResult.Yes)
     {
         Delete();
         grcDanhSach.DataSource = DeNghiXuatTieuHaoProvider.GetListDeNghiXuatTieuHao();
     }
 }
コード例 #2
0
        private void btnThemPhieu_Click(object sender, EventArgs e)
        {
            frm_PhieuDeNghiXuatTieuHao frm = new frm_PhieuDeNghiXuatTieuHao();

            if (frm.ShowDialog() == DialogResult.OK)
            {
                grcDanhSach.DataSource = DeNghiXuatTieuHaoProvider.GetListDeNghiXuatTieuHao();
            }
        }
コード例 #3
0
 private void frm_DanhSachPhieuDeNghiXuatTH_Load(object sender, EventArgs e)
 {
     grcDanhSach.DataSource = DeNghiXuatTieuHaoProvider.GetListDeNghiXuatTieuHao();
     btnMoPhieu.Enabled     = false;
     btnXoaPhieu.Enabled    = IsSupperUser();
     btnMoPhieu.Text        = Resources.btnInfor;
     btnThemPhieu.Text      = Resources.btnAdd;
     btnXoaPhieu.Text       = Resources.btnDelete;
     btnDong.Text           = Resources.btnClose;
     LoadTrangThai();
 }
コード例 #4
0
        private void btnMoPhieu_Click(object sender, EventArgs e)
        {
            if (grvDanhSach.FocusedRowHandle < 0)
            {
                return;
            }
            ChungTuDeNghiXuatTieuHaoInfor info = ((ChungTuDeNghiXuatTieuHaoInfor)grvDanhSach.GetRow(grvDanhSach.FocusedRowHandle));
            frm_PhieuDeNghiXuatTieuHao    frm  = new frm_PhieuDeNghiXuatTieuHao(info.IdChungTu, info.SoChungTu, info.NgayLap.ToString(), "", info.TrangThai, info.GhiChu, info.HoTen, info.IdChiPhi, info.IdPhongBan);

            if (frm.ShowDialog() == DialogResult.OK)
            {
                grcDanhSach.DataSource = DeNghiXuatTieuHaoProvider.GetListDeNghiXuatTieuHao();
            }
        }