|
@@ -33,6 +33,7 @@ import vip.xiaonuo.biz.modular.qyrecardbody.service.QyRecardBodyService;
|
|
|
import vip.xiaonuo.biz.modular.qyrecordattachment.entity.QyRecordAttachment;
|
|
|
import vip.xiaonuo.biz.modular.qyrecordattachment.param.QyRecordAttachmentAddParam;
|
|
|
import vip.xiaonuo.biz.modular.qyrecordattachment.param.QyRecordAttachmentEditParam;
|
|
|
+import vip.xiaonuo.biz.modular.qyrecordattachment.param.QyRecordAttachmentIdParam;
|
|
|
import vip.xiaonuo.biz.modular.qyrecordattachment.service.QyRecordAttachmentService;
|
|
|
import vip.xiaonuo.biz.modular.qyrecordinfochecklist.entity.QyRecordInfoCheckList;
|
|
|
import vip.xiaonuo.biz.modular.qyrecordinfochecklist.service.QyRecordInfoCheckListService;
|
|
@@ -143,6 +144,16 @@ public class QyRecordInfoServiceImpl extends ServiceImpl<QyRecordInfoMapper, QyR
|
|
|
});
|
|
|
qyRecardBodyService.delete(bodyIdParams);
|
|
|
}
|
|
|
+ List<QyRecordAttachment> list_ = qyRecordAttachmentService.list(new LambdaQueryWrapper<QyRecordAttachment>().eq(QyRecordAttachment::getQyRecordInfoId, qyRecordInfo.getId()));
|
|
|
+ if(CollectionUtil.isNotEmpty(list_)){
|
|
|
+ List<String> ids = list.stream().map(qyRecordAttachment -> qyRecordAttachment.getId()).collect(Collectors.toList());
|
|
|
+ List<QyRecordAttachmentIdParam> attachmentIdParams = new ArrayList<>();
|
|
|
+ ids.forEach(id ->{
|
|
|
+ attachmentIdParams.add(new QyRecordAttachmentIdParam(id));
|
|
|
+ });
|
|
|
+ qyRecordAttachmentService.delete(attachmentIdParams);
|
|
|
+ }
|
|
|
+
|
|
|
List<QyRecardBodyEditParam> bodyAddParams = qyRecordInfoEditParam.getQyRecardBodyEditParams();
|
|
|
if (CollectionUtil.isNotEmpty(bodyAddParams)){
|
|
|
bodyAddParams.stream().forEach(qyRecardBodyAddParam -> {
|
|
@@ -152,7 +163,6 @@ public class QyRecordInfoServiceImpl extends ServiceImpl<QyRecordInfoMapper, QyR
|
|
|
qyRecardBodyService.save(qyRecardBody);
|
|
|
});
|
|
|
}
|
|
|
-
|
|
|
List<QyRecordAttachmentEditParam> attachmentEditParams = qyRecordInfoEditParam.getQyRecordAttachmentEditParams();
|
|
|
if(CollectionUtil.isNotEmpty(attachmentEditParams)){
|
|
|
attachmentEditParams.stream().forEach(qyRecordAttachmentAddParam -> {
|