Эх сурвалжийг харах

[fix]
注掉数据清洗接口

limeng 4 сар өмнө
parent
commit
23acd622a4

+ 68 - 69
application-webadmin/src/main/java/com/tourism/webadmin/app/website/controller/CleanDataController.java

@@ -75,74 +75,73 @@ public class CleanDataController {
 //
 //    }
 
-
-    @Autowired
-    private TourTourismProjectTravelNotesService tourTourismProjectTravelNotesService;
-
-    @Autowired
-    private TourTourismTravelNotesContentService tourTourismTravelNotesContentService;
-
-    @Autowired
-    private TourismProjectTravelNotesWriteService tourismProjectTravelNotesWriteService;
-
-    @Autowired
-    private TourismProjectTravelNotesWriteService writeService;
-
-    @Autowired
-    private TourismTravelNotesContentWriteService contentWriteService;
-
-    @SaIgnore
-    @GetMapping("/test")
-    public void moveData(){
-        // 查询原游记信息
-        List<TourTourismProjectTravelNotes> originNoteList = tourTourismProjectTravelNotesService.getTourTourismProjectTravelNotesList(new TourTourismProjectTravelNotes(), "");
-        // 游记主表数据写入write表
-        List<TourismProjectTravelNotesWrite> writeList = new ArrayList<>();
-        List<TourismTravelNotesContentWrite> contentList = new ArrayList<>();
-        originNoteList.forEach(e->{
-            TourismProjectTravelNotesWrite write = new TourismProjectTravelNotesWrite();
-            write.setId(Long.valueOf(e.getId()));
-            write.setProjectTitle(e.getProjectTitle());
-            write.setRemarks(e.getRemarks());
-            //热点
-            write.setIsHotspot(e.getIsHotspot());
-            //标签
-            write.setNoteLabel(e.getProjectLabel());
-            //目的地
-            write.setEndPlace(e.getBelongTab());
-            write.setCountTimes(e.getCountTimes());
-            write.setTourismUrl(e.getTourismUrl());
-            write.setCreateTime(e.getCreateTime());
-            write.setCreateUserId(e.getCreateUserId());
-            write.setUpdateTime(e.getUpdateTime());
-            write.setUpdateUserId(e.getUpdateUserId());
-            write.setDataState(e.getDataState());
-            write.setTravelNotesBanner(e.getTravelNotesBanner());
-            write.setLikeCount(e.getLikeCount());
-            write.setPageViewCount(e.getPageViewCount());
-            write.setRole(e.getRole());
-            write.setDepartureTime(e.getDepartureTime());
-            write.setAverageCost(e.getAverageCost());
-            write.setRecommendationRate(e.getRecommendationRate());
-            write.setHotValue(e.getHotValue());
-            write.setIsOriginal(e.getIsOriginal());
-            write.setState(3);
-            write.setUnmountState(1);
-            writeList.add(write);
-        });
-
-        List<TourTourismTravelNotesContent> originContentList = tourTourismTravelNotesContentService.getTourTourismTravelNotesContentList(new TourTourismTravelNotesContent(), "");
-        // 游记富文本数据写入write_content表
-        originContentList.forEach(e->{
-            List<TourismTravelNotesContentWrite> content = tourismProjectTravelNotesWriteService.parseHTML(e);
-            contentList.addAll(content);
-        });
-
-        log.info("清洗完了~~~");
-
-        writeService.saveNewBatch(writeList);
 //
-        contentWriteService.saveNewBatch(contentList);
-        // 结束
-    }
+//    @Autowired
+//    private TourTourismProjectTravelNotesService tourTourismProjectTravelNotesService;
+//
+//    @Autowired
+//    private TourTourismTravelNotesContentService tourTourismTravelNotesContentService;
+//
+//    @Autowired
+//    private TourismProjectTravelNotesWriteService tourismProjectTravelNotesWriteService;
+//
+//    @Autowired
+//    private TourismProjectTravelNotesWriteService writeService;
+//
+//    @Autowired
+//    private TourismTravelNotesContentWriteService contentWriteService;
+//
+//    @SaIgnore
+//    @GetMapping("/test")
+//    public void moveData(){
+//        // 查询原游记信息
+//        List<TourTourismProjectTravelNotes> originNoteList = tourTourismProjectTravelNotesService.getTourTourismProjectTravelNotesList(new TourTourismProjectTravelNotes(), "");
+//        // 游记主表数据写入write表
+//        List<TourismProjectTravelNotesWrite> writeList = new ArrayList<>();
+//        List<TourismTravelNotesContentWrite> contentList = new ArrayList<>();
+//        originNoteList.forEach(e->{
+//            TourismProjectTravelNotesWrite write = new TourismProjectTravelNotesWrite();
+//            write.setId(Long.valueOf(e.getId()));
+//            write.setProjectTitle(e.getProjectTitle());
+//            write.setRemarks(e.getRemarks());
+//            //热点
+//            write.setIsHotspot(e.getIsHotspot());
+//            //标签
+//            write.setNoteLabel(e.getProjectLabel());
+//            //目的地
+//            write.setEndPlace(e.getBelongTab());
+//            write.setCountTimes(e.getCountTimes());
+//            write.setTourismUrl(e.getTourismUrl());
+//            write.setCreateTime(e.getCreateTime());
+//            write.setCreateUserId(e.getCreateUserId());
+//            write.setUpdateTime(e.getUpdateTime());
+//            write.setUpdateUserId(e.getUpdateUserId());
+//            write.setDataState(e.getDataState());
+//            write.setTravelNotesBanner(e.getTravelNotesBanner());
+//            write.setLikeCount(e.getLikeCount());
+//            write.setPageViewCount(e.getPageViewCount());
+//            write.setRole(e.getRole());
+//            write.setDepartureTime(e.getDepartureTime());
+//            write.setAverageCost(e.getAverageCost());
+//            write.setRecommendationRate(e.getRecommendationRate());
+//            write.setHotValue(e.getHotValue());
+//            write.setIsOriginal(e.getIsOriginal());
+//            write.setState(3);
+//            write.setUnmountState(1);
+//            writeList.add(write);
+//        });
+//
+//        List<TourTourismTravelNotesContent> originContentList = tourTourismTravelNotesContentService.getTourTourismTravelNotesContentList(new TourTourismTravelNotesContent(), "");
+//        // 游记富文本数据写入write_content表
+//        originContentList.forEach(e->{
+//            List<TourismTravelNotesContentWrite> content = tourismProjectTravelNotesWriteService.parseHTML(e);
+//            contentList.addAll(content);
+//        });
+//
+//        log.info("清洗完了~~~");
+//
+//        writeService.saveNewBatch(writeList);
+//        contentWriteService.saveNewBatch(contentList);
+//        // 结束
+//    }
 }