From c723f150a9035380f2de39ad4dc07db2ded41a12 Mon Sep 17 00:00:00 2001 From: Kevin Pfeifer Date: Mon, 19 Oct 2026 11:20:48 +0200 Subject: [PATCH] add docs for ORM alias change --- docs/en/appendices/5-5-migration-guide.md | 13 +++++++++++++ 1 file changed, 13 insertions(+) diff --git a/docs/en/appendices/5-5-migration-guide.md b/docs/en/appendices/5-5-migration-guide.md index edd9ac908c..067170a4d4 100644 --- a/docs/en/appendices/5-5-migration-guide.md +++ b/docs/en/appendices/5-5-migration-guide.md @@ -20,6 +20,19 @@ bin/cake upgrade rector --rules cakephp55 - `Postgres` driver does not replace `FunctionsBuilder::concat()` expressions with `||` operations. +### ORM + +- Joined association fields and contained association conditions now use the + association name when registering column types. When the association name + differs from the target table alias, such as when using `targetTable` or + calling `Table::setAlias()`, fields such as datetime columns are now correctly + converted to their PHP types instead of remaining strings. +- `Cake\ORM\Query\CommonQueryTrait::addDefaultTypes()` now accepts an optional + second parameter, `?string $alias = null`, to register column types under a + specific alias. It defaults to the table alias. Query subclasses overriding + this method must add the optional parameter to their signature and pass it + through when calling `parent::addDefaultTypes()`. + ## Deprecations Coming soon