|
...
|
...
|
@@ -33,6 +33,7 @@ use Illuminate\Database\Eloquent\Model; |
|
|
|
use Illuminate\Support\Collection;
|
|
|
|
use Illuminate\Support\Facades\Cache;
|
|
|
|
use Illuminate\Support\Facades\Log;
|
|
|
|
use Illuminate\Support\Str;
|
|
|
|
|
|
|
|
class RankDataLogic extends BaseLogic
|
|
|
|
{
|
|
...
|
...
|
@@ -194,6 +195,11 @@ class RankDataLogic extends BaseLogic |
|
|
|
$data['current_api_no'] = $api_no;
|
|
|
|
$data['current_api_source'] = $api_no == 10690 ? 'Yandex' : 'Google';
|
|
|
|
}
|
|
|
|
$data['api_no'] = $api_no;
|
|
|
|
$bmseo_id = RankDataBmseo::where('project_id', $project_id)->value('id');
|
|
|
|
if($bmseo_id){
|
|
|
|
$data['bmseo_api_no'] = $bmseo_id . '_bmseo';
|
|
|
|
}
|
|
|
|
|
|
|
|
return $data;
|
|
|
|
}
|
|
...
|
...
|
@@ -227,7 +233,12 @@ class RankDataLogic extends BaseLogic |
|
|
|
$ai_projects = $this->getAiProjects()['data'] ?? [];
|
|
|
|
$flg_ai = $this->getAiFlag($ai_projects, $domain);
|
|
|
|
$ai_domain = str_replace('www.', '', $this->getAiProjects($domain)['domain'] ?? '');
|
|
|
|
$list = RankData::where('project_id', $project_id)->where('api_no', $api_no)->where('lang', $lang)->value('data') ?: [];
|
|
|
|
if (Str::endsWith($api_no, '_bmseo')) {
|
|
|
|
$list = RankDataBmseo::where('project_id', $project_id)->where('api_no', $api_no)->where('lang', $lang)->value('data') ?: [];
|
|
|
|
} else {
|
|
|
|
$list = RankData::where('project_id', $project_id)->where('api_no', $api_no)->where('lang', $lang)->value('data') ?: [];
|
|
|
|
}
|
|
|
|
|
|
|
|
$list30 = []; //排名前三十的
|
|
|
|
$list30_0 = []; //排名前三十且近三天没有排名的
|
|
|
|
$list100 = []; //排名前100的
|
...
|
...
|
|