|
@@ -63,7 +63,7 @@
|
|
|
d.checkinDate as checkoffDate,d.exceptionType as checkoffException,e.checkinDate as checkoutDate1,g.checkinDate as checkoutDate2,
|
|
|
f.createdDateTime as leaveCreatedTime, f.startDate as leaveStartDate,
|
|
|
f.endDate as leaveEndDate,f.deductionQuantity as leaveDay,f.`comment` as leaveComment, m.`day` as bukaDay, '正常' as result
|
|
|
- from wx_user a join sap_checkdate b on b.weekday = 1 and a.delFlag=0
|
|
|
+ from wx_user a join sap_checkdate b on a.delFlag=0
|
|
|
and b.checkinDay >= #{startDay} and b.checkinDay <= #{endDay}
|
|
|
LEFT JOIN sap_checkin c on a.userId = c.userId and b.checkinDay = c.checkinDay
|
|
|
LEFT JOIN sap_checkoff d on a.userId = d.userId and b.checkinDay = d.checkinDay
|
|
@@ -83,8 +83,7 @@
|
|
|
replace(group_concat(case when a.checkinDay = '2020-05-14' then a.result else '' end ),',','') as '2020-05-14',
|
|
|
replace(group_concat(case when a.checkinDay = '2020-05-15' then a.result else '' end ),',','') as '2020-05-15'
|
|
|
from sap_check_report a, sap_checkdate b
|
|
|
- where b.weekday = 1 and a.checkinDay=b.checkinDay
|
|
|
- where a.checkinDay >= #{startDay} and a.checkinDay <= #{endDay}
|
|
|
+ where a.checkinDay=b.checkinDay and a.checkinDay >= #{startDay} and a.checkinDay <= #{endDay}
|
|
|
group by a.userId, a.name;
|
|
|
</select>
|
|
|
|
|
@@ -154,7 +153,7 @@
|
|
|
checkinDate,checkinException,checkoffDate,checkoffException,checkoutDate1,checkoutDate2,leaveCreatedTime,
|
|
|
leaveStartDate,leaveEndDate,leaveDay,leaveComment,bukaDay,result
|
|
|
from sap_check_report a, sap_checkdate b, wx_user c
|
|
|
- where b.weekday = 1 and a.checkinDay=b.checkinDay and a.userId = c.userId
|
|
|
+ where a.checkinDay=b.checkinDay and a.userId = c.userId
|
|
|
<if test="departId != null and departId != ''">
|
|
|
and (a.firstDepartId=#{departId} or a.secondDepartId=#{departId})
|
|
|
</if>
|
|
@@ -179,7 +178,7 @@
|
|
|
<select id="findUserReportTotal" resultType="Long">
|
|
|
SELECT count(1)
|
|
|
from sap_check_report a, sap_checkdate b, wx_user c
|
|
|
- where b.weekday = 1 and a.checkinDay=b.checkinDay and a.userId = c.userId
|
|
|
+ where a.checkinDay=b.checkinDay and a.userId = c.userId
|
|
|
<if test="departId != null and departId != ''">
|
|
|
and (a.firstDepartId=#{departId} or a.secondDepartId=#{departId})
|
|
|
</if>
|