mirror of
https://github.com/jxxghp/MoviePilot-Frontend.git
synced 2026-09-06 08:06:43 +08:00
去除自动选项
- 仅当`目的路径`为空时,才会设为`自动` - 已选择`整理方式`后, 再选择配置的`媒体库目录`整理方式不再改变 - `自定义路径`时: - - `整理方式`为自动时,会修改为`复制`,请注意 - - `整理方式`不为自动时, 不会改变
This commit is contained in:
@@ -73,7 +73,6 @@ export const storageDict = storageOptions.reduce((dict, item) => {
|
|||||||
}, {} as Record<string, string>)
|
}, {} as Record<string, string>)
|
||||||
|
|
||||||
export const transferTypeOptions = [
|
export const transferTypeOptions = [
|
||||||
{ title: '自动', value: '' },
|
|
||||||
{ title: '复制', value: 'copy' },
|
{ title: '复制', value: 'copy' },
|
||||||
{ title: '移动', value: 'move' },
|
{ title: '移动', value: 'move' },
|
||||||
{ title: '硬链接', value: 'link' },
|
{ title: '硬链接', value: 'link' },
|
||||||
|
|||||||
@@ -114,11 +114,19 @@ watch(
|
|||||||
const directory = directories.value.find(item => item.library_path === newPath)
|
const directory = directories.value.find(item => item.library_path === newPath)
|
||||||
if (directory) {
|
if (directory) {
|
||||||
transferForm.target_storage = directory.library_storage ?? 'local'
|
transferForm.target_storage = directory.library_storage ?? 'local'
|
||||||
transferForm.transfer_type = directory.transfer_type ?? ''
|
transferForm.transfer_type = transferForm.transfer_type || directory.transfer_type
|
||||||
transferForm.scrape = directory.scraping ?? false
|
transferForm.scrape = directory.scraping ?? false
|
||||||
transferForm.library_category_folder = directory.library_category_folder ?? false
|
transferForm.library_category_folder = directory.library_category_folder ?? false
|
||||||
transferForm.library_type_folder = directory.library_type_folder ?? false
|
transferForm.library_type_folder = directory.library_type_folder ?? false
|
||||||
|
} else {
|
||||||
|
transferForm.transfer_type = transferForm.transfer_type || 'copy'
|
||||||
|
transferForm.scrape = false
|
||||||
|
transferForm.library_category_folder = false
|
||||||
|
transferForm.library_type_folder = false
|
||||||
}
|
}
|
||||||
|
} else {
|
||||||
|
// 路径为空时, 整理方式留空(自动)
|
||||||
|
transferForm.transfer_type = ''
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
)
|
)
|
||||||
@@ -225,8 +233,11 @@ onMounted(() => {
|
|||||||
label="整理方式"
|
label="整理方式"
|
||||||
:items="transferTypeOptions"
|
:items="transferTypeOptions"
|
||||||
hint="文件操作整理方式"
|
hint="文件操作整理方式"
|
||||||
persistent-hint
|
persistent-hint>
|
||||||
/>
|
<template v-slot:selection="{ item }">
|
||||||
|
{{ transferForm.transfer_type === '' ? '自动' : item.title }}
|
||||||
|
</template>
|
||||||
|
</VSelect>
|
||||||
</VCol>
|
</VCol>
|
||||||
<VCol cols="12">
|
<VCol cols="12">
|
||||||
<VCombobox
|
<VCombobox
|
||||||
|
|||||||
Reference in New Issue
Block a user