private void button_refresh_Click(object sender, RoutedEventArgs e) { DatabaseReader databaseReader = new DatabaseReader(); databaseReader.Connect(); query = databaseReader.Read("SELECT o.id, o.Status, u.address, f.name, oi.quantity, o.total FROM orders o join users u on o.user_id=u.id join order_items oi on oi.order_id=o.id join foods f on f.id = oi.food_id"); databaseReader.Close(); }
private void Button_Click(object sender, RoutedEventArgs e) { DatabaseReader databaseReader = new DatabaseReader(); databaseReader.Connect(); query = databaseReader.Read("update orders set Status='W realizacji' where id= " + query[comboBoxOrders.SelectedIndex][0]); databaseReader.Close(); }
private void button_refresh_Click(object sender, RoutedEventArgs e) { DatabaseReader databaseReader = new DatabaseReader(); databaseReader.Connect(); query = databaseReader.Read("select o.id, f.name, oi.quantity, o.Status from orders o join order_items oi on o.id=oi.id join foods f on f.id=oi.food_id"); databaseReader.Close(); }
private void Button_Click(object sender, RoutedEventArgs e) { Paragon(); DatabaseReader databaseReader = new DatabaseReader(); databaseReader.Connect(); query = databaseReader.Read("update orders set Status='W dostawie' where id= " + query[comboBoxDelivery.SelectedIndex][0]); databaseReader.Close(); }
public Delivery() { InitializeComponent(); DatabaseReader databaseReader = new DatabaseReader(); databaseReader.Connect(); query = databaseReader.Read("SELECT o.id, o.Status, u.address, f.name, oi.quantity, o.total FROM orders o join users u on o.user_id=u.id join order_items oi on oi.order_id=o.id join foods f on f.id = oi.food_id"); databaseReader.Close(); SetOrdersId(); }
public Cook() { InitializeComponent(); DatabaseReader databaseReader = new DatabaseReader(); databaseReader.Connect(); query = databaseReader.Read("select o.id, f.name, oi.quantity, o.Status from orders o join order_items oi on o.id=oi.id join foods f on f.id=oi.food_id"); databaseReader.Close(); SetOrdersId(); }