mirror of
https://github.com/lidarr/lidarr.git
synced 2025-07-15 01:23:53 -07:00
Fixed: Showing already imported tracks as downloading in Artists index
(cherry picked from commit 8c3a0ebabae163274b7587afe1f998edb39c5184)
This commit is contained in:
parent
af12fad185
commit
ecb37b8378
2 changed files with 18 additions and 3 deletions
|
@ -12,7 +12,10 @@ function createArtistQueueDetailsSelector(artistId: number) {
|
||||||
(queueItems) => {
|
(queueItems) => {
|
||||||
return queueItems.reduce(
|
return queueItems.reduce(
|
||||||
(acc: ArtistQueueDetails, item) => {
|
(acc: ArtistQueueDetails, item) => {
|
||||||
if (item.artistId !== artistId) {
|
if (
|
||||||
|
item.trackedDownloadState === 'imported' ||
|
||||||
|
item.artistId !== artistId
|
||||||
|
) {
|
||||||
return acc;
|
return acc;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
@ -2,6 +2,18 @@ import ModelBase from 'App/ModelBase';
|
||||||
import { QualityModel } from 'Quality/Quality';
|
import { QualityModel } from 'Quality/Quality';
|
||||||
import CustomFormat from 'typings/CustomFormat';
|
import CustomFormat from 'typings/CustomFormat';
|
||||||
|
|
||||||
|
export type QueueTrackedDownloadStatus = 'ok' | 'warning' | 'error';
|
||||||
|
|
||||||
|
export type QueueTrackedDownloadState =
|
||||||
|
| 'downloading'
|
||||||
|
| 'downloadFailed'
|
||||||
|
| 'downloadFailedPending'
|
||||||
|
| 'importPending'
|
||||||
|
| 'importing'
|
||||||
|
| 'importFailed'
|
||||||
|
| 'imported'
|
||||||
|
| 'ignored';
|
||||||
|
|
||||||
export interface StatusMessage {
|
export interface StatusMessage {
|
||||||
title: string;
|
title: string;
|
||||||
messages: string[];
|
messages: string[];
|
||||||
|
@ -17,8 +29,8 @@ interface Queue extends ModelBase {
|
||||||
estimatedCompletionTime: string;
|
estimatedCompletionTime: string;
|
||||||
added?: string;
|
added?: string;
|
||||||
status: string;
|
status: string;
|
||||||
trackedDownloadStatus: string;
|
trackedDownloadStatus: QueueTrackedDownloadStatus;
|
||||||
trackedDownloadState: string;
|
trackedDownloadState: QueueTrackedDownloadState;
|
||||||
statusMessages: StatusMessage[];
|
statusMessages: StatusMessage[];
|
||||||
errorMessage: string;
|
errorMessage: string;
|
||||||
downloadId: string;
|
downloadId: string;
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue