Exemple #1
0
        // GET: Admin/FeedBackandComplaint
        public ActionResult Index()
        {
            AdminDataContext loAdminContext = new AdminDataContext();
            FeedBackModel    loFeedBack     = new FeedBackModel();

            loFeedBack.loComplaints = loAdminContext.GetComplaintsList();
            var s = 0;
            var U = 0;

            foreach (var data in loFeedBack.loComplaints)
            {
                if (data.Solution == null)
                {
                    U++;
                }
                else
                {
                    s++;
                }
            }
            ViewBag.Solved          = s;
            ViewBag.UnSolved        = U;
            ViewBag.TotalComplaints = loFeedBack.loComplaints.Count();
            return(View(loFeedBack));
        }
Exemple #2
0
        public ActionResult GetComplaints(string ID, string status)
        {
            AdminDataContext loAdminContext = new AdminDataContext();
            FeedBackModel    loFeedBack     = new FeedBackModel();

            loFeedBack.loComplaints = loAdminContext.GetComplaintsList((ID == "") ? null : ID, (status == "") ? null : status);
            return(View("~/Areas/Admin/Views/FeedBackandComplaint/_GetComplaintsForSearch.cshtml", loFeedBack));
        }