作者 赵彬吉

update

@@ -431,9 +431,10 @@ class RelayInquiry extends Command @@ -431,9 +431,10 @@ class RelayInquiry extends Command
431 } 431 }
432 $this->logChannel()->info('随机域名', array_column($random_data, 'url')); 432 $this->logChannel()->info('随机域名', array_column($random_data, 'url'));
433 foreach ($random_data as $item) { 433 foreach ($random_data as $item) {
434 - //需要多个ip访问的国家 随机2-5次访问,只有一次询盘  
435 $times = 1; 434 $times = 1;
436 $inquiry_time = 1; 435 $inquiry_time = 1;
  436 +
  437 + //需要多个ip访问的国家 随机2-5次访问,只有一次询盘
437 if (in_array($form->country_name, $this->multiple_ip_visit_country)) { 438 if (in_array($form->country_name, $this->multiple_ip_visit_country)) {
438 $times = mt_rand(2, 5); //随机次数 439 $times = mt_rand(2, 5); //随机次数
439 $inquiry_time = mt_rand(1, $times); //第几次询盘 440 $inquiry_time = mt_rand(1, $times); //第几次询盘
@@ -480,10 +481,12 @@ class RelayInquiry extends Command @@ -480,10 +481,12 @@ class RelayInquiry extends Command
480 $pre = 0; 481 $pre = 0;
481 $start_time = time(); 482 $start_time = time();
482 $seconds = rand(300, 7200); // 开始时间 从5-2小时后开始 483 $seconds = rand(300, 7200); // 开始时间 从5-2小时后开始
483 - $exists = ReInquiryDetail::where('re_website', $domain)->where('email', $form->email)->first();  
484 - if($exists){  
485 - $this->output('转发站点邮件已存在');  
486 - continue; 484 + if($is_inquiry) {
  485 + $exists = ReInquiryDetail::where('re_website', $domain)->where('email', $form->email)->first();
  486 + if ($exists) {
  487 + $this->output('转发站点邮件已存在');
  488 + continue;
  489 + }
487 } 490 }
488 // 写入推送详情 491 // 写入推送详情
489 $re_detail = ReInquiryDetail::createInquiry($task['id'], $form->id, $domain, $country_name, $ip, $form->full_name, $form->email, $phone, $message, $message_id, $device_port, 492 $re_detail = ReInquiryDetail::createInquiry($task['id'], $form->id, $domain, $country_name, $ip, $form->full_name, $form->email, $phone, $message, $message_id, $device_port,