Index.php 685 B

123456789101112131415161718192021222324252627
  1. <?php
  2. namespace app\admin\controller;
  3. use payment\wechat\WechatTransfers;
  4. class Index
  5. {
  6. public function index()
  7. {
  8. return redirect('/admin.php/home');
  9. }
  10. public function t1()
  11. {
  12. halt(11);
  13. $batch_name = '测试提现功能';//转账的名称
  14. $out_trade_no = 'lgd'.getUniId();//单号
  15. $money = 1;//金额
  16. $openid = 'o4a9g5ffjsMcXS9wCtTyONqMTdEc';//用户openid
  17. $detail = [];
  18. $transfers = new WechatTransfers();
  19. $detail[] = $transfers->getDetailList($out_trade_no,$money,$batch_name,$openid);
  20. $res = $transfers->transfers($batch_name,$detail);
  21. halt($res);
  22. }
  23. }