source: src/main/java/com/example/moviezone/web/HomeController.java@ 27adfc8

Last change on this file since 27adfc8 was adf250d, checked in by DenicaKj <dkorvezir@…>, 22 months ago

Update HomeController.java

  • Property mode set to 100644
File size: 657 bytes
Line 
1package com.example.moviezone.web;
2
3
4import com.example.moviezone.service.FilmService;
5import org.springframework.stereotype.Controller;
6import org.springframework.ui.Model;
7import org.springframework.web.bind.annotation.GetMapping;
8import org.springframework.web.bind.annotation.RequestMapping;
9
10@Controller
11@RequestMapping("/")
12public class HomeController {
13
14private final FilmService filmService;
15
16 public HomeController(FilmService filmService) {
17 this.filmService = filmService;
18 }
19
20 @GetMapping
21 public String getHomePage(Model model) {
22 model.addAttribute("bodyContent", "home");
23 return "master-template";
24 }
25
26
27}
Note: See TracBrowser for help on using the repository browser.