'require', 'device_id' => 'require', 'wind_direction' => 'require', 'wind_speed' => 'require', 'temperature' => 'require', 'moisture' => 'require', 'co2_content' => 'require', 'pressure' => 'require', 'rainfall' => 'require', 'light_intensity' => 'require', ]; /** * 参数描述 * @var string[] */ protected $field = [ 'id' => 'id', 'device_id' => '设备ID', 'wind_direction' => '风向', 'wind_speed' => '风速', 'temperature' => '空气温度', 'moisture' => '空气湿度', 'co2_content' => '二氧化碳含量', 'pressure' => '大气压强', 'rainfall' => '降雨量', 'light_intensity' => '光照强度', ]; /** * @notes 添加场景 * @return AirMonitorValidate * @author likeadmin * @date 2023/11/24 16:49 */ public function sceneAdd() { return $this->only(['device_id','wind_direction','wind_speed','temperature','moisture','co2_content','pressure','rainfall','light_intensity']); } /** * @notes 编辑场景 * @return AirMonitorValidate * @author likeadmin * @date 2023/11/24 16:49 */ public function sceneEdit() { return $this->only(['id','device_id','wind_direction','wind_speed','temperature','moisture','co2_content','pressure','rainfall','light_intensity']); } /** * @notes 删除场景 * @return AirMonitorValidate * @author likeadmin * @date 2023/11/24 16:49 */ public function sceneDelete() { return $this->only(['id']); } /** * @notes 详情场景 * @return AirMonitorValidate * @author likeadmin * @date 2023/11/24 16:49 */ public function sceneDetail() { return $this->only(['id']); } }