|
|
@@ -51,9 +51,18 @@ import java.util.*; |
|
|
|
@Slf4j |
|
|
|
public class MissionServiceImpl extends BaseServiceImpl<ThMissionMapper, ThMission> implements IMissionService { |
|
|
|
|
|
|
|
@Resource |
|
|
|
@Autowired |
|
|
|
private ThMissionMapper thMissionMapper; |
|
|
|
|
|
|
|
@Autowired |
|
|
|
private QuestionMapper questionMapper; |
|
|
|
|
|
|
|
@Autowired |
|
|
|
private ThInspectionMapper inspectionMapper; |
|
|
|
|
|
|
|
@Autowired |
|
|
|
private ReportMapper reportMapper; |
|
|
|
|
|
|
|
@Autowired |
|
|
|
private RedisUtils redisUtils; |
|
|
|
|
|
|
@@ -294,10 +303,18 @@ public class MissionServiceImpl extends BaseServiceImpl<ThMissionMapper, ThMissi |
|
|
|
|
|
|
|
@Override |
|
|
|
public boolean deleteBatch(List<Integer> idList) { |
|
|
|
Integer updateUser = ShiroUtils.getUserId(); |
|
|
|
//Integer updateUser = ShiroUtils.getUserId(); |
|
|
|
ThMission mission=new ThMission(UpdateOrCreateEnum.UPDATE.getCode()); |
|
|
|
mission.setMark(MarkTypeEnum.NOTVALID.getCode()); |
|
|
|
return thMissionMapper.update(mission,new LambdaUpdateWrapper<ThMission>().in(ThMission::getId,idList))>0; |
|
|
|
boolean result=false; |
|
|
|
if(thMissionMapper.update(mission,new LambdaUpdateWrapper<ThMission>().in(ThMission::getId,idList))>0){ |
|
|
|
Integer missionId = mission.getId(); |
|
|
|
questionMapper.delete(new LambdaQueryWrapper<Question>().eq(Question::getMissionId,missionId)); |
|
|
|
inspectionMapper.delete(new LambdaQueryWrapper<ThInspection>().eq(ThInspection::getMissionId,missionId)); |
|
|
|
reportMapper.delete(new LambdaQueryWrapper<Report>().eq(Report::getMissionId,missionId)); |
|
|
|
result=true; |
|
|
|
} |
|
|
|
return result; |
|
|
|
} |
|
|
|
|
|
|
|
@Override |