Bug #89939
closedEnabling/disabling backend users via context menu has no effect
100%
Description
It is not possible to enable or disable a TYPO3 Backend user via context menu.
Technical analysis
Context menu sends the following command to disable backend user: /typo3/index.php?route=%2Frecord%2Fcommit&token=xxx&data[be_users][2][hidden]=1&prErr=1&redirect=%2Ftypo3%2Findex.php%3FM%3Dsystem_BeuserTxBeuser%26moduleToken%3Dyyy
The problem here is data[be_users][2][hidden]
part, which is constructed in ContextMenuActions.disableRecord
function of EXT:backend/Resources/Public/JavaScript/ContextMenuActions.js
Unlike all other tables, be_users
table uses disable
field instead of hidden
. Thus the call from context menu has no effect.
Interestingly the enable/disable button on the right of the user module send the following command: /typo3/index.php?route=%2Frecord%2Fcommit&token=xxx&prErr=1&uPT=1&redirect=%2Ftypo3%2Findex.php%3FM%3Dsystem_BeuserTxBeuser%26moduleToken%3Dyyy&data%5Bbe_users%5D%5B2%5D%5Bdisable%5D=1
In the List module the enable/disable button sends http://easyweb.ddev.site/typo3/index.php?ajaxID=%2Fajax%2Frecord%2Fprocess&ajaxToken=xxx&data[be_users][2][disable]=0
Updated by Oliver Bartsch almost 5 years ago
Hi,
this only affects 8.7 or should this also be check on 9.5 and master?
Updated by Dmitry Dulepov almost 5 years ago
I wrote the lowest version where I detected it. I believe nothing changed in 9/10 in this area, so it must be the problem for 9/10 too. I guess the bug exists since TYPO3 3.x.
Updated by Benni Mack almost 5 years ago
- Status changed from New to Accepted
HI dmitry!
thanks a lot for your report and your investigation. This is indeed a stupid bug (which I believe is there since forever), should be addressed properly!
Updated by Dmitry Dulepov almost 5 years ago
Benni, should we unify this table with all other tables and use hidden
field? This will a breaking change but it is still doable for v10. Not for other versions though.
Locally (v8/v9) I fixed it by a DataHandler by simply checking for be_users
table and disable
field and set hidden
instead of disable
in the table. This could be also a solution (non-breaking), for all supported versions. I would actually prefer this non-breaking solution.
What do you think?
Updated by Benni Mack almost 5 years ago
Dmitry Dulepov wrote:
What do you think?
I think we should go with a non-breaking solution, there are lots of other TCA tables that use a different naming...
Updated by Dmitry Dulepov almost 5 years ago
Ok, I'll see if I have time next week to make a patch.
Updated by Gerrit Code Review almost 5 years ago
- Status changed from Accepted to Under Review
Patch set 1 for branch master of project Packages/TYPO3.CMS has been pushed to the review server.
It is available at https://review.typo3.org/c/Packages/TYPO3.CMS/+/62879
Updated by Gerrit Code Review almost 5 years ago
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/c/Packages/TYPO3.CMS/+/62879
Updated by Gerrit Code Review almost 5 years 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/c/Packages/TYPO3.CMS/+/62879
Updated by Gerrit Code Review almost 5 years 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/c/Packages/TYPO3.CMS/+/62879
Updated by Gerrit Code Review almost 5 years 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/c/Packages/TYPO3.CMS/+/62879
Updated by Gerrit Code Review almost 5 years ago
Patch set 1 for branch master of project Packages/TYPO3.CMS has been pushed to the review server.
It is available at https://review.typo3.org/c/Packages/TYPO3.CMS/+/62953
Updated by Gerrit Code Review almost 5 years ago
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/c/Packages/TYPO3.CMS/+/62953
Updated by Gerrit Code Review almost 5 years ago
Patch set 1 for branch 9.5 of project Packages/TYPO3.CMS has been pushed to the review server.
It is available at https://review.typo3.org/c/Packages/TYPO3.CMS/+/63028
Updated by Benni Mack almost 5 years ago
- Status changed from Under Review to Resolved
- % Done changed from 0 to 100
Applied in changeset bd2c592125bede68069fdb986d573479e55a97b1.