mirror of
https://github.com/lidarr/lidarr.git
synced 2025-08-19 21:13:28 -07:00
Fixed: show disambiguation in interactive import modal (#576)
This commit is contained in:
parent
ef9072fc3b
commit
c749405a45
2 changed files with 9 additions and 2 deletions
|
@ -34,6 +34,7 @@ class SelectAlbumRow extends Component {
|
||||||
render() {
|
render() {
|
||||||
const {
|
const {
|
||||||
title,
|
title,
|
||||||
|
disambiguation,
|
||||||
albumType,
|
albumType,
|
||||||
releaseDate,
|
releaseDate,
|
||||||
statistics,
|
statistics,
|
||||||
|
@ -47,6 +48,8 @@ class SelectAlbumRow extends Component {
|
||||||
totalTrackCount
|
totalTrackCount
|
||||||
} = statistics;
|
} = statistics;
|
||||||
|
|
||||||
|
const extendedTitle = disambiguation ? `${title} (${disambiguation})` : title;
|
||||||
|
|
||||||
return (
|
return (
|
||||||
<TableRow
|
<TableRow
|
||||||
onClick={this.onPress}
|
onClick={this.onPress}
|
||||||
|
@ -66,7 +69,7 @@ class SelectAlbumRow extends Component {
|
||||||
if (name === 'title') {
|
if (name === 'title') {
|
||||||
return (
|
return (
|
||||||
<TableRowCell key={name}>
|
<TableRowCell key={name}>
|
||||||
{title}
|
{extendedTitle}
|
||||||
</TableRowCell>
|
</TableRowCell>
|
||||||
);
|
);
|
||||||
}
|
}
|
||||||
|
@ -118,6 +121,7 @@ class SelectAlbumRow extends Component {
|
||||||
SelectAlbumRow.propTypes = {
|
SelectAlbumRow.propTypes = {
|
||||||
id: PropTypes.number.isRequired,
|
id: PropTypes.number.isRequired,
|
||||||
title: PropTypes.string.isRequired,
|
title: PropTypes.string.isRequired,
|
||||||
|
disambiguation: PropTypes.string.isRequired,
|
||||||
albumType: PropTypes.string.isRequired,
|
albumType: PropTypes.string.isRequired,
|
||||||
releaseDate: PropTypes.string.isRequired,
|
releaseDate: PropTypes.string.isRequired,
|
||||||
onAlbumSelect: PropTypes.func.isRequired,
|
onAlbumSelect: PropTypes.func.isRequired,
|
||||||
|
|
|
@ -185,7 +185,10 @@ class InteractiveImportRow extends Component {
|
||||||
} = this.state;
|
} = this.state;
|
||||||
|
|
||||||
const artistName = artist ? artist.artistName : '';
|
const artistName = artist ? artist.artistName : '';
|
||||||
const albumTitle = album ? album.title : '';
|
let albumTitle = '';
|
||||||
|
if (album) {
|
||||||
|
albumTitle = album.disambiguation ? `${album.title} (${album.disambiguation})` : album.title;
|
||||||
|
}
|
||||||
const trackNumbers = tracks.map((track) => `${track.mediumNumber}x${track.trackNumber}`)
|
const trackNumbers = tracks.map((track) => `${track.mediumNumber}x${track.trackNumber}`)
|
||||||
.join(', ');
|
.join(', ');
|
||||||
|
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue