Commit ddc111c9 authored by 廖旭伟's avatar 廖旭伟

测试bug修改

parent 023b79ab
......@@ -7,9 +7,7 @@ import com.mortals.xhx.base.system.user.service.UserService;
import com.mortals.xhx.common.code.CheckTypeEnum;
import com.mortals.xhx.module.dept.model.DeptEntity;
import com.mortals.xhx.module.dept.service.DeptService;
import com.mortals.xhx.module.perform.model.PerformDeptConfDetailEntity;
import com.mortals.xhx.module.perform.model.PerformDeptConfDetailQuery;
import com.mortals.xhx.module.perform.model.PerformRulesCategoryEntity;
import com.mortals.xhx.module.perform.model.*;
import com.mortals.xhx.module.perform.service.PerformDeptConfDetailService;
import com.mortals.xhx.module.perform.service.PerformRulesCategoryService;
import org.apache.commons.collections4.CollectionUtils;
......@@ -19,7 +17,6 @@ import com.mortals.framework.service.impl.AbstractCRUDServiceImpl;
import com.mortals.framework.exception.AppException;
import com.mortals.framework.model.Context;
import com.mortals.xhx.module.perform.dao.PerformDeptConfDao;
import com.mortals.xhx.module.perform.model.PerformDeptConfEntity;
import com.mortals.xhx.module.perform.service.PerformDeptConfService;
import lombok.extern.slf4j.Slf4j;
import org.springframework.util.ObjectUtils;
......@@ -92,6 +89,12 @@ public class PerformDeptConfServiceImpl extends AbstractCRUDServiceImpl<PerformD
item.setId(null);
}
performDeptConfDetailService.save(entity.getDeptConfDetail(), context);
}else {
List<PerformDeptConfDetailEntity> list = performDeptConfDetailService.find(new PerformDeptConfDetailQuery().deptConfId(entity.getId()));
if(CollectionUtils.isNotEmpty(list)){
Long[] ids = list.stream().map(PerformDeptConfDetailEntity::getId).toArray(Long[]::new);
performDeptConfDetailService.remove(ids,context);
}
}
}
......@@ -133,6 +136,12 @@ public class PerformDeptConfServiceImpl extends AbstractCRUDServiceImpl<PerformD
} else {
entity.setOtherCount(0);
}
}else {
entity.setAttendCount(0);
entity.setAssessCount(0);
entity.setWorkCount(0);
entity.setOtherCount(0);
entity.setEffectCount(0);
}
}
......@@ -152,6 +161,12 @@ public class PerformDeptConfServiceImpl extends AbstractCRUDServiceImpl<PerformD
item.setId(null);
}
performDeptConfDetailService.save(entity.getDeptConfDetail(), context);
}else {
List<PerformDeptConfDetailEntity> list = performDeptConfDetailService.find(new PerformDeptConfDetailQuery().deptConfId(entity.getId()));
if(CollectionUtils.isNotEmpty(list)){
Long[] ids = list.stream().map(PerformDeptConfDetailEntity::getId).toArray(Long[]::new);
performDeptConfDetailService.remove(ids,context);
}
}
}
......
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