mirror of
https://github.com/EstrellaXD/Auto_Bangumi.git
synced 2026-03-31 17:20:47 +08:00
fix: config
This commit is contained in:
@@ -7,11 +7,11 @@ const program = computed(() => form.program);
|
||||
<template>
|
||||
<ConfigFormRow title="主程序">
|
||||
<ConfigFormCol label="RSS 检查间隔">
|
||||
<el-input v-model.number="program.sleep_time" type="number" />
|
||||
<el-input v-model.number="program.rss_time" type="number" />
|
||||
</ConfigFormCol>
|
||||
|
||||
<ConfigFormCol label="重命名频率">
|
||||
<el-input v-model.number="program.rename_times" type="number" />
|
||||
<el-input v-model.number="program.rename_time" type="number" />
|
||||
</ConfigFormCol>
|
||||
|
||||
<ConfigFormCol label="WebUI 端口" prop="program.webui_port">
|
||||
|
||||
@@ -28,7 +28,7 @@ const proxy = computed(() => form.proxy);
|
||||
</el-select>
|
||||
</ConfigFormCol>
|
||||
|
||||
<ConfigFormCol label="ip" prop="proxy.host">
|
||||
<ConfigFormCol label="host" prop="proxy.host">
|
||||
<el-input v-model="proxy.host"></el-input>
|
||||
</ConfigFormCol>
|
||||
|
||||
|
||||
@@ -1,5 +1,11 @@
|
||||
<script lang="ts" setup>
|
||||
import { form, rssParserLang, rssParserType, tfOptions } from '../form-data';
|
||||
import {
|
||||
form,
|
||||
rssParserLang,
|
||||
rssParserType,
|
||||
rssParserMethodType,
|
||||
tfOptions,
|
||||
} from '../form-data';
|
||||
|
||||
const rssParser = computed(() => form.rss_parser);
|
||||
|
||||
@@ -51,13 +57,12 @@ watch(filter, (nv) => {
|
||||
<el-input v-model="rssParser.custom_url"></el-input>
|
||||
</ConfigFormCol>
|
||||
|
||||
<ConfigFormCol label="TMDB 解析">
|
||||
<el-select v-model="rssParser.enable_tmdb" flex-1>
|
||||
<ConfigFormCol label="解析类型">
|
||||
<el-select v-model="rssParser.parser_type" flex-1>
|
||||
<el-option
|
||||
v-for="(opt, index) in tfOptions"
|
||||
:key="index"
|
||||
:label="opt.label"
|
||||
:value="opt.value"
|
||||
v-for="(opt, index) in rssParserMethodType"
|
||||
:key="opt"
|
||||
:value="opt"
|
||||
></el-option>
|
||||
</el-select>
|
||||
</ConfigFormCol>
|
||||
|
||||
@@ -6,13 +6,13 @@ import type {
|
||||
RenameMethod,
|
||||
RssParserLang,
|
||||
RssParserType,
|
||||
RssParserMethodType,
|
||||
} from '#/config';
|
||||
|
||||
export const form = reactive<Config>({
|
||||
data_version: 4,
|
||||
program: {
|
||||
sleep_time: 0,
|
||||
rename_times: 0,
|
||||
rss_time: 0,
|
||||
rename_time: 0,
|
||||
webui_port: 0,
|
||||
},
|
||||
downloader: {
|
||||
@@ -28,9 +28,9 @@ export const form = reactive<Config>({
|
||||
type: 'mikan',
|
||||
token: '',
|
||||
custom_url: '',
|
||||
enable_tmdb: false,
|
||||
filter: [],
|
||||
language: 'zh',
|
||||
parser_type: 'parser',
|
||||
},
|
||||
bangumi_manage: {
|
||||
enable: true,
|
||||
@@ -60,10 +60,19 @@ export const form = reactive<Config>({
|
||||
|
||||
export const downloaderType: DownloaderType = ['qbittorrent'];
|
||||
export const rssParserType: RssParserType = ['mikan'];
|
||||
export const rssParserMethodType: RssParserMethodType = [
|
||||
'tmdb',
|
||||
'mikan',
|
||||
'parser',
|
||||
];
|
||||
export const rssParserLang: RssParserLang = ['zh', 'en', 'jp'];
|
||||
export const renameMethod: RenameMethod = ['normal', 'pn', 'advance', 'none'];
|
||||
export const proxyType: ProxyType = ['http', 'https', 'socks5'];
|
||||
export const notificationType: NotificationType = ['telegram', 'server-chan', 'bark'];
|
||||
export const notificationType: NotificationType = [
|
||||
'telegram',
|
||||
'server-chan',
|
||||
'bark',
|
||||
];
|
||||
export const tfOptions = [
|
||||
{ label: '是', value: true },
|
||||
{ label: '否', value: false },
|
||||
|
||||
Reference in New Issue
Block a user