强子线路表
This commit is contained in:
@@ -16,19 +16,26 @@ $product_model = new Product;
|
||||
$product_list = $product_model->field('Id,Token')->fetchAll();
|
||||
|
||||
// //测试用
|
||||
// $xingxing_data = get_product(__DIR__ . '/data/xingxing.csv');
|
||||
// $xingxing_f = fopen(__DIR__ . '/data/xingxing.csv', 'w');
|
||||
// $time = time();
|
||||
// $noce = md5(time());
|
||||
// $apikey = 'd50f2b2ffd421efa67df8efb96d5ff6c';
|
||||
// $sign = md5($time.$noce.$apikey);
|
||||
// $url = "http://106.54.198.154/api/getNodeList?agentid=admin1&ti=".$time."&nonce=".$noce."&sign=".$sign;
|
||||
// $xingxing = json_decode(file_get_contents($url), true)['data'];
|
||||
// //写入星星文件
|
||||
// xingxing_getList($xingxing, $xingxing_f, $all, $xingxing_data);
|
||||
// fclose($xingxing_f);
|
||||
// die;
|
||||
$time = time();
|
||||
$noce = md5(time());
|
||||
$apikey = 'a77160a26aa0c4f8bb68c85e5e2c73d8';
|
||||
$sign = md5($time.$noce.$apikey);
|
||||
$url = "http://47.92.65.184:2223/api/getNodeList?agentid=admin2&ti=".$time."&nonce=".$noce."&sign=".$sign;
|
||||
|
||||
$qiangzi = json_decode(file_get_contents($url), true);
|
||||
print_r($qiangzi);die;
|
||||
if(!empty($qiangzi)){
|
||||
$qiangzi_data = get_product(__DIR__ . '/data/qiangzi.csv');
|
||||
$qiangzi_f = fopen(__DIR__ . '/data/qiangzi.csv', 'w');
|
||||
|
||||
//写入强子文件
|
||||
qiangzi_getList($qiangzi, $qiangzi_f, $all, $qiangzi_data);
|
||||
fclose($qiangzi_f);
|
||||
}
|
||||
|
||||
die;
|
||||
|
||||
///////////////////////////////////////////////////////////////////////////////////////////////////////////////////////
|
||||
|
||||
$all = fopen(__DIR__ . '/data/all.csv', 'w');
|
||||
$dnx_exit = fopen(__DIR__ . '/data/dns_diff.csv', 'a');
|
||||
@@ -193,11 +200,6 @@ function qiangzi_getList($data, &$file, &$all, $exit)
|
||||
$record['maxuser'] = $info['maxuser'];
|
||||
$record['online'] = $info['online'] == 1 ? '正常' : '故障';
|
||||
|
||||
//强子沈阳修改
|
||||
if($record['city'] == '沈阳市' || $record['city'] == '沈阳市2'){
|
||||
$record['online'] = '故障';
|
||||
}
|
||||
|
||||
$record['status'] = $status[$info['status']];
|
||||
|
||||
if (strpos($info['description'], '省混')) {
|
||||
|
||||
Reference in New Issue
Block a user