fix: installation_id is missing when in tools page (#27849)
This commit is contained in:
@@ -73,7 +73,7 @@ const DetailHeader = ({
|
|||||||
const { enable_marketplace } = useGlobalPublicStore(s => s.systemFeatures)
|
const { enable_marketplace } = useGlobalPublicStore(s => s.systemFeatures)
|
||||||
|
|
||||||
const {
|
const {
|
||||||
installation_id,
|
id,
|
||||||
source,
|
source,
|
||||||
tenant_id,
|
tenant_id,
|
||||||
version,
|
version,
|
||||||
@@ -197,7 +197,7 @@ const DetailHeader = ({
|
|||||||
|
|
||||||
const handleDelete = useCallback(async () => {
|
const handleDelete = useCallback(async () => {
|
||||||
showDeleting()
|
showDeleting()
|
||||||
const res = await uninstallPlugin(installation_id)
|
const res = await uninstallPlugin(id)
|
||||||
hideDeleting()
|
hideDeleting()
|
||||||
if (res.success) {
|
if (res.success) {
|
||||||
hideDeleteConfirm()
|
hideDeleteConfirm()
|
||||||
@@ -207,7 +207,7 @@ const DetailHeader = ({
|
|||||||
if (PluginType.tool.includes(category))
|
if (PluginType.tool.includes(category))
|
||||||
invalidateAllToolProviders()
|
invalidateAllToolProviders()
|
||||||
}
|
}
|
||||||
}, [showDeleting, installation_id, hideDeleting, hideDeleteConfirm, onUpdate, category, refreshModelProviders, invalidateAllToolProviders])
|
}, [showDeleting, id, hideDeleting, hideDeleteConfirm, onUpdate, category, refreshModelProviders, invalidateAllToolProviders])
|
||||||
|
|
||||||
return (
|
return (
|
||||||
<div className={cn('shrink-0 border-b border-divider-subtle bg-components-panel-bg p-4 pb-3')}>
|
<div className={cn('shrink-0 border-b border-divider-subtle bg-components-panel-bg p-4 pb-3')}>
|
||||||
@@ -351,7 +351,6 @@ const DetailHeader = ({
|
|||||||
content={
|
content={
|
||||||
<div>
|
<div>
|
||||||
{t(`${i18nPrefix}.deleteContentLeft`)}<span className='system-md-semibold'>{label[locale]}</span>{t(`${i18nPrefix}.deleteContentRight`)}<br />
|
{t(`${i18nPrefix}.deleteContentLeft`)}<span className='system-md-semibold'>{label[locale]}</span>{t(`${i18nPrefix}.deleteContentRight`)}<br />
|
||||||
{/* {usedInApps > 0 && t(`${i18nPrefix}.usedInApps`, { num: usedInApps })} */}
|
|
||||||
</div>
|
</div>
|
||||||
}
|
}
|
||||||
onCancel={hideDeleteConfirm}
|
onCancel={hideDeleteConfirm}
|
||||||
|
|||||||
Reference in New Issue
Block a user