mirror of
				https://github.com/continew-org/continew-admin-ui.git
				synced 2025-10-31 10:57:10 +08:00 
			
		
		
		
	fix: 修复全部已读调用接口错误
This commit is contained in:
		| @@ -16,7 +16,7 @@ export function deleteMessage(ids: Array<string>) { | ||||
| } | ||||
|  | ||||
| /** @desc 标记已读 */ | ||||
| export function readMessage(ids?: Array<string>) { | ||||
| export function readMessage(ids: Array<string>) { | ||||
|   return http.patch(`${BASE_URL}/read`, { ids }) | ||||
| } | ||||
|  | ||||
|   | ||||
| @@ -20,7 +20,7 @@ | ||||
|  | ||||
| <script setup lang="ts"> | ||||
| import { onMounted } from 'vue' | ||||
| import { type MessageResp, listMessage, readMessage } from '@/apis' | ||||
| import { type MessageResp, listMessage, readAllMessage } from '@/apis' | ||||
| import router from '@/router' | ||||
|  | ||||
| const emit = defineEmits<{ | ||||
| @@ -54,7 +54,7 @@ const open = () => { | ||||
|  | ||||
| // 全部已读 | ||||
| const readAll = async () => { | ||||
|   await readMessage() | ||||
|   await readAllMessage() | ||||
|   await getMessageData() | ||||
|   emit('readall-success') | ||||
| } | ||||
|   | ||||
		Reference in New Issue
	
	Block a user