shudonghui 1 year ago
parent
commit
ff4b2fc869
1 changed files with 1 additions and 1 deletions
  1. 1 1
      sop-business/src/main/resources/mapper/TBDingMapper.xml

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

@@ -270,7 +270,7 @@
 
     <select id="attendanceCount" resultType="com.qmth.sop.business.bean.result.TBDingAttendanceCountResult">
         SELECT
-        count( d.id ) total,
+        sum( CASE WHEN d.sign_in_time IS NOT NULL THEN 1 ELSE 0 END )+ sum( CASE WHEN d.sign_out_time IS NOT NULL THEN 1 ELSE 0 END ) total,
         sum( CASE WHEN d.sign_in_time IS NULL THEN 1 ELSE 0 END )+ sum( CASE WHEN d.sign_out_time IS NULL THEN 1 ELSE 0 END ) abnormal,
         SUM( CASE WHEN d.sign_in_time IS NOT NULL AND d.sign_out_time IS NOT NULL THEN 1 ELSE 0 END ) all_days,
         SUM( CASE WHEN d.sign_in_time IS NOT NULL AND d.sign_out_time IS NOT NULL THEN