Commit dc08bc25 authored by speedprogs_de's avatar speedprogs_de

fixed extensionSettings error, added extensions back reference to tag object

git-svn-id: https://svn.typo3.org/TYPO3v4/Extensions/terfe/branches/ter_fe2@45948 735d13b6-9817-0410-8766-e36946ffe9aa
parent 9e15dba5
......@@ -93,7 +93,7 @@
$updateInfoArray = array();
foreach ($this->settings['extensionProviders'] as $providerIdent => $providerSettings) {
// Get update info from one Extension Provider
$extensionProvider = $this->getConcreteExtensionProvider($providerIdent, $providerSettings);
$extensionProvider = $this->getConcreteExtensionProvider($providerIdent);
$updateInfo = $extensionProvider->getUpdateInfo($lastRunTime);
// Set providerIdent recursively
......@@ -150,10 +150,9 @@
* Load a concrete Extension provider by identifier
*
* @param string $providerIdent Identifier of the Extension Provider
* @param array $providerSettings Provider specific settings
* @return Tx_TerFe2_ExtensionProvider_ExtensionProviderInterface Extension Provider
*/
protected function getConcreteExtensionProvider($providerIdent, array $providerSettings) {
protected function getConcreteExtensionProvider($providerIdent) {
if (empty($providerIdent)) {
throw new Exception('No Extension Provider given');
}
......@@ -162,11 +161,12 @@
return $this->concreteExtensionProviders[$providerIdent];
}
if (empty($providerSettings['className'])) {
if (empty($this->settings['extensionProviders'][$providerIdent]['className'])) {
throw new Exception('No className found for Extension Provider "' . $providerIdent . '"');
}
// Create new one from settings
$providerSettings = $this->settings['extensionProviders'][$providerIdent];
$extensionProvider = $this->objectManager->get($providerSettings['className']);
if ($extensionProvider instanceof Tx_TerFe2_ExtensionProvider_AbstractExtensionProvider) {
$extensionProvider->setConfiguration($providerSettings);
......
......@@ -6,7 +6,7 @@
$TCA['tx_terfe2_domain_model_tag'] = array(
'ctrl' => $TCA['tx_terfe2_domain_model_tag']['ctrl'],
'interface' => array(
'showRecordFieldList' => 'title',
'showRecordFieldList' => 'title,extensions',
),
'types' => array(
'1' => array('showitem' => 'title'),
......@@ -70,6 +70,21 @@
'eval' => 'trim,required',
),
),
'extensions' => array(
'exclude' => 1,
'label' => 'LLL:EXT:ter_fe2/Resources/Private/Language/locallang_db.xml:tx_terfe2_domain_model_tag.extensions',
'config' => array(
'type' => 'select',
'size' => 10,
'minitems' => 0,
'maxitems' => 9999,
'autoSizeMax' => 30,
'multiple' => 0,
'foreign_table' => 'tx_terfe2_domain_model_extension',
'MM' => 'tx_terfe2_extension_tag_mm',
'MM_opposite_field' => 'tags',
),
),
),
);
?>
\ No newline at end of file
......@@ -23,6 +23,7 @@
<label index="tx_terfe2_domain_model_tag">Tag</label>
<label index="tx_terfe2_domain_model_tag.title">Title</label>
<label index="tx_terfe2_domain_model_tag.extensions">Extensions</label>
<label index="tx_terfe2_domain_model_version">Version</label>
<label index="tx_terfe2_domain_model_version.title">Title</label>
......
Markdown is supported
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