protected void AddReportsFromClient(Database.Client client) { foreach (Database.Device dev in client.GetDevices()) { cReports1.fastObjectListView1.AddObjects(dev.GetRecords()); } }
private void btnDownload_Click(object sender, EventArgs e) { if (client == null) { //cDeviceList1.loadList(Global.database.getAllDevices()); cDeviceList1.fastObjectListView1.SetObjects(Database.DAO.GetAllDevices()); } else { cDeviceList1.fastObjectListView1.SetObjects(client.GetDevices()); } }
private void FillControl(Database.Client client) { foreach (string s in client.f_numbers) { tbCbFax.Items.Add(s); } foreach (string s in client.p_numbers) { tbCbPhones.Items.Add(s); } foreach (string s in client.wwwsites) { tbCbSites.Items.Add(s); } foreach (string s in client.emails) { tbCbMails.Items.Add(s); } if (tbCbFax.Items.Count > 0) { tbCbFax.SelectedIndex = tbCbFax.Items.Count - 1; } if (tbCbPhones.Items.Count > 0) { tbCbPhones.SelectedIndex = tbCbPhones.Items.Count - 1; } if (tbCbSites.Items.Count > 0) { tbCbSites.SelectedIndex = tbCbSites.Items.Count - 1; } if (tbCbMails.Items.Count > 0) { tbCbMails.SelectedIndex = tbCbMails.Items.Count - 1; } this.lName.Text = client.name; this.lNIP.Text = client.NIP; this.tbNote.Text = client.notes; this.checkBox1.Checked = client.ser_agr; cDeviceList1.fastObjectListView1.AddObjects(client.GetDevices()); FillAddress(); }
private void loadClient(string clientID) { this.client = Database.DAO.GetClient(clientID); this.cDeviceList1.fastObjectListView1.SetObjects(client.GetDevices()); }