ysh před 3 roky
rodič
revize
e8afdef9dc

+ 8 - 0
jeecg-boot-module-system/src/main/java/org/jeecg/modules/viewClockIn/entity/ViewClockIn.java

@@ -73,6 +73,10 @@ public class ViewClockIn {
 	@Excel(name = "早退分钟数", width = 15)
     @ApiModelProperty(value = "latetimeX")
 	private Integer latetimeX;
+
+	/**加班申请早退时间数 当日加班申请结束时间 与 实际下班打卡时间 ,为负数,则表示打卡时间比下班时间晚,正数则表示比下班时间早 */
+    @ApiModelProperty(value = "workOvertime")
+	private Integer workOvertime;
 	/**用户id*/
     @ApiModelProperty(value = "用户id")
 	private String userId;
@@ -111,6 +115,10 @@ public class ViewClockIn {
 	@Excel(name = "加班事由", width = 15)
     @ApiModelProperty(value = "加班事由")
 	private String demo;
+	/**
+	 * 加班申请时间
+	 */
+	private String commitDate;
 	/**加班时长*/
 	@Excel(name = "加班时长", width = 15)
     @ApiModelProperty(value = "加班时长")

+ 13 - 6
jeecg-boot-module-system/src/main/java/org/jeecg/modules/viewClockIn/mapper/xml/viewClockInMapper.xml

@@ -45,9 +45,11 @@
         select A.depart_name,count(b.username) errornum from sys_depart A left join (
         select b.username,b.depart_names from view_clock_in_1 b
         where DATE_FORMAT(b.view_date,'%Y-%m') = #{viewDate}
-        and (b.lateTime_s < 0 or b.lateTime_x > 0 || b.shift_real_time_s is null || b.shift_real_time_s = '' || (b.ifwork !=0 and attendance_Count < 2)
-            || (b.name is not null and (b.goto_time is null || b.goto_time = '' ||  b.goto_time = null))
-
+        and (
+                b.lateTime_s < 0 or b.lateTime_x > 0
+                || (b.ifwork !=0 and attendance_Count < 2 and b.name is not null)
+                || (b.name is not null and b.name != '' and (b.goto_time is null || b.goto_time = '' ||  b.goto_time = null))
+                || b.duration is not null
             )
 
         and (b.set_info is null or b.set_info = '')
@@ -64,14 +66,19 @@
     <select id="selectUserError" resultType="Map">
 
         select a.username,a.realname,a.depart_ids departids,a.category,b.errornum from sys_user A left join (
-        select b.username,count(1) as errornum from view_clock_in_1 b
+        select b.user_id,count(1) as errornum from view_clock_in_1 b
         where DATE_FORMAT(b.view_date,'%Y-%m') = #{viewDate}
-        and (b.lateTime_s &lt; 0 or b.lateTime_x > 0 || b.shift_real_time_s is null || b.shift_real_time_s = '' || (b.ifwork !=0 and attendance_Count &lt; 2))
+        and (
+            b.lateTime_s &lt; 0 or b.lateTime_x > 0
+            || (b.ifwork !=0 and attendance_Count &lt; 2 and b.name is not null)
             || (b.name is not null and b.name != '' and (b.goto_time is null || b.goto_time = '' ||  b.goto_time = null))
+            || b.duration is not null
+
+            )
         and (b.set_info is null or b.set_info = '')
         group by b.username
         ) B
-        on a.username = b.username
+        on a.id = b.user_id
 
 
     </select>