Example #1
0
 public function load($fields = '*')
 {
     $ret = parent::load($fields);
     $this->acl = \Prj\Acl\Manage::getInstance();
     //TODO: manager-rights const
     $this->acl->fromString($this->getField('rights', true));
     return $ret;
 }
Example #2
0
 /**
  * 获取符合条件的账号的数量
  * @param array $where
  * @return int
  */
 public function getAccountNum($where)
 {
     if ($this->rpc !== null) {
         return $this->rpc->initArgs(array('where' => $where))->send(__FUNCTION__);
     } else {
         $this->setAccountStorage('', 'local');
         return \Sooh\DB\Cases\AccountStorage::loopGetRecordsCount($where);
     }
 }