private void AllreservationsBtn_Click(object sender, EventArgs e) { HidePanelsRecursively(this); Res_pnl.Show(); Order_pnl.Show(); AddRes_pnl.Show(); FillResList(); }
private void AllOrdersBtn2_Click(object sender, EventArgs e) { HidePanelsRecursively(this); FillOrderItemList(); AllOrders_pnl.Show(); Order_pnl.Show(); }
// -- // bestelling // faruk // -- private void AllOrdersBtn_Click(object sender, EventArgs e) { HidePanelsRecursively(this); Order_pnl.Show(); AllOrders_pnl.Show(); Table10_pnl.Show(); Table9_pnl.Show(); Table8_pnl.Show(); Table7_pnl.Show(); Table6_pnl.Show(); Table5_pnl.Show(); Table4_pnl.Show(); Table3_pnl.Show(); Table2_pnl.Show(); Table1_pnl.Show(); AllOrderslv.Items.Clear(); FillOrderItemList(); FillResList(); }
private void AddRes() { HidePanelsRecursively(this); Order_pnl.Show(); AddRes_pnl.Show(); FillResList(); AddTafelDD.Items.Clear(); foreach (Table t in t_service.GetTables()) { AddTafelDD.Items.Add(t.tableId); } }
private void ChangeResAcceptBtn_Click(object sender, EventArgs e) // aanpassing bevestigen { HidePanelsRecursively(this); Res_pnl.Show(); Order_pnl.Show(); int reservationId = int.Parse(Reservationlv.SelectedItems[0].SubItems[0].Text); int tableId = int.Parse(Reservationlv.SelectedItems[0].SubItems[1].Text); string reservationName = Reservationlv.SelectedItems[0].SubItems[2].Text; string reservationTel = Reservationlv.SelectedItems[0].SubItems[3].Text; string reservationEmail = Reservationlv.SelectedItems[0].SubItems[4].Text; string reservationComment = Reservationlv.SelectedItems[0].SubItems[5].Text; DateTime reservationDate = DateTime.Parse(Reservationlv.SelectedItems[0].SubItems[6].Text); if (!string.IsNullOrEmpty(reservationId.ToString())) { tableId = int.Parse(TafelResDD.Text.ToString()); reservationTel = telBox.Text; reservationName = aamBox.Text; reservationEmail = emailBox.Text; reservationComment = opmerkingBox.Text; reservationDate = DateTime.Parse(datumBox.Text); } else { throw new Exception("Er is iets fout gegaan!"); } Reservering r = new Reservering(); r.reservationId = int.Parse(Reservationlv.SelectedItems[0].SubItems[0].Text); r.tableId = int.Parse(Reservationlv.SelectedItems[0].SubItems[1].Text); r.reservationName = Reservationlv.SelectedItems[0].SubItems[2].Text; r.reservationTel = Reservationlv.SelectedItems[0].SubItems[3].Text; r.reservationEmail = Reservationlv.SelectedItems[0].SubItems[4].Text; r.reservationComment = Reservationlv.SelectedItems[0].SubItems[5].Text; r.reservationDate = DateTime.Parse(Reservationlv.SelectedItems[0].SubItems[6].Text); if (res_service.EditReservering(r) == true) { MessageBox.Show($"Rerservering gewijzigd!"); FillResList(); ChangeRes_pnl.Hide(); } else { MessageBox.Show("Er is iets fout gegaan"); } }
private void Add() // dropdown vullen met data { HidePanelsRecursively(this); AddOrder_pnl.Show(); Order_pnl.Show(); TafelDD.Items.Clear(); foreach (Table t in t_service.GetTables()) { TafelDD.Items.Add(t.tableId); } MenuDD.Items.Clear(); foreach (Menuu m in m_service.GetMenuNames()) { MenuDD.Items.Add(m.menuName); } ConsumptieDD.Items.Clear(); FillMenuItem(0); // menu items vullen op basis van menu }