dever 5 years ago
parent
commit
881cda15d9
2 changed files with 7 additions and 0 deletions
  1. 6 0
      README.md
  2. 1 0
      lib/Wechat.php

+ 6 - 0
README.md

@@ -24,4 +24,10 @@ $result = Dever::load('pay/api')->get(1, $param);
 
 //测试地址
 http://192.168.33.10/grow/pay/?api.get?account_id=1&uid=10&username=test&product_id=1&name=test&cash=1&refer=2&json=1
+
+
+//notify地址,需要做下rewrite 如nginx:
+if ( $request_uri ~* /pay/notify ) {
+   rewrite ^/pay/notify/([0-9+]) /pay/index.php?l=api.notify&account_id=$1 last;
+}
 ```

+ 1 - 0
lib/Wechat.php

@@ -10,6 +10,7 @@ class Wechat extends Core
 		$this->config = new \WxPayConfig();
 		# 通知接口
 		$config['notify'] = $this->url($config['type'], $config['id']);
+		echo $config['notify'];die;
 		# 证书
 		$config['ssl'] = array
 		(