Esempio n. 1
0
        public ActionResult FilterRecordsFromCategory(int id)
        {
            ViewData["Title"]  = "MyTitle";
            ViewData["list"]   = _datamanager.Record.GetRecordsFromCategory(id);
            ViewData["Action"] = "FilterRecordsFromCategory";
            RecordIdForComment r = new RecordIdForComment();

            ViewData["commentCount"]  = r.recordforcomment((IEnumerable <Record>)ViewData["list"]);
            ViewData["CategoryTitle"] = _datamanager.Category.GetCategory(id).NameCategory;
            return(View());
        }
Esempio n. 2
0
        //////////////////////////////////////////////////

        public ActionResult Index()
        {
            ViewData["Title"] = "MyTitle";
            ViewData["list"]  = _datamanager.Record.GetAllRecords();
            RecordIdForComment r = new RecordIdForComment();

            ViewData["commentCount"] = r.recordforcomment((IEnumerable <Record>)ViewData["list"]);
            IEnumerable <Record> query = _datamanager.Record.GetAllRecords().OrderByDescending(record => record.Id_Record);

            ViewData["SHIT"] = query;
            return(View());
        }