Move computers index to Blazor.

This commit is contained in:
2020-05-22 01:08:12 +01:00
parent 44ae0b38b2
commit 2e9fe91777
7 changed files with 486 additions and 252 deletions

View File

@@ -47,21 +47,6 @@ namespace Marechai.Controllers
_context = context;
}
public IActionResult Index()
{
ViewBag.ItemCount = _context.Machines.Count(m => m.Type == MachineType.Computer);
ViewBag.MinYear = _context.
Machines.Where(t => t.Type == MachineType.Computer && t.Introduced.HasValue &&
t.Introduced.Value.Year > 1000).Min(t => t.Introduced.Value.Year);
ViewBag.MaxYear = _context.
Machines.Where(t => t.Type == MachineType.Computer && t.Introduced.HasValue &&
t.Introduced.Value.Year > 1000).Max(t => t.Introduced.Value.Year);
return View();
}
public IActionResult ByLetter(char id)
{
// ToUpper()