private void btnThemPhieu_Click(object sender, EventArgs e) { frm_PhieuDeNghiNhanDieuChuyen frm = new frm_PhieuDeNghiNhanDieuChuyen(); foreach (DMKhoCBOLoadInfo nguoiDungInfor in ((NguoiDungInfor)Declare.USER_INFOR).KhoNguoiDung) { IdKho += nguoiDungInfor.IdKho + ","; } if (frm.ShowDialog() == DialogResult.OK) { grcDanhSach.DataSource = NhanDieuChuyenDataProvider.GetListNhanDieuChuyen(IdKho); } }
private void btnMoPhieu_Click(object sender, EventArgs e) { if (grvDanhSach.FocusedRowHandle < 0) { return; } ChungTuDeNghiNhanDieuChuyenInfor info = ((ChungTuDeNghiNhanDieuChuyenInfor)grvDanhSach.GetRow(grvDanhSach.FocusedRowHandle)); frm_PhieuDeNghiNhanDieuChuyen frm = new frm_PhieuDeNghiNhanDieuChuyen(info.IdChungTu, info.SoChungTu, info.NgayLap.ToString(), "", info.TrangThai, info.SoChungTuGoc); foreach (DMKhoCBOLoadInfo nguoiDungInfor in ((NguoiDungInfor)Declare.USER_INFOR).KhoNguoiDung) { IdKho += nguoiDungInfor.IdKho + ","; } if (frm.ShowDialog() == DialogResult.OK) { grcDanhSach.DataSource = NhanDieuChuyenDataProvider.GetListNhanDieuChuyen(IdKho); } }