mirror of
				https://gitee.com/hhyykk/ipms-sjy.git
				synced 2025-10-31 10:18:42 +08:00 
			
		
		
		
	实现 SensitiveWord API 实现类
This commit is contained in:
		
							
								
								
									
										71
									
								
								yudao-ui-admin/src/api/system/sensitiveWord.js
									
									
									
									
									
										Normal file
									
								
							
							
						
						
									
										71
									
								
								yudao-ui-admin/src/api/system/sensitiveWord.js
									
									
									
									
									
										Normal file
									
								
							| @@ -0,0 +1,71 @@ | ||||
| import request from '@/utils/request' | ||||
| import qs from 'qs' | ||||
|  | ||||
| // 创建敏感词 | ||||
| export function createSensitiveWord(data) { | ||||
|   return request({ | ||||
|     url: '/system/sensitive-word/create', | ||||
|     method: 'post', | ||||
|     data: data | ||||
|   }) | ||||
| } | ||||
|  | ||||
| // 更新敏感词 | ||||
| export function updateSensitiveWord(data) { | ||||
|   return request({ | ||||
|     url: '/system/sensitive-word/update', | ||||
|     method: 'put', | ||||
|     data: data | ||||
|   }) | ||||
| } | ||||
|  | ||||
| // 删除敏感词 | ||||
| export function deleteSensitiveWord(id) { | ||||
|   return request({ | ||||
|     url: '/system/sensitive-word/delete?id=' + id, | ||||
|     method: 'delete' | ||||
|   }) | ||||
| } | ||||
|  | ||||
| // 获得敏感词 | ||||
| export function getSensitiveWord(id) { | ||||
|   return request({ | ||||
|     url: '/system/sensitive-word/get?id=' + id, | ||||
|     method: 'get' | ||||
|   }) | ||||
| } | ||||
|  | ||||
| // 获得敏感词分页 | ||||
| export function getSensitiveWordPage(query) { | ||||
|   return request({ | ||||
|     url: '/system/sensitive-word/page', | ||||
|     method: 'get', | ||||
|     params: query | ||||
|   }) | ||||
| } | ||||
|  | ||||
| // 导出敏感词 Excel | ||||
| export function exportSensitiveWordExcel(query) { | ||||
|   return request({ | ||||
|     url: '/system/sensitive-word/export-excel', | ||||
|     method: 'get', | ||||
|     params: query, | ||||
|     responseType: 'blob' | ||||
|   }) | ||||
| } | ||||
|  | ||||
| // 获取所有敏感词的标签数组 | ||||
| export function getSensitiveWordTags(){ | ||||
|   return request({ | ||||
|     url: '/system/sensitive-word/get-tags', | ||||
|     method: 'get' | ||||
|   }) | ||||
| } | ||||
|  | ||||
| // 获得文本所包含的不合法的敏感词数组 | ||||
| export function validateText(query) { | ||||
|   return request({ | ||||
|     url: '/system/sensitive-word/validate-text?' + qs.stringify(query, {arrayFormat: 'repeat'}), | ||||
|     method: 'get', | ||||
|   }) | ||||
| } | ||||
		Reference in New Issue
	
	Block a user
	 YunaiV
					YunaiV