[Spring][쇼핑몰 프로젝트][15] 작가목록 기능 구현 - 4

https://kimvampa.tistory.com/186
This commit is contained in:
SeoJin Kim
2021-03-12 08:31:15 +09:00
parent f4ad236265
commit cee5f89f3d
6 changed files with 198 additions and 42 deletions

View File

@@ -60,7 +60,11 @@ public class AdminController {
/* 작가 목록 출력 데이터 */
List list = authorService.authorGetList(cri);
model.addAttribute("list", list);
if(!list.isEmpty()) {
model.addAttribute("list",list); // 작가 존재 경우
} else {
model.addAttribute("listCheck", "empty"); // 작가 존재하지 않을 경우
}
/* 페이지 이동 인터페이스 데이터 */
model.addAttribute("pageMaker", new PageDTO(cri, authorService.authorGetTotal(cri)));