|
|
|
@ -305,15 +305,18 @@ public class AchievementManagementServiceImpl extends ServiceImpl<AchievementMan |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
@Override |
|
|
|
|
public R deleteReportById(Integer projectId,Integer projectPermissions, Integer id) { |
|
|
|
|
if (id != null && projectPermissions == 1){ |
|
|
|
|
public R deleteReportById(List<Integer> projectIds,Integer projectPermissions, List<Integer> ids) { |
|
|
|
|
if (projectPermissions == 1){//实验教学
|
|
|
|
|
for (Integer id: ids) { |
|
|
|
|
List<AchievementManagementVO> teachAchievements = achievementManagementDao.getTeachAchievement(id); |
|
|
|
|
for (AchievementManagementVO teachAchievement :teachAchievements) { |
|
|
|
|
for (AchievementManagementVO teachAchievement : teachAchievements) { |
|
|
|
|
Integer reportId = teachAchievement.getReportId(); |
|
|
|
|
Integer recordId = teachAchievement.getRecordId(); |
|
|
|
|
achievementManagementDao.deleteReport(reportId,recordId); |
|
|
|
|
achievementManagementDao.deleteReport(reportId, recordId); |
|
|
|
|
} |
|
|
|
|
} |
|
|
|
|
}else { |
|
|
|
|
for (Integer projectId: projectIds) {//虚仿实验
|
|
|
|
|
List<AchievementManagementVO> imitationAchievements = achievementManagementDao.getImitationAchievement(projectId); |
|
|
|
|
for (AchievementManagementVO imitationAchievement: imitationAchievements) { |
|
|
|
|
Integer reportId = imitationAchievement.getReportId(); |
|
|
|
@ -321,6 +324,7 @@ public class AchievementManagementServiceImpl extends ServiceImpl<AchievementMan |
|
|
|
|
achievementManagementDao.deleteReport(reportId,recordId); |
|
|
|
|
} |
|
|
|
|
} |
|
|
|
|
} |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
return R.ok(); |
|
|
|
|