mirror of
https://github.com/claunia/marechai.git
synced 2025-12-16 19:14:25 +00:00
Sort machine families. Fixes #11
This commit is contained in:
@@ -2,7 +2,7 @@
|
|||||||
<Project Sdk="Microsoft.NET.Sdk.Web">
|
<Project Sdk="Microsoft.NET.Sdk.Web">
|
||||||
<PropertyGroup>
|
<PropertyGroup>
|
||||||
<TargetFramework>netcoreapp3.1</TargetFramework>
|
<TargetFramework>netcoreapp3.1</TargetFramework>
|
||||||
<Version>4.0.0.1576</Version>
|
<Version>4.0.0.1577</Version>
|
||||||
<Company>Canary Islands Computer Museum</Company>
|
<Company>Canary Islands Computer Museum</Company>
|
||||||
<Copyright>Copyright © 2003-2020 Natalia Portillo</Copyright>
|
<Copyright>Copyright © 2003-2020 Natalia Portillo</Copyright>
|
||||||
<Product>Canary Islands Computer Museum Website</Product>
|
<Product>Canary Islands Computer Museum Website</Product>
|
||||||
|
|||||||
@@ -43,7 +43,7 @@ namespace Marechai.Services
|
|||||||
Select(m => new MachineFamilyViewModel
|
Select(m => new MachineFamilyViewModel
|
||||||
{
|
{
|
||||||
Id = m.Id, Company = m.Company.Name, Name = m.Name
|
Id = m.Id, Company = m.Company.Name, Name = m.Name
|
||||||
}).ToListAsync();
|
}).OrderBy(m => m.Name).ToListAsync();
|
||||||
|
|
||||||
public async Task<MachineFamilyViewModel> GetAsync(int id) =>
|
public async Task<MachineFamilyViewModel> GetAsync(int id) =>
|
||||||
await _context.MachineFamilies.Where(f => f.Id == id).Select(m => new MachineFamilyViewModel
|
await _context.MachineFamilies.Where(f => f.Id == id).Select(m => new MachineFamilyViewModel
|
||||||
|
|||||||
Reference in New Issue
Block a user