function _fieldValues()
 {
     if (empty($this->dDateTime)) {
         $this->dDateTime = getCurrentDateTime();
     }
     if (empty($this->iSessionId)) {
         $this->iSessionId = $_SESSION['sessionID'];
     }
     $oFolder = Folder::get($this->iFolderId);
     // head off the certain breakage down the line.
     if (PEAR::isError($oFolder) || $oFolder === false) {
         $this->bAdminMode = 0;
     } else {
         if (KTBrowseUtil::inAdminMode($oUser, $oFolder)) {
             $this->bAdminMode = 1;
         } else {
             $this->bAdminMode = 0;
         }
     }
     return parent::_fieldValues();
 }
Esempio n. 2
0
 function _fieldValues()
 {
     static $lastFolder = null;
     if (is_null($lastFolder) || $lastFolder->getID() !== $this->iFolderId) {
         $lastFolder = Folder::get($this->iFolderId);
         if (PEAR::isError($lastFolder)) {
             $lastFolder = null;
         }
     }
     if (!is_null($lastFolder)) {
         $this->sFullPath = 'pending';
         if (!is_null($this->getMetadataVersionId())) {
             $metadata = KTDocumentMetadataVersion::get($this->getMetadataVersionId());
             $name = $metadata->getName();
             if ($lastFolder->getId() == 1) {
                 $this->sFullPath = $name;
             } else {
                 $this->sFullPath = $lastFolder->getFullPath() . '/' . $name;
             }
         }
         $this->sParentFolderIds = $lastFolder->getParentFolderIDs();
     }
     return parent::_fieldValues();
 }
Esempio n. 3
0
 function _fieldValues()
 {
     $aRet = parent::_fieldValues();
     $aRet['search'] = base64_encode(serialize($aRet['search']));
     return $aRet;
 }