正在显示
1 个修改的文件
包含
8 行增加
和
2 行删除
@@ -10,7 +10,10 @@ namespace app\portal\controller; | @@ -10,7 +10,10 @@ namespace app\portal\controller; | ||
10 | 10 | ||
11 | 11 | ||
12 | use app\portal\model\EquipmentModel; | 12 | use app\portal\model\EquipmentModel; |
13 | +use app\portal\model\OrderModel; | ||
13 | use cmf\controller\AdminBaseController; | 14 | use cmf\controller\AdminBaseController; |
15 | +use EasyWeChat\Payment\Order; | ||
16 | + | ||
14 | /** | 17 | /** |
15 | * Class AdminOrderController | 18 | * Class AdminOrderController |
16 | * @package app\portal\controller | 19 | * @package app\portal\controller |
@@ -27,8 +30,11 @@ use cmf\controller\AdminBaseController; | @@ -27,8 +30,11 @@ use cmf\controller\AdminBaseController; | ||
27 | class AdminOrderController extends AdminBaseController{ | 30 | class AdminOrderController extends AdminBaseController{ |
28 | 31 | ||
29 | public function index(){ | 32 | public function index(){ |
30 | - $Equipment=new EquipmentModel(); | ||
31 | - $data=$Equipment->paginate(10); | 33 | + $Order=new OrderModel(); |
34 | + $data=$Order->alias('a') | ||
35 | + ->join('equipment b','a.mac_address=b.mac_address') | ||
36 | + ->paginate(10); | ||
37 | + dump($data->items()); | ||
32 | $this->assign('data',$data); | 38 | $this->assign('data',$data); |
33 | return $this->fetch(); | 39 | return $this->fetch(); |
34 | } | 40 | } |
-
请 注册 或 登录 后发表评论