|
@@ -199,9 +199,10 @@ public class WorkHourStatistics {
|
|
|
private void standardMonthlyHour(ChuanyunUserCompanyDO chuanyunUserCompanyDO) {
|
|
|
//删除上一次状态为审核中,但本次已经审核通过的数据
|
|
|
chuanyunSelfCostDao.findAllByStatusAndUserId(ChuanYunConstant.IN_PROCESS,chuanyunUserCompanyDO.getUserId()).forEach(chuanyunSelfCostDO -> {
|
|
|
- List<ChuanyunSelfWorkHourDO> chuanyunSelfWorkHourList=chuanyunSelfWorkHourDao.findAllByUserIdAndProjectIdAndStatusAndDayLogDateBetween(
|
|
|
+ List<ChuanyunSelfWorkHourDO> chuanyunSelfWorkHourList=chuanyunSelfWorkHourDao.findAllByUserIdAndProjectIdAndProjectTypeAndStatusAndDayLogDateBetween(
|
|
|
chuanyunSelfCostDO.getUserId(),
|
|
|
chuanyunSelfCostDO.getProjectId(),
|
|
|
+ chuanyunSelfCostDO.getProjectType(),
|
|
|
ChuanYunConstant.IN_PROCESS,
|
|
|
chuanyunSelfCostDO.getDayLogDate(),
|
|
|
chuanyunSelfCostDO.getDayLogDate().plusMonths(1L));
|
|
@@ -214,6 +215,7 @@ public class WorkHourStatistics {
|
|
|
matchers.add("F0000003_2,"+chuanyunSelfCostDO.getProjectId());
|
|
|
matchers.add("F0000009_2,"+ChuanYunConstant.IN_PROCESS);
|
|
|
matchers.add("F0000002_2,"+chuanyunSelfCostDO.getUserId());
|
|
|
+ matchers.add("F0000008_2,"+chuanyunSelfCostDO.getProjectType());
|
|
|
matchers.add("F0000004_2,"+chuanyunSelfCostDO.getDayLogDate());
|
|
|
var filter= Filter.instance(0,1,true,"And",matchers);
|
|
|
try {
|
|
@@ -254,6 +256,7 @@ public class WorkHourStatistics {
|
|
|
chuanyunSelfCostDO.setDepartmentId(chuanyunUserCompanyDO.getDepartmentId());
|
|
|
ChuanyunSelfCostDO oldSelfDO = chuanyunSelfCostDao.getOldSelfDO(chuanyunSelfCostDO.getUserId(),
|
|
|
chuanyunSelfCostDO.getProjectId(),
|
|
|
+ chuanyunSelfCostDO.getProjectType(),
|
|
|
df.format(chuanyunSelfCostDO.getDayLogDate()),
|
|
|
projectMonth.getStatus());
|
|
|
if (oldSelfDO !=null) {
|