feat: clear selected IDs on document deletion action in DocumentList component

pull/21398/head
twwu 10 months ago
parent 916a8c76e7
commit 2414dbb5f8

@ -166,6 +166,8 @@ const DocumentList: FC<IDocumentListProps> = ({
const [e] = await asyncRunSafe<CommonResponse>(opApi({ datasetId, documentIds: selectedIds }) as Promise<CommonResponse>)
if (!e) {
if (actionName === DocumentActionType.delete)
onSelectedIdChange([])
Toast.notify({ type: 'success', message: t('common.actionMsg.modifiedSuccessfully') })
onUpdate()
}

Loading…
Cancel
Save