mirror of
https://github.com/Readarr/Readarr.git
synced 2026-04-24 22:35:39 -04:00
Update UI Packages
Align with Lidarr
This commit is contained in:
@@ -147,7 +147,7 @@ class SignalRConnector extends Component {
|
||||
}
|
||||
|
||||
console.error(`signalR: Unable to find handler for ${name}`);
|
||||
}
|
||||
};
|
||||
|
||||
handleCalendar = (body) => {
|
||||
if (body.action === 'updated') {
|
||||
@@ -157,7 +157,7 @@ class SignalRConnector extends Component {
|
||||
...body.resource
|
||||
});
|
||||
}
|
||||
}
|
||||
};
|
||||
|
||||
handleCommand = (body) => {
|
||||
if (body.action === 'sync') {
|
||||
@@ -176,7 +176,7 @@ class SignalRConnector extends Component {
|
||||
} else {
|
||||
this.props.dispatchUpdateCommand(resource);
|
||||
}
|
||||
}
|
||||
};
|
||||
|
||||
handleBook = (body) => {
|
||||
const action = body.action;
|
||||
@@ -193,7 +193,7 @@ class SignalRConnector extends Component {
|
||||
id: body.resource.id
|
||||
});
|
||||
}
|
||||
}
|
||||
};
|
||||
|
||||
handleBookfile = (body) => {
|
||||
const section = 'bookFiles';
|
||||
@@ -206,11 +206,11 @@ class SignalRConnector extends Component {
|
||||
|
||||
// Repopulate the page to handle recently imported file
|
||||
repopulatePage('bookFileUpdated');
|
||||
}
|
||||
};
|
||||
|
||||
handleHealth = () => {
|
||||
this.props.dispatchFetchHealth();
|
||||
}
|
||||
};
|
||||
|
||||
handleAuthor = (body) => {
|
||||
const action = body.action;
|
||||
@@ -222,7 +222,7 @@ class SignalRConnector extends Component {
|
||||
this.props.dispatchRemoveItem({ section, id: body.resource.id });
|
||||
this.props.dispatchDeleteAuthorBooks({ authorId: body.resource.id });
|
||||
}
|
||||
}
|
||||
};
|
||||
|
||||
handleQualitydefinition = () => {
|
||||
this.props.dispatchFetchQualityDefinitions();
|
||||
@@ -232,21 +232,21 @@ class SignalRConnector extends Component {
|
||||
if (this.props.isQueuePopulated) {
|
||||
this.props.dispatchFetchQueue();
|
||||
}
|
||||
}
|
||||
};
|
||||
|
||||
handleQueueDetails = () => {
|
||||
this.props.dispatchFetchQueueDetails();
|
||||
}
|
||||
};
|
||||
|
||||
handleQueueStatus = (body) => {
|
||||
this.props.dispatchUpdate({ section: 'queue.status', data: body.resource });
|
||||
}
|
||||
};
|
||||
|
||||
handleVersion = (body) => {
|
||||
const version = body.version;
|
||||
|
||||
this.props.dispatchSetVersion({ version });
|
||||
}
|
||||
};
|
||||
|
||||
handleWantedCutoff = (body) => {
|
||||
if (body.action === 'updated') {
|
||||
@@ -256,7 +256,7 @@ class SignalRConnector extends Component {
|
||||
...body.resource
|
||||
});
|
||||
}
|
||||
}
|
||||
};
|
||||
|
||||
handleWantedMissing = (body) => {
|
||||
if (body.action === 'updated') {
|
||||
@@ -266,11 +266,11 @@ class SignalRConnector extends Component {
|
||||
...body.resource
|
||||
});
|
||||
}
|
||||
}
|
||||
};
|
||||
|
||||
handleSystemTask = () => {
|
||||
this.props.dispatchFetchCommands();
|
||||
}
|
||||
};
|
||||
|
||||
handleRootfolder = (body) => {
|
||||
if (body.action === 'updated') {
|
||||
@@ -280,7 +280,7 @@ class SignalRConnector extends Component {
|
||||
...body.resource
|
||||
});
|
||||
}
|
||||
}
|
||||
};
|
||||
|
||||
handleTag = (body) => {
|
||||
if (body.action === 'sync') {
|
||||
@@ -288,7 +288,7 @@ class SignalRConnector extends Component {
|
||||
this.props.dispatchFetchTagDetails();
|
||||
return;
|
||||
}
|
||||
}
|
||||
};
|
||||
|
||||
//
|
||||
// Listeners
|
||||
@@ -303,7 +303,7 @@ class SignalRConnector extends Component {
|
||||
isDisconnected: false,
|
||||
isRestarting: false
|
||||
});
|
||||
}
|
||||
};
|
||||
|
||||
onStart = () => {
|
||||
console.debug('[signalR] connected');
|
||||
@@ -314,11 +314,11 @@ class SignalRConnector extends Component {
|
||||
isDisconnected: false,
|
||||
isRestarting: false
|
||||
});
|
||||
}
|
||||
};
|
||||
|
||||
onReconnecting = () => {
|
||||
this.props.dispatchSetAppValue({ isReconnecting: true });
|
||||
}
|
||||
};
|
||||
|
||||
onReconnected = () => {
|
||||
|
||||
@@ -340,17 +340,17 @@ class SignalRConnector extends Component {
|
||||
dispatchFetchAuthor();
|
||||
dispatchFetchCommands();
|
||||
repopulatePage();
|
||||
}
|
||||
};
|
||||
|
||||
onClose = () => {
|
||||
console.debug('[signalR] connection closed');
|
||||
}
|
||||
};
|
||||
|
||||
onReceiveMessage = (message) => {
|
||||
console.debug('[signalR] received', message.name, message.body);
|
||||
|
||||
this.handleMessage(message);
|
||||
}
|
||||
};
|
||||
|
||||
//
|
||||
// Render
|
||||
|
||||
Reference in New Issue
Block a user