|
...
|
...
|
@@ -36,7 +36,7 @@ class CountAllProject extends Command |
|
|
|
public function handle(){
|
|
|
|
// $noSixData = [];
|
|
|
|
$noSixData = $this->NoSixProject();
|
|
|
|
// $sixData = $this->sixProject();
|
|
|
|
$sixData = $this->sixProject();
|
|
|
|
$data = array_merge($noSixData ?? [],$sixData ?? []);
|
|
|
|
echo 'success:' .count($data) . PHP_EOL . date('Y-m-d H:i:s');
|
|
|
|
return true;
|
|
...
|
...
|
@@ -77,13 +77,11 @@ class CountAllProject extends Command |
|
|
|
}
|
|
|
|
|
|
|
|
public function httpGetProxy($url){
|
|
|
|
$ip_port = $this->httpGet("http://proxy.globalso.com/get_proxy.php");
|
|
|
|
$ch1 = curl_init();
|
|
|
|
$timeout = 0;
|
|
|
|
$proxy = 'http://'.$ip_port; // 替换为你的代理 IP 和端口
|
|
|
|
curl_setopt($ch1, CURLOPT_URL, $url);
|
|
|
|
curl_setopt($ch1, CURLOPT_RETURNTRANSFER, true);
|
|
|
|
curl_setopt($ch1, CURLOPT_PROXY, $proxy);
|
|
|
|
curl_setopt($ch1, CURLOPT_PROXY, 'http://69.90.188.183:51395');
|
|
|
|
curl_setopt($ch1, CURLOPT_ENCODING, '');
|
|
|
|
curl_setopt($ch1, CURLOPT_MAXREDIRS, 10);
|
|
|
|
curl_setopt($ch1, CURLOPT_HTTPHEADER, array());
|
|
...
|
...
|
@@ -98,25 +96,6 @@ class CountAllProject extends Command |
|
|
|
return json_decode($content, true);
|
|
|
|
}
|
|
|
|
|
|
|
|
public function httpGet($url){
|
|
|
|
$ch1 = curl_init();
|
|
|
|
$timeout = 0;
|
|
|
|
curl_setopt($ch1, CURLOPT_URL, $url);
|
|
|
|
curl_setopt($ch1, CURLOPT_RETURNTRANSFER, true);
|
|
|
|
curl_setopt($ch1, CURLOPT_ENCODING, '');
|
|
|
|
curl_setopt($ch1, CURLOPT_MAXREDIRS, 10);
|
|
|
|
curl_setopt($ch1, CURLOPT_HTTPHEADER, array());
|
|
|
|
curl_setopt($ch1, CURLOPT_CONNECTTIMEOUT, $timeout);
|
|
|
|
curl_setopt($ch1, CURLOPT_SSL_VERIFYPEER, FALSE);
|
|
|
|
curl_setopt($ch1, CURLOPT_SSL_VERIFYHOST, FALSE);
|
|
|
|
curl_setopt($ch1, CURLOPT_FOLLOWLOCATION, true);
|
|
|
|
curl_setopt($ch1, CURLOPT_CUSTOMREQUEST, 'GET');
|
|
|
|
curl_setopt($ch1, CURLOPT_HTTP_VERSION, CURL_HTTP_VERSION_1_1);
|
|
|
|
$access_txt = curl_exec($ch1);
|
|
|
|
curl_close($ch1);
|
|
|
|
return $access_txt;
|
|
|
|
}
|
|
|
|
|
|
|
|
public function sixProject(){
|
|
|
|
$projectModel = new Project();
|
|
|
|
$manageModel = new ManageHr();
|
...
|
...
|
|