Пример #1
0
        // GET: Data
        public ActionResult Index()
        {
            DataModel model = new DataModel();

            SubjectManager manager = new SubjectManager();

            //model.Species = DataModelHelper.ToDataTable<Species>(manager.GetAll<Species>());

            List <PlantModel> lPLants = new List <PlantModel>();

            manager.GetAll <Plant>().ToList().ForEach(p => lPLants.Add(PlantModel.Convert(p)));
            model.Plants = DataModelHelper.ToDataTable <PlantModel>(lPLants);
            return(View(model));
        }