Esempio n. 1
0
 /**
  * Return name of storage.
  * @return string
  */
 public function getTitle()
 {
     $entityId = $this->storage->getEntityId();
     if ($entityId == 'shared_files_s1' || $entityId == 'shared_files' || $entityId == 'shared') {
         return Loc::getMessage('DISK_PROXY_TYPE_COMMON_TITLE_S1');
     }
     return parent::getTitle();
 }
Esempio n. 2
0
 /**
  * Get name of entity (ex. user last name + first name, group name, etc)
  * By default: get title
  * @return string
  */
 public function getEntityTitle()
 {
     $group = $this->getGroup();
     return isset($group['~NAME']) ? $group['~NAME'] : parent::getEntityTitle();
 }
Esempio n. 3
0
 /**
  * Return name of storage.
  * May be concrete by current user context.
  * Should not use in notification, email to another person.
  * @return string
  */
 public function getTitleForCurrentUser()
 {
     global $USER;
     if (is_object($USER) && $USER->getId() == $this->entityId) {
         return Loc::getMessage('DISK_PROXY_TYPE_USER_TITLE_CURRENT_USER');
     }
     return parent::getTitle();
 }