This commit is contained in:
wucongxing8150 2025-07-28 16:56:40 +08:00
parent 72cc412f50
commit 3f94685c77
2 changed files with 38 additions and 28 deletions

View File

@ -0,0 +1,17 @@
package com.example.caseData.request.CaseClinicalVideoRequest;
import com.fasterxml.jackson.annotation.JsonProperty;
import lombok.Data;
import java.util.List;
@Data
public class deleteClinicalVideoApp {
// 动作add:新增 update:修改 delete:删除
@JsonProperty("action")
private String action;
// 视频编号保利
@JsonProperty("videoNo")
private String videoNo;
}

View File

@ -690,33 +690,26 @@ public class CaseClinicalVideoService {
List<addClinicalVideoApp.Author> addList = new ArrayList<>();
List<CaseClinicalVideoAuthorModel> deleteList = new ArrayList<>();
// // 新增作者和删除作者判断
// // 构建现有作者的唯一标识集合
// Map<String, CaseClinicalVideoAuthorModel> existingAuthorsMap = new HashMap<>();
// for (CaseClinicalVideoAuthorModel a : caseClinicalVideoAuthors) {
// String key = a.getCaseClinicalDoctor().getDoctorIden();
// existingAuthorsMap.put(key, a);
// }
// // 构建新作者的唯一标识集合
// Map<String, addClinicalVideoApp.Author> newAuthorsMap = new HashMap<>();
// for (addClinicalVideoApp.Author a : r.getAuthor()) {
// String key = a.getDoctorIden();
// newAuthorsMap.put(key, a);
// }
// // 找出需要新增的作者
// for (addClinicalVideoApp.Author a : r.getAuthor()) {
// String key = a.getDoctorIden();
// if (!existingAuthorsMap.containsKey(key)) {
// addList.add(a);
// }
// }
// // 找出需要删除的作者
// for (CaseClinicalVideoAuthorModel a : caseClinicalVideoAuthors) {
// String key = a.getDoctorIden();
// if (!newAuthorsMap.containsKey(key)) {
// deleteList.add(a);
// }
// 新增的
for (addClinicalVideoApp.Author a : r.getAuthor()){
for (CaseClinicalVideoAuthorModel b: caseClinicalVideoAuthors){
}
}
// 删除的
// // 获取医生数据
// LambdaQueryWrapper<CaseClinicalDoctorModel> doctorQueryWrapper = new LambdaQueryWrapper<>();
// doctorQueryWrapper.eq(CaseClinicalDoctorModel::getDoctorId, a.getDoctorId());
// CaseClinicalDoctorModel caseClinicalDoctor = caseClinicalDoctorDao.selectOne(doctorQueryWrapper);
// if (caseClinicalDoctor == null) {
// throw new BusinessException("-1", "无法完成此操作");
// }
System.out.println(addList);
System.out.println(deleteList);
}
// 删除
@ -725,11 +718,11 @@ public class CaseClinicalVideoService {
}
throw new BusinessException("-1", "错误");
} catch (Exception e) {
throw new BusinessException("-1", e.getMessage());
}
return true;
// return true;
}
}