mirror of
https://github.com/jxxghp/MoviePilot-Frontend.git
synced 2026-09-05 07:28:37 +08:00
刷新数据时重新加载文件夹配置,以确保插件正确显示。
This commit is contained in:
@@ -403,25 +403,6 @@ function sortPluginOrder() {
|
|||||||
})
|
})
|
||||||
}
|
}
|
||||||
|
|
||||||
// 保存顺序设置
|
|
||||||
async function savePluginOrder() {
|
|
||||||
// 只在主列表中保存顺序,文件夹内不保存全局顺序
|
|
||||||
if (currentFolder.value) return
|
|
||||||
|
|
||||||
// 顺序配置
|
|
||||||
const orderObj = filteredDataList.value.map(item => ({ id: item.id || '' }))
|
|
||||||
orderConfig.value = orderObj
|
|
||||||
const orderString = JSON.stringify(orderObj)
|
|
||||||
localStorage.setItem('MP_PLUGIN_ORDER', orderString)
|
|
||||||
|
|
||||||
// 保存到服务端
|
|
||||||
try {
|
|
||||||
await api.post('/user/config/PluginOrder', orderObj)
|
|
||||||
} catch (error) {
|
|
||||||
console.error(error)
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
// 保存混合排序
|
// 保存混合排序
|
||||||
async function saveMixedSortOrder() {
|
async function saveMixedSortOrder() {
|
||||||
try {
|
try {
|
||||||
@@ -707,6 +688,8 @@ async function getPluginStatistics() {
|
|||||||
async function refreshData() {
|
async function refreshData() {
|
||||||
await fetchInstalledPlugins()
|
await fetchInstalledPlugins()
|
||||||
fetchUninstalledPlugins()
|
fetchUninstalledPlugins()
|
||||||
|
// 重新加载文件夹配置,确保分身插件能正确显示在文件夹中
|
||||||
|
await loadPluginFolders()
|
||||||
}
|
}
|
||||||
|
|
||||||
// 对uninstalledList进行排序到sortedUninstalledList
|
// 对uninstalledList进行排序到sortedUninstalledList
|
||||||
|
|||||||
Reference in New Issue
Block a user