示例#1
0
文件: Show.php 项目: sinfocol/gwf3
 private function sanitize()
 {
     if (false === ($this->pm = GWF_PM::getByID(Common::getGet('pmid')))) {
         return $this->module->error('err_pm');
     }
     if (false === $this->pm->canRead(GWF_Session::getUser())) {
         return $this->module->error('err_perm_read');
     }
     //		$this->term = Common::getGet('term', '');
     return false;
 }
示例#2
0
文件: Send.php 项目: sinfocol/gwf3
 private function sanitizePM($pmid)
 {
     if (false === ($this->pm = GWF_PM::getByID($pmid))) {
         return $this->module->error('err_pm');
     }
     if (!$this->pm->canRead($this->user)) {
         return $this->module->error('err_perm_read');
     }
     $this->rec = $this->pm->getSender();
     if ($this->rec->getID() === GWF_Session::getUserID()) {
         $this->rec = $this->pm->getReceiver();
     }
     return false;
 }