mirror of https://github.com/langgenius/dify.git
feat: clear selected IDs on document deletion action in DocumentList component
This commit is contained in:
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…
Reference in New Issue