diff --git a/src/main/java/Team5/SmartTowns/Webpages/WebpageController.java b/src/main/java/Team5/SmartTowns/Webpages/WebpageController.java new file mode 100644 index 0000000000000000000000000000000000000000..9b6e9d2d8cd46f5ac11b195c9db49cbe3cc9423e --- /dev/null +++ b/src/main/java/Team5/SmartTowns/Webpages/WebpageController.java @@ -0,0 +1,32 @@ +package Team5.SmartTowns.Webpages; + + +import org.springframework.web.bind.annotation.GetMapping; +import org.springframework.web.servlet.ModelAndView; +import org.springframework.stereotype.Controller; +@Controller +public class WebpageController { + + + @GetMapping("/Caerleon") + public ModelAndView getCaerleonPage(){ + ModelAndView modelAndView = new ModelAndView("towns/caerleon"); + return modelAndView; + } + + @GetMapping("/Caerphilly") + public ModelAndView getCaerphillyPage(){ + ModelAndView modelAndView = new ModelAndView("towns/caerphilly"); + return modelAndView; + } + + @GetMapping("/Risca") + public ModelAndView getRiscaPage(){ + ModelAndView modelAndView = new ModelAndView("towns/risca"); + return modelAndView; + } + + + + +} diff --git a/src/main/resources/static/test.html b/src/main/resources/static/test.html new file mode 100644 index 0000000000000000000000000000000000000000..98a5d8ce3c443e9b3c9e183848b038b11f2df7de --- /dev/null +++ b/src/main/resources/static/test.html @@ -0,0 +1,11 @@ +<!DOCTYPE html> +<html lang="en"> +<head> + <meta charset="UTF-8"> + <title>asdasd</title> +</head> +<body> +sadasdasdasd + +</body> +</html> \ No newline at end of file diff --git a/src/main/resources/towns/caerleon.html b/src/main/resources/templates/towns/caerleon.html similarity index 100% rename from src/main/resources/towns/caerleon.html rename to src/main/resources/templates/towns/caerleon.html diff --git a/src/main/resources/towns/caerphilly.html b/src/main/resources/templates/towns/caerphilly.html similarity index 100% rename from src/main/resources/towns/caerphilly.html rename to src/main/resources/templates/towns/caerphilly.html diff --git a/src/main/resources/towns/risca.html b/src/main/resources/templates/towns/risca.html similarity index 100% rename from src/main/resources/towns/risca.html rename to src/main/resources/templates/towns/risca.html