fix: pass operation name to onUpdate callback in StatusItem component (#26019)

This commit is contained in:
Wu Tianwei 2025-09-22 10:19:12 +08:00 • committed by GitHub
commit 8c38363038
No known key found for this signature in database
GPG key ID: B5690EEEBB952194

View file

@ -72,7 +72,7 @@ const StatusItem = ({
const [e] = await asyncRunSafe<CommonResponse>(opApi({ datasetId, documentId: id }) as Promise<CommonResponse>) const [e] = await asyncRunSafe<CommonResponse>(opApi({ datasetId, documentId: id }) as Promise<CommonResponse>)
if (!e) { if (!e) {
notify({ type: 'success', message: t('common.actionMsg.modifiedSuccessfully') }) notify({ type: 'success', message: t('common.actionMsg.modifiedSuccessfully') })
onUpdate?.() onUpdate?.(operationName)
} }
else { notify({ type: 'error', message: t('common.actionMsg.modifiedUnsuccessfully') }) } else { notify({ type: 'error', message: t('common.actionMsg.modifiedUnsuccessfully') }) }
} }