Project

General

Profile

Actions

Bug #57163

closed

Epic #57533: Pagetree epic

Pagetree unfold wrong page whith multiple mount points

Added by Alexander Stehlik over 10 years ago. Updated about 6 years ago.

Status:
Closed
Priority:
Should have
Assignee:
-
Category:
Pagetree
Target version:
-
Start date:
2014-03-21
Due date:
% Done:

100%

Estimated time:
TYPO3 Version:
6.2
PHP Version:
5.4
Tags:
Complexity:
Is Regression:
No
Sprint Focus:

Description

How to reproduce:

Create a pagetree:

  • Page 1
  • Page 1.1
  • Page 1.1.1

Create a user with two database mounts:

  • Page 1
  • Page 1.1

Now when you unfold Page 1 (and Page 1.1 gets visible as a child node) you get this strange behavior:

When you place your mouse over the Page 1.1 database mount page, the subpage of Page 1 will be highlighted.

When you unfold the Page 1.1 database mount, the page below Page 1 will be unfolded, not the one you clicked on.

The behavior of the child nodes of the Page 1.1 database mount is the same.

Things i've tried

I was looking at the ext:tree-node-id property and realized that it is the same for both nodes. This is why I set the mountpoint in the child nodes:

--- typo3/sysext/backend/Classes/Tree/Pagetree/DataProvider.php
+++ typo3/sysext/backend/Classes/Tree/Pagetree/DataProvider.php
@@ -155,6 +155,9 @@ class DataProvider extends \TYPO3\CMS\Backend\Tree\AbstractTreeDataProvider {
                                // must be calculated above getRecordWithWorkspaceOverlay,
                                // because the information is lost otherwise
                                $isMountPoint = $subpage['isMountPoint'] === TRUE;
+                               if ($isMountPoint && $mountPoint === 0) {
+                                       $mountPoint = (int)$subpage['uid'];
+                               }
                                $subpage = $this->getRecordWithWorkspaceOverlay($subpage['uid'], TRUE);
                                if (!$subpage) {
                                        continue;

This resulted in unique tree nodes, looking like this:

<div ext:tree-node-id="p2725-271d" class="x-tree-node-el x-unselectable x-tree-node-collapsed" unselectable="on" id="extdd-13">
...
</div>

But it did not help. Still the same behavior.

I also removed all custom code from typo3/js/extjs/components/pagetree/javascript/nodeui.js so that the native rendering of ExtJS is used but this did not help either.

No idea where to look next. Any help is appreciated.

Actions

Also available in: Atom PDF