Actions
Bug #24032
closedThe content object type EDITPANEL is missing, causing pi_getEditPanel to break.
Start date:
2010-11-12
Due date:
% Done:
0%
Estimated time:
TYPO3 Version:
PHP Version:
Tags:
Complexity:
Is Regression:
Sprint Focus:
Description
pi_getEditPanel return a blank string, as EDITPANEL is not available as cObj anymore.
the pibase function can be rewritten as:
function pi_getEditPanel($row='',$tablename='',$label='',$conf=Array()) {
$panel='';
if (!$row || !$tablename) {
$row = $this->internal['currentRow'];
$tablename = $this->internal['currentTable'];
}
if ($GLOBALS['TSFE']->beUserLogin) {
// Create local cObj if not set:
if (!is_object($this->pi_EPtemp_cObj)) {
$this->pi_EPtemp_cObj = t3lib_div::makeInstance('tslib_cObj');
$this->pi_EPtemp_cObj->setParent($this->cObj->data,$this->cObj->currentRecord);
}
// Initialize the cObj object with current row
$this->pi_EPtemp_cObj->start($row,$tablename);
$this->pi_EPtemp_cObj->data=$this->internal;
// Setting TypoScript values in the $conf array. See documentation in TSref for the EDITPANEL cObject.
if (empty($conf['allow'])){
$conf['allow'] = 'edit,new,delete,move,hide';
}
$panel = $this->pi_EPtemp_cObj->editPanel('',$conf);
}
if ($panel) {
if ($label) {
return '<table border="0" cellpadding="0" cellspacing="0" width="100%"><tr><td valign="top">'.$label.'</td><td valign="top" align="right">'.$panel.'</td></tr></table>';
} else return ''.$panel.'';
} else return $label;
}
(issue imported from #M16364)
Files
Updated by Jeff Segars about 14 years ago
Bjorn,
Thanks for the bug report! I just noticed this myself too.
The attached patch re-adds the EDITPANEL cObject so there shouldn't be any patching of pi_getEditPanel needed. Are you able to test it and give feedback here or preferably on the core list?
Thanks!
Jeff
Actions