示例#1
0
        //
        // GET: /Share/
        public ActionResult List(string id)
        {
            var sharedList = new API_ListShare();
            if (id != string.Empty)
            {
                var util = new GyftoList.Util.Greeting();
                ViewBag.Greeting = util.GetRandomGreeting();

                var gAPI = new ListShareController();
                try
                {
                    sharedList = gAPI.GetListShare(id);
                }
                catch (Exception ex)
                {
                    throw new Exception("Shared List not found" + ex.InnerException.ToString());
                }
            }
            else { throw new Exception("Shared  List not provided"); }

            return View(sharedList);
        }
示例#2
0
 public ActionResult All()
 {
     var gAPI = new ListShareController();
     return View(gAPI.GetListShares());
 }