Fixed bug: #5069: TSconfig mod.web_list.allowedNewTables used in t3lib_TCEforms_inline
authorOliver Hader <oliver.hader@typo3.org>
Thu, 1 Mar 2007 14:52:02 +0000 (14:52 +0000)
committerOliver Hader <oliver.hader@typo3.org>
Thu, 1 Mar 2007 14:52:02 +0000 (14:52 +0000)
git-svn-id: https://svn.typo3.org/TYPO3v4/Core/trunk@2166 709f56b5-9817-0410-a4d7-c38de5d9e867

ChangeLog
t3lib/class.t3lib_tceforms_inline.php

index af0404a..4e8b617 100755 (executable)
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,7 @@
+2007-03-01  Oliver Hader  <oh@inpublica.de>
+
+       * Fixed bug: #5069: TSconfig mod.web_list.allowedNewTables used in t3lib_TCEforms_inline
+
 2007-03-01  Karsten Dambekalns <karsten@typo3.org>
 
        * typo3/sysext/indexed_search: DBAL compliancy patch
index eb66e7e..3b7b415 100755 (executable)
@@ -454,11 +454,6 @@ class t3lib_TCEforms_inline {
                        t3lib_BEfunc::readPageAccess($rec['pid'], $GLOBALS['BE_USER']->getPagePermsClause(1))
                );
 
-                       // FIXME: Put these calls somewhere else... possibly they arn't needed here
-               $web_list_modTSconfig = t3lib_BEfunc::getModTSconfig($rec['pid'],'mod.web_list');
-               $allowedNewTables = t3lib_div::trimExplode(',',$this->fObj->web_list_modTSconfig['properties']['allowedNewTables'],1);
-               $showNewRecLink = !count($allowedNewTables) || in_array($foreign_table, $allowedNewTables);
-
                        // If the listed table is 'pages' we have to request the permission settings for each page:
                if ($isPagesTable)      {
                        $localCalcPerms = $GLOBALS['BE_USER']->calcPerms(t3lib_BEfunc::getRecord('pages',$rec['uid']));
@@ -482,13 +477,13 @@ class t3lib_TCEforms_inline {
                                        (!$isPagesTable && ($calcPerms&16)) ||  // For NON-pages, must have permission to edit content on this parent page
                                        ($isPagesTable && ($calcPerms&8))               // For pages, must have permission to create new pages here.
                                        )       {
-                                       if ($showNewRecLink)    {
-                                               $onClick = "return inline.createNewRecord('".$nameObjectFt."','".$rec['uid']."')";
-                                               if ($config['inline']['inlineNewButtonStyle']) $style = ' style="'.$config['inline']['inlineNewButtonStyle'].'"';
-                                               $cells[]='<a href="#" onclick="'.htmlspecialchars($onClick).'" class="inlineNewButton"'.$style.'>'.
-                                                               '<img'.t3lib_iconWorks::skinImg($this->backPath,'gfx/new_'.($isPagesTable?'page':'el').'.gif','width="'.($isPagesTable?13:11).'" height="12"').' title="'.$GLOBALS['LANG']->sL('LLL:EXT:lang/locallang_mod_web_list.xml:new'.($isPagesTable?'Page':'Record'),1).'" alt="" />'.
-                                                               '</a>';
+                                       $onClick = "return inline.createNewRecord('".$nameObjectFt."','".$rec['uid']."')";
+                                       if ($config['inline']['inlineNewButtonStyle']) {
+                                               $style = ' style="'.$config['inline']['inlineNewButtonStyle'].'"';
                                        }
+                                       $cells[]='<a href="#" onclick="'.htmlspecialchars($onClick).'" class="inlineNewButton"'.$style.'>'.
+                                                       '<img'.t3lib_iconWorks::skinImg($this->backPath,'gfx/new_'.($isPagesTable?'page':'el').'.gif','width="'.($isPagesTable?13:11).'" height="12"').' title="'.$GLOBALS['LANG']->sL('LLL:EXT:lang/locallang_mod_web_list.xml:new'.($isPagesTable?'Page':'Record'),1).'" alt="" />'.
+                                                       '</a>';
                                }
                        }