发布添加完成人数
This commit is contained in:
parent
5b6bc557e7
commit
4cb0e50a66
|
@ -46,4 +46,6 @@ public interface SysEvaluationRecordMapper extends BaseMapperPlus<SysEvaluationR
|
||||||
List<StatisticNumVo> selectFactorNum(@Param("batchNo") Long batchNo, @Param("scaleId") Long scaleId);
|
List<StatisticNumVo> selectFactorNum(@Param("batchNo") Long batchNo, @Param("scaleId") Long scaleId);
|
||||||
List<StatisticNumVo> selectFactorWarnNum(@Param("batchNo") Long batchNo, @Param("scaleId") Long scaleId,@Param("list")List<Integer> warnList);
|
List<StatisticNumVo> selectFactorWarnNum(@Param("batchNo") Long batchNo, @Param("scaleId") Long scaleId,@Param("list")List<Integer> warnList);
|
||||||
|
|
||||||
|
int selectUndoneNumByBatchNoAndUserId(@Param("batchNo") Long batchNo,@Param("userId") Long userId);
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
|
@ -37,4 +37,5 @@ public interface SysScalePublishMapper extends BaseMapperPlus<SysScalePublish, S
|
||||||
|
|
||||||
int selectCountScalePublish();
|
int selectCountScalePublish();
|
||||||
|
|
||||||
|
void addCompleteNum(Long batchNo);
|
||||||
}
|
}
|
||||||
|
|
|
@ -151,6 +151,7 @@ public class WebServiceImpl implements IWebService {
|
||||||
}
|
}
|
||||||
SysScalePublishVo scalePublishVo = recordMapper.selectPublishByUseRecord(recordId);
|
SysScalePublishVo scalePublishVo = recordMapper.selectPublishByUseRecord(recordId);
|
||||||
//查询考核结果
|
//查询考核结果
|
||||||
|
Long batchNo = scalePublishVo.getBatchNo();
|
||||||
if (scalePublishVo.getAllowQueryResult() == 0) {
|
if (scalePublishVo.getAllowQueryResult() == 0) {
|
||||||
allowQueryResult = false;
|
allowQueryResult = false;
|
||||||
}
|
}
|
||||||
|
@ -167,6 +168,10 @@ public class WebServiceImpl implements IWebService {
|
||||||
update.setUpdateTime(new Date());
|
update.setUpdateTime(new Date());
|
||||||
recordMapper.updateById(update);
|
recordMapper.updateById(update);
|
||||||
|
|
||||||
|
int undoneNum = recordMapper.selectUndoneNumByBatchNoAndUserId(batchNo, loginUser.getUserId());
|
||||||
|
if (undoneNum <= 1) {
|
||||||
|
publishMapper.addCompleteNum(batchNo);
|
||||||
|
}
|
||||||
Integer riskLevel = -1;
|
Integer riskLevel = -1;
|
||||||
//选择风险等级最高
|
//选择风险等级最高
|
||||||
for (SysEvaluationConclusionVo ec : list) {
|
for (SysEvaluationConclusionVo ec : list) {
|
||||||
|
@ -177,13 +182,14 @@ public class WebServiceImpl implements IWebService {
|
||||||
List<Integer> used = warnMapper.selectUseConfig();
|
List<Integer> used = warnMapper.selectUseConfig();
|
||||||
if (used.contains(riskLevel)) {
|
if (used.contains(riskLevel)) {
|
||||||
SysWarnRecord wre = new SysWarnRecord();
|
SysWarnRecord wre = new SysWarnRecord();
|
||||||
wre.setBatchNo(scalePublishVo.getBatchNo());
|
wre.setBatchNo(batchNo);
|
||||||
wre.setUserId(loginUser.getUserId());
|
wre.setUserId(loginUser.getUserId());
|
||||||
wre.setDeptId(loginUser.getDeptId());
|
wre.setDeptId(loginUser.getDeptId());
|
||||||
wre.setWarnTime(new Date());
|
wre.setWarnTime(new Date());
|
||||||
wre.setSituation(riskLevel);
|
wre.setSituation(riskLevel);
|
||||||
warnRecordService.insertByBo(wre);
|
warnRecordService.insertByBo(wre);
|
||||||
}
|
}
|
||||||
|
|
||||||
//不允许查看考核结果
|
//不允许查看考核结果
|
||||||
if (!allowQueryResult) {
|
if (!allowQueryResult) {
|
||||||
return null;
|
return null;
|
||||||
|
|
|
@ -110,4 +110,12 @@
|
||||||
where sf.scale_id = #{scaleId}
|
where sf.scale_id = #{scaleId}
|
||||||
group by sf.factor_id
|
group by sf.factor_id
|
||||||
</select>
|
</select>
|
||||||
|
|
||||||
|
<select id="selectUndoneNumByBatchNoAndUserId" resultType="int">
|
||||||
|
select count(*)
|
||||||
|
from sys_evaluation_record
|
||||||
|
where batch_no = #{batchNo}
|
||||||
|
and user_id= #{userId}
|
||||||
|
and status < 1
|
||||||
|
</select>
|
||||||
</mapper>
|
</mapper>
|
||||||
|
|
|
@ -89,4 +89,10 @@
|
||||||
select count(*)
|
select count(*)
|
||||||
from sys_scale_publish
|
from sys_scale_publish
|
||||||
</select>
|
</select>
|
||||||
|
|
||||||
|
<select id="addCompleteNum" >
|
||||||
|
update sys_scale_publish
|
||||||
|
set complete_num = complete_num + 1
|
||||||
|
where batch_no = #{batchNo}
|
||||||
|
</select>
|
||||||
</mapper>
|
</mapper>
|
||||||
|
|
Loading…
Reference in New Issue