Skill/spring
thymeleaf 에서 include 페이지 조회
진열사랑
2024. 5. 22. 09:44
//thymeleaf의 포함된 페이지로 조회할 때
@AuthMethod(hasAuth = CommonUtil.UserAuth.READONLY)
@PostMapping(value = "/selectTransactionStatement")
public ModelAndView selectTransactionStatement(@RequestBody TIDStatement tidStatement) {
ModelAndView mav = new ModelAndView("transaction/paymentStatement :: paymentStatement");
mav.addObject("tidStatement", paymentService.selectTransactionStatement(tidStatement));
return mav;
}
// JSP
<th:block th:replace="transaction/paymentStatement :: paymentStatement"></th:block>