diff --git a/app/api/controller/IndexController.php b/app/api/controller/IndexController.php index a4845ab1..ca6ca230 100644 --- a/app/api/controller/IndexController.php +++ b/app/api/controller/IndexController.php @@ -48,25 +48,25 @@ class IndexController extends BaseApiController $data['monitor'] = []; }else{ $data['monitor']['soil_monitor_data'] = [ - 'wind_direction'=>$landCollection['wind_direction'], - 'wind_speed'=>$landCollection['wind_speed'], - 'air_temperature'=>$landCollection['ambient_temperature'], - 'air_moisture'=>$landCollection['ambient_humidity'], - 'co2_content'=>$landCollection['carbon_dioxide'], - 'pressure'=>$landCollection['ambient_air_pressure'], - 'rainfall'=>$landCollection['rainfall'], - 'light_intensity'=>$landCollection['ambient_lighting'], - 'create_time' => $landCollection['create_time'] + 'soil_temperature'=>$landCollection['soil_temperature'], + 'soil_moisture'=>$landCollection['soil_moisture'], + 'conductivity'=>$landCollection['soil_conductivity'], + 'ph'=>$landCollection['soil_PH'], + 'n_content'=>$landCollection['soil_potassium_phosphate_nitrogen'], + 'p_content'=>$landCollection['soil_potassium_phosphate_phosphorus'], + 'k_content'=>$landCollection['soil_potassium_phosphate_potassium'], + 'create_time' => $landCollection['create_time'] ]; $data['monitor']['air_monitor_data'] = [ - 'soil_temperature'=>$landCollection['soil_temperature'], - 'soil_moisture'=>$landCollection['soil_moisture'], - 'conductivity'=>$landCollection['soil_conductivity'], - 'ph'=>$landCollection['soil_PH'], - 'n_content'=>$landCollection['soil_potassium_phosphate_nitrogen'], - 'p_content'=>$landCollection['soil_potassium_phosphate_phosphorus'], - 'k_content'=>$landCollection['soil_potassium_phosphate_potassium'], - 'create_time' => $landCollection['create_time'] + 'wind_direction'=>$landCollection['wind_direction'], + 'wind_speed'=>$landCollection['wind_speed'], + 'air_temperature'=>$landCollection['ambient_temperature'], + 'air_moisture'=>$landCollection['ambient_humidity'], + 'co2_content'=>$landCollection['carbon_dioxide'], + 'pressure'=>$landCollection['ambient_air_pressure'], + 'rainfall'=>$landCollection['rainfall'], + 'light_intensity'=>$landCollection['ambient_lighting'], + 'create_time' => $landCollection['create_time'] ]; } }