//
        // GET: /Home/

        public ActionResult Index(string id)
        {
            if (id == null)
            {
                if (Request.Cookies.AllKeys.Contains("appcacheUpdate"))
                {
                    return(View("AppCacheUpdate"));
                }
                else
                {
                    var articles = _service.Get();
                    return(View(articles));
                }
            }
            else
            {
                var article = _service.Get(id);
                return(View("Article", article));
            }
        }
Esempio n. 2
0
 // GET api/articles
 public IEnumerable <Article> Get()
 {
     return(_service.Get());
 }