From b2a466dfb1a1a676fc760001ecca5506f9cfd8e1 Mon Sep 17 00:00:00 2001 From: "renovate[bot]" <29139614+renovate[bot]@users.noreply.github.com> Date: Sat, 15 Jun 2024 20:44:33 +0530 Subject: [PATCH] fix(deps): update dependency org.webjars.npm:alpinejs to v3.14.0 (#760) * fix(deps): update dependency org.webjars.npm:alpinejs to v3.14.0 * adds webjars locator * Update ReadMe.md --------- Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com> Co-authored-by: Raja Kolli --- retail-store-webapp/ReadMe.md | 4 ++-- retail-store-webapp/pom.xml | 6 +++++- .../webapp/web/controller/ProductController.java | 6 +++--- .../src/main/resources/templates/layout.html | 2 +- test-em-all.sh | 2 +- 5 files changed, 12 insertions(+), 8 deletions(-) diff --git a/retail-store-webapp/ReadMe.md b/retail-store-webapp/ReadMe.md index 68d62040..0b03feec 100644 --- a/retail-store-webapp/ReadMe.md +++ b/retail-store-webapp/ReadMe.md @@ -14,9 +14,9 @@ username: admin password : admin1234 ``` -## UI +## UI -http://localhost:8080 +[Local UI](http://localhost:8080) ## Export realm diff --git a/retail-store-webapp/pom.xml b/retail-store-webapp/pom.xml index ea3d75eb..a50dce34 100644 --- a/retail-store-webapp/pom.xml +++ b/retail-store-webapp/pom.xml @@ -70,6 +70,10 @@ io.opentelemetry opentelemetry-exporter-zipkin + + org.webjars + webjars-locator-core + org.webjars bootstrap @@ -88,7 +92,7 @@ org.webjars.npm alpinejs - 3.13.10 + 3.14.0 diff --git a/retail-store-webapp/src/main/java/com/example/retailstore/webapp/web/controller/ProductController.java b/retail-store-webapp/src/main/java/com/example/retailstore/webapp/web/controller/ProductController.java index 6e196067..fe756f0a 100644 --- a/retail-store-webapp/src/main/java/com/example/retailstore/webapp/web/controller/ProductController.java +++ b/retail-store-webapp/src/main/java/com/example/retailstore/webapp/web/controller/ProductController.java @@ -34,8 +34,8 @@ String showProductsPage(@RequestParam(name = "page", defaultValue = "1") int pag @GetMapping("/api/products") @ResponseBody - PagedResult products(@RequestParam(name = "page", defaultValue = "0") int page, Model model) { - log.info("Fetching products for page: {}", page); - return catalogService.getProducts(page); + PagedResult products(@RequestParam(name = "page", defaultValue = "1") int page, Model model) { + log.info("Fetching products for page: {}", page - 1); + return catalogService.getProducts(page - 1); } } diff --git a/retail-store-webapp/src/main/resources/templates/layout.html b/retail-store-webapp/src/main/resources/templates/layout.html index c1de9e2e..e02a3df1 100644 --- a/retail-store-webapp/src/main/resources/templates/layout.html +++ b/retail-store-webapp/src/main/resources/templates/layout.html @@ -62,7 +62,7 @@ - +