Project

General

Profile

Actions

Bug #88046

closed

RelationHandler does not respect deleted elements

Added by Robert Vock about 5 years ago. Updated about 4 years ago.

Status:
Closed
Priority:
Should have
Assignee:
-
Category:
DataHandler aka TCEmain
Target version:
-
Start date:
2019-04-01
Due date:
% Done:

0%

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

Description

The Database RelationHandler does not respect deleted elements, because it removes all QueryRestrictions:

RelationHandler.php:493
RelationHandler.php:528
RelationHandler.php:652

In one of our installations, this leads to an error in workspace. We have Delete-Placeholders which are deleted (??), so t3ver_state=2 and deleted=1 but those records still do not appear at some places. Our example is an image which was deleted in the workspace and somehow restored (the DELETE-Placeholder has deleted=1). But the image still does not appear as a Thumbnail in the Backend Page View.


Related issues 2 (0 open2 closed)

Related to TYPO3 Core - Bug #88503: Delete placeholders are not considered in FormEngine TcaInline view anymoreClosed2019-06-06

Actions
Related to TYPO3 Core - Bug #88144: TcaGroup does not respect deleted elements in a workspaceClosed2019-04-14

Actions
Actions #1

Updated by Robert Vock about 5 years ago

This might be fixed with #88144

I need to check if I can reproduce this bug, when I am back at work.

Actions #2

Updated by Susanne Moog about 5 years ago

  • Status changed from New to Needs Feedback

Setting status to "needs feedback" until you checked.

Actions #3

Updated by Susanne Moog about 5 years ago

  • Category set to DataHandler aka TCEmain
Actions #4

Updated by Oliver Hader almost 5 years ago

Can you please describe in which scenario this appears? RelationHandler is used in multiple different places used to retrieve (basically) live elements in correct sorting order:

  • DataHandler processing (needs view on live elements and versioned elements)
  • FormEngine used to visualize current versioning state (having to take care of delete placeholders in FormEngine currently - works in v8, regression in v9 currently)
  • Frontend via "whatever" (TypoScript, Extbase, PageRepository, ...)

PlainDataResolver is created in RelationHandler like this

    protected function getResolver($tableName, array $ids, array $sortingStatement = null)
    {
        /** @var PlainDataResolver $resolver */
        $resolver = GeneralUtility::makeInstance(
            PlainDataResolver::class,
            $tableName,
            $ids,
            $sortingStatement
        );
        $resolver->setWorkspaceId($this->getWorkspaceId());
        $resolver->setKeepDeletePlaceholder(true);
        $resolver->setKeepLiveIds($this->useLiveReferenceIds);
        return $resolver;
    }

Setting setKeepDeletePlaceholder might be context specific (setting it to true won't remove delete placeholders - required for some of the scenarios mentioned above)

Actions #5

Updated by Oliver Hader almost 5 years ago

  • Related to Bug #88503: Delete placeholders are not considered in FormEngine TcaInline view anymore added
Actions #6

Updated by Benni Mack over 4 years ago

  • Related to Bug #88144: TcaGroup does not respect deleted elements in a workspace added
Actions #7

Updated by Susanne Moog about 4 years ago

  • Status changed from Needs Feedback to Closed

See explanation above, no feedback for months now - I'm going to close the issue here, please report if this pops up again.

Actions

Also available in: Atom PDF