Commit 80ea368c authored by 廖旭伟's avatar 廖旭伟

病假扣分规则全天1分半天0.5分

parent 107369c2
......@@ -15,6 +15,7 @@ import com.mortals.xhx.module.staff.service.StaffPerformSummaryEditService;
import com.mortals.xhx.module.staff.service.StaffPerformSummaryService;
import lombok.extern.slf4j.Slf4j;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.dao.QueryTimeoutException;
import org.springframework.stereotype.Component;
import org.springframework.util.ObjectUtils;
......@@ -67,6 +68,7 @@ public class StaffCheckSummaryService implements IApplicationStartedService {
try {
StaffCheckSummaryQuery query = cacheService.brpop(KEY_CHECK_SUMMARY_CACHE,60, StaffCheckSummaryQuery.class);
if(!ObjectUtils.isEmpty(query)){
log.info("绩效分数汇总开始:" + JSONObject.toJSONString(query));
if(StringUtils.isNotEmpty(query.getCheckTimeStart())){
Date date = DateUtil.parse(query.getCheckTimeStart(),"yyyy-MM-dd");
query.setCheckTimeStart(DateUtil.beginOfMonth(date).toDateStr());
......@@ -131,7 +133,6 @@ public class StaffCheckSummaryService implements IApplicationStartedService {
checkOtherRecordService.summaryCheck(query);
}
if(query.getCheckType()==null){
log.info("绩效分数汇总开始:"+ JSONObject.toJSONString(query));
checkAttendRecordService.summaryCheck(query);
checkEffectRecordService.summaryCheck(query);
checkGoworkRecordService.summaryCheck(query);
......@@ -152,14 +153,16 @@ public class StaffCheckSummaryService implements IApplicationStartedService {
} catch (InterruptedException e2) {
}
} catch (Exception e) {
// log.error("异常", e);
} catch (QueryTimeoutException e) {
} catch (Exception e) {
log.error("绩效分数汇总异常", e);
try {
Thread.sleep(waitTime);
} catch (InterruptedException e2) {
}
}
}
}
});
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment