Exemplo n.º 1
0
        public JsonResult ForMorris2()
        {
            ReportsController rc = new ReportsController();
            var model            = rc.MonthlySalesByDate_forCharts(DateTime.Today.Year, DateTime.Today.Month);

            var value = model.Select(i => new Object[] { i.Day.ToString(), i.Total }).ToArray();

            return(Json(value, JsonRequestBehavior.AllowGet));
        }
Exemplo n.º 2
0
        public JsonResult ForMorris()
        {
            string year = Convert.ToString(DateTime.Today.Year);

            ReportsController rc = new ReportsController();
            var model            = rc.YearlySalesByMonth_forCharts(year).ToList();

            var count = model.Select(i => new Object[] { i.GrandTotal }).ToList();

            return(Json(count, JsonRequestBehavior.AllowGet));
        }