コード例 #1
0
 @RequestMapping(method = RequestMethod.GET)
 public Page<Kriteria> listKriteria(
     @RequestParam(name = "search") String search, Pageable pageable) {
   if (search.equals("")) {
     return kriteriaRepository.findAll(pageable);
   }
   return kriteriaRepository.findBySearch(search, pageable);
 }
コード例 #2
0
 @RequestMapping(value = "/all", method = RequestMethod.GET)
 public Iterable<Kriteria> listKriteria() {
   return kriteriaRepository.findAll();
 }