coupon-admin/app/controller/manager/Bill.php

38 lines
751 B
PHP
Raw Normal View History

2021-11-25 10:11:50 +00:00
<?php
namespace app\controller\manager;
/*流水查看*/
use app\repository\BillRepository;
class Bill extends Base
{
/**
* 流水列表
*
* @return Json|View
* @throws Exception
*/
public function index()
{
if ($this->request->isPost()) {
$repo = BillRepository::getInstance();
$keyword = $this->request->param('keyword/s', '');
$page = $this->request->param('page/d', 1);
$size = $this->request->param('size/d', 30);
$orders = ['sort'=>'asc'];
$list = $repo->billList($keyword, $page, $size, $orders);
return $this->json(0, 'success', $list);
}
return $this->view();
}
}