Theoretical handling of system task updates; stdout straight to logger

This commit is contained in:
James Barnsley
2020-01-17 23:14:43 +13:00
parent 0e15a8745e
commit 169396042a
11 changed files with 7788 additions and 54 deletions

View File

@ -116,6 +116,9 @@ const PusherMiddleware = (function () {
case 'local_scan_started':
store.dispatch(uiActions.updateProcess('local_scan', 'Scanning local library'));
break;
case 'local_scan_updated':
store.dispatch(uiActions.updateProcess('local_scan', 'Scanning local library', {}, message.params.output));
break;
case 'local_scan_finished':
store.dispatch(uiActions.processFinished('local_scan'));
store.dispatch(uiActions.createNotification({
@ -124,7 +127,7 @@ const PusherMiddleware = (function () {
break;
case 'local_scan_error':
store.dispatch(uiActions.processFinished('local_scan'));
store.dispatch(uiActions.createNotification({ type: 'bad', content: message.params.message, description: message.params.error }));
store.dispatch(coreActions.handleException('Local scan failed', message, message.params.error));
break;
// Upgrade
@ -136,7 +139,7 @@ const PusherMiddleware = (function () {
break;
case 'upgrade_error':
store.dispatch(uiActions.processFinished('upgrade'));
store.dispatch(uiActions.createNotification({ type: 'bad', content: message.params.message, description: message.params.error }));
store.dispatch(coreActions.handleException('Upgrade failed', message, message.params.error));
break;
// Restart
@ -146,7 +149,7 @@ const PusherMiddleware = (function () {
break;
case 'restart_error':
store.dispatch(uiActions.processFinished('upgrade'));
store.dispatch(uiActions.createNotification({ type: 'bad', content: message.params.message, description: message.params.error }));
store.dispatch(coreActions.handleException('Restart failed', message, message.params.error));
break;
// Test