field($field); if (empty($where) === false) { $result = $result->where($where); } $result = $result->find(); return $result; }//end findUsers() /** * 单个数据筛选 * * @access public * @param mixed $field 字段 * @param mixed $where 条件 * @param mixed $join 关联 * @return array 返回类型 */ public function findInfo($field, $where=[], $join=[]) { $result = $this->field($field); if (empty($join) === false) { $result = $result->alias('a'); foreach ($join as $k => $v) { $result = $result->join($k, $v); } } if (empty($where) === false) { $result = $result->where($where); } $result = $result->find(); return $result; }//end findUsers() }