作者 lyh

gx

... ... @@ -22,7 +22,7 @@ class GoogleSearchController extends BaseController
* @method :post
* @time :2025/3/27 13:59
*/
public function searchList(){
public function getSearchList(){
$this->request->validate([
'search' => 'required'
],[
... ... @@ -31,8 +31,7 @@ class GoogleSearchController extends BaseController
//获取当前项目域名
$domain = parse_url($this->user['domain'], PHP_URL_HOST);
$googleService = new GoogleSearchService();
$googleService->googleSearch();
$data = [];
$data = $googleService->googleSearch($domain,$this->param['search']);
$this->response('success',Code::SUCCESS,$data);
}
}
... ...
... ... @@ -700,7 +700,10 @@ Route::middleware(['bloginauth'])->group(function () {
Route::prefix('google_keyword_insight')->group(function () {
Route::any('/getKeywordInsight', [\App\Http\Controllers\Bside\GoogleKeywordInsight\GoogleKeywordInsightController::class, 'getKeywordInsight'])->name('google_keyword_insight_getKeywordInsight');
});
//google搜索数据
Route::prefix('google_search')->group(function () {
Route::any('/getSearchList', [\App\Http\Controllers\Bside\GoogleKeywordInsight\GoogleSearchController::class, 'getSearchList'])->name('google_search_getSearchList');
});
//企业产品库
Route::prefix('enterprise_product')->group(function () {
Route::any('/getEnterProduct', [\App\Http\Controllers\Bside\SeoSetting\EnterpriseProductController::class, 'getEnterProduct'])->name('enterprise_product_getEnterProduct');
... ...