mirror of
https://github.com/Lidarr/Lidarr
synced 2025-12-06 16:33:52 +01:00
Fixed: Track status on album details
This commit is contained in:
parent
4dd5411461
commit
e8ec12f09e
3 changed files with 7 additions and 7 deletions
|
|
@ -188,7 +188,7 @@ class TrackRow extends Component {
|
||||||
className={styles.status}
|
className={styles.status}
|
||||||
>
|
>
|
||||||
<EpisodeStatusConnector
|
<EpisodeStatusConnector
|
||||||
albumId={id}
|
albumId={albumId}
|
||||||
trackFileId={trackFileId}
|
trackFileId={trackFileId}
|
||||||
/>
|
/>
|
||||||
</TableRowCell>
|
</TableRowCell>
|
||||||
|
|
|
||||||
|
|
@ -11,7 +11,7 @@ import styles from './EpisodeStatus.css';
|
||||||
|
|
||||||
function EpisodeStatus(props) {
|
function EpisodeStatus(props) {
|
||||||
const {
|
const {
|
||||||
airDateUtc,
|
releaseDate,
|
||||||
monitored,
|
monitored,
|
||||||
grabbed,
|
grabbed,
|
||||||
queueItem,
|
queueItem,
|
||||||
|
|
@ -20,7 +20,7 @@ function EpisodeStatus(props) {
|
||||||
|
|
||||||
const hasTrackFile = !!trackFile;
|
const hasTrackFile = !!trackFile;
|
||||||
const isQueued = !!queueItem;
|
const isQueued = !!queueItem;
|
||||||
const hasAired = isBefore(airDateUtc);
|
const isReleased = isBefore(releaseDate);
|
||||||
|
|
||||||
if (isQueued) {
|
if (isQueued) {
|
||||||
const {
|
const {
|
||||||
|
|
@ -74,7 +74,7 @@ function EpisodeStatus(props) {
|
||||||
);
|
);
|
||||||
}
|
}
|
||||||
|
|
||||||
if (!airDateUtc) {
|
if (!releaseDate) {
|
||||||
return (
|
return (
|
||||||
<div className={styles.center}>
|
<div className={styles.center}>
|
||||||
<Icon
|
<Icon
|
||||||
|
|
@ -96,7 +96,7 @@ function EpisodeStatus(props) {
|
||||||
);
|
);
|
||||||
}
|
}
|
||||||
|
|
||||||
if (hasAired) {
|
if (isReleased) {
|
||||||
return (
|
return (
|
||||||
<div className={styles.center}>
|
<div className={styles.center}>
|
||||||
<Icon
|
<Icon
|
||||||
|
|
@ -118,7 +118,7 @@ function EpisodeStatus(props) {
|
||||||
}
|
}
|
||||||
|
|
||||||
EpisodeStatus.propTypes = {
|
EpisodeStatus.propTypes = {
|
||||||
airDateUtc: PropTypes.string,
|
releaseDate: PropTypes.string,
|
||||||
monitored: PropTypes.bool,
|
monitored: PropTypes.bool,
|
||||||
grabbed: PropTypes.bool,
|
grabbed: PropTypes.bool,
|
||||||
queueItem: PropTypes.object,
|
queueItem: PropTypes.object,
|
||||||
|
|
|
||||||
|
|
@ -15,7 +15,7 @@ function createMapStateToProps() {
|
||||||
createTrackFileSelector(),
|
createTrackFileSelector(),
|
||||||
(album, queueItem, trackFile) => {
|
(album, queueItem, trackFile) => {
|
||||||
const result = _.pick(album, [
|
const result = _.pick(album, [
|
||||||
'airDateUtc',
|
'releaseDate',
|
||||||
'monitored',
|
'monitored',
|
||||||
'grabbed'
|
'grabbed'
|
||||||
]);
|
]);
|
||||||
|
|
|
||||||
Loading…
Reference in a new issue