feat(models): 视频分辨率档位增加 768p,编辑弹窗支持增删档位

- CustomModelModal:VID_RES/ALL_RES 加入 768p
- ModelFormModal:provider=custom 的模型编辑时渲染 候选档位 ∪ 已存档位
  完整价格网格,填价即开通、留空即下线;PATCH 的 resolutions/durations
  改发"有价键集合"(与新建语义一致),非 custom 模型行为不变
- 摘要面板仍只显示已开通档位,提示文案区分 catalog / custom

Generated with [Devin](https://devin.ai)

Co-Authored-By: Devin <158243242+devin-ai-integration[bot]@users.noreply.github.com>
This commit is contained in:
2026-10-14 18:24:32 +08:00
co-authored by Devin
parent b17cc3e9c8
commit ecdbc0b281
2 changed files with 50 additions and 34 deletions
+3 -3
View File
@@ -10,8 +10,8 @@ const emit = defineEmits(['close', 'saved'])
// the backend guessRatio() and the docs 对照表. 9:21 removed (no image provider accepts it).
const RATIO_OPTS = ['1:1', '5:4', '4:3', '3:2', '16:9', '2:1', '21:9', '3:1', '4:1', '8:1', '4:5', '3:4', '2:3', '9:16', '1:3', '1:4', '1:8']
const IMG_RES = ['1K', '2K', '4K']
const VID_RES = ['720p', '1080p', '2K', '4K']
const ALL_RES = ['1K', '2K', '4K', '720p', '1080p']
const VID_RES = ['720p', '768p', '1080p', '2K', '4K']
const ALL_RES = ['1K', '2K', '4K', '720p', '768p', '1080p']
const DUR_OPTS = ['5s', '6s', '8s', '10s', '15s']
const id = ref('')
@@ -50,7 +50,7 @@ function removeDur(key) {
}
const isVideo = computed(() => type.value === 'video')
// Resolution tiers depend on type: image = 1K/2K/4K, video = 540p/720p/1080p/2K/4K.
// Resolution tiers depend on type: image = 1K/2K/4K, video = 720p/768p/1080p/2K/4K.
const resOpts = computed(() => (isVideo.value ? VID_RES : IMG_RES))
function toggleRatio(r) {