Example #1
0
 /*    */ @RequiresPermissions({"admin:keyword:save"})
 /*    */ @RequestMapping({"/keyword/o_save.do"})
 /*    */ public String save(Keyword bean, HttpServletRequest request, ModelMap model) {
   /* 38 */ Site site = ContextTools.getSite(request);
   /* 39 */ bean = this.service.save(bean, site);
   /* 40 */ log.info("save Keyword id={}", bean.getId());
   /* 41 */ this.logService.operating(
       request, "添加关键字", "id=" + bean.getId() + ";name=" + /* 42 */ bean.getName());
   /* 43 */ model.addAttribute("msg", "关键字添加成功!");
   /* 44 */ return list();
   /*    */ }
Example #2
0
 /*    */ @RequiresPermissions({"admin:keyword:delete"})
 /*    */ @RequestMapping({"/keyword/o_ajax_delete.do"})
 /*    */ public void deleteRole(
     Integer[] ids, HttpServletRequest request, HttpServletResponse response)
     throws JSONException {
   /* 75 */ JSONObject json = new JSONObject();
   /* 76 */ Keyword[] beans = this.service.deleteByIds(ids);
   /* 77 */ for (Keyword bean : beans) {
     /* 78 */ log.info("delete Keyword id={}", bean.getId());
     /* 79 */ this.logService.operating(
         request, "删除关键字", "id=" + bean.getId() + /* 80 */ ";name=" + bean.getName());
     /*    */ }
   /* 82 */ json.put("success", true);
   /* 83 */ json.put("status", 1);
   /* 84 */ ResponseUtils.renderJson(response, json.toString());
   /*    */ }