Пример #1
0
 @ResponseBody
 @RequestMapping(value = "/pageQuery", method = RequestMethod.POST)
 public void pageQuery(HttpServletRequest request, HttpServletResponse response) {
   NewsRealReceiverBo bo = GsonUtils.wrapDataToEntity(request, NewsRealReceiverBo.class);
   PageVo pageVo = newsRealReceiverService.pageQuery(bo);
   GsonUtils.printData(response, pageVo);
 }
Пример #2
0
 @RequestMapping(value = "/update", method = RequestMethod.POST)
 @ResponseBody
 public void update(HttpServletRequest request, HttpServletResponse response) {
   NewsRealReceiver newsRealReceiver = GsonUtils.wrapDataToEntity(request, NewsRealReceiver.class);
   newsRealReceiverService.update(newsRealReceiver);
   GsonUtils.printSuccess(response);
 }
Пример #3
0
 @ResponseBody
 @RequestMapping(
     value = "/get",
     params = {"id"},
     method = RequestMethod.GET)
 public void findById(@RequestParam String id, HttpServletResponse response) {
   NewsRealReceiverVo vo = newsRealReceiverService.findById(id);
   GsonUtils.printData(response, vo);
 }
Пример #4
0
 @ResponseBody
 @RequestMapping(
     value = "/delete",
     params = {"ids"},
     method = RequestMethod.DELETE)
 public void deleteByIds(@RequestParam String ids, HttpServletResponse response) {
   String[] idArr = ids.split(",");
   newsRealReceiverService.deleteByIds(idArr);
   GsonUtils.printSuccess(response);
 }