Browse Source

增加时间字段,可以直接用子表统计

gogs 2 months ago
parent
commit
b4c69840a1
2 changed files with 2 additions and 0 deletions
  1. 1 0
      app/Service/DeviceWorkService.php
  2. 1 0
      app/Service/PersonWorkService.php

+ 1 - 0
app/Service/DeviceWorkService.php

@@ -468,6 +468,7 @@ class DeviceWorkService extends Service
                     'total_work_min' => $value['total_work_min'],
                     'crt_time' => $time,
                     'top_depart_id' => $value['top_depart_id'],
+                    'order_time' => $data['order_time'] ?? 0
                 ];
             }
             if(! empty($unit)) DailyDwOrderDetails::insert($unit);

+ 1 - 0
app/Service/PersonWorkService.php

@@ -450,6 +450,7 @@ class PersonWorkService extends Service
                     'total_work_min' => $value['total_work_min'],
                     'crt_time' => $time,
                     'top_depart_id' => $value['top_depart_id'],
+                    'order_time' =>  $data['order_time'] ?? 0,
                 ];
             }
             if(! empty($unit)) DailyPwOrderDetails::insert($unit);