24 lines
586 B
Java
24 lines
586 B
Java
package controller;
|
|
|
|
|
|
import org.springframework.beans.factory.annotation.Autowired;
|
|
import org.springframework.stereotype.Controller;
|
|
import org.springframework.ui.ModelMap;
|
|
import org.springframework.web.bind.annotation.RequestMapping;
|
|
import org.springframework.web.bind.annotation.RequestMethod;
|
|
|
|
import dao.entities.DMPDao;
|
|
|
|
@Controller
|
|
public class UIController {
|
|
|
|
@Autowired private DMPDao dMPDao;
|
|
|
|
@RequestMapping(value = "/home", method = RequestMethod.GET)
|
|
public String printWelcome(ModelMap model) {
|
|
model.addAttribute("DMPs", dMPDao.getAll());
|
|
return "home";
|
|
}
|
|
|
|
}
|