| | |
| | | import com.ruoyi.common.core.utils.page.PageDTO; |
| | | import io.swagger.annotations.Api; |
| | | import io.swagger.annotations.ApiOperation; |
| | | import io.swagger.annotations.ApiParam; |
| | | import lombok.RequiredArgsConstructor; |
| | | import org.springframework.validation.annotation.Validated; |
| | | import org.springframework.web.bind.annotation.DeleteMapping; |
| | | import org.springframework.web.bind.annotation.PathVariable; |
| | | import org.springframework.web.bind.annotation.PostMapping; |
| | | import org.springframework.web.bind.annotation.RequestBody; |
| | | import org.springframework.web.bind.annotation.RequestMapping; |
| | |
| | | sensitiveWordsService.saveSensitiveWords(dto); |
| | | return R.ok(); |
| | | } |
| | | |
| | | /** |
| | | * 上传敏感词 |
| | | * |
| | | * @param id 敏感词id |
| | | */ |
| | | @ApiOperation("删除敏感词") |
| | | @DeleteMapping("/{id}") |
| | | public R<?> delSensitiveWords( |
| | | @ApiParam(name = "id", value = "敏感词id", required = true) @PathVariable("id") Long id) { |
| | | sensitiveWordsService.removeById(id); |
| | | return R.ok(); |
| | | } |
| | | } |