Project

General

Profile

Actions

Bug #22774

closed

Sorting missing in "template overview"

Added by Reinhard Führicht almost 14 years ago. Updated over 5 years ago.

Status:
Closed
Priority:
Should have
Assignee:
-
Category:
-
Target version:
-
Start date:
2010-05-31
Due date:
% Done:

100%

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

Description

The overview of all TS templates shows a tree like view listing all pages having a ts template on them. But this view doesn't sort the pages by "sorting" like in the pagetree. This results in a different order.

- Choose the module "Template".
- Click on the root page (PID: 0).
- Compare the order of pages in the page tree and in the overview shown on the right.

NOTE: You need to have various ts templates on different pages to see this properly.

(issue imported from #M14551)


Files

14551.diff (555 Bytes) 14551.diff Administrator Admin, 2010-05-31 14:36
template.png (109 KB) template.png Administrator Admin, 2010-05-31 15:37

Related issues 1 (0 open1 closed)

Has duplicate TYPO3 Core - Bug #21798: Templates in Web>Template on rootpage (overview) is in wrong orderClosedChristian Kuhn2009-12-04

Actions
Actions #1

Updated by Chris topher almost 14 years ago

Is this committed?

According to the thread in Core List it should be fixed with #21798; but I can't find any of these in ChangeLog...

Actions #2

Updated by Steffen Gebert over 13 years ago

No, Christopher! #21798 is set to resolved as this bug entry is open as duplicate.
It's pending in core list since May 31 (sent by Reinhard), but no votes are given, yet!

@Reinhard
Could you please attach the tag "pening in core list" to BT entries, when RFC was sent? Thanks

Actions #3

Updated by Steffen Gebert over 13 years ago

Sorry, missed one part of the thread. Seems to be more tricky, may be you can remind Christian or you have a look at it again and provide a solution.

Actions #4

Updated by Alexander Opitz almost 11 years ago

  • Status changed from Accepted to Needs Feedback
  • Target version deleted (0)

The issue is very old, does this issue exists in newer versions of TYPO3 CMS (4.5 or 6.1)?

Actions #5

Updated by Reinhard Führicht almost 11 years ago

Hi Alexander,

yes, this issue still exists!

Here is a quick diff against the current GIT repository.
I am not sure about how to format this really long line properly, but you should at least see what should be changed.

Should I try to push the change to Gerrit?

diff --git a/typo3/sysext/tstemplate/Classes/Controller/TypoScriptTemplateModuleController.php b/typo3/sysext/tstemplate/Classes/Controller/TypoScriptTemplateModuleController.php
index db878dd..079102b 100644
--- a/typo3/sysext/tstemplate/Classes/Controller/TypoScriptTemplateModuleController.php
+++ b/typo3/sysext/tstemplate/Classes/Controller/TypoScriptTemplateModuleController.php
@@ -189,7 +189,15 @@ class TypoScriptTemplateModuleController extends \TYPO3\CMS\Backend\Module\BaseS
                 TABLE#ts-overview tr.t3-row-header td { padding: 2px 4px; font-weight:bold; color: #fff; }
             ';
             // Template pages:
-            $res = $GLOBALS['TYPO3_DB']->exec_SELECTquery('pages.uid, count(*) AS count, max(sys_template.root) AS root_max_val, min(sys_template.root) AS root_min_val', 'pages,sys_template', 'pages.uid=sys_template.pid' . \TYPO3\CMS\Backend\Utility\BackendUtility::deleteClause('pages') . \TYPO3\CMS\Backend\Utility\BackendUtility::versioningPlaceholderClause('pages') . \TYPO3\CMS\Backend\Utility\BackendUtility::deleteClause('sys_template') . \TYPO3\CMS\Backend\Utility\BackendUtility::versioningPlaceholderClause('sys_template'), 'pages.uid');
+            $res = $GLOBALS['TYPO3_DB']->exec_SELECTquery(
+                'pages.uid, count(*) AS count, max(sys_template.root) AS root_max_val, min(sys_template.root) AS root_min_val', 
+                'pages,sys_template', 
+                'pages.uid=sys_template.pid' . \TYPO3\CMS\Backend\Utility\BackendUtility::deleteClause('pages') . 
+                \TYPO3\CMS\Backend\Utility\BackendUtility::versioningPlaceholderClause('pages') . 
+                \TYPO3\CMS\Backend\Utility\BackendUtility::deleteClause('sys_template') . 
+                \TYPO3\CMS\Backend\Utility\BackendUtility::versioningPlaceholderClause('sys_template'), 
+                'pages.sorting'
+            );
             $templateArray = array();
             $pArray = array();
             while ($row = $GLOBALS['TYPO3_DB']->sql_fetch_assoc($res)) {
Actions #6

Updated by Alexander Opitz almost 11 years ago

  • Status changed from Needs Feedback to New

Yes, push it to gerrit. :-)

The line breaking looks good, but I would prefer following:

$res = $GLOBALS['TYPO3_DB']->exec_SELECTquery(
    'pages.uid, count(*) AS count,
    max(sys_template.root) AS root_max_val,
    min(sys_template.root) AS root_min_val', 
    'pages,sys_template', 
    'pages.uid=sys_template.pid' .
    \TYPO3\CMS\Backend\Utility\BackendUtility::deleteClause('pages') . 
    \TYPO3\CMS\Backend\Utility\BackendUtility::versioningPlaceholderClause('pages') . 
    \TYPO3\CMS\Backend\Utility\BackendUtility::deleteClause('sys_template') . 
    \TYPO3\CMS\Backend\Utility\BackendUtility::versioningPlaceholderClause('sys_template'), 
    'pages.sorting'
);
Actions #7

Updated by Gerrit Code Review almost 11 years ago

  • Status changed from New to Under Review

Patch set 1 for branch master has been pushed to the review server.
It is available at https://review.typo3.org/21366

Actions #8

Updated by Gerrit Code Review almost 11 years ago

Patch set 2 for branch master has been pushed to the review server.
It is available at https://review.typo3.org/21366

Actions #9

Updated by Gerrit Code Review almost 11 years ago

Patch set 3 for branch master has been pushed to the review server.
It is available at https://review.typo3.org/21366

Actions #10

Updated by Gerrit Code Review over 9 years ago

Patch set 4 for branch master of project Packages/TYPO3.CMS has been pushed to the review server.
It is available at http://review.typo3.org/21366

Actions #11

Updated by Gerrit Code Review almost 9 years ago

Patch set 5 for branch master of project Packages/TYPO3.CMS has been pushed to the review server.
It is available at http://review.typo3.org/21366

Actions #12

Updated by Gerrit Code Review almost 9 years ago

Patch set 1 for branch TYPO3_6-2 of project Packages/TYPO3.CMS has been pushed to the review server.
It is available at http://review.typo3.org/40490

Actions #13

Updated by Reinhard Führicht almost 9 years ago

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

Updated by Benni Mack over 5 years ago

  • Status changed from Resolved to Closed
Actions

Also available in: Atom PDF