示例#1
0
        public ActionResult <ResponseObject <Film> > GetUpcoming()
        {
            ActionResult <ResponseObject <Film> > res;

            try
            {
                var data = _filmContext.GetUpcomingFilms();
                res = new ResponseObject <Film>(true, ResponseText.SuccessfullyRetrievedUpcomingFilms, new List <Film>(data));
                return(res);
            }
            catch (Exception)
            {
                res = new ResponseObject <Film>(false, ResponseText.UnableToRetrieveUpcomingFilms, null);
                return(res);
            }
        }