search(array('ids' => $yes)); } if (!$keyword) { $where['limit'] = '0,50'; $data = Dever::db($table)->search($where); } else { $where['name'] = $keyword; $data = Dever::db($table)->search($where); } $result = array(); if ($yes) { foreach ($yes as $k => $v) { if (isset($data[$k])) { unset($data[$k]); } $yes[$k]['selected'] = 'selected'; } $data = $yes + $data; $data = array_merge($data, array()); } else { $data = array_merge($data, array()); } if (!$data) { Dever::alert('暂无数据'); } return $data; } # 搜索文章 public function search_article_api() { return $this->search('article/info'); } }