public ActionResult Index()
        {
            Dictionary <string, double> dictMateriels = new Dictionary <string, double>()
            {
                { "materiels", 0 }
            };

            ViewBag.PercentageMateriels = dictMateriels;

            IEnumerable <materiel> totalMateriels = service.GetAllMateriels();

            //ViewBag.totalMateriels = totalMateriels;


            if (totalMateriels.Count() != 0)
            {
                //ViewBag.idM = totalMateriels;
                ViewBag.PercentageMateriels = getDescriptionMateriels(totalMateriels);
                //Debug.WriteLine("aaaa "+ViewBag.PercentageMateriels["materiels"]);
            }

            return(View());
        }
Пример #2
0
        // GET: Materiel
        public ActionResult Index()
        {
            var l = service.GetAllMateriels();

            return(View(l));
        }