You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
25 lines
748 B
25 lines
748 B
package org.ros.chatto.controller;
|
|
|
|
import java.security.Principal;
|
|
|
|
import org.ros.chatto.service.UserService;
|
|
import org.springframework.beans.factory.annotation.Autowired;
|
|
import org.springframework.stereotype.Controller;
|
|
import org.springframework.web.bind.annotation.RequestMapping;
|
|
import org.springframework.web.servlet.ModelAndView;
|
|
|
|
@Controller
|
|
@RequestMapping("/admin")
|
|
public class AdminController {
|
|
|
|
@Autowired
|
|
private UserService userService;
|
|
|
|
@RequestMapping
|
|
public ModelAndView viewManageUsers(Principal principal) {
|
|
ModelAndView modelAndView = new ModelAndView("/admin/home");
|
|
modelAndView.addObject("user", new String());
|
|
modelAndView.addObject("userNames", userService.getAllRegularUsers());
|
|
return modelAndView;
|
|
}
|
|
}
|