diff --git a/Classes/Utility/Tca/AbstractTca.php b/Classes/Utility/Tca/AbstractTca.php index b95d92f..9669334 100755 --- a/Classes/Utility/Tca/AbstractTca.php +++ b/Classes/Utility/Tca/AbstractTca.php @@ -31,7 +31,7 @@ class AbstractTca */ public function getSearchFields() { - return implode(',', $this->conf->getSearchFields()); + return implode(',', $this->conf->ctrl->getSearchFields()); } /** diff --git a/Classes/Utility/Tca/Tca.php b/Classes/Utility/Tca/Tca.php index 42baca5..3801cf2 100755 --- a/Classes/Utility/Tca/Tca.php +++ b/Classes/Utility/Tca/Tca.php @@ -12,13 +12,18 @@ class Tca extends AbstractTca * @param Configuration $configuration */ public function init(Configuration $configuration) + { + $this->setDefaults($configuration); + } + + /** + * @param Configuration $configuration + */ + private function setDefaults(Configuration $configuration) { $this->conf = $configuration; $this->conf->interface->setShowRecordFieldList($this->getRecordsFieldList()); - - - $ll = $this->conf->getLl(); $iconFile = $this->conf->ctrl->getIconFile(); $enableColumns = $this->conf->ctrl->getEnableColumns(); @@ -28,11 +33,11 @@ public function init(Configuration $configuration) } if (empty($iconFile)) { - $this->iconFile = ExtensionManagementUtility::extRelPath($this->conf->getExt()) . 'Resources/Public/Icons/' . $this->conf->getModel() . '.gif'; + $this->conf->ctrl->setIconFile(ExtensionManagementUtility::extRelPath($this->conf->getExt()) . 'Resources/Public/Icons/' . $this->conf->getModel() . '.gif'); } if (count($enableColumns) == 0) { - $this->conf->setEnableColumns(array( + $this->conf->ctrl->setEnableColumns(array( 'disabled' => 'hidden', 'starttime' => 'starttime', 'endtime' => 'endtime', @@ -50,7 +55,7 @@ public function createTca() $tca = array( 'ctrl' => array( - 'title' => $this->conf->ctrl->getTitle(), + 'title' => $this->getFieldLabel($this->conf->ctrl->getTitle()), 'label' => $this->conf->ctrl->getLabel(), 'label_alt' => $this->conf->ctrl->getLabelAlt(), 'label_alt_force' => $this->conf->ctrl->isLabelAltForce(),