diff --git a/README.md b/README.md index 076b5cc..7f867d9 100644 --- a/README.md +++ b/README.md @@ -88,6 +88,20 @@ ALTER TABLE users ADD COLUMN locked_until DATETIME NULL; ``` +Also needed for the photo reposition/zoom tool (`photo_focal_x`/`photo_focal_y`/`photo_zoom` on both `sessions` and `novena_groups` — defaults reproduce today's centered, no-zoom crop, so this is safe to run any time): + +```sql +ALTER TABLE sessions + ADD COLUMN photo_focal_x FLOAT NOT NULL DEFAULT 50, + ADD COLUMN photo_focal_y FLOAT NOT NULL DEFAULT 50, + ADD COLUMN photo_zoom FLOAT NOT NULL DEFAULT 1; + +ALTER TABLE novena_groups + ADD COLUMN photo_focal_x FLOAT NOT NULL DEFAULT 50, + ADD COLUMN photo_focal_y FLOAT NOT NULL DEFAULT 50, + ADD COLUMN photo_zoom FLOAT NOT NULL DEFAULT 1; +``` + ## Deployment Checklist - [ ] `config/db.php` filled in with production credentials diff --git a/admin/builder.php b/admin/builder.php index 2b1f9f3..d3f9ff7 100644 --- a/admin/builder.php +++ b/admin/builder.php @@ -7,6 +7,7 @@ require_once __DIR__ . '/../config/db.php'; require_once __DIR__ . '/../includes/auth.php'; require_once __DIR__ . '/../includes/csrf.php'; +require_once __DIR__ . '/../includes/photo.php'; require_role('superuser'); @@ -73,6 +74,7 @@ $page_title = $session ? 'Edit: ' . htmlspecialchars($session['name']) : 'Rosary