...
|
...
|
@@ -10,6 +10,7 @@ |
|
|
// +----------------------------------------------------------------------
|
|
|
namespace app\portal\controller;
|
|
|
//use cmf\controller\HomeBaseController;
|
|
|
use api\portal\model\OrderModel;
|
|
|
use app\portal\model\MemberModel;
|
|
|
use app\portal\model\UserModel;
|
|
|
use app\portal\service\PostService;
|
...
|
...
|
@@ -113,5 +114,23 @@ class IndexController extends CommonController |
|
|
\QRcode::png($url);
|
|
|
}
|
|
|
|
|
|
// 检测微信支付是否完成
|
|
|
public function checkStatus() {
|
|
|
if($this->request->isAjax()) {
|
|
|
$order_sn = $this->request->param('order_sn');
|
|
|
$order_model = new OrderModel();
|
|
|
$status = $order_model->where(['order_sn'=>$order_sn])->value('status');
|
|
|
if(empty($status)) {
|
|
|
$this->apiResponse(0,'订单不存在');
|
|
|
}
|
|
|
if($status == 1 || $status == 9) {
|
|
|
$this->apiResponse(0,'未支付成功');
|
|
|
}
|
|
|
if($status == 2) {
|
|
|
$this->apiResponse(1,'支付成功');
|
|
|
}
|
|
|
}
|
|
|
}
|
|
|
|
|
|
|
|
|
} |
...
|
...
|
|