Example #1
0
 public function refreshStatus()
 {
     if ($this->id()) {
         M('Log')->record('activity', 'session', sprintf("%s\t%s\t%s\t%s", $this->id(), M('Tools')->web()->getRealIP(), @$_REQUEST['CSID'], M('Tools')->web()->makeUrl('', $_GET, 'abs')));
         $loginExpire = $this->_mapper->getLoginExpireByUserId($this->id());
         return $this->_mapper->updateUserSession($this->id(), C('user.auth-cookie.online-expire'), lor($loginExpire, C('user.auth-cookie.login-expire')));
     }
 }