Exemplo n.º 1
0
 @RequestMapping(value = "/addTag", method = RequestMethod.POST)
 public String addTag(ModelMap model, Tag tag) throws ServiceException {
   if (tag.getTagName().length() != 0) {
     tagService.addTag(tag.getTagName());
   }
   fillingTags(model, 0);
   return "addUpdateTags";
 }
Exemplo n.º 2
0
 @RequestMapping(value = "/updateTag", method = RequestMethod.POST)
 public String updateTag(ModelMap model, Tag tag) throws ServiceException {
   if (tag.getTagName().length() == 0) {
     tagService.deleteTag(tag.getTagId());
   } else {
     tagService.editTag(tag.getTagId(), tag.getTagName());
   }
   fillingTags(model, 0);
   return "addUpdateTags";
 }