正在显示
1 个修改的文件
包含
10 行增加
和
11 行删除
@@ -220,7 +220,7 @@ public function websiteHtml(Request $request){ | @@ -220,7 +220,7 @@ public function websiteHtml(Request $request){ | ||
220 | $domain = $request->getHost(); | 220 | $domain = $request->getHost(); |
221 | $token = env("WEB_SITE_TOKEN"); | 221 | $token = env("WEB_SITE_TOKEN"); |
222 | $apiUrl = env("API_URL"); | 222 | $apiUrl = env("API_URL"); |
223 | - $requestUrl = $apiUrl."?domain=".$domain."&token=".$token; | 223 | + $requestUrl = $apiUrl."api/get_url_verify_token/?domain=".$domain."&token=".$token; |
224 | @file_put_contents(storage_path('logs/notify_get_url.log'), date('Y-m-d H:i:s') . "接收到通知:". $requestUrl . PHP_EOL, FILE_APPEND); | 224 | @file_put_contents(storage_path('logs/notify_get_url.log'), date('Y-m-d H:i:s') . "接收到通知:". $requestUrl . PHP_EOL, FILE_APPEND); |
225 | 225 | ||
226 | try { | 226 | try { |
@@ -336,10 +336,10 @@ public function deleteDirectory($path) | @@ -336,10 +336,10 @@ public function deleteDirectory($path) | ||
336 | * @param $request | 336 | * @param $request |
337 | * @param string $type | 337 | * @param string $type |
338 | * @param int $traffic | 338 | * @param int $traffic |
339 | - * @param array $files | ||
340 | * @return string | 339 | * @return string |
341 | */ | 340 | */ |
342 | public function transmit($request, $type = self::TYPEVISIT, $traffic = self::TRAFFICZERO){ | 341 | public function transmit($request, $type = self::TYPEVISIT, $traffic = self::TRAFFICZERO){ |
342 | + | ||
343 | if($request->getClientIp() == "127.0.0.1"){ | 343 | if($request->getClientIp() == "127.0.0.1"){ |
344 | return $this->success(); | 344 | return $this->success(); |
345 | } | 345 | } |
@@ -363,12 +363,9 @@ public function transmit($request, $type = self::TYPEVISIT, $traffic = self::TRA | @@ -363,12 +363,9 @@ public function transmit($request, $type = self::TYPEVISIT, $traffic = self::TRA | ||
363 | $req["type"] = $type; | 363 | $req["type"] = $type; |
364 | $req["traffic"] = $traffic; | 364 | $req["traffic"] = $traffic; |
365 | 365 | ||
366 | - @file_put_contents(storage_path('logs/notify_send.log'), date('Y-m-d H:i:s') . "请求:". $req . PHP_EOL, FILE_APPEND); | ||
367 | //转发接口 | 366 | //转发接口 |
368 | $transmitUrl = env("TRANSMIT_URL"); | 367 | $transmitUrl = env("TRANSMIT_URL"); |
369 | - $resp = $this->httpPost($transmitUrl,json_encode($req)); | ||
370 | - @file_put_contents(storage_path('logs/notify_send.log'), date('Y-m-d H:i:s') . "响应:". $resp . PHP_EOL, FILE_APPEND); | ||
371 | - return $resp; | 368 | + return $this->httpPost($transmitUrl."api/selfSiteApi/",json_encode($req)); |
372 | } | 369 | } |
373 | 370 | ||
374 | /** | 371 | /** |
@@ -559,6 +556,7 @@ public function inquiryQd(Request $request){ | @@ -559,6 +556,7 @@ public function inquiryQd(Request $request){ | ||
559 | /** | 556 | /** |
560 | * 搜索 | 557 | * 搜索 |
561 | * @param Request $request | 558 | * @param Request $request |
559 | + * @return mixed|string | ||
562 | */ | 560 | */ |
563 | public function search(Request $request) | 561 | public function search(Request $request) |
564 | { | 562 | { |
@@ -567,17 +565,18 @@ public function search(Request $request) | @@ -567,17 +565,18 @@ public function search(Request $request) | ||
567 | //获取搜索参数 | 565 | //获取搜索参数 |
568 | $data["search_content"] = ''; | 566 | $data["search_content"] = ''; |
569 | if (isset($data['s'])) { | 567 | if (isset($data['s'])) { |
570 | - $data["search_content"] = $searchContent = $data['s']; | 568 | + $req["search_content"] = $searchContent = $data['s']; |
571 | } | 569 | } |
572 | if (isset($data['search'])) { | 570 | if (isset($data['search'])) { |
573 | - $data["search_content"] = $data['search']; | 571 | + $req["search_content"] = $data['search']; |
574 | } | 572 | } |
575 | 573 | ||
576 | //分页 | 574 | //分页 |
577 | - $data["page"] = isset($data['page']) && (int)$data['page'] > 1 ? (int)$data['page'] : 1; | 575 | + $req["page"] = isset($data['page']) && (int)$data['page'] > 1 ? (int)$data['page'] : 1; |
578 | 576 | ||
579 | //转发data | 577 | //转发data |
580 | - | ||
581 | - | 578 | + $transmitUrl = env("API_URL"); |
579 | + $resp = $this->httpPost($transmitUrl."api/get_search_content/",json_encode($req)); | ||
580 | + return $resp["html"]; | ||
582 | } | 581 | } |
583 | } | 582 | } |
-
请 注册 或 登录 后发表评论