find ( array ('where' => $str.$str2.$str3.$str4.$str5, 'desc'=>'make_day', 'asArray' => TRUE ) ); }else{ return $this->find ( array ('where' => " key_num like '%".$search."%'",'desc'=>'make_day', 'asArray' => TRUE ) ); } } public function getLongleReceive($cid,$status,$othercid=""){ $str=""; if(!empty($othercid)) $str= " cid in (".$cid.",".$othercid." )"; else $str= " cid in (".$cid." )"; return $this->find ( array ('where' => $str." and status=".$status, 'asArray' => TRUE ) ); } public function getLongleBykeynum($keynum){ return $this->find ( array ('where' => " key_num = '".$keynum."'", 'asArray' => TRUE ) ); } public function getLongleBykeynum2($keynum){ return $this->find ( array ('where' => " key_num like '%".$keynum."%'",'limit'=>'10', 'asArray' => TRUE ) ); } public function getLongleByLid($lid){ return $this->find ( array ('where' => " lid =".$lid, 'asArray' => TRUE ) ); } public function getLongleByClient($clientname){ return $this->find ( array ('where' => " client like '".$clientname."'", 'asArray' => TRUE ) ); } public function getLongleBySerialNumber($SerialNumber){ return $this->getOne ( array ('where' => " SerialNumber like '".$SerialNumber."'", 'asArray' => TRUE ) ); } public function getLongleByClientid($client){ return $this->find ( array ('where' => " clientid = '".$client."'", 'asArray' => TRUE ) ); } // public function getLongleByRe($cid,$status=1){ // // } public function getUser() { return $this->find ( array ('asc' => 'uid', 'asArray' => TRUE ) ); } public function getUserByIdList($puid){ return $this->find ( array ('where' => "uid= '".$puid."'", 'asArray' => TRUE ) ); } } ?>