// GET: OrderList
        public ActionResult Index()
        {
            UserSession userSession = new UserSession();
            string      token       = userSession.BearerToken;

            List <Order> orderList = new List <Order>();

            var resultContent = GenericClient.GetEvent("http://localhost:57359/api/orders", "", token);

            if (resultContent != "")
            {
                orderList = JsonConvert.DeserializeObject <List <Order> >(resultContent);
            }

            return(View(orderList));
        }
        // GET:
        public ActionResult Delete(int id = 0)
        {
            UserSession userSession = new UserSession();
            string      token       = userSession.BearerToken;

            Order order = null;

            string url          = "http://localhost:57359/api/orders/";
            var    urlWithParam = string.Format("{0}{1}", url, id);

            var resultContent = GenericClient.GetEvent(urlWithParam, "", token);

            if (resultContent != "")
            {
                order = JsonConvert.DeserializeObject <Order>(resultContent);
            }

            return(View("Details", order));
        }