refactor(platform): make base template fully CMS-driven and platform-aware
Some checks failed
Some checks failed
Remove all hardcoded OMS-specific content from platform base template: nav links, contact info, brand name, and footer columns. Everything is now dynamic via platform model and CMS page queries. Wire up legal_pages context (privacy/terms) from database instead of hardcoded fallback. Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
This commit is contained in:
@@ -282,6 +282,7 @@ class ContentPageService:
|
||||
include_unpublished: bool = False,
|
||||
footer_only: bool = False,
|
||||
header_only: bool = False,
|
||||
legal_only: bool = False,
|
||||
) -> list[ContentPage]:
|
||||
"""
|
||||
List platform marketing pages.
|
||||
@@ -292,6 +293,7 @@ class ContentPageService:
|
||||
include_unpublished: Include draft pages
|
||||
footer_only: Only pages marked for footer display
|
||||
header_only: Only pages marked for header display
|
||||
legal_only: Only legal pages (privacy, terms) — not in header or footer nav
|
||||
|
||||
Returns:
|
||||
List of platform marketing ContentPage objects
|
||||
@@ -311,6 +313,9 @@ class ContentPageService:
|
||||
if header_only:
|
||||
filters.append(ContentPage.show_in_header == True)
|
||||
|
||||
if legal_only:
|
||||
filters.append(ContentPage.slug.in_(["privacy", "terms"]))
|
||||
|
||||
return (
|
||||
db.query(ContentPage)
|
||||
.filter(and_(*filters))
|
||||
|
||||
Reference in New Issue
Block a user