作者 lyh

gx

@@ -17,9 +17,16 @@ use Illuminate\Http\Request; @@ -17,9 +17,16 @@ use Illuminate\Http\Request;
17 class VisitController extends BaseController 17 class VisitController extends BaseController
18 { 18 {
19 19
  20 + /**
  21 + * @remark :获取列表
  22 + * @name :index
  23 + * @author :lyh
  24 + * @method :post
  25 + * @time :2023/8/10 10:35
  26 + */
20 public function index(VisitLogic $logic) 27 public function index(VisitLogic $logic)
21 { 28 {
22 - $data = $logic->getList(); 29 + $data = $logic->getVisitList($this->map,$this->page,$this->row,$this->order);
23 return $this->success($data); 30 return $this->success($data);
24 } 31 }
25 32
@@ -22,10 +22,11 @@ class VisitLogic extends BaseLogic @@ -22,10 +22,11 @@ class VisitLogic extends BaseLogic
22 $this->model = new Visit(); 22 $this->model = new Visit();
23 } 23 }
24 24
25 - public function getList(array $map = [], array $sort = ['id' => 'desc'], array $columns = ['*'], int $limit = 20) 25 + public function getVisitList($map,$page,$row,$order,$filed = ['*'])
26 { 26 {
27 $map['domain'] = $this->user['domain']; 27 $map['domain'] = $this->user['domain'];
28 - return Logic::getList($map, $sort, ['id', 'url', 'referrer_url', 'device_port', 'country', 'ip', 'depth', 'created_at'], $limit); 28 + $lists = $this->model->lists($map,$page,$row,$order,$filed);
  29 + return $this->success($lists);
29 } 30 }
30 31
31 public function getItemList(array $map = [], array $sort = ['id' => 'desc'], array $columns = ['*'], int $limit = 20){ 32 public function getItemList(array $map = [], array $sort = ['id' => 'desc'], array $columns = ['*'], int $limit = 20){