...
|
...
|
@@ -6,6 +6,7 @@ use cmf\controller\HomeBaseController; |
|
|
use EasyWeChat\Foundation\Application;
|
|
|
use EasyWeChat\Payment\Order;
|
|
|
use think\Db;
|
|
|
use app\portal\controller\BirdController;
|
|
|
|
|
|
/**
|
|
|
* 微信支付,退款,提现DEMO
|
...
|
...
|
@@ -87,6 +88,11 @@ class PayController extends HomeBaseController |
|
|
//查询订单信息
|
|
|
$order = Db::name('indent')->where('order_number',$out_trade_no)->find();
|
|
|
if($successful){
|
|
|
$bird = new BirdController;
|
|
|
$takeOrder = $bird -> takeOrder($order['id']);
|
|
|
$createOrder = $bird -> createOrder($order['id']);
|
|
|
cache('dingyue',$takeOrder);
|
|
|
cache('yuyue',$createOrder);
|
|
|
$update['state'] = 2;
|
|
|
//更新订单状态为待发货
|
|
|
Db::name('indent')->where('order_number',$out_trade_no)->update($update);
|
...
|
...
|
|