public IActionResult GetAll()
        {
            var software = _softwareService.GetAll();

            var result = new List <SoftwareAllViewModel>();

            foreach (var s in software)
            {
                result.Add(new SoftwareAllViewModel()
                {
                    Software         = s,
                    SoftwareVersions = _softwareVersionService.GetAll().Where(sv => sv.SoftwareId == s.ID).ToArray()
                });
            }

            return(new OkObjectResult(result.ToArray()));
        }
Beispiel #2
0
 // GET: Software
 public ActionResult Index()
 {
     return(View(_softwareService.GetAll()));
 }
Beispiel #3
0
        public IActionResult Index()
        {
            var software = _softwareService.GetAll();

            return(View(software));
        }