예제 #1
0
 public function __construct($id = 0)
 {
     parent::__construct($id);
     if (is_numeric($this->gid)) {
         $this->gid = array($this->gid);
     }
     $this->spGroups();
     /* include default visitor permissions */
     $this->gid[] = 0;
     $this->parentGids();
     Sobi::Trigger('UserGroup', 'Appoint', array($id, &$this->gid));
 }
예제 #2
0
파일: user.php 프로젝트: pelloq1/SobiPro
 public function __construct($id = 0)
 {
     parent::__construct($id);
     $this->gid[] = 0;
     // this array is really a bad joke :(
     foreach ($this->groups as $index => $value) {
         if (is_string($index) && !is_numeric($index)) {
             $this->gid[] = $value;
             $this->usertype = $index;
         } else {
             $this->gid[] = $index;
             $this->usertype = $value;
         }
     }
     $this->spGroups();
     /* include default visitor permissions */
     $this->parentGids();
     Sobi::Trigger('UserGroup', 'Appoint', array($id, &$this->gid));
 }