<div th:text="${@urlService.getApplicationUrl()}">...</div>
@Service 어노테이션으로 빈에 등록되어 사용이 가능합니다.
ref : https://stackoverflow.com/questions/43841458/how-to-call-a-service-method-with-thymeleaf
'Spring Boot' 카테고리의 다른 글
[Spring] REST API로 파일 보내기 (0) | 2023.08.10 |
---|---|
[Swagger] swagger-ui.html 접속 url 변경하기 (리다이렉트) (0) | 2023.08.09 |
[Spring] Lombok을 이용한 간단한 의존성 생성자 주입 (0) | 2023.08.01 |
[Spring] List를 Page로 변환하기 (0) | 2023.07.12 |
[Spring] @OneToMany @ManyToOne 정리 (0) | 2023.05.25 |