diff --git a/webht/third_party/dingtools/controllers/index.php b/webht/third_party/dingtools/controllers/index.php index 103c6de4..a98745af 100644 --- a/webht/third_party/dingtools/controllers/index.php +++ b/webht/third_party/dingtools/controllers/index.php @@ -118,7 +118,7 @@ class index extends CI_Controller { } //创建回调 - public function callback(){ + public function registercallback(){ $access_url = 'https://oapi.dingtalk.com/gettoken?appkey='.$this->AppKey.'&appsecret='.$this->AppSecret; $access_token = GetPost_http($access_url,'',''); $access_token = json_decode($access_token)->access_token; @@ -134,15 +134,13 @@ class index extends CI_Controller { print_r($register); } - public function recivecallback(){ + public function recivecallback(){ $recivejson = file_get_contents('php://input'); - $encrypt = json_decode($recivejson)->encrypt; - echo '{ - "msg_signature":"", - "timeStamp":"'.time().'", - "nonce":"123456", - "encrypt":"'.$encrypt.'" - }'; + log_message('error','dingding回调:'.$recivejson); + log_message('error','signature:'.$_GET['signature']); + log_message('error','timestamp:'.$_GET['timestamp']); + log_message('error','nonce:'.$_GET['nonce']); + log_message('error','get:'.$_GET); } } \ No newline at end of file