Skip to content
Snippets Groups Projects
Commit 3c266751 authored by Romain Derie's avatar Romain Derie
Browse files

[FIX] website: restore the seo_name field cleaning

Part of [1] was lost during the frontend>backend merge [2].
The SEO name field was not "slugified" anymore in JS, it led to 2
issues:
- Bad UX, one could type something and it would end up after save with
  something completely different
- 404/crash: as the generated URL in js (based on the seo name value)
  would not be slugified, it would redirect to that URL, which would not
  be found as the record URL in python would be slugified. There would
  be an URL mismatch between the python route and the JS redirect value.
  This could still somehow happen as the JS and PY slug are not doing
  the exact same things but at least this will restore what we had
  before and mitigate the issue.

Step to reproduce:
- Go to a blog post and open the SEO dialog
- In the custom URL input, type "créé"
- You will be redirected to `/@/blog/travel-1/créé-1`
This will be a 404 page, as the correct URL is now
`/@/blog/travel-1/cree-1`.

[1]: https://github.com/odoo/odoo/commit/c387ec19b4648ae52bf3210253febd7825745627
[2]: https://github.com/odoo/odoo/commit/31cc10b91dc7762e23b4bde9b945be0c4ce3fe3b

Part-of: odoo/odoo#104908
parent 99383897
No related branches found
No related tags found
Loading
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment