mirror of
https://github.com/arsvendg/Stirling-PDF.git
synced 2026-07-16 11:23:10 +02:00
option to hide google drive and add settings (#5863)
Co-authored-by: EthanHealy01 <[email protected]>
This commit is contained in:
co-authored by
EthanHealy01
parent
cafcee6c99
commit
7d640e9ce6
+18
@@ -159,6 +159,24 @@ public class ConfigController {
|
||||
"defaultHideUnavailableConversions",
|
||||
applicationProperties.getUi().isDefaultHideUnavailableConversions());
|
||||
|
||||
// Hide disabled tools settings
|
||||
configData.put(
|
||||
"hideDisabledToolsGoogleDrive",
|
||||
applicationProperties.getUi().getHideDisabledTools().isGoogleDrive());
|
||||
configData.put(
|
||||
"hideDisabledToolsMobileQRScanner",
|
||||
applicationProperties.getUi().getHideDisabledTools().isMobileQRScanner());
|
||||
|
||||
// Google Drive backend settings (only if enabled)
|
||||
ApplicationProperties.Premium.ProFeatures.GoogleDrive googleDrive =
|
||||
applicationProperties.getPremium().getProFeatures().getGoogleDrive();
|
||||
if (googleDrive.isEnabled()) {
|
||||
configData.put("googleDriveEnabled", true);
|
||||
configData.put("googleDriveClientId", googleDrive.getClientId());
|
||||
configData.put("googleDriveApiKey", googleDrive.getApiKey());
|
||||
configData.put("googleDriveAppId", googleDrive.getAppId());
|
||||
}
|
||||
|
||||
// Security settings
|
||||
// enableLogin requires both the config flag AND proprietary features to be loaded
|
||||
// If userService is null, proprietary module isn't loaded
|
||||
|
||||
@@ -96,6 +96,11 @@ premium:
|
||||
author: username
|
||||
creator: Stirling-PDF
|
||||
producer: Stirling-PDF
|
||||
googleDrive:
|
||||
enabled: false # Enable Google Drive file picker integration
|
||||
clientId: "" # Google OAuth 2.0 client ID (obtain from Google Cloud Console)
|
||||
apiKey: "" # Google API key for Google Picker API (obtain from Google Cloud Console)
|
||||
appId: "" # Google Drive app ID
|
||||
enterpriseFeatures:
|
||||
audit:
|
||||
enabled: true # Enable audit logging for security and compliance tracking
|
||||
@@ -238,6 +243,9 @@ ui:
|
||||
languages: [] # If empty, all languages are enabled. To display only German and Polish ["de_DE", "pl_PL"]. British English is always enabled.
|
||||
defaultHideUnavailableTools: false # Default user preference: hide disabled tools instead of greying them out
|
||||
defaultHideUnavailableConversions: false # Default user preference: hide disabled conversion options instead of greying them out
|
||||
hideDisabledTools:
|
||||
googleDrive: false # Hide Google Drive button when not enabled
|
||||
mobileQRScanner: false # Hide mobile QR scanner button when not enabled
|
||||
|
||||
endpoints:
|
||||
toRemove: [] # list endpoints to disable (e.g. ['img-to-pdf', 'remove-pages'])
|
||||
|
||||
Reference in New Issue
Block a user