odoo/odoo#277992

Created by fw-bot
Merged at 6bc721ecfd9184326725c6116ce7cc7c64eca61d

Statuses:

label
odoo-dev:saas-19.3-19.0-redirect-slug-jke-549297-fw
head
9fd0fd4fd09c8467e3a8c9a36d62dcec5aa9d38c
merged
2 days ago by Accounting, Habib Ayob (ayh)
odoo/odoo
19.0 #276515
saas-19.1 #277909
saas-19.2 #277923
saas-19.3 #277992
saas-19.4 #278045 missing r+
master

[IMP] website: support unslugified url for redirect

In some cases, you want to redirect a record with ModelConverter, whatever the slug value.

E.g. /shop/old-name-1 => /shop/alt-product-10
/shop/new-name-1 => /shop/alt-product-10
/fr/shop/nom-1 => /shop/alternatif-product-10
/de/shop/produktname-1 => /de/shop/produktname-10

In this case, adding only one redirect /shop/1 => /shop/10 covers the need to support all the translated slugs and the old name that we remember.

On odoo.com we have this need e.g. when we archive a Job Position, we create a redirect, but in some cases the job position is translated or has been renamed and we don't remember all the old urls. With this change, we will be able to redirect all old urls, translated urls, ... with only one redirect.

/jobs/10 -> /explore-more-opportunities-with-us

task-6391567

Forward-Port-Of: #276515