private void show_DichVu() { show_dvt(); dvBUS = new DichVuBUS(); IList <DichVuDTO> listDV = dvBUS.getListDichVuAll(); cmbDVtinh.Items.Clear(); lsvDichVu.Items.Clear(); foreach (DichVuDTO dv in listDV) { int i = lsvDichVu.Items.Count; lsvDichVu.Items.Add(dv.Madichvu); lsvDichVu.Items[i].SubItems.Add(dv.Tendichvu); lsvDichVu.Items[i].SubItems.Add(dv.Gia.ToString("0,0")); lsvDichVu.Items[i].SubItems.Add(dv.Donvitinh); } }
private void FormPhieuThuePhong_Load(object sender, EventArgs e) { if (frmMain.m_chucvu == "Quản lý") { btnThem.Enabled = false; btnXoa.Enabled = false; btnSua.Enabled = false; } dtpNgayGio.Format = DateTimePickerFormat.Custom; dtpNgayGio.CustomFormat = "dd/MM/yyyy h:mm:ss"; sizeOld = this.Size; if (maphieudat != "") { nhanphong(maphieudat); } dvBUS = new DichVuBUS(); cmbMaDV.DataSource = dvBUS.getListDichVuAll(); cmbMaDV.DisplayMember = "Tendichvu"; cmbMaDV.ValueMember = "Madichvu"; emtylsvKH(); lbTitle.Text += str; show_MaPT(); if (cmbMaPT.Text != "") { show_CTTP(); show_kh(); } if (maphieuthue != "" && maphong != "") { cmbMaPT.Text = maphieuthue; cmbMaPT.Text = maphong; } }