feat(api): add backend support for toggling admin login link visibility on status page

This commit is contained in:
Jeffer Marcelino committed 2025-06-22 18:26:20 +02:00
1 parent 31321749b2
commit 7c5516cd75
3 files changed
+6

No files matched your search

+4
View File
@@ -70,6 +70,10 @@ const StatusPageSchema = mongoose.Schema(
type: Boolean, type: Boolean,
default: true, default: true,
}, },
showAdminLoginLink: {
type: Boolean,
default: false,
}
}, },
{ timestamps: true } { timestamps: true }
); );
@@ -153,6 +153,7 @@ const getStatusPage = async (url) => {
showCharts: 1, showCharts: 1,
showUptimePercentage: 1, showUptimePercentage: 1,
timezone: 1, timezone: 1,
showAdminLoginLink: 1,
url: 1, url: 1,
}, },
monitors: { monitors: {
+1
View File
@@ -463,6 +463,7 @@ const createStatusPageBodyValidation = joi.object({
isPublished: joi.boolean(), isPublished: joi.boolean(),
showCharts: joi.boolean().optional(), showCharts: joi.boolean().optional(),
showUptimePercentage: joi.boolean(), showUptimePercentage: joi.boolean(),
showAdminLoginLink: joi.boolean().optional(),
}); });
const imageValidation = joi const imageValidation = joi