Skip to content

refactor!: rename the ctype_id slice column to content_section_id - #6786

Merged
gharlan merged 2 commits into
6.xfrom
refactor/content-section-column
Oct 21, 2026
Merged

gharlan merged 2 commits into
6.xfrom
refactor/content-section-column

Conversation

@gharlan

@gharlan gharlan commented Oct 21, 2026

Copy link
Copy Markdown
Member

Renames the ctype_id column of rex_article_slice and rex_article_slice_history to content_section_id, in line with the content section terminology of 6.x (ArticleSlice::$contentSectionId, ContentSection). The full name is used rather than section_id because "section" is already taken by the backend panel (core/page/section.php), and the neighbouring columns are spelled out as well (article_id, language_id).

There is no migration — install() only describes the target state. Existing 6.x dev databases have to rename the column manually, otherwise install() adds the new column next to the old NOT NULL ctype_id and inserting slices fails:

ALTER TABLE rex_article_slice RENAME COLUMN ctype_id TO content_section_id;
ALTER TABLE rex_article_slice_history RENAME COLUMN ctype_id TO content_section_id;

The remaining ctype naming in PHP (StructureContext::$ctypeId, ArticleSlice::getFirstSliceForCtype(), the ctype request parameter, extension point params) follows in a separate PR.

Aligns the column of `rex_article_slice` and `rex_article_slice_history` with the content section terminology
(`ArticleSlice::$contentSectionId`). Existing 6.x dev databases have to rename the column manually.
@gharlan gharlan added this to the REDAXO 6.0 milestone Oct 21, 2026
@gharlan
gharlan merged commit fa458f9 into 6.x Oct 21, 2026
15 checks passed
@gharlan
gharlan deleted the refactor/content-section-column branch October 21, 2026 21:28
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Development

Successfully merging this pull request may close these issues.

2 participants