* Fixed bug #0000341: Changed table definition of "fe_session_data" so field "content...
authorIngmar Schlecht <ingmar.schlecht@typo3.org>
Mon, 28 Mar 2005 10:04:27 +0000 (10:04 +0000)
committerIngmar Schlecht <ingmar.schlecht@typo3.org>
Mon, 28 Mar 2005 10:04:27 +0000 (10:04 +0000)
* Fixed bug #0000890: fe_adminLib.inc procesSetFixed does not support userFunc_afterSave
* Fixed bug #0000316: Backend typo3/template.php output spurious </body> tag for doctype xhtml_frames
* Added two hooks to t3lib_userauthgroup for Sebastian Kurfuerst's ACL implementation

git-svn-id: https://svn.typo3.org/TYPO3v4/Core/trunk@585 709f56b5-9817-0410-a4d7-c38de5d9e867

ChangeLog
t3lib/class.t3lib_userauthgroup.php
typo3/sysext/cms/ext_tables.sql
typo3/sysext/cms/tslib/media/scripts/fe_adminLib.inc
typo3/template.php

index 7654169..1ad3840 100755 (executable)
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,10 @@
+2005-03-28  Ingmar Schlecht  <ingmar@typo3.org>
+
+       * Fixed bug #0000341: Changed table definition of "fe_session_data" so field "content" is MEDIUMBLOB instead of BLOB
+       * Fixed bug #0000890: fe_adminLib.inc procesSetFixed does not support userFunc_afterSave
+       * Fixed bug #0000316: Backend typo3/template.php output spurious </body> tag for doctype xhtml_frames
+       * Added two hooks to t3lib_userauthgroup for Sebastian Kurfuerst's ACL implementation
+
 2005-03-25  Michael Stucki  <michael@typo3.org>
 
        * Added two hooks for tx_timtaw, written by Sebastian Kurfuerst
@@ -9,7 +16,7 @@
 
 2005-03-16  Ingmar Schlecht  <ingmar@typo3.org>
 
-       * Fixed bug #0000335 in class.t3lib_extfilefunc.php: If $this->dont_use_exec_commands was set, it was impossible to delete any directories, which is now possible again. It's still impossible to delete direcories recursively though.
+       * Fixed bug #0000335: in class.t3lib_extfilefunc.php: If $this->dont_use_exec_commands was set, it was impossible to delete any directories, which is now possible again. It's still impossible to delete direcories recursively though.
        * Fixed bug #0000280: pi_list_query() produced wrong query when $orderBy paramater was not given.
 
 2005-03-10  Kasper Skårhøj,,,  <kasper@typo3.com>
index 1ec56ac..cc713a6 100755 (executable)
@@ -288,6 +288,7 @@ class t3lib_userAuthGroup extends t3lib_userAuth {
         * @return      string          Part of where clause. Prefix " AND " to this.
         */
        function getPagePermsClause($perms)     {
+               global $TYPO3_CONF_VARS;
                if (is_array($this->user))      {
                        if ($this->isAdmin())   {
                                return ' 1=1';
@@ -299,6 +300,18 @@ class t3lib_userAuthGroup extends t3lib_userAuth {
                                'OR(pages.perms_userid = '.$this->user['uid'].' AND pages.perms_user & '.$perms.' = '.$perms.')';       // User
                        if ($this->groupList){$str.='OR(pages.perms_groupid in ('.$this->groupList.') AND pages.perms_group & '.$perms.' = '.$perms.')';}       // Group (if any is set)
                        $str.=')';
+                       
+                       // ****************
+                       // getPagePermsClause-HOOK
+                       // ****************
+                       if (is_array($TYPO3_CONF_VARS['SC_OPTIONS']['t3lib/class.t3lib_userauthgroup.php']['getPagePermsClause'])) {
+                               
+                               foreach($TYPO3_CONF_VARS['SC_OPTIONS']['t3lib/class.t3lib_userauthgroup.php']['getPagePermsClause'] as $_funcRef) {
+                                       $_params = array('currentClause' => $str, 'perms' => $perms);
+                                       $str = t3lib_div::callUserFunction($_funcRef, $_params, $this);
+                               }
+                       }
+                       
                        return $str;
                } else {
                        return ' 1=0';
@@ -314,6 +327,7 @@ class t3lib_userAuthGroup extends t3lib_userAuth {
         * @return      integer         Bitwise representation of the users permissions in relation to input page row, $row
         */
        function calcPerms($row)        {
+               global $TYPO3_CONF_VARS;
                if ($this->isAdmin()) {return 31;}              // Return 31 for admin users.
 
                $out=0;
@@ -326,6 +340,20 @@ class t3lib_userAuthGroup extends t3lib_userAuth {
                        }
                        $out|=$row['perms_everybody'];
                }
+               
+               // ****************
+               // CALCPERMS hook
+               // ****************
+               if (is_array($TYPO3_CONF_VARS['SC_OPTIONS']['t3lib/class.t3lib_userauthgroup.php']['calcPerms'])) {
+                       foreach($TYPO3_CONF_VARS['SC_OPTIONS']['t3lib/class.t3lib_userauthgroup.php']['calcPerms'] as $_funcRef) {
+                               $_params = array(
+                                       'row' => $row,
+                                       'outputPermissions' => $out
+                               );
+                               $out = t3lib_div::callUserFunction($_funcRef, $_params, $this);
+                       }
+               }
+               
                return $out;
        }
 
index 1bbf7d0..ca31570 100755 (executable)
@@ -96,7 +96,7 @@ CREATE TABLE fe_groups (
 #
 CREATE TABLE fe_session_data (
   hash varchar(32) DEFAULT '' NOT NULL,
-  content blob NOT NULL,
+  content MEDIUMBLOB NOT NULL,
   tstamp int(11) unsigned DEFAULT '0' NOT NULL,
   PRIMARY KEY (hash)
 );
index 863924c..99e765d 100755 (executable)
@@ -1120,7 +1120,9 @@ class user_feAdmin        {
                                                $this->cObj->DBgetDelete($this->theTable, $theUid, TRUE);
                                        } else {
                                                $newFieldList = implode(',',array_intersect(t3lib_div::trimExplode(',',$this->fieldList),t3lib_div::trimExplode(',',implode($fieldArr,','),1)));
-                                               $this->cObj->DBgetUpdate($this->theTable, $theUid, $fD, $newFieldList, TRUE);
+                                               $this->cObj->DBgetUpdate($this->theTable, $theUid, $fD, $newFieldList, TRUE);^
+                                               $this->currentArr = $GLOBALS['TSFE']->sys_page->getRawRecord($this->theTable,$theUid);
+                                               $this->userProcess_alt($this->conf['setfixed.']['userFunc_afterSave'],$this->conf['setfixed.']['userFunc_afterSave.'],array('rec'=>$this->currentArr, 'origRec'=>$origArr));
                                        }
 
                                                // Outputting template
index 40bff00..9fa3774 100755 (executable)
@@ -671,14 +671,19 @@ $str.=$this->docBodyTagBegin().
                                t3lib_BEfunc::getSetUpdateSignal().
                                $this->parseTime().
                                ($this->form?'
-</form>':'').
-                               ($this->divClass?'
+</form>':'');
+               
+               if ($this->docType!='xhtml_frames') {
+               
+                       $str .= ($this->divClass?'
 
 <!-- Wrapping DIV-section for whole page END -->
-</div>':'').
-                               '
-</body>
-</html>        ';
+</div>':'').'
+</body>        ';
+
+               }
+
+               $str .= '</html>';
 
                        // Logging: Can't find better place to put it:
                if (TYPO3_DLOG) t3lib_div::devLog('END of BACKEND session','',0,array('_FLUSH'=>TRUE));
@@ -1842,4 +1847,4 @@ $LANG->init($BE_USER->uc['lang']);
 // The template is loaded
 // ******************************
 $TBE_TEMPLATE = t3lib_div::makeInstance('template');
-?>
\ No newline at end of file
+?>