Epic #84729

Epic #84726: Initiative: URL Routing Integration / Site Handling

Epic #84728: Introduce speaking URLs for pages

Implement "slug" handling for pages and other records

Added by Benni Mack over 1 year ago. Updated 11 months ago.

Status:
Closed
Priority:
Should have
Assignee:
Category:
Link Handling, Site Handling & Routing
Target version:
Start date:
2018-08-23
Due date:
% Done:

100%

Sprint Focus:

Description

1. Create a new pages DB field "slug" ("URL path")

2. Create a new TCA type "type=slug"
- FormEngine: renders an input field and validates against URI schemes (JS validation), prepends the current / configured site to get the full URL
- Also Consider (Copy 1) in pages etc. so they get a "-1" and not a "-copy1"
- Validate for "Uniqueness" on save (or before?)
- TCA type "slug":
type = 'slug'
config [
'valueFields' => ['a-field-from-the-same-table', 'another-field'], - special key "site-rootline"
'fieldSeparator' => '/' => (so you could do /year/month/title/uid')
'custom' => Userfunc?
]

Open topics:
- discuss if slugs always need a prepending or a appending slash?
- Should we still allow ?id=123 ?

3. Create a CLI command to create slugs for pages (or all TCA tables) - allow to migrate from realurl?
4. Create an upgrade wizard that does the same
5. Ensure that all pages within a site have a slug - possible?
6. Handle things like "moving a page to a different site"


Subtasks

Task #85937: Generate default slug for entities not being submitted via FormEngineClosed

Task #85938: Handle renaming of "base" property of a siteRejected

Bug #85957: Pages on root level cannot be created nowClosedBenni Mack

Bug #86073: Create url segment if localizing pageRejected

Bug #86074: Properly create slug if adding new pages via FormEngineClosed

Task #86077: Add recreate button to slug fieldClosed

Associated revisions

Revision 7df267c8 (diff)
Added by Benni Mack 12 months ago

[FEATURE] Add a new TCA type "slug"

A new TCA type "slug" is added, which allows to generate a part of a URL
which can later be used for adding URL segments to any kind of record.

The new slug TCA type will be added to the pages database table separately
to fill a page with the rootline "Home => Products => My Product" with
"/products/my-product/details/" into the slug field when creating
a subpage "Details" under "My Product".

Once the slug field is added when persisting the record, changing a title
(like the page title) will not modify the slug anymore, but instead this
has to be modified separately.

Next steps:
- Add the TCA type "slug" to pages table
- Introduce an upgrade wizard for that pages table
- Improve FormEngine via AJAX validation of "uniqueInSite" for slugs
- Implement slug resolving for pages.

Resolves: #84729
Releases: master
Change-Id: I079267f42308f40da71ab4765ba7e0251e79f736
Reviewed-on: https://review.typo3.org/56889
Tested-by: TYPO3com <>
Reviewed-by: Oliver Hader <>
Tested-by: Oliver Hader <>
Reviewed-by: Christian Kuhn <>
Tested-by: Christian Kuhn <>

History

#1 Updated by Gerrit Code Review over 1 year ago

  • Status changed from New to Under Review

Patch set 2 for branch master of project Packages/TYPO3.CMS has been pushed to the review server.
It is available at https://review.typo3.org/56889

#2 Updated by Gerrit Code Review over 1 year ago

Patch set 3 for branch master of project Packages/TYPO3.CMS has been pushed to the review server.
It is available at https://review.typo3.org/56889

#3 Updated by Gerrit Code Review over 1 year ago

Patch set 4 for branch master of project Packages/TYPO3.CMS has been pushed to the review server.
It is available at https://review.typo3.org/56889

#4 Updated by Gerrit Code Review about 1 year ago

Patch set 5 for branch master of project Packages/TYPO3.CMS has been pushed to the review server.
It is available at https://review.typo3.org/56889

#5 Updated by Gerrit Code Review about 1 year ago

Patch set 6 for branch master of project Packages/TYPO3.CMS has been pushed to the review server.
It is available at https://review.typo3.org/56889

#6 Updated by Gerrit Code Review about 1 year ago

Patch set 7 for branch master of project Packages/TYPO3.CMS has been pushed to the review server.
It is available at https://review.typo3.org/56889

#7 Updated by Gerrit Code Review about 1 year ago

Patch set 8 for branch master of project Packages/TYPO3.CMS has been pushed to the review server.
It is available at https://review.typo3.org/56889

#8 Updated by Benni Mack about 1 year ago

  • Target version changed from 9.3 to 9.4

#9 Updated by Gerrit Code Review about 1 year ago

Patch set 9 for branch master of project Packages/TYPO3.CMS has been pushed to the review server.
It is available at https://review.typo3.org/56889

#10 Updated by Gerrit Code Review 12 months ago

Patch set 10 for branch master of project Packages/TYPO3.CMS has been pushed to the review server.
It is available at https://review.typo3.org/56889

#11 Updated by Gerrit Code Review 12 months ago

Patch set 11 for branch master of project Packages/TYPO3.CMS has been pushed to the review server.
It is available at https://review.typo3.org/56889

#12 Updated by Gerrit Code Review 12 months ago

Patch set 12 for branch master of project Packages/TYPO3.CMS has been pushed to the review server.
It is available at https://review.typo3.org/56889

#13 Updated by Gerrit Code Review 12 months ago

Patch set 13 for branch master of project Packages/TYPO3.CMS has been pushed to the review server.
It is available at https://review.typo3.org/56889

#14 Updated by Gerrit Code Review 12 months ago

Patch set 14 for branch master of project Packages/TYPO3.CMS has been pushed to the review server.
It is available at https://review.typo3.org/56889

#15 Updated by Gerrit Code Review 12 months ago

Patch set 15 for branch master of project Packages/TYPO3.CMS has been pushed to the review server.
It is available at https://review.typo3.org/56889

#16 Updated by Gerrit Code Review 12 months ago

Patch set 16 for branch master of project Packages/TYPO3.CMS has been pushed to the review server.
It is available at https://review.typo3.org/56889

#17 Updated by Gerrit Code Review 12 months ago

Patch set 17 for branch master of project Packages/TYPO3.CMS has been pushed to the review server.
It is available at https://review.typo3.org/56889

#18 Updated by Gerrit Code Review 12 months ago

Patch set 18 for branch master of project Packages/TYPO3.CMS has been pushed to the review server.
It is available at https://review.typo3.org/56889

#19 Updated by Gerrit Code Review 12 months ago

Patch set 19 for branch master of project Packages/TYPO3.CMS has been pushed to the review server.
It is available at https://review.typo3.org/56889

#20 Updated by Gerrit Code Review 12 months ago

Patch set 20 for branch master of project Packages/TYPO3.CMS has been pushed to the review server.
It is available at https://review.typo3.org/56889

#21 Updated by Gerrit Code Review 12 months ago

Patch set 21 for branch master of project Packages/TYPO3.CMS has been pushed to the review server.
It is available at https://review.typo3.org/56889

#22 Updated by Gerrit Code Review 12 months ago

Patch set 22 for branch master of project Packages/TYPO3.CMS has been pushed to the review server.
It is available at https://review.typo3.org/56889

#23 Updated by Gerrit Code Review 12 months ago

Patch set 23 for branch master of project Packages/TYPO3.CMS has been pushed to the review server.
It is available at https://review.typo3.org/56889

#24 Updated by Gerrit Code Review 12 months ago

Patch set 24 for branch master of project Packages/TYPO3.CMS has been pushed to the review server.
It is available at https://review.typo3.org/56889

#25 Updated by Gerrit Code Review 12 months ago

Patch set 25 for branch master of project Packages/TYPO3.CMS has been pushed to the review server.
It is available at https://review.typo3.org/56889

#26 Updated by Gerrit Code Review 12 months ago

Patch set 26 for branch master of project Packages/TYPO3.CMS has been pushed to the review server.
It is available at https://review.typo3.org/56889

#27 Updated by Gerrit Code Review 12 months ago

Patch set 27 for branch master of project Packages/TYPO3.CMS has been pushed to the review server.
It is available at https://review.typo3.org/56889

#28 Updated by Benni Mack 12 months ago

  • Status changed from Under Review to Resolved
  • % Done changed from 0 to 100

#29 Updated by Christian Kuhn 12 months ago

  • Related to Bug #86073: Create url segment if localizing page added

#30 Updated by Christian Kuhn 12 months ago

  • Related to deleted (Bug #86073: Create url segment if localizing page)

#31 Updated by David Bruchmann 11 months ago

Benni Mack wrote:

Applied in changeset 7df267c885f4e7f065c36423faebf761d4194cff.

In line 44 of SlugHelperTest is written "'strig tags' => [", is "strig" correct?
I'd suppose it shall be "string" ...

#32 Updated by Benni Mack 11 months ago

  • Status changed from Resolved to Closed

Also available in: Atom PDF