|
|
@ -47,9 +47,11 @@ class CarInfoHandle |
|
|
|
}); |
|
|
|
}); |
|
|
|
$values = array_slice($arr, 0, $keys_len); |
|
|
|
$values = array_slice($arr, 0, $keys_len); |
|
|
|
$values[$keys_len - 1] = $id; |
|
|
|
$values[$keys_len - 1] = $id; |
|
|
|
return array_combine($keys, $values); |
|
|
|
$data = array_combine($keys, $values); |
|
|
|
|
|
|
|
$data['register_date'] = date('Y-m-d', strtotime($data['register_date'])); |
|
|
|
|
|
|
|
return $data; |
|
|
|
}); |
|
|
|
}); |
|
|
|
$insert_data['register_date'] = date('Y-m-d', strtotime($insert_data['register_date'])); |
|
|
|
|
|
|
|
Db::name('car_info_t')->insertAll($insert_data); |
|
|
|
Db::name('car_info_t')->insertAll($insert_data); |
|
|
|
cache('shell_process_' . $id, round(($i + 2000) / $lines * 100, 3), 300); |
|
|
|
cache('shell_process_' . $id, round(($i + 2000) / $lines * 100, 3), 300); |
|
|
|
echo '当前进度:' . round(round(($i + 2000) / $lines * 100, 3)) . PHP_EOL; |
|
|
|
echo '当前进度:' . round(round(($i + 2000) / $lines * 100, 3)) . PHP_EOL; |
|
|
|