public function getAdSpace($id) { if (empty($id)) { return array(); } $map['ad_id'] = $id; $data = $this->where($map)->find(); return $data; }