Ejemplo n.º 1
0
 /**
 * Delete this object
 *
 * @param void
 * @return boolean
 */
 function delete() {
   if ($this->isAccountOwner()) {
     return false;
   } // if
   
   ProjectUsers::clearByUser($this);
   MessageSubscriptions::clearByUser($this);
   return parent::delete();
 } // delete
Ejemplo n.º 2
0
 /**
  * Delete this object
  *
  * @param void
  * @return boolean
  */
 function delete()
 {
     if ($this->isAccountOwner()) {
         return false;
     }
     // if
     if ($this->isTaggable()) {
         $this->clearTags();
     }
     // if
     // TODO check all things that need to be deleted
     // ticket subscriptions
     // message subscriptions
     // project-user association
     $this->deleteAvatar();
     $this->clearImValues();
     if ($this->hasUserAccount()) {
         ProjectUsers::clearByUser($this->getUserAccount());
         MessageSubscriptions::clearByUser($this->getUserAccount());
         $this->getUserAccount()->delete();
     }
     // if
     return parent::delete();
 }