public JsonResult Table(dtParam param) { var query = db.Products.AsNoTracking(); dtProduct res = new dtProduct(); res.data = res.GetData(param, query); res.draw = param.Draw; res.recordsTotal = query.Count(); res.recordsFiltered = res.Count(param, query); return(Json(res)); }
public JsonResult Report0(dtParam param) { var query = db.Products.AsNoTracking().Where(p => p.Balance == 0); dtProduct res = new dtProduct(); res.data = res.GetData(param, query); res.draw = param.Draw; res.recordsTotal = db.Products.AsNoTracking().Count(); res.recordsFiltered = res.Count(param, query); return(Json(res)); }