Project

General

Profile

Actions

Bug #34636

closed

option.disableDelete does not disable deletion

Added by Bernd Wilke about 12 years ago. Updated over 5 years ago.

Status:
Closed
Priority:
Should have
Assignee:
-
Category:
Backend User Interface
Target version:
-
Start date:
2012-03-07
Due date:
% Done:

100%

Estimated time:
TYPO3 Version:
6.2
PHP Version:
Tags:
Complexity:
easy
Is Regression:
No
Sprint Focus:
On Location Sprint

Description

On our last UG-meeting we discovered a nice option for user-/page-TSconfig:
option.disableDelete
which 'Disables the "Delete" button in TCEFORMs.' [¹].

but instead of realy disabling the user to delete a record it only removed the delete-icon from the headarea (beside the store-icons)

the user is still able to delete records at 3 (maybe 4) different places:
list view with 'Extended view',
list view: contextmenu of record
page view: record head (visible on mouseover),
page view_ contextmenu of record (same as list view?)

[¹] http://typo3.org/documentation/document-library/core-documentation/doc_core_tsconfig/4.6.0/view/1/4/

It does not work in 4.5 and 4.6.
searching the net it seems to be broken around 4.3


Files

PageLayoutView.php.patch (3.91 KB) PageLayoutView.php.patch Teamgeist Medien, 2016-06-21 11:04
DatabaseRecordList.php.patch (1.69 KB) DatabaseRecordList.php.patch Teamgeist Medien, 2016-06-21 11:04

Related issues 1 (1 open0 closed)

Related to TYPO3 Core - Feature #77740: User-specific detailled per-table action permissions (create,delete,edit)New2016-09-01

Actions
Actions #1

Updated by Tolleiv Nietsch about 12 years ago

  • Status changed from New to Accepted
  • Complexity set to easy
Actions #2

Updated by Fabian over 11 years ago

I tried in 4.5.22 and this is still not working.

Complexity easy ?

It's been 10 Months :)

Actions #3

Updated by Ludwig Rafelsberger over 10 years ago

Seems not to work in 6.1.5 either. I'd really wish this functionality was removed from TSconfig documentation as long as it's broken, instead of wasting our users time trying to get that feature working.

Actions #4

Updated by Peter Kraume over 9 years ago

Too bad that there is still no solution for this issue.

Actions #5

Updated by Riccardo De Contardi almost 9 years ago

  • TYPO3 Version changed from 4.5 to 6.2
  • Is Regression set to No

as far as I can see it is still present in 6.2.12.

Actions #6

Updated by Viktor Livakivskyi almost 9 years ago

I would suggest not to remove this TSconfig option, but rather make it work =)

We have a case now, that editors should be able to just edit records - not create new or delete existing ones.
Forbidding of creation is done via mod.web_list.deniedNewTables.
But there is no clean solution to disble deletion. We use now hacky workaround, which consists of option.disableDelete, contextMenu.[key].disableItems = delete and disabling "Extended view" for an editor. And this is really bad solution.

Actions #7

Updated by Riccardo De Contardi over 8 years ago

the bug is still present in TYPO3 7.5-dev (latest master)

Actions #8

Updated by Andre Koller about 8 years ago

Problem still exists in Typo3 v7.6.4

Actions #9

Updated by Salvatore Eckel almost 8 years ago

And still exists in TYPO3 v6.2.22

Updated by Teamgeist Medien almost 8 years ago

The problem still exists.

At several places this option won't be checked anymore. I've created two patch files for DatabaseRecordList.php and PageLayoutView.php which will prevent the delete button to be displayed in the page and the list module. Due to lack of time this will only work for option.disableDelete = 1 and not option.[table].disableDelete, yet. But this can be implemented later easily.

Please notice that this will just prevent the buttons to be rendered. Maybe a user is able to delete records anyway if he finds out the URL to delete an item. Don't know if the moduleToken will prevent from such url-sniffing.

Still To Do:
  • Implement option.[table].disableDelete
  • Hide the delete buttons in context-menus
  • Check if url-sniffing is possible to delete records anyway

EDIT: This patch probably won't work in the list view when using gridelements which is overwriting the DatabaseRecordList with a Hook.

Greetings,
Paul Beck / Teamgeist Medien

Actions #11

Updated by Gerrit Code Review over 7 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/49678

Actions #12

Updated by Gerrit Code Review over 7 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/49678

Actions #13

Updated by Gerrit Code Review over 7 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/49678

Actions #14

Updated by Gerrit Code Review over 7 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/49678

Actions #15

Updated by Gerrit Code Review over 7 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/49678

Actions #16

Updated by Tymoteusz Motylewski over 7 years ago

  • Sprint Focus set to On Location Sprint
Actions #17

Updated by Anonymous over 7 years ago

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

Updated by Gerrit Code Review over 7 years ago

  • Status changed from Resolved to Under Review

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

Actions #19

Updated by Gerrit Code Review over 7 years ago

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

Actions #20

Updated by Gerrit Code Review over 7 years ago

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

Actions #21

Updated by Anonymous over 7 years ago

  • Status changed from Under Review to Resolved
Actions #22

Updated by Benni Mack over 5 years ago

  • Status changed from Resolved to Closed
Actions

Also available in: Atom PDF