mirror of
https://github.com/Cleanuparr/Cleanuparr.git
synced 2026-05-19 12:06:03 -04:00
Add app status setting to general settings (#433)
This commit is contained in:
@@ -49,6 +49,7 @@ export class DocumentationService {
|
||||
'httpCertificateValidation': 'http-certificate-validation',
|
||||
'searchEnabled': 'search-enabled',
|
||||
'searchDelay': 'search-delay',
|
||||
'statusCheckEnabled': 'status-check',
|
||||
'log.level': 'log-level',
|
||||
'log.rollingSizeMB': 'rolling-size-mb',
|
||||
'log.retainedFileCount': 'retained-file-count',
|
||||
|
||||
@@ -25,6 +25,9 @@
|
||||
<app-toggle label="Display Support Banner" [(checked)]="displaySupportBanner"
|
||||
hint="Show the support section on the dashboard with links to GitHub and sponsors"
|
||||
helpKey="general:displaySupportBanner" />
|
||||
<app-toggle label="Status Check" [(checked)]="statusCheckEnabled"
|
||||
hint="When enabled, Cleanuparr will periodically check for new versions. Disable this if your environment has restricted outbound network access."
|
||||
helpKey="general:statusCheckEnabled" />
|
||||
|
||||
<div class="form-divider"></div>
|
||||
|
||||
|
||||
@@ -62,6 +62,7 @@ export class GeneralSettingsComponent implements OnInit, HasPendingChanges {
|
||||
readonly httpCertificateValidation = signal<unknown>(CertificateValidationType.Enabled);
|
||||
readonly searchEnabled = signal(true);
|
||||
readonly searchDelay = signal<number | null>(5);
|
||||
readonly statusCheckEnabled = signal(true);
|
||||
readonly ignoredDownloads = signal<string[]>([]);
|
||||
|
||||
// Logging
|
||||
@@ -165,6 +166,7 @@ export class GeneralSettingsComponent implements OnInit, HasPendingChanges {
|
||||
this.httpCertificateValidation.set(config.httpCertificateValidation);
|
||||
this.searchEnabled.set(config.searchEnabled);
|
||||
this.searchDelay.set(config.searchDelay);
|
||||
this.statusCheckEnabled.set(config.statusCheckEnabled);
|
||||
this.ignoredDownloads.set(config.ignoredDownloads ?? []);
|
||||
if (config.log) {
|
||||
this.logLevel.set(config.log.level);
|
||||
@@ -200,6 +202,7 @@ export class GeneralSettingsComponent implements OnInit, HasPendingChanges {
|
||||
httpCertificateValidation: this.httpCertificateValidation() as CertificateValidationType,
|
||||
searchEnabled: this.searchEnabled(),
|
||||
searchDelay: this.searchDelay() ?? 5,
|
||||
statusCheckEnabled: this.statusCheckEnabled(),
|
||||
ignoredDownloads: this.ignoredDownloads(),
|
||||
log: {
|
||||
level: this.logLevel() as LogEventLevel,
|
||||
@@ -237,6 +240,7 @@ export class GeneralSettingsComponent implements OnInit, HasPendingChanges {
|
||||
httpCertificateValidation: this.httpCertificateValidation(),
|
||||
searchEnabled: this.searchEnabled(),
|
||||
searchDelay: this.searchDelay(),
|
||||
statusCheckEnabled: this.statusCheckEnabled(),
|
||||
ignoredDownloads: this.ignoredDownloads(),
|
||||
logLevel: this.logLevel(),
|
||||
logRollingSizeMB: this.logRollingSizeMB(),
|
||||
|
||||
@@ -18,6 +18,7 @@ export interface GeneralConfig {
|
||||
httpCertificateValidation: CertificateValidationType;
|
||||
searchEnabled: boolean;
|
||||
searchDelay: number;
|
||||
statusCheckEnabled: boolean;
|
||||
log?: LoggingConfig;
|
||||
ignoredDownloads: string[];
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user