Example #1
0
 private void usrThietBi_Load(object sender, EventArgs e)
 {
     backgroundWorker.RunWorkerAsync();
     BUS.BUSPHONG _Phong = new BUS.BUSPHONG();
     BUS.BUSKIEUPHONG _KieuPhong = new BUS.BUSKIEUPHONG();
     BUS.BUSLOAIPHONG _LoaiPhong = new BUS.BUSLOAIPHONG();
     KieuPhong = _KieuPhong.LayTatCaKIEUPHONG();
     LoaiPhong = _LoaiPhong.LayTatCaLOAIPHONG();
     Phong = _Phong.LayTatCaPHONG();
     LoadThongTinBangGia();
     btnCapNhat.Visible = Function.Gia.CapNhat;
 }
Example #2
0
        private void frmHienThiThueDatPhong_Load(object sender, EventArgs e)
        {
            try
            {
                dtpNgayBD.Value = dateNgayBD;
                dtpNgayKT.Value = dateNgayKT;
            }
            catch
            {
                dateNgayKT = dtpNgayKT.MaxDate;
                dateNgayBD = dtpNgayBD.MinDate;
            }
            foreach (int i in lsthtLoaiPhieu)
            {
                switch (i)
                {
                    case 2:
                        {
                            cbxDaThanhToan.CheckState = CheckState.Checked;
                        };break;
                    case 1:
                        {
                            cbxĐatPhong.CheckState = CheckState.Checked;
                        };break;
                    case 0:
                        {
                            cbxThuePhong.CheckState = CheckState.Checked;
                        };break;
                }
            }

            BUS.BUSPHONG _busPhong = new BUS.BUSPHONG();
            foreach (DTO.DTOPHONG _p in _busPhong.LayTatCaPHONG())
            {
                ListViewItem _it=lswPhong.Items.Add(new ListViewItem(_p.MAPHONG.ToString()));
                if (lsthtPhong.IndexOf(_p.MAPHONG) >= 0) _it.Checked = true;
            }
        }
 protected override void OnFirstLoad()
 {
     backgroundWorker.RunWorkerAsync();
     txtNhanVien.Text = clsXuLy.MANV.ToString();
     BUS.BUSPHONG _busPhong = new BUS.BUSPHONG();
     BUS.BUSNHANVIEN _busNhanVien = new BUS.BUSNHANVIEN();
     BUS.BUSKHACHHANG _busKhachHang = new BUS.BUSKHACHHANG();
     BUS.BUSKIEUPHONG _busKieuPhong = new BUS.BUSKIEUPHONG();
     BUS.BUSLOAIPHONG _busLoaiPhong = new BUS.BUSLOAIPHONG();
     BUS.BUSBANGGIA _busBangGia = new BUS.BUSBANGGIA();
     BUS.BUSTINHTRANG _busTinhTrang = new BUS.BUSTINHTRANG();
     lstTinhTrang = _busTinhTrang.LayTatCaTINHTRANG();
     lstBangGia = _busBangGia.LayTatCaBANGGIA();
     lstLoaiPhong = _busLoaiPhong.LayTatCaLOAIPHONG();
     lstKieuPhong = _busKieuPhong.LayTatCaKIEUPHONG();
     lstPhong = _busPhong.LayTatCaPHONG();
     lstNhanVien = _busNhanVien.LayTatCaNHANVIEN();
     lstKhachHang = _busKhachHang.LayTatCaKHACHHANG();
     glkKhachHang.Properties.DataSource = lstKhachHang;
     glkKhachHang.Properties.DisplayMember = "HOTEN";
     glkKhachHang.Properties.ValueMember = "MAKH";
     txtNhanVien.Text = clsXuLy.MANV.ToString();
     ccbeMaPhong.Properties.DataSource = lstPhong;
     ccbeMaPhong.Properties.DisplayMember = "MAPHONG";
     ccbeMaPhong.Properties.ValueMember = "MAPHONG";
     scheControl.OptionsCustomization.AllowInplaceEditor = UsedAppointmentType.None;
     scheControl.OptionsCustomization.AllowAppointmentDrag = UsedAppointmentType.None;
     scheControl.OptionsCustomization.AllowAppointmentResize = UsedAppointmentType.None;
     scheControl.OptionsCustomization.AllowAppointmentDelete = UsedAppointmentType.None;
     schedulerStrorage.Resources.DataSource = lstPhong;
     schedulerStrorage.Resources.Mappings.Caption = "MAPHONG";
     schedulerStrorage.Resources.Mappings.Id = "MAPHONG";
     scheControl.GroupType = SchedulerGroupType.Resource;
     scheControl.GoToToday();
 }