Commit 5e4c965d authored by wdy's avatar wdy

新增车企文件

parent 81a86ca8
......@@ -24,6 +24,7 @@ import org.springframework.stereotype.Service;
import java.util.ArrayList;
import java.util.Date;
import java.util.List;
import java.util.Objects;
/**
* @author wangfei
......@@ -83,6 +84,18 @@ public class ReviewEnterpriseArchiveServiceImpl extends ServiceImpl<ReviewEnterp
throw new ServiceException("新增文件名称重复,请检查", HttpStatus.ERROR);
} else {
reviewEnterpriseArchiveService.save(reviewEnterpriseArchive);
ReviewEnterpriseArchiveFindByTaskIdRequest request = new ReviewEnterpriseArchiveFindByTaskIdRequest();
request.setTaskId(reviewEnterpriseArchive.getTaskId());
List<ReviewEnterpriseArchive> list = reviewEnterpriseArchiveMapper.findEnterpriseArchiveByTaskId(request);
if (list != null && list.size() != 0) {
for (ReviewEnterpriseArchive archive : list) {
if (!Objects.equals(archive.getEnterpriseName(), reviewEnterpriseArchive.getEnterpriseName())) {
archive.setEnterpriseName(reviewEnterpriseArchive.getEnterpriseName());
}
}
reviewEnterpriseArchiveService.updateBatchById(list);
}
}
return reviewEnterpriseArchive.getId();
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment