Browse Source

修改票据模板

zhongwei
段飞宇 1 year ago
parent
commit
1e675c76d7
  1. 10
      hzims-service/ticket/src/main/java/com/hnac/hzims/ticket/library/service/impl/TicketMatterGroupServiceImpl.java

10
hzims-service/ticket/src/main/java/com/hnac/hzims/ticket/library/service/impl/TicketMatterGroupServiceImpl.java

@ -117,7 +117,13 @@ public class TicketMatterGroupServiceImpl extends BaseServiceImpl<TicketMatterGr
updateById(groupEntity);
List<TwoTicketMatterLibraryEntity> libraryEntityList = new ArrayList<>();
if (CollectionUtil.isNotEmpty(req.getMatterLibraryListOne())) {
libraryEntityList.addAll(req.getMatterLibraryListOne().stream().map(libraryDto -> BeanUtil.copy(libraryDto, TwoTicketMatterLibraryEntity.class)).collect(Collectors.toList()));
libraryEntityList.addAll(req.getMatterLibraryListOne().stream().map(libraryDto -> {
if ("8".equals(groupEntity.getTicketType())){
libraryDto.setType("8");
}
BeanUtil.copy(libraryDto, TwoTicketMatterLibraryEntity.class);
return libraryDto;
}).collect(Collectors.toList()));
}
if (CollectionUtil.isNotEmpty(req.getMatterLibraryListTwo())) {
libraryEntityList.addAll(req.getMatterLibraryListTwo().stream().map(libraryDto -> BeanUtil.copy(libraryDto, TwoTicketMatterLibraryEntity.class)).collect(Collectors.toList()));
@ -160,7 +166,7 @@ public class TicketMatterGroupServiceImpl extends BaseServiceImpl<TicketMatterGr
if (CollectionUtil.isNotEmpty(req.getMatterLibraryListOne())) {
list.addAll(req.getMatterLibraryListOne().stream().map(matterLibrary -> {
TwoTicketMatterLibraryEntity libraryEntity = BeanUtil.copy(matterLibrary, TwoTicketMatterLibraryEntity.class);
if ("8" == req.getTicketType()) {
if ("8".equals(req.getTicketType())) {
libraryEntity.setType("8");
}
libraryEntity.setMatterGroup(groupEntity.getId());

Loading…
Cancel
Save