Merge branch 'dane/restore-backups' into develop

This commit is contained in:
Dane Everitt 2021-02-17 20:59:40 -08:00
commit 245989967b
No known key found for this signature in database
GPG key ID: EEA66103B3D71F53

View file

@ -31,6 +31,7 @@ import { faExternalLinkAlt } from '@fortawesome/free-solid-svg-icons';
import RequireServerPermission from '@/hoc/RequireServerPermission'; import RequireServerPermission from '@/hoc/RequireServerPermission';
import ServerInstallSvg from '@/assets/images/server_installing.svg'; import ServerInstallSvg from '@/assets/images/server_installing.svg';
import ServerRestoreSvg from '@/assets/images/server_restore.svg'; import ServerRestoreSvg from '@/assets/images/server_restore.svg';
import ServerErrorSvg from '@/assets/images/server_error.svg';
const ConflictStateRenderer = () => { const ConflictStateRenderer = () => {
const status = ServerContext.useStoreState(state => state.server.data?.status || null); const status = ServerContext.useStoreState(state => state.server.data?.status || null);
@ -44,11 +45,18 @@ const ConflictStateRenderer = () => {
message={'Your server should be ready soon, please try again in a few minutes.'} message={'Your server should be ready soon, please try again in a few minutes.'}
/> />
: :
<ScreenBlock status === 'suspended' ?
title={isTransferring ? 'Transferring' : 'Restoring from Backup'} <ScreenBlock
image={ServerRestoreSvg} title={'Server Suspended'}
message={isTransferring ? 'Your server is being transfered to a new node, please check back later.' : 'Your server is currently being restored from a backup, please check back in a few minutes.'} image={ServerErrorSvg}
/> message={'This server is suspended and cannot be accessed.'}
/>
:
<ScreenBlock
title={isTransferring ? 'Transferring' : 'Restoring from Backup'}
image={ServerRestoreSvg}
message={isTransferring ? 'Your server is being transfered to a new node, please check back later.' : 'Your server is currently being restored from a backup, please check back in a few minutes.'}
/>
); );
}; };