diff --git a/bookstore/src/main/java/com/fjordtek/bookstore/service/session/BookStorePages.java b/bookstore/src/main/java/com/fjordtek/bookstore/service/session/BookStorePages.java index 30822bb..6afba4a 100644 --- a/bookstore/src/main/java/com/fjordtek/bookstore/service/session/BookStorePages.java +++ b/bookstore/src/main/java/com/fjordtek/bookstore/service/session/BookStorePages.java @@ -51,7 +51,10 @@ public class BookStorePages { RESTCATEGORIES, RESTUSERS, RESTROLES, - RESTUSERROLES + RESTUSERROLES, + RESCSS, + RESJS, + RESIMAGES ; @PostConstruct @@ -89,6 +92,10 @@ public class BookStorePages { this.RESTROLES = env.getProperty("page.url.restapi.roles"); this.RESTUSERROLES = env.getProperty("page.url.restapi.userroles"); + this.RESCSS = env.getProperty("page.url.resources.css"); + this.RESJS = env.getProperty("page.url.resources.js"); + this.RESIMAGES = env.getProperty("page.url.resources.images"); + } } diff --git a/bookstore/src/main/resources/templates/apiref.html b/bookstore/src/main/resources/templates/apiref.html index a1865ee..cd12cfb 100644 --- a/bookstore/src/main/resources/templates/apiref.html +++ b/bookstore/src/main/resources/templates/apiref.html @@ -3,8 +3,8 @@ - - + + page.title.browser.apiref diff --git a/bookstore/src/main/resources/templates/bookadd.html b/bookstore/src/main/resources/templates/bookadd.html index 67ed447..323730f 100644 --- a/bookstore/src/main/resources/templates/bookadd.html +++ b/bookstore/src/main/resources/templates/bookadd.html @@ -3,8 +3,8 @@ <head> <meta http-equiv="Content-Type" content="text/html; charset=UTF-8" /> - <link type="text/css" rel="stylesheet" href="../static/css/bookstore.css" th:href="@{../css/bookstore.css}" /> - <link type="text/css" rel="stylesheet" href="../static/css/bootstrap.min.css" th:href="@{../css/bootstrap.min.css}" /> + <link type="text/css" rel="stylesheet" href="../static/css/bookstore.css" th:href="@{__${@Pages.RESCSS}__/bookstore.css}" /> + <link type="text/css" rel="stylesheet" href="../static/css/bootstrap.min.css" th:href="@{__${@Pages.RESCSS}__/bootstrap.min.css}" /> <title th:text="${#messages.msgOrNull('page.title.browser.add')} ?: 'page.title.browser.add'"> page.title.browser.add diff --git a/bookstore/src/main/resources/templates/bookedit.html b/bookstore/src/main/resources/templates/bookedit.html index aac737d..4057c71 100644 --- a/bookstore/src/main/resources/templates/bookedit.html +++ b/bookstore/src/main/resources/templates/bookedit.html @@ -3,8 +3,8 @@ <head> <meta http-equiv="Content-Type" content="text/html; charset=UTF-8" /> - <link type="text/css" rel="stylesheet" href="../static/css/bookstore.css" th:href="@{../css/bookstore.css}" /> - <link type="text/css" rel="stylesheet" href="../static/css/bootstrap.min.css" th:href="@{../css/bootstrap.min.css}" /> + <link type="text/css" rel="stylesheet" href="../static/css/bookstore.css" th:href="@{__${@Pages.RESCSS}__/bookstore.css}" /> + <link type="text/css" rel="stylesheet" href="../static/css/bootstrap.min.css" th:href="@{__${@Pages.RESCSS}__/bootstrap.min.css}" /> <title th:text="${#messages.msgOrNull('page.title.browser.edit')} ?: 'page.title.browser.edit'"> page.title.browser.edit diff --git a/bookstore/src/main/resources/templates/booklist.html b/bookstore/src/main/resources/templates/booklist.html index 3b517a2..40d5354 100644 --- a/bookstore/src/main/resources/templates/booklist.html +++ b/bookstore/src/main/resources/templates/booklist.html @@ -39,8 +39,8 @@ Idea of the following syntax used in this and other HTML document: */--> - <link type="text/css" rel="stylesheet" href="../static/css/bookstore.css" th:href="@{../css/bookstore.css}" /> - <link type="text/css" rel="stylesheet" href="../static/css/bootstrap.min.css" th:href="@{../css/bootstrap.min.css}" /> + <link type="text/css" rel="stylesheet" href="../static/css/bookstore.css" th:href="@{__${@Pages.RESCSS}__/bookstore.css}" /> + <link type="text/css" rel="stylesheet" href="../static/css/bootstrap.min.css" th:href="@{__${@Pages.RESCSS}__/bootstrap.min.css}" /> <title th:text="${#messages.msgOrNull('page.title.browser.list')} ?: 'page.title.browser.list'"> page.title.browser.list diff --git a/bookstore/src/main/resources/templates/error.html b/bookstore/src/main/resources/templates/error.html index bede37a..1457d61 100644 --- a/bookstore/src/main/resources/templates/error.html +++ b/bookstore/src/main/resources/templates/error.html @@ -3,8 +3,8 @@ <head> <meta http-equiv="Content-Type" content="text/html; charset=UTF-8" /> - <link type="text/css" rel="stylesheet" href="../static/css/bookstore.css" th:href="@{../css/bookstore.css}" /> - <link type="text/css" rel="stylesheet" href="../static/css/bootstrap.min.css" th:href="@{../css/bootstrap.min.css}" /> + <link type="text/css" rel="stylesheet" href="../static/css/bookstore.css" th:href="@{__${@Pages.RESCSS}__/bookstore.css}" /> + <link type="text/css" rel="stylesheet" href="../static/css/bootstrap.min.css" th:href="@{__${@Pages.RESCSS}__/bootstrap.min.css}" /> <title th:text="${#messages.msgOrNull('page.title.browser.error')} ?: 'page.title.browser.error'"> page.title.browser.error diff --git a/bookstore/src/main/resources/templates/statsref.html b/bookstore/src/main/resources/templates/statsref.html index e7fea2b..e844f51 100644 --- a/bookstore/src/main/resources/templates/statsref.html +++ b/bookstore/src/main/resources/templates/statsref.html @@ -3,8 +3,8 @@ <head> <meta http-equiv="Content-Type" content="text/html; charset=UTF-8" /> - <link type="text/css" rel="stylesheet" href="../static/css/bookstore.css" th:href="@{../css/bookstore.css}" /> - <link type="text/css" rel="stylesheet" href="../static/css/bootstrap.min.css" th:href="@{../css/bootstrap.min.css}" /> + <link type="text/css" rel="stylesheet" href="../static/css/bookstore.css" th:href="@{__${@Pages.RESCSS}__/bookstore.css}" /> + <link type="text/css" rel="stylesheet" href="../static/css/bootstrap.min.css" th:href="@{__${@Pages.RESCSS}__/bootstrap.min.css}" /> <title th:text="${#messages.msgOrNull('page.title.browser.statsref')} ?: 'page.title.browser.statsref'"> page.title.browser.statsref