作者 董瑞恩
1 个管道 的构建 通过 耗费 0 秒

order

@@ -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 }