mirror of
https://github.com/navidrome/navidrome.git
synced 2026-11-09 03:38:48 +01:00
feat: rename year to max_year and add min_year to album. #118
This commit is contained in:
parent
fc650cd127
commit
53e8a92fed
10 changed files with 95 additions and 14 deletions
|
|
@ -11,8 +11,8 @@ const AlbumDetails = ({ classes, record }) => {
|
|||
if (record.genre) {
|
||||
genreDateLine.push(record.genre)
|
||||
}
|
||||
if (record.year) {
|
||||
genreDateLine.push(record.year)
|
||||
if (record.maxYear) {
|
||||
genreDateLine.push(record.maxYear)
|
||||
}
|
||||
return genreDateLine.join(' · ')
|
||||
}
|
||||
|
|
|
|||
|
|
@ -31,7 +31,7 @@ const AlbumFilter = (props) => (
|
|||
<AutocompleteInput emptyText="-- None --" />
|
||||
</ReferenceInput>
|
||||
<NullableBooleanInput source="compilation" />
|
||||
<NumberInput source="year" />
|
||||
<NumberInput source="max_year" />
|
||||
</Filter>
|
||||
)
|
||||
|
||||
|
|
@ -68,7 +68,7 @@ const AlbumList = (props) => {
|
|||
render={(r) => (r.albumArtist ? r.albumArtist : r.artist)}
|
||||
/>
|
||||
{isDesktop && <NumberField source="songCount" />}
|
||||
<TextField source="year" />
|
||||
<TextField source="maxYear" />
|
||||
{isDesktop && <DurationField source="duration" />}
|
||||
</Datagrid>
|
||||
</List>
|
||||
|
|
|
|||
|
|
@ -19,7 +19,7 @@ const artistRowClick = (id, basePath, record) => {
|
|||
const filter = { artist_id: id }
|
||||
return `/album?filter=${JSON.stringify(
|
||||
filter
|
||||
)}&order=ASC&sort=year&displayedFilters={"compilation":true}`
|
||||
)}&order=ASC&sort=maxYear&displayedFilters={"compilation":true}`
|
||||
}
|
||||
|
||||
const ArtistList = (props) => (
|
||||
|
|
|
|||
|
|
@ -83,7 +83,7 @@ const SongList = (props) => {
|
|||
{isDesktop && <TextField source="album" />}
|
||||
<TextField source="artist" />
|
||||
{isDesktop && <NumberField source="trackNumber" />}
|
||||
{isDesktop && <TextField source="year" />}
|
||||
{isDesktop && <TextField source="maxYear" />}
|
||||
<DurationField source="duration" />
|
||||
</Datagrid>
|
||||
)}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue