Project

General

Profile

Actions

Bug #88144

closed

TcaGroup does not respect deleted elements in a workspace

Added by Robert Vock about 5 years ago. Updated over 1 year ago.

Status:
Closed
Priority:
Should have
Assignee:
-
Category:
Workspaces
Target version:
-
Start date:
2019-04-14
Due date:
% Done:

100%

Estimated time:
TYPO3 Version:
9
PHP Version:
Tags:
Complexity:
Is Regression:
Sprint Focus:

Description

If you delete elements in a workspace, which are used within a group field, those deleted elements still show up in the workspace.

1. To test it, you can generate two sys_file_collections. Add those to one content element of CType uploads.
2. Now change to a workspace and delete one of the sys_file_collections.
3. Go back to editing the content element and see that there are still two file collections.

I've attached a testcase for this problem.


Files

tca-group-test.patch (5.7 KB) tca-group-test.patch Robert Vock, 2019-04-14 13:40
deleted-in-workspace.png (34.5 KB) deleted-in-workspace.png Robert Vock, 2019-04-14 13:41

Related issues 1 (0 open1 closed)

Related to TYPO3 Core - Bug #88046: RelationHandler does not respect deleted elementsClosed2019-04-01

Actions
Actions #1

Updated by Robert Vock about 5 years ago

I think the correct solution would be to remove the deletePlaceholders after getting the items from DB:
TcaGroup.php:86

$relationHandler->getFromDB();
$relationHandler->processDeletePlaceholder(); // <-- NEW
$relations = $relationHandler->getResolvedItemArray();

But it also appears that the RelationHandler does not correctly purges delete placeholders:
RelationHandler.php:1565

$queryBuilder->expr()->neq(
    't3ver_wsid',
    $queryBuilder->createNamedParameter(
        $this->getWorkspaceId(),
        \PDO::PARAM_INT
    )
),

It removes all elements which are deleted in OTHER workspaces, not in the current. If I am correct, the neq should be a eq.

Actions #2

Updated by Gerrit Code Review about 5 years ago

  • Status changed from New 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/+/60468

Actions #3

Updated by Gerrit Code Review about 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/+/60468

Actions #4

Updated by Gerrit Code Review about 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/+/60468

Actions #5

Updated by Benni Mack over 4 years ago

  • Related to Bug #88046: RelationHandler does not respect deleted elements added
Actions #6

Updated by Gerrit Code Review over 4 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/+/60468

Actions #7

Updated by Gerrit Code Review over 4 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/+/60468

Actions #8

Updated by Gerrit Code Review over 4 years 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/c/Packages/TYPO3.CMS/+/60468

Actions #9

Updated by Gerrit Code Review over 4 years 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/c/Packages/TYPO3.CMS/+/60468

Actions #10

Updated by Gerrit Code Review almost 4 years 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/c/Packages/TYPO3.CMS/+/60468

Actions #11

Updated by Gerrit Code Review almost 4 years 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/c/Packages/TYPO3.CMS/+/60468

Actions #12

Updated by Gerrit Code Review over 2 years 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/c/Packages/TYPO3.CMS/+/60468

Actions #13

Updated by Gerrit Code Review over 2 years ago

Patch set 1 for branch 10.4 of project Packages/TYPO3.CMS has been pushed to the review server.
It is available at https://review.typo3.org/c/Packages/TYPO3.CMS/+/71929

Actions #14

Updated by Anonymous over 2 years ago

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

Updated by Benni Mack over 1 year ago

  • Status changed from Resolved to Closed
Actions

Also available in: Atom PDF