|
@@ -64,7 +64,11 @@ async function analyzeDates(dateArray, startDate, endDate, holiday, takingLeave)
|
|
|
const sortedDates = dateArray.sort((a, b) => a - b);
|
|
|
const currentDay = startDate.clone();
|
|
|
|
|
|
- while (currentDay.isSameOrBefore(endDate, 'day')) {
|
|
|
+ // 日志查询至26号9点,实际截至时间为25号24点
|
|
|
+ // 所以结束时间为endDate - 1天
|
|
|
+ let end = moment(endDate).subtract(1, 'days')
|
|
|
+
|
|
|
+ while (currentDay.isSameOrBefore(end, 'day')) {
|
|
|
let index = -1;
|
|
|
let dayKey = currentDay.format('YYYY-MM-DD');
|
|
|
if (holiday[dayKey] || currentDay.day() === 0 || currentDay.day() === 6) {
|
|
@@ -157,7 +161,7 @@ export async function getData(startTime, endTime, onProcess) {
|
|
|
reportData,
|
|
|
onProcess,
|
|
|
});
|
|
|
-
|
|
|
+ debugger
|
|
|
// 判断员工入职时间和离职时间
|
|
|
await filterByHireDate(employeeData, onProcess);
|
|
|
await filterByResignationDate(employeeData, onProcess);
|