mirror of
https://github.com/arsvendg/Stirling-PDF.git
synced 2026-07-16 11:23:10 +02:00
Shorten onbaording (#5198)
Also added `enableDesktopInstallSlide` flag in `settings.yml` to hide the download for desktop page in the onboarding. --------- Co-authored-by: James Brunton <[email protected]>
This commit is contained in:
co-authored by
James Brunton
parent
371d816ce7
commit
0064c1866e
+18
-2
@@ -23,8 +23,14 @@ const AdminAuditSection: React.FC = () => {
|
||||
setError(null);
|
||||
const status = await auditService.getSystemStatus();
|
||||
setSystemStatus(status);
|
||||
} catch (err) {
|
||||
setError(err instanceof Error ? err.message : 'Failed to load audit system status');
|
||||
} catch (err: any) {
|
||||
// Check if this is a permission/license error (403/404)
|
||||
const status = err?.response?.status;
|
||||
if (status === 403 || status === 404) {
|
||||
setError('enterprise-license-required');
|
||||
} else {
|
||||
setError(err instanceof Error ? err.message : 'Failed to load audit system status');
|
||||
}
|
||||
} finally {
|
||||
setLoading(false);
|
||||
}
|
||||
@@ -56,6 +62,16 @@ const AdminAuditSection: React.FC = () => {
|
||||
}
|
||||
|
||||
if (error) {
|
||||
if (error === 'enterprise-license-required') {
|
||||
return (
|
||||
<Alert color="blue" title={t('audit.enterpriseRequired', 'Enterprise License Required')}>
|
||||
{t(
|
||||
'audit.enterpriseRequiredMessage',
|
||||
'The audit logging system is an enterprise feature. Please upgrade to an enterprise license to access audit logs and analytics.'
|
||||
)}
|
||||
</Alert>
|
||||
);
|
||||
}
|
||||
return (
|
||||
<Alert color="red" title={t('audit.error.title', 'Error loading audit system')}>
|
||||
{error}
|
||||
|
||||
Reference in New Issue
Block a user