Browse Source

系统日志导出优化3

master
wanghongjun 6 days ago
parent
commit
bfbe2b7dea
  1. 12
      app/Console/Commands/ScheduledMessageDelivery.php

12
app/Console/Commands/ScheduledMessageDelivery.php

@ -47,10 +47,14 @@ class ScheduledMessageDelivery extends Command
$updated_at = $item['updated_at']; $updated_at = $item['updated_at'];
$updated_times = strtotime($updated_at); $updated_times = strtotime($updated_at);
$diff_times = $now_times - $updated_times; $diff_times = $now_times - $updated_times;
$camera_status = ParkingCamera::query()->where( $res = ParkingCamera::query()->where('id', $item['camera_id'])
'id', ->first();
$item['camera_id'] if ($res) {
)->value('status'); $camera_status = $res['status'];
} else {
// 设备不存在则结束不通知
$camera_status = 1;
}
$updated = [ $updated = [
'updated_at' => $now_time 'updated_at' => $now_time

Loading…
Cancel
Save