Commit 505904d5 authored by Wouter Wolters's avatar Wouter Wolters Committed by Benni Mack
Browse files

[TASK] BACK_PATH RecordList and friends

Resolves: #68807
Releases: master
Change-Id: I018b1114a82146e2331a178f41c8bf48ee89cba4
Reviewed-on: http://review.typo3.org/42320

Reviewed-by: Christian Kuhn's avatarChristian Kuhn <lolli@schwarzbu.ch>
Tested-by: Christian Kuhn's avatarChristian Kuhn <lolli@schwarzbu.ch>
Reviewed-by: Benni Mack's avatarBenni Mack <benni@typo3.org>
Tested-by: Benni Mack's avatarBenni Mack <benni@typo3.org>
parent 618a0d3d
......@@ -65,11 +65,6 @@ class Clipboard {
*/
public $current = '';
/**
* @var string
*/
public $backPath = '';
/**
* @var int
*/
......@@ -93,7 +88,6 @@ class Clipboard {
* @return void
*/
public function initializeClipboard() {
$this->backPath = $GLOBALS['BACK_PATH'];
// Get data
$clipData = $this->getBackendUser()->getModuleData('clipboard', $this->getBackendUser()->getTSConfigVal('options.saveClipboard') ? '' : 'ses');
// NumberTabs
......@@ -529,7 +523,7 @@ class Clipboard {
$str = '<span class="text-muted">' . $str . '</span>';
} else {
if (ExtensionManagementUtility::isLoaded('filelist')) {
$str = '<a href="' . htmlspecialchars(($this->backPath . BackendUtility::getModuleUrl('file_list') . '&id=' . dirname($rec))) . '">' . $str . '</a>';
$str = '<a href="' . htmlspecialchars(BackendUtility::getModuleUrl('file_list', array('id' => dirname($rec)))) . '">' . $str . '</a>';
}
}
}
......
......@@ -164,7 +164,6 @@ class NewContentElementController {
// Init position map object:
$posMap = GeneralUtility::makeInstance(\TYPO3\CMS\Backend\Tree\View\ContentCreationPagePositionMap::class);
$posMap->cur_sys_language = $this->sys_language;
$posMap->backPath = $GLOBALS['BACK_PATH'];
// If a column is pre-set:
if (isset($this->colPos)) {
if ($this->uid_pid < 0) {
......@@ -249,7 +248,7 @@ class NewContentElementController {
<a href="#" onclick="' . htmlspecialchars($aOnClick) . '">
' . $content . '
<div class="media-left">
<img' . IconUtility::skinImg($this->doc->backPath, $icon) . ' alt="" />
<img' . IconUtility::skinImg('', $icon) . ' alt="" />
</div>
<div class="media-body">
<strong>' . htmlspecialchars($wInfo['title']) . '</strong>' .
......
......@@ -45,11 +45,6 @@ class FileSystemNavigationFrameController {
*/
public $doc;
/**
* @var string
*/
public $backPath;
// Internal, static: GPvar:
/**
* @var string
......@@ -86,8 +81,6 @@ class FileSystemNavigationFrameController {
* @return void
*/
protected function init() {
// Setting backPath
$this->backPath = $GLOBALS['BACK_PATH'];
// Setting GPvars:
$this->currentSubScript = GeneralUtility::_GP('currentSubScript');
$this->cMR = GeneralUtility::_GP('cMR');
......
......@@ -314,7 +314,7 @@ class NewRecordController {
$excludeDokTypes = array(PageRepository::DOKTYPE_RECYCLER, PageRepository::DOKTYPE_SYSFOLDER, PageRepository::DOKTYPE_SPACER);
}
if (!in_array((int)$this->pageinfo['doktype'], $excludeDokTypes, TRUE)) {
$buttons['view'] = '<a href="#" onclick="' . htmlspecialchars(BackendUtility::viewOnClick($this->pageinfo['uid'], $this->doc->backPath, BackendUtility::BEgetRootLine($this->pageinfo['uid']))) . '" title="' . $this->getLanguageService()->sL('LLL:EXT:lang/locallang_core.xlf:labels.showPage', TRUE) . '">' . IconUtility::getSpriteIcon('actions-document-view') . '</a>';
$buttons['view'] = '<a href="#" onclick="' . htmlspecialchars(BackendUtility::viewOnClick($this->pageinfo['uid'], '', BackendUtility::BEgetRootLine($this->pageinfo['uid']))) . '" title="' . $this->getLanguageService()->sL('LLL:EXT:lang/locallang_core.xlf:labels.showPage', TRUE) . '">' . IconUtility::getSpriteIcon('actions-document-view') . '</a>';
}
}
return $buttons;
......
......@@ -156,13 +156,6 @@ class PageLayoutController {
*/
public $doc;
/**
* Back path of the module
*
* @var string
*/
public $backPath;
/**
* "Pseudo" Description -table name
*
......@@ -316,7 +309,6 @@ class PageLayoutController {
// Setting module configuration / page select clause
$this->MCONF = $GLOBALS['MCONF'];
$this->perms_clause = $this->getBackendUser()->getPagePermsClause(1);
$this->backPath = $GLOBALS['BACK_PATH'];
// Get session data
$sessionData = $this->getBackendUser()->getSessionData(RecordList::class);
$this->search_field = !empty($sessionData['search_field']) ? $sessionData['search_field'] : '';
......@@ -941,7 +933,6 @@ class PageLayoutController {
// Select element matrix:
if ($this->eRParts[0] == 'tt_content' && MathUtility::canBeInterpretedAsInteger($this->eRParts[1])) {
$posMap = GeneralUtility::makeInstance(ContentLayoutPagePositionMap::class);
$posMap->backPath = $GLOBALS['BACK_PATH'];
$posMap->cur_sys_language = $this->current_sys_language;
$HTMLcode = '';
// CSH:
......@@ -962,7 +953,6 @@ class PageLayoutController {
public function renderListContent() {
/** @var $dbList \TYPO3\CMS\Backend\View\PageLayoutView */
$dbList = GeneralUtility::makeInstance(PageLayoutView::class);
$dbList->backPath = $GLOBALS['BACK_PATH'];
$dbList->thumbs = $this->imagemode;
$dbList->no_noWrap = 1;
$dbList->descrTable = $this->descrTable;
......
......@@ -56,11 +56,6 @@ class PageTreeNavigationController {
*/
public $active_tempMountPoint = 0;
/**
* @var string
*/
public $backPath;
/**
* @var string
*/
......@@ -101,8 +96,6 @@ class PageTreeNavigationController {
* @return void
*/
protected function init() {
// Setting backPath
$this->backPath = $GLOBALS['BACK_PATH'];
// Setting GPvars:
$this->cMR = (bool)GeneralUtility::_GP('cMR');
$this->currentSubScript = GeneralUtility::_GP('currentSubScript');
......
......@@ -75,15 +75,6 @@ class AbstractWizardController {
return $GLOBALS['LANG'];
}
/**
* Returns the backpath
*
* @return string
*/
protected function getBackPath() {
return $GLOBALS['BACK_PATH'];
}
/**
* Returns an instance of DocumentTemplate
*
......
......@@ -160,7 +160,6 @@ class ColorpickerController extends AbstractWizardController {
}
// Initialize document object:
$this->doc = GeneralUtility::makeInstance(DocumentTemplate::class);
$this->doc->backPath = $this->getBackPath();
$this->doc->JScode = $this->doc->wrapScriptTags('
function checkReference() { //
if (parent.opener && parent.opener.document && parent.opener.document.' . $this->formName . ' && parent.opener.document.' . $this->formName . '["' . $this->fieldName . '"]) {
......
......@@ -93,7 +93,6 @@ class RteController extends AbstractWizardController {
$this->MCONF['name'] = 'wizard_rte';
// Starting the document template object:
$this->doc = GeneralUtility::makeInstance(DocumentTemplate::class);
$this->doc->backPath = $this->getBackPath();
$this->doc->setModuleTemplate('EXT:backend/Resources/Private/Templates/wizard_rte.html');
// Need to NOT have the page wrapped in DIV since if we do that we destroy
// the feature that the RTE spans the whole height of the page!!!
......
......@@ -129,7 +129,6 @@ class TableController extends AbstractWizardController {
$this->inputStyle = isset($this->TABLECFG['textFields']) ? (bool)$this->TABLECFG['textFields'] : TRUE;
// Document template object:
$this->doc = GeneralUtility::makeInstance(DocumentTemplate::class);
$this->doc->backPath = $this->getBackPath();
$this->doc->setModuleTemplate('EXT:backend/Resources/Private/Templates/wizard_table.html');
// Setting form tag:
list($rUri) = explode('#', GeneralUtility::getIndpEnv('REQUEST_URI'));
......
......@@ -61,11 +61,6 @@ abstract class AbstractRecordList {
*/
public $oddColumnsCssClass = '';
/**
* @var string
*/
public $backPath = '';
/**
* Decides the columns shown. Filled with values that refers to the keys of the data-array. $this->fieldArray[0] is the title column.
*
......
......@@ -39,13 +39,6 @@ use TYPO3\CMS\Fluid\View\StandaloneView;
class DocumentTemplate {
// Vars you typically might want to/should set from outside after making instance of this class:
/**
* 'backPath' pointing back to the PATH_typo3
*
* @var string
*/
public $backPath = '';
/**
* This can be set to the HTML-code for a formtag.
* Useful when you need a form to span the whole page; Inserted exactly after the body-tag.
......@@ -529,17 +522,17 @@ function jumpToUrl(URL) {
* If the BE_USER has access to Web>List then a link to that module is shown as well (with return-url)
*
* @param int $id The page id
* @param string $backPath The current "BACK_PATH" (the back relative to the typo3/ directory)
* @param string $_ @deprecated since TYPO3 CMS 7, will be removed in TYPO3 CMS 8
* @return string HTML string with linked icon(s)
*/
public function viewPageIcon($id, $backPath) {
public function viewPageIcon($id, $_ = '') {
// If access to Web>List for user, then link to that module.
$str = BackendUtility::getListViewLink(array(
'id' => $id,
'returnUrl' => GeneralUtility::getIndpEnv('REQUEST_URI')
), $GLOBALS['LANG']->sL('LLL:EXT:lang/locallang_core.xlf:labels.showList'));
// Make link to view page
$str .= '<a href="#" onclick="' . htmlspecialchars(BackendUtility::viewOnClick($id, $backPath, BackendUtility::BEgetRootLine($id))) . '" title="' . $GLOBALS['LANG']->sL('LLL:EXT:lang/locallang_core.xlf:labels.showPage', TRUE) . '">' . IconUtility::getSpriteIcon('actions-document-view') . '</a>';
$str .= '<a href="#" onclick="' . htmlspecialchars(BackendUtility::viewOnClick($id, '', BackendUtility::BEgetRootLine($id))) . '" title="' . $GLOBALS['LANG']->sL('LLL:EXT:lang/locallang_core.xlf:labels.showPage', TRUE) . '">' . IconUtility::getSpriteIcon('actions-document-view') . '</a>';
return $str;
}
......@@ -549,7 +542,7 @@ function jumpToUrl(URL) {
*
* @param string $params is a set of GET params to send to tce_db.php. Example: "&cmd[tt_content][123][move]=456" or "&data[tt_content][123][hidden]=1&data[tt_content][123][title]=Hello%20World
* @param string|int $redirectUrl Redirect URL, default is to use GeneralUtility::getIndpEnv('REQUEST_URI'), -1 means to generate an URL for JavaScript using T3_THIS_LOCATION
* @return string URL to tce_db.php + parameters (backpath is taken from $this->backPath)
* @return string URL to BackendUtility::getModuleUrl('tce_db') + parameters
* @see \TYPO3\CMS\Backend\Utility\BackendUtility::editOnClick()
*/
public function issueCommand($params, $redirectUrl = '') {
......@@ -588,10 +581,7 @@ function jumpToUrl(URL) {
if (is_array($row) && $row['uid']) {
$iconImgTag = IconUtility::getSpriteIconForRecord($table, $row, array('title' => htmlspecialchars($path)));
$title = strip_tags(BackendUtility::getRecordTitle($table, $row));
$viewPage = $noViewPageIcon ? '' : $this->viewPageIcon($row['uid'], $this->backPath);
if ($table == 'pages') {
$path .= ' - ' . BackendUtility::titleAttribForPages($row, '', 0);
}
$viewPage = $noViewPageIcon ? '' : $this->viewPageIcon($row['uid']);
} else {
$iconImgTag = IconUtility::getSpriteIcon('apps-pagetree-page-domain', array('title' => htmlspecialchars($path)));
$title = $GLOBALS['TYPO3_CONF_VARS']['SYS']['sitename'];
......@@ -786,7 +776,6 @@ function jumpToUrl(URL) {
}
}
}
$this->pageRenderer->backPath = $this->backPath;
// alternative template for Header and Footer
if ($this->pageHeaderFooterTemplateFile) {
$file = GeneralUtility::getFileAbsFileName($this->pageHeaderFooterTemplateFile, TRUE);
......@@ -828,7 +817,7 @@ function jumpToUrl(URL) {
// add docstyles
$this->docStyle();
if ($this->extDirectStateProvider) {
$this->pageRenderer->addJsFile($this->backPath . 'sysext/backend/Resources/Public/JavaScript/ExtDirect.StateProvider.js');
$this->pageRenderer->addJsFile('sysext/backend/Resources/Public/JavaScript/ExtDirect.StateProvider.js');
}
// Add jsCode for overriding the console with a debug panel connection
$this->pageRenderer->addJsInlineCode('consoleOverrideWithDebugPanel', 'if (typeof top.Ext === "object") {
......@@ -867,7 +856,7 @@ function jumpToUrl(URL) {
// Note: please do not reference "bootstrap" outside of the TYPO3 Core (not in your own extensions)
// as this is preliminary as long as Twitter bootstrap does not support AMD modules
// this logic will be changed once Twitter bootstrap 4 is included
$this->pageRenderer->addJsFile($this->backPath . 'sysext/core/Resources/Public/JavaScript/Contrib/bootstrap/bootstrap.js');
$this->pageRenderer->addJsFile('sysext/core/Resources/Public/JavaScript/Contrib/bootstrap/bootstrap.js');
// hook for additional headerData
if (isset($GLOBALS['TYPO3_CONF_VARS']['SC_OPTIONS']['typo3/template.php']['preHeaderRenderHook'])) {
......@@ -1116,10 +1105,10 @@ function jumpToUrl(URL) {
$this->inDocStylesArray = array();
if ($this->styleSheetFile) {
$this->pageRenderer->addCssFile($this->backPath . $this->styleSheetFile);
$this->pageRenderer->addCssFile($this->styleSheetFile);
}
if ($this->styleSheetFile2) {
$this->pageRenderer->addCssFile($this->backPath . $this->styleSheetFile2);
$this->pageRenderer->addCssFile($this->styleSheetFile2);
}
if ($inDocStyles !== '') {
......@@ -1127,7 +1116,7 @@ function jumpToUrl(URL) {
}
if ($this->styleSheetFile_post) {
$this->pageRenderer->addCssFile($this->backPath . $this->styleSheetFile_post);
$this->pageRenderer->addCssFile($this->styleSheetFile_post);
}
}
......@@ -1141,12 +1130,7 @@ function jumpToUrl(URL) {
* @return void
*/
public function addStyleSheet($key, $href, $title = '', $relation = 'stylesheet') {
if (strpos($href, '://') !== FALSE || $href[0] === '/') {
$file = $href;
} else {
$file = $this->backPath . $href;
}
$this->pageRenderer->addCssFile($file, $relation, 'screen', $title);
$this->pageRenderer->addCssFile($href, $relation, 'screen', $title);
}
/**
......@@ -1470,15 +1454,14 @@ function jumpToUrl(URL) {
}
/**
* Includes a javascript library that exists in the core /typo3/ directory. The
* backpath is automatically applied
* Includes a javascript library that exists in the core /typo3/ directory
*
* @param string $lib: Library name. Call it with the full path like "sysext/core/Resources/Public/JavaScript/QueryGenerator.js" to load it
* @return void
*/
public function loadJavascriptLib($lib) {
// @todo: maybe we can remove this one as well
$this->pageRenderer->addJsFile($this->backPath . $lib);
$this->pageRenderer->addJsFile($lib);
}
/**
......@@ -1673,7 +1656,7 @@ function jumpToUrl(URL) {
if (GeneralUtility::isFirstPartOfStr($filename, 'EXT:')) {
$filename = GeneralUtility::getFileAbsFileName($filename, TRUE, TRUE);
} elseif (!GeneralUtility::isAbsPath($filename)) {
$filename = GeneralUtility::resolveBackPath($this->backPath . $filename);
$filename = GeneralUtility::resolveBackPath($filename);
} elseif (!GeneralUtility::isAllowedAbsPath($filename)) {
$filename = '';
}
......@@ -1955,7 +1938,7 @@ function jumpToUrl(URL) {
* @return string
*/
protected function getBackendFavicon() {
return $GLOBALS['TBE_STYLES']['favicon'] ?: $this->backPath . 'sysext/backend/Resources/Public/Icons/favicon.ico';
return $GLOBALS['TBE_STYLES']['favicon'] ?: 'sysext/backend/Resources/Public/Icons/favicon.ico';
}
}
......@@ -165,13 +165,6 @@ abstract class AbstractTreeView {
*/
public $domIdPrefix = 'row';
/**
* Back path for icons
*
* @var string
*/
public $backPath;
/**
* If TRUE, HTML code is also accumulated in ->tree array during rendering of the tree.
* If 2, then also the icon prefix code (depthData) is stored
......@@ -288,7 +281,6 @@ abstract class AbstractTreeView {
/**
* Initialize the tree class. Needs to be overwritten
* Will set ->fieldsArray, ->backPath and ->clause
*
* @param string Record WHERE clause
* @param string Record ORDER BY field
......@@ -297,8 +289,6 @@ abstract class AbstractTreeView {
public function init($clause = '', $orderByFields = '') {
// Setting BE_USER by default
$this->BE_USER = $GLOBALS['BE_USER'];
// Setting backpath.
$this->backPath = $GLOBALS['BACK_PATH'];
// Setting clause
if ($clause) {
$this->clause = $clause;
......
......@@ -36,11 +36,6 @@ class PagePositionMap {
*/
public $dontPrintPageInsertIcons = 0;
/**
* @var string
*/
public $backPath = '';
// How deep the position page tree will go.
/**
* @var int
......
......@@ -1639,7 +1639,7 @@ class BackendUtility {
* @param bool $linkInfoPopup Whether to wrap with a link opening the info popup
* @return string Thumbnail image tag.
*/
static public function thumbCode($row, $table, $field, $backPath, $thumbScript = '', $uploaddir = NULL, $abs = 0, $tparams = '', $size = '', $linkInfoPopup = TRUE) {
static public function thumbCode($row, $table, $field, $backPath = '', $thumbScript = '', $uploaddir = NULL, $abs = 0, $tparams = '', $size = '', $linkInfoPopup = TRUE) {
// Check and parse the size parameter
$size = trim($size);
$sizeParts = array(64, 64);
......@@ -2782,13 +2782,13 @@ class BackendUtility {
* REMEMBER to always htmlspecialchar() content in href-properties to ampersands get converted to entities (XHTML requirement and XSS precaution)
*
* @param string $params Parameters sent along to EditDocumentController. This requires a much more details description which you must seek in Inside TYPO3s documentation of the FormEngine API. And example could be '&edit[pages][123] = edit' which will show edit form for page record 123.
* @param string $backPath (unused)
* @param string $_ (unused)
* @param string $requestUri An optional returnUrl you can set - automatically set to REQUEST_URI.
*
* @return string
* @see \TYPO3\CMS\Backend\Template\DocumentTemplate::issueCommand()
*/
static public function editOnClick($params, $backPath = '', $requestUri = '') {
static public function editOnClick($params, $_ = '', $requestUri = '') {
if ($requestUri == -1) {
$returnUrl = 'T3_THIS_LOCATION';
} else {
......
......@@ -523,7 +523,7 @@ class PageLayoutView extends \TYPO3\CMS\Recordlist\RecordList\AbstractDatabaseRe
'&returnUrl=' . rawurlencode(GeneralUtility::getIndpEnv('REQUEST_URI'))) . ';';
} else {
$params = '&edit[tt_content][' . -$row['uid'] . ']=new';
$onClick = BackendUtility::editOnClick($params, $this->backPath);
$onClick = BackendUtility::editOnClick($params);
}
$singleElementHTML .= '
<a href="#" onclick="' . htmlspecialchars($onClick) . '" title="'
......@@ -672,7 +672,7 @@ class PageLayoutView extends \TYPO3\CMS\Recordlist\RecordList\AbstractDatabaseRe
// "View page" icon is added:
$viewLink = '';
if (!VersionState::cast($this->getPageLayoutController()->pageinfo['t3ver_state'])->equals(VersionState::DELETE_PLACEHOLDER)) {
$onClick = BackendUtility::viewOnClick($this->id, $this->backPath, BackendUtility::BEgetRootLine($this->id), '', '', ('&L=' . $lP));
$onClick = BackendUtility::viewOnClick($this->id, '', BackendUtility::BEgetRootLine($this->id), '', '', ('&L=' . $lP));
$viewLink = '<a href="#" onclick="' . htmlspecialchars($onClick) . '" title="' . $this->getLanguageService()->sL('LLL:EXT:lang/locallang_core.xlf:labels.showPage', TRUE) . '">' . IconUtility::getSpriteIcon('actions-document-view') . '</a>';
}
// Language overlay page header:
......@@ -2046,7 +2046,7 @@ class PageLayoutView extends \TYPO3\CMS\Recordlist\RecordList\AbstractDatabaseRe
* @return string HTML for thumbnails, if any.
*/
public function getThumbCodeUnlinked($row, $table, $field) {
return BackendUtility::thumbCode($row, $table, $field, $this->backPath, '', NULL, 0, '', '', FALSE);
return BackendUtility::thumbCode($row, $table, $field, '', '', NULL, 0, '', '', FALSE);
}
/**
......
......@@ -182,7 +182,6 @@ class FormsController extends \TYPO3\CMS\Backend\Controller\Wizard\AbstractWizar
$this->xmlStorage = $this->P['params']['xmlOutput'];
// Document template object:
$this->doc = GeneralUtility::makeInstance(\TYPO3\CMS\Backend\Template\DocumentTemplate::class);
$this->doc->backPath = $this->getBackPath();
$this->doc->setModuleTemplate('EXT:compatibility6/Resources/Private/Templates/Wizard/Forms.html');
// Setting form tag:
list($rUri) = explode('#', GeneralUtility::getIndpEnv('REQUEST_URI'));
......
......@@ -283,7 +283,6 @@ class FileListController {
// Create filelisting object
$this->filelist = GeneralUtility::makeInstance(FileList::class);
$this->filelist->backPath = $GLOBALS['BACK_PATH'];
// Apply predefined values for hidden checkboxes
// Set predefined value for DisplayBigControlPanel:
$backendUser = $this->getBackendUser();
......
......@@ -572,7 +572,7 @@ class FileList extends AbstractRecordList {
* @return string HTML
*/
public function linkWrapDir($title, Folder $folderObject) {
$href = $this->backPath . $this->script . '&id=' . rawurlencode($folderObject->getCombinedIdentifier());
$href = $this->script . '&id=' . rawurlencode($folderObject->getCombinedIdentifier());
$onclick = ' onclick="' . htmlspecialchars(('top.document.getElementsByName("navigation")[0].contentWindow.Tree.highlightActiveItem("file","folder' . GeneralUtility::md5int($folderObject->getCombinedIdentifier()) . '_"+top.fsMod.currentBank)')) . '"';
// Sometimes $code contains plain HTML tags. In such a case the string should not be modified!
if ((string)$title === strip_tags($title)) {
......@@ -608,7 +608,7 @@ class FileList extends AbstractRecordList {
/**
* Returns list URL; This is the URL of the current script with id and imagemode parameters, that's all.
* The URL however is not relative (with the backpath), otherwise GeneralUtility::sanitizeLocalUrl() would say that
* The URL however is not relative, otherwise GeneralUtility::sanitizeLocalUrl() would say that
* the URL would be invalid
*
* @return string URL
......@@ -695,7 +695,7 @@ class FileList extends AbstractRecordList {
'justLocalized' => 'sys_file_metadata:' . $metaDataRecord['uid'] . ':' . $languageId,
'returnUrl' => $this->listURL()
];
$returnUrl = BackendUtility::getModuleUrl('record_edit', $parameters, $this->backPath) . BackendUtility::getUrlToken('editRecord');
$returnUrl = BackendUtility::getModuleUrl('record_edit', $parameters) . BackendUtility::getUrlToken('editRecord');
$href = $GLOBALS['SOBE']->doc->issueCommand(
'&cmd[sys_file_metadata][' . $metaDataRecord['uid'] . '][localize]=' . $languageId,
$returnUrl
......@@ -799,7 +799,7 @@ class FileList extends AbstractRecordList {
$params = '&SET[sort]=' . $col . '&SET[reverse]=0';
$sortArrow = '';
}
$href = GeneralUtility::resolveBackPath(($GLOBALS['BACK_PATH'] . $this->script)) . '&id=' . rawurlencode($folderIdentifier) . $params;
$href = GeneralUtility::resolveBackPath($this->script) . '&id=' . rawurlencode($folderIdentifier) . $params;
return '<a href="' . htmlspecialchars($href) . '">' . $code . ' ' . $sortArrow . '</a>';
}
......
......@@ -81,7 +81,6 @@ class TableListViewHelper extends \TYPO3\CMS\Fluid\ViewHelpers\Be\AbstractBacken
$pageinfo = \TYPO3\CMS\Backend\Utility\BackendUtility::readPageAccess(\TYPO3\CMS\Core\Utility\GeneralUtility::_GP('id'), $GLOBALS['BE_USER']->getPagePermsClause(1));
/** @var $dblist \TYPO3\CMS\Recordlist\RecordList\DatabaseRecordList */
$dblist = \TYPO3\CMS\Core\Utility\GeneralUtility::makeInstance(\TYPO3\CMS\Recordlist\RecordList\DatabaseRecordList::class);
$dblist->backPath = $GLOBALS['BACK_PATH'];
$dblist->pageRow = $pageinfo;
if ($readOnly === FALSE) {
$dblist->calcPerms = $GLOBALS['BE_USER']->calcPerms($pageinfo);
......
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment