예제 #1
0
        public ActionResult Results()
        {
            var data = DBBridge.LoadResults();
            List <ResultModel> Results = new List <ResultModel>();

            foreach (var row in data)
            {
                Results.Add(new ResultModel
                {
                    ResultId           = row.ResId,
                    InstitutionId      = row.InstitutionId,
                    AssignmentName     = row.AsName,
                    Score              = row.Score,
                    NumberofAttendance = row.TotAsNum
                });
            }

            return(View(Results));
        }
예제 #2
0
        public ActionResult Results()
        {
            ViewBag.Message = "View the past results.";

            var data = DBBridge.LoadResults();
            List <ResultModel> Results = new List <ResultModel>();

            foreach (var row in data)
            {
                Results.Add(new ResultModel
                {
                    ResultId           = row.ResultId,
                    AssignmentName     = row.AssignmentName,
                    Score              = row.Score,
                    NumberofAttendance = row.TotalAssignmentNumber
                });
            }

            return(View(Results));
        }