Feature #14472
closedRanges in ID lists
100%
Description
I would like to write
temp.menu.excludeUidList = 23-28,30,100-102
instead of
temp.menu.excludeUidList = 23,24,25,26,27,28,30,100,101,1002
the same applies for e.g. [PIDinRootline] and other occurences of such lists...
(issue imported from #M646)
Files
Updated by Sacha Vorbeck over 19 years ago
I would like to add that I`d love to have stdWrap properties for e. g. excludeUidList.. This might be a solution for the original problem as well.
Updated by Martin Kutschker over 19 years ago
I've attached a small helper for t3lib_div that may come in handy for all kind of lists (eg HMENU special=list special.value=1,2,3,4,...)
Updated by Ernesto Baschny almost 19 years ago
Yes, also nice would be resolving aliases in "special.value" and other uid-lists.
It makes no sense to me to hard-code "uids" in TypoScript. If I export/import the page structure, the ids might be different and I have to adapt the uidlists. Aliases are there for this, aren't they? "home", "servicemenu" etc.
Updated by Ingmar Schlecht almost 19 years ago
Ernesto Baschny wrote:
Yes, also nice would be resolving aliases in "special.value" and other uid-lists.
This would be fantastic! Could you write a patch for it?
cheers,
Ingmar
Updated by Martin Kutschker almost 19 years ago
To be consistent resolving of aliases should be done in all UID properties, not only lists, eg in pi_base.
Updated by Ernesto Baschny almost 19 years ago
I don't think pi_base should be doing alias translation or any other "magic" on uid-lists. If a extension developer needs this functionality, he can call getPageIdFromAlias() himself (which would be nice thing e.g. in tt_news for all those page-id settings)
But with TypoScript there is currently no way to have this done if PHP doesn't do it. So I think we should just find TS-properties where the user is expected to pass uid's or uid-lists and make them all "alias" and maybe "range" compatible.
The places that I've found so far:
>select.uidInList>select.pidInList
->typolink.parameter (already doing alias-conversion)
- config.MP_mapRootPoints (allows "root" magic word, so we shouldn't be trying to do alias conversions here
- config.typolinkLinkAccessRestrictedPages (allows "NONE" magic word, which cannot be an alias (upper-case). But can we do alias-checking in "config." already?)
- HMENU.special.value
- HMENU.excludeUidList
- HMENU.alwaysActivePIDlist
- HMENU.special.[item].uid (in special=browse)
Ok, I haven't found any other.
And finally we need a stdWrap function to convert an alias to an uid, so that we can use this functionality on any other property that is already being stdWrapped. Imagine that tt_news passes $conf['backPid.'] through stdWrap:
plugin.tt_news.backPid = newsarchive
plugin.tt_news.backPid.asPidList = 1
which would instruct stdWrap to consider the property as a list of uids and it would then translate aliases, translate ranges, etc and return a proper comma-separated list of UIDs back to the caller.
Updated by Mr. Hudson over 13 years ago
Patch set 1 of change I6d25e0ccac47218445713f3b491a2109188ca579 has been pushed to the review server.
It is available at http://review.typo3.org/2585
Updated by Mr. Hudson over 13 years ago
Patch set 2 of change I6d25e0ccac47218445713f3b491a2109188ca579 has been pushed to the review server.
It is available at http://review.typo3.org/2585
Updated by Mr. Hudson over 13 years ago
Patch set 3 of change I6d25e0ccac47218445713f3b491a2109188ca579 has been pushed to the review server.
It is available at http://review.typo3.org/2585
Updated by Mr. Hudson over 13 years ago
Patch set 4 of change I6d25e0ccac47218445713f3b491a2109188ca579 has been pushed to the review server.
It is available at http://review.typo3.org/2585
Updated by Xavier Perseguers over 13 years ago
- Status changed from Accepted to Resolved
- Target version changed from 0 to 4.6.0-beta1
- % Done changed from 0 to 100
- TYPO3 Version changed from 3.7.0 to 4.6
Change has been successfully cherry-picked as d83d13911efa1296c98634eccc0fd60f17493588.
Updated by Xavier Perseguers over 12 years ago
- Status changed from Resolved to Closed
Updated by Ernesto Baschny over 11 years ago
- Target version deleted (
4.6.0-beta1)