作者 lihan
1 个管道 的构建 通过 耗费 0 秒

支付宝

@@ -170,11 +170,12 @@ class IndexController extends HomeBaseController @@ -170,11 +170,12 @@ class IndexController extends HomeBaseController
170 'merchant_private_key' => config('private_key'), 170 'merchant_private_key' => config('private_key'),
171 'alipay_public_key' => config('alipay_public_key'), 171 'alipay_public_key' => config('alipay_public_key'),
172 'charset' => "UTF-8", 172 'charset' => "UTF-8",
173 - 'sign_type' => "RSA1" 173 + 'sign_type' => "RSA"
174 ]; 174 ];
175 $alipay = new \AlipayTradeService($alipay_config); 175 $alipay = new \AlipayTradeService($alipay_config);
176 $builder = [ 176 $builder = [
177 - 'oid' => 2 177 + 'out_trade_no' => 20181212201251,
  178 + 'total_amount' => 0.01
178 ]; 179 ];
179 $return = $alipay->wapPay($builder, '', ''); 180 $return = $alipay->wapPay($builder, '', '');
180 print_r($return); 181 print_r($return);