feat: add organization-level certificate toggle and update tower-governor imports

This commit is contained in:
2026-04-14 13:58:58 -04:00
parent 169a0a18a2
commit c21942983a
3 changed files with 10 additions and 2 deletions
@@ -4,5 +4,11 @@
ALTER TABLE organization_exercise_settings
ADD COLUMN IF NOT EXISTS certificates_enabled BOOLEAN NOT NULL DEFAULT TRUE;
ALTER TABLE organizations
ADD COLUMN IF NOT EXISTS certificates_enabled BOOLEAN NOT NULL DEFAULT TRUE;
COMMENT ON COLUMN organization_exercise_settings.certificates_enabled
IS 'Enable/disable built-in certificate generation. When false, students cannot generate/download certificates from the platform.';
COMMENT ON COLUMN organizations.certificates_enabled
IS 'Enable/disable built-in certificate generation. When false, students cannot generate/download certificates from the platform.';
+2 -1
View File
@@ -161,7 +161,8 @@ async fn main() {
])
.expose_headers([header::CONTENT_LENGTH, header::CONTENT_TYPE, header::CONTENT_RANGE, header::ACCEPT_RANGES]);
use tower_governor::{GovernorConfigBuilder, GovernorLayer};
use tower_governor::governor::GovernorConfigBuilder;
use tower_governor::GovernorLayer;
use std::sync::Arc;
let governor_conf = Arc::new(
+2 -1
View File
@@ -119,7 +119,8 @@ async fn main() {
])
.expose_headers([header::CONTENT_LENGTH, header::CONTENT_TYPE]);
use tower_governor::{GovernorConfigBuilder, GovernorLayer};
use tower_governor::governor::GovernorConfigBuilder;
use tower_governor::GovernorLayer;
use std::sync::Arc;
let governor_conf = Arc::new(