Bug #82970

Page tree reload is triggered to early

Added by Nicole Cordes over 3 years ago. Updated over 2 years ago.

Status:
Closed
Priority:
Should have
Assignee:
-
Category:
Pagetree
Start date:
2017-11-10
Due date:
% Done:

100%

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

Description

Given:

- a page with many records and references to sys_categories
- delete that page by using the context menu

Expectation:

- delete process is started
- after everything is done (can take longer because of relations und sys_reference changes), the tree should be reloaded, the page should be removed

Actual:

- the page tree is reloaded immediately, as the page record is not yet deleted the page is still visible


Related issues

Related to TYPO3 Core - Bug #84294: Pagetree reload every time after delete, pasteInto, disable and enableClosedAndreas Fernandez2018-03-15

Actions
#1

Updated by Tymoteusz Motylewski over 3 years ago

this is caused probably by the
.defer(500) in the ContextMenuActions.js

currently is (in v8):

top.TYPO3.Backend.ContentContainer.setUrl(
     top.TYPO3.settings.RecordCommit.moduleUrl + ....
    );
      if (table === 'pages' && top.TYPO3.Backend.NavigationContainer.PageTree) {
        top.TYPO3.Backend.NavigationContainer.PageTree.refreshTree.defer(500);
     }

But should be (this is already fixed in 9)
top.TYPO3.Backend.ContentContainer.setUrl(
      top.TYPO3.settings.RecordCommit.moduleUrl + '&redirect=' + ContextMenuActions.getReturnUrl() ...
         ).done(function () {
      if (table === 'pages' && top.TYPO3.Backend.NavigationContainer.PageTree) {
           top.TYPO3.Backend.NavigationContainer.PageTree.refreshTree();
         }
      });

It was changed in 9 in here:
https://review.typo3.org/#/c/51594/113/typo3/sysext/backend/Resources/Public/JavaScript/ContextMenuActions.js

#2

Updated by Gerrit Code Review over 3 years ago

  • Status changed from New to Under Review

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

#3

Updated by Gerrit Code Review over 3 years ago

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

#4

Updated by Tymoteusz Motylewski over 3 years ago

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

Updated by Benjamin Kluge about 3 years ago

Tymoteusz Motylewski wrote:

Applied in changeset 17136ee9f2bfc29268b1676a56f96eb6d97b59aa.

This patch reloads the page tree on every load event. To reproduce disable a page and then edit a content element. The Page tree reloads on every button click on the main frame. The load event should be removed after execution.

#6

Updated by Benjamin Kluge about 3 years ago

i opened a new bug #84294 and committing now a patch

#7

Updated by Andreas Fernandez about 3 years ago

  • Related to Bug #84294: Pagetree reload every time after delete, pasteInto, disable and enable added
#8

Updated by Benni Mack over 2 years ago

  • Status changed from Resolved to Closed

Also available in: Atom PDF