Hacktoberfest 2026: những issue maintainer đã đánh dấu cho tháng Mười, đang mở và phù hợp người mới. Xem issue Hacktoberfest

Document null page titles and the 422 on route generation without a title

Đang mở Phù hợp với người mới
#227 0 bình luận 0 reaction 0 người được giao Xem trên GitHub

Chưa có ai nhận issue này.

Đánh giá

Độ khó
2/5
Thời gian dự kiến
1-3 giờ
Mức phù hợp với người mới
70/100
Loại issue
Tài liệu
Độ rõ ràng
Đặc tả rõ ràng
Mức độ hoạt động
Sôi nổi
Công nghệ
php, sql
Lĩnh vực
api, database, documentation

Hướng nghiên cứu

Bắt đầu từ PR của bundle được liên kết components-web-app/api-components-bundle#440 để xác nhận hành vi: title mặc định là null trên Page và AbstractPageData, lỗi 422 từ POST /_/routes/generate, và các thay đổi trong CwaFixtureBuilder. Sau đó ghi lại các nội dung này vào tài liệu, bao gồm migration Doctrine và hai câu lệnh SQL UPDATE, kèm ghi chú dùng table_prefix đã cấu hình. Hoàn thành khi cả bốn phần đã được viết và SQL khớp với tên bảng mà bundle sử dụng.

Do mô hình lập chỉ mục viết ra từ nội dung của issue.

Mô tả

Bundle PR: components-web-app/api-components-bundle#440 (fixes components-web-app/api-components-bundle#439)

Please document the following.

A page's title defaults to null

A Page or page data (AbstractPageData) created without a title now stores and returns title: null. It used to be 'Unnamed Page'. Page data's title column is now nullable, as the page's already was. Front ends can tell an untitled page apart from a chosen title, so a page data with no title can fall back to its page template's title.

Route generation needs a title

POST /_/routes/generate for a page or page data with no title, or with a title that gives no slug (for example only punctuation), returns 422 with one violation on title: "A title is needed to generate a route." Nothing is created, and an existing route is not turned into a redirect. Before this change it generated /unnamed-page. Explicit route creation (POST /_/routes) is unaffected.

CwaFixtureBuilder: a page or page data with no route: and no title gets no route, top-level or nested. In an --append load, untitled page data with no route: is identified like withoutRoute() page data: it is created only with its template or parent.

Upgrade step

Generate and run a Doctrine migration. It makes _acb_abstract_page_data.title nullable. Then clear the old default:

UPDATE _acb_page SET title = NULL WHERE title = 'Unnamed Page';
UPDATE _acb_abstract_page_data SET title = NULL WHERE title = 'Unnamed Page';

Replace _acb_ with the configured table_prefix if it differs.

Ngôn ngữ chính
Vue
Star
0
Fork
0
Chỉ số merge pull request
Không có pull request nào được merge trong 30 ngày

Chuẩn bị môi trường

Dự án này không cung cấp dev container, Dockerfile hay hướng dẫn đóng góp, nên bạn cần tự thiết lập môi trường: hãy bắt đầu từ README và xem hướng dẫn đóng góp lần đầu của chúng tôi để biết các bước chung.

Bắt đầu từ đâu

  1. Đọc hết issue, rồi đọc hướng dẫn đóng góp của dự án.
  2. Bình luận trên issue rằng bạn sẽ nhận — tránh hai người làm cùng một việc.
  3. Fork repository và làm thay đổi trên một nhánh.
  4. Mở pull request có tham chiếu số hiệu của issue.

Issue khác của components-web-app/docs

Tất cả issue của components-web-app/docs

Issue tương tự

Thêm issue về Backend & API Design

Nhận issue mới trong hộp thư của bạn

Bản tóm tắt ngắn những issue GitHub phù hợp với người mới.