Forums Feature Requests Thread

[New Feature] White-label email digest builder

Patrick Bass · May 24 · 24 · 1 Locked
[Deployed to Production]
🚀 OP May 24, 2026 7:52pm

Type: New Feature

Priority: P4

What: Let community admins customize the weekly digest email template: which sections to include, header image, CTA buttons, featured content selection. Currently the digest is code-driven with no admin customization.

Who benefits: Creators (brand control, engagement).

Why: Email digests are the primary re-engagement channel. Giving admins control increases their effectiveness.

Complexity: Medium


Patrick Bass
@mobieus

🚀 May 28, 2026 3:36pm

Status: Deployed in commit 541d3db2.

Built the full scope of the original request. Admins can now customise the weekly digest from /admin/email/digest with no code changes.

What admins can configure

  • Branding — header image URL (above the greeting), brand colour (drives the CTA background + accent links)
  • Greeting and sign-off — custom intro text (replaces the default "Here is your weekly roundup…") + custom outro text (appears above the CTA)
  • CTA button — text + URL (internal path like /forums, or absolute https://…)
  • Section toggles — 7 toggles to show/hide:
    • Your forums this week (per-recipient)
    • Featured threads (pin up to 3)
    • Top posts this week
    • Most active threads
    • New file uploads
    • Upcoming events
    • New members this week
  • Featured threads — comma-separated thread IDs (max 3), pinned at the top of every digest when the section is on
  • Email me a preview button — sends a test render to the admin's own inbox using current saved settings

Under the hood

  • New table digest_settings — single-row config (id = 1 enforced) per tenant. Migration applied to support, fort-smith-live, dev.
  • New model App\Models\DigestSettingsget(), save(array $fields), featuredIds().
  • New controller AdminEmailDigestControllershow(), save(), test(). All actions audit-logged.
  • Routes added to the /admin group: GET /email/digest, POST /email/digest/save, POST /email/digest/test.
  • Renderer templates/email/weekly-digest.php gates every section on $_show() with safe defaults (every original section defaults ON), adds the header-image / intro / outro / featured-threads / config-driven CTA blocks.
  • Sender bin/send-weekly-digest.php loads settings + featured-thread rows once at the top of the cron and passes them into every per-user payload — no per-user query overhead.

Backwards-compatible: any deployment that hasn't visited /admin/email/digest will get a row of defaults inserted on first read. Legacy callers that don't pass digestCfg still render the default digest layout because every $_show() defaults ON.

Live on all three tenants. Locking thread.


Patrick Bass
@mobieus

Log in or register to reply to this thread.