h-lab/src/main/java/com/hlab/yanalyst/web/WebController.java
hehihoho3@gmail.com f22f7028c4 refactor: 발행/유통(발행 큐) 기능 제거 — 예능 전환
유통(내가 올려서 발행)에서 예능 소재 파이프라인으로 방향을 틀면서
발행 큐 기능을 제거한다. domain/publish 전체와 발행 준비 UI(재가공 화면),
사이드바 발행 큐 링크, 대시보드 발행 현황 위젯을 걷어냈다.

- domain/publish/* (Controller/Service/Repository/Entity) 삭제
- publish.html · PublishServiceTest 삭제
- rework.html 발행 준비 섹션·JS 제거
- dashboard.html · DashboardService 발행 집계 제거
- WebController /publish 라우트, sidebar 링크 제거
- ChannelVideo.publishedAt(원본 게시일)은 발행 기능과 무관하여 그대로 유지

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
2026-07-23 15:13:46 +09:00

88 lines
2.8 KiB
Java

package com.hlab.yanalyst.web;
import org.springframework.stereotype.Controller;
import org.springframework.ui.Model;
import org.springframework.web.bind.annotation.GetMapping;
@Controller
public class WebController {
private final com.hlab.yanalyst.domain.production.ProductionService productionService;
private final com.hlab.yanalyst.domain.channel.ChannelService channelService;
public WebController(com.hlab.yanalyst.domain.production.ProductionService productionService, com.hlab.yanalyst.domain.channel.ChannelService channelService) {
this.productionService = productionService;
this.channelService = channelService;
}
@GetMapping("/")
public String dashboard(Model model) {
model.addAttribute("currentPage", "dashboard");
return "dashboard";
}
@GetMapping("/channels")
public String channels(Model model) {
model.addAttribute("currentPage", "channels");
model.addAttribute("channels", channelService.getAllChannels());
return "channels";
}
@GetMapping("/videos")
public String videos(Model model) {
model.addAttribute("currentPage", "videos");
return "videos";
}
@GetMapping("/collection")
public String collection(Model model) {
model.addAttribute("currentPage", "collection");
return "collection";
}
@GetMapping("/board")
public String board(Model model) {
model.addAttribute("currentPage", "board");
return "board";
}
@GetMapping("/discover")
public String discover(Model model) {
model.addAttribute("currentPage", "discover");
return "discover";
}
@GetMapping("/recommend")
public String recommend(Model model) {
model.addAttribute("currentPage", "recommend");
return "recommend";
}
@GetMapping("/rework/{id}")
public String rework(@org.springframework.web.bind.annotation.PathVariable Long id, Model model) {
model.addAttribute("currentPage", "collection");
model.addAttribute("videoId", id);
return "rework";
}
@GetMapping("/comment-cards")
public String commentCards(Model model) {
model.addAttribute("currentPage", "comment-cards");
return "comment-cards";
}
@GetMapping("/production")
public String production(Model model) {
model.addAttribute("currentPage", "production");
model.addAttribute("historyList", productionService.getAllHistory());
return "production";
}
@GetMapping("/production/{id}")
public String productionDetail(@org.springframework.web.bind.annotation.PathVariable Long id, Model model) {
model.addAttribute("currentPage", "production");
model.addAttribute("history", productionService.getHistory(id));
return "production_detail";
}
}