public void loadData() { OrdersDAO dao = new OrdersDAO(); List <Orders> list = new List <Orders>(); try { list = dao.GetAllOrders(frmLogin.AuthorizedUser.Username); } catch (Exception) { throw; } tblOrderHistory.DataSource = list; }
public List <Orders> GetOrder([FromBody] string username) { return(_ordersDao.GetAllOrders(username)); }