shudonghui 1 년 전
부모
커밋
e00d24704c
1개의 변경된 파일3개의 추가작업 그리고 3개의 파일을 삭제
  1. 3 3
      sop-business/src/main/resources/mapper/TBDingMapper.xml

+ 3 - 3
sop-business/src/main/resources/mapper/TBDingMapper.xml

@@ -269,9 +269,9 @@
         SELECT d.*,d.axis_in_x AS axis_x, d.axis_in_y AS axis_y,d.sign_in_address address, d.sign_in_time sign_time,'IN' AS type FROM t_b_ding d UNION ALL
         SELECT d.*,d.axis_out_x AS axis_x, d.axis_out_y AS axis_y,d.sign_out_address address, d.sign_out_time sign_time,'OUT' AS type FROM t_b_ding d
         where
-        date_format(from_unixtime(d.create_time/1000),'%Y-%m-%d') != date_format(now(),'%Y-%m-%d') or
-        (d.sign_out_time is not null and
-        date_format(from_unixtime(d.create_time/1000),'%Y-%m-%d') = date_format(now(),'%Y-%m-%d'))
+        d.sign_out_time is not null  or
+        (d.sign_out_time is  null and
+        date_format(from_unixtime(d.create_time/1000),'%Y-%m-%d') != date_format(now(),'%Y-%m-%d'))
         ) d
         LEFT JOIN t_b_user_archives ua ON ua.id = d.user_archives_id
         LEFT JOIN t_b_user_archives_supplier us ON us.user_archives_id = ua.id