|
@@ -26,6 +26,16 @@ class IndexController extends CommonController |
|
@@ -26,6 +26,16 @@ class IndexController extends CommonController |
26
|
{
|
26
|
{
|
27
|
public function index()
|
27
|
public function index()
|
28
|
{
|
28
|
{
|
|
|
29
|
+ $return = $this->wxpay(['order_sn'=>123123123123],'保证金支付');
|
|
|
30
|
+ $qrcode_url = url('portal/Index/qrcode',['data'=>urlencode($return['code_url'])],true,true);
|
|
|
31
|
+ echo '<img src="'.$qrcode_url.'" alt=""/>';
|
|
|
32
|
+// $back = [
|
|
|
33
|
+// 'return'=>$return,
|
|
|
34
|
+// 'code_url'=>base64_encode($return['code_url']),
|
|
|
35
|
+// 'qrcode'=> '<img src="'.$qrcode_url.'" alt=""/>',
|
|
|
36
|
+// 'alipay_url'=>url('portal/Alipay/alipay',array('order_sn'=>$edu['order_sn'],'name'=>$lic,'price'=>0.01))
|
|
|
37
|
+// ];
|
|
|
38
|
+
|
29
|
echo "<pre/>";
|
39
|
echo "<pre/>";
|
30
|
print_r('7777');
|
40
|
print_r('7777');
|
31
|
die;
|
41
|
die;
|
|
@@ -95,5 +105,13 @@ class IndexController extends CommonController |
|
@@ -95,5 +105,13 @@ class IndexController extends CommonController |
95
|
}
|
105
|
}
|
96
|
}
|
106
|
}
|
97
|
|
107
|
|
|
|
108
|
+ // 微信支付二维码
|
|
|
109
|
+ public function qrcode() {
|
|
|
110
|
+ $data = $this->request->param('data');
|
|
|
111
|
+ require_once VENDOR_PATH.'WxpayAPI/example/phpqrcode/phpqrcode.php';
|
|
|
112
|
+ $url = urldecode($data);
|
|
|
113
|
+ \QRcode::png($url);
|
|
|
114
|
+ }
|
|
|
115
|
+
|
98
|
|
116
|
|
99
|
} |
117
|
} |