mirror of
https://github.com/collinbarrett/FilterLists.git
synced 2026-03-11 09:04:27 +00:00
dto naming consistency, fix valign of list names
This commit is contained in:
parent
c176ff73c4
commit
3971cd38bf
5 changed files with 9 additions and 5 deletions
|
|
@ -16,12 +16,12 @@ public FilterListService(FilterListsDbContext filterListsDbContext)
|
|||
this.filterListsDbContext = filterListsDbContext;
|
||||
}
|
||||
|
||||
public async Task<IEnumerable<FilterListSummaryDto>> GetAllSummariesAsync()
|
||||
public async Task<IEnumerable<ListSummaryDto>> GetAllSummariesAsync()
|
||||
{
|
||||
return await filterListsDbContext.FilterLists
|
||||
.AsNoTracking()
|
||||
.OrderBy(x => x.Name)
|
||||
.ProjectTo<FilterListSummaryDto>()
|
||||
.ProjectTo<ListSummaryDto>()
|
||||
.ToListAsync();
|
||||
}
|
||||
|
||||
|
|
|
|||
|
|
@ -2,7 +2,7 @@
|
|||
|
||||
namespace FilterLists.Services.FilterListService
|
||||
{
|
||||
public class FilterListSummaryDto
|
||||
public class ListSummaryDto
|
||||
{
|
||||
public int Id { get; set; }
|
||||
public IEnumerable<ListLanguagesDto> Languages { get; set; }
|
||||
|
|
@ -8,7 +8,7 @@ public class MappingProfiles : Profile
|
|||
{
|
||||
public MappingProfiles()
|
||||
{
|
||||
CreateMap<FilterList, FilterListSummaryDto>()
|
||||
CreateMap<FilterList, ListSummaryDto>()
|
||||
.ForMember(dto => dto.Languages,
|
||||
conf => conf.MapFrom(list =>
|
||||
list.FilterListLanguages.Select(listLangs => listLangs.Language)));
|
||||
|
|
|
|||
|
|
@ -53,7 +53,7 @@ export class Home extends React.Component<RouteComponentProps<{}>, IFilterListsS
|
|||
filterMethod: (filter: any, row: any) => row[filter.id].toUpperCase()
|
||||
.includes(filter.value.toUpperCase()),
|
||||
sortMethod: (a: any, b: any) => a.toUpperCase() > b.toUpperCase() ? 1 : -1,
|
||||
Cell: (cell: any) => <h2>{cell.value}</h2>
|
||||
Cell: (cell: any) => <h2 className="list-title">{cell.value}</h2>
|
||||
},
|
||||
{
|
||||
Header: "Languages",
|
||||
|
|
|
|||
|
|
@ -15,6 +15,10 @@ body, h2, h3, h4, h5, blockquote {
|
|||
align-items: center;
|
||||
}
|
||||
|
||||
.list-title {
|
||||
margin: 0;
|
||||
}
|
||||
|
||||
.panel-list-details {
|
||||
padding: 20px;
|
||||
margin-bottom: 0;
|
||||
|
|
|
|||
Loading…
Reference in a new issue