|
|
|
@ -387,16 +387,20 @@ class CarInfoHandle |
|
|
|
|
$is_update_failed = 0; |
|
|
|
|
for ($row = 2; $row <= $highestRow; $row++) { |
|
|
|
|
$car_no = trim($worksheet->getCellByColumnAndRow(1, $row)->getValue()); |
|
|
|
|
$car_man = trim($worksheet->getCellByColumnAndRow(2, $row)->getValue()); |
|
|
|
|
$factory_model = trim($worksheet->getCellByColumnAndRow(3, $row)->getValue()); |
|
|
|
|
$engine_no = trim($worksheet->getCellByColumnAndRow(4, $row)->getValue()); |
|
|
|
|
$car_frame_no = trim($worksheet->getCellByColumnAndRow(5, $row)->getValue()); |
|
|
|
|
$register_date = trim($worksheet->getCellByColumnAndRow(6, $row)->getValue()); |
|
|
|
|
$company = trim($worksheet->getCellByColumnAndRow(7, $row)->getValue()); |
|
|
|
|
$insurer1_date = trim($worksheet->getCellByColumnAndRow(8, $row)->getValue()); |
|
|
|
|
$insurer2_date = trim($worksheet->getCellByColumnAndRow(9, $row)->getValue()); |
|
|
|
|
$id_man = trim($worksheet->getCellByColumnAndRow(10, $row)->getValue()); |
|
|
|
|
$id_number = trim($worksheet->getCellByColumnAndRow(11, $row)->getValue()); |
|
|
|
|
$car_number = trim($worksheet->getCellByColumnAndRow(4, $row)->getValue()); |
|
|
|
|
$car_man = trim($worksheet->getCellByColumnAndRow(5, $row)->getValue()); |
|
|
|
|
$factory_model = trim($worksheet->getCellByColumnAndRow(10, $row)->getValue()); |
|
|
|
|
$engine_no = trim($worksheet->getCellByColumnAndRow(3, $row)->getValue()); |
|
|
|
|
$car_frame_no = trim($worksheet->getCellByColumnAndRow(2, $row)->getValue()); |
|
|
|
|
$register_date = substr(trim($worksheet->getCellByColumnAndRow(11, $row)->getValue()), 0, 10); |
|
|
|
|
$company = trim($worksheet->getCellByColumnAndRow(12, $row)->getValue()); |
|
|
|
|
$insurer1_date = substr(trim($worksheet->getCellByColumnAndRow(14, $row)->getValue()), 0, 10); |
|
|
|
|
$insurer2_date = substr(trim($worksheet->getCellByColumnAndRow(13, $row)->getValue()), 0, 10); |
|
|
|
|
$id_man = trim($worksheet->getCellByColumnAndRow(7, $row)->getValue()); |
|
|
|
|
$id_number = trim($worksheet->getCellByColumnAndRow(6, $row)->getValue()); |
|
|
|
|
$insured_man = trim($worksheet->getCellByColumnAndRow(9, $row)->getValue()); |
|
|
|
|
$insured_number = trim($worksheet->getCellByColumnAndRow(8, $row)->getValue()); |
|
|
|
|
|
|
|
|
|
if ($car_frame_no == '') { |
|
|
|
|
continue; |
|
|
|
|
} |
|
|
|
@ -407,6 +411,7 @@ class CarInfoHandle |
|
|
|
|
} |
|
|
|
|
$car_info->car_no = $car_no != '' ? $car_no : $car_info->car_no; |
|
|
|
|
$car_info->car_man = $car_info->car_man != '' ? $car_info->car_man : $car_man; |
|
|
|
|
$car_info->car_number = $car_info->car_number != '' ? $car_info->car_number : $car_number; |
|
|
|
|
$car_info->register_date = $register_date; |
|
|
|
|
$car_info->factory_model = $factory_model; |
|
|
|
|
//对比原信息是否包含待更新信息(删除星号) |
|
|
|
@ -423,6 +428,8 @@ class CarInfoHandle |
|
|
|
|
$car_info->company = $company != '' ? $company : $car_info->company; |
|
|
|
|
$car_info->id_man = $car_info->id_man != '' && startsWith($car_info->id_man, rtrim($id_man, '*')) ? $car_info->id_man : $id_man; |
|
|
|
|
$car_info->id_number = $car_info->id_number != '' && startsWith($car_info->id_number, rtrim($id_number, '*')) ? $car_info->id_number : $id_number; |
|
|
|
|
$car_info->insured_man = $car_info->insured_man != '' && startsWith($car_info->insured_man, rtrim($insured_man, '*')) ? $car_info->insured_man : $insured_man; |
|
|
|
|
$car_info->insured_number = $car_info->insured_number != '' && startsWith($car_info->insured_number, rtrim($insured_number, '*')) ? $car_info->insured_number : $insured_number; |
|
|
|
|
} |
|
|
|
|
$car_info->is_update_bhx = $id; |
|
|
|
|
$car_info->is_export_failed = 0; |
|
|
|
@ -656,4 +663,4 @@ class CarInfoHandle |
|
|
|
|
$export_log->create_timestamp = date('Y-m-d H:i:s'); |
|
|
|
|
$export_log->save(); |
|
|
|
|
} |
|
|
|
|
} |
|
|
|
|
} |
|
|
|
|