fix(admin): LLM 路由显示不准确
- 默认路由改为动态取第一个活跃提供商(当前为 nvidia step-3.7-flash) - 合规审查标签改为固定 sensenova (deepseek-v4-flash) - 移除硬编码的 opencode-go 标签
This commit is contained in:
@@ -108,10 +108,10 @@
|
|||||||
<div v-if="activeTab === 'llmconfigs'">
|
<div v-if="activeTab === 'llmconfigs'">
|
||||||
<div style="margin-bottom:12px;padding:10px 16px;background:#f0f9eb;border-radius:6px;border:1px solid #e1f3d8;font-size:13px;display:flex;align-items:center;gap:8px;flex-wrap:wrap">
|
<div style="margin-bottom:12px;padding:10px 16px;background:#f0f9eb;border-radius:6px;border:1px solid #e1f3d8;font-size:13px;display:flex;align-items:center;gap:8px;flex-wrap:wrap">
|
||||||
<span>🤖 LLM 路由:</span>
|
<span>🤖 LLM 路由:</span>
|
||||||
<el-tag type="success" size="small" effect="dark" v-for="c in llmConfigs.filter(x=>x.is_active)" :key="c.id">{{ c.provider }} ({{ c.model }})</el-tag>
|
<el-tag type="success" size="small" effect="dark">{{ defaultProvider }} ({{ defaultModel }})</el-tag>
|
||||||
<span style="color:#999">← 默认(趋势/采集/创作)</span>
|
<span style="color:#999">← 默认(趋势/采集/创作/优化)</span>
|
||||||
<span style="margin:0 4px;color:#ccc">|</span>
|
<span style="margin:0 4px;color:#ccc">|</span>
|
||||||
<el-tag type="warning" size="small" effect="dark">opencode-go (deepseek-v4-flash)</el-tag>
|
<el-tag type="warning" size="small" effect="dark">sensenova (deepseek-v4-flash)</el-tag>
|
||||||
<span style="color:#999">← 合规审查固定</span>
|
<span style="color:#999">← 合规审查固定</span>
|
||||||
</div>
|
</div>
|
||||||
<div class="toolbar">
|
<div class="toolbar">
|
||||||
@@ -1100,7 +1100,16 @@ const llmConfigs = ref([]);
|
|||||||
else { switchTab('users'); }
|
else { switchTab('users'); }
|
||||||
});
|
});
|
||||||
|
|
||||||
|
const defaultProvider = computed(() => {
|
||||||
|
const active = llmConfigs.value.filter(x => x.is_active);
|
||||||
|
return active.length ? active[0].provider : '-';
|
||||||
|
});
|
||||||
|
const defaultModel = computed(() => {
|
||||||
|
const active = llmConfigs.value.filter(x => x.is_active);
|
||||||
|
return active.length ? active[0].model : '-';
|
||||||
|
});
|
||||||
return {
|
return {
|
||||||
|
defaultProvider, defaultModel,
|
||||||
activeTab, switchTab,
|
activeTab, switchTab,
|
||||||
llmConfigs, llmConfigsLoading, llmConfigDialogVisible, llmConfigForm, llmConfigDialogTitle, showLLMConfigDialog, saveLLMConfig, deleteLLMConfig,
|
llmConfigs, llmConfigsLoading, llmConfigDialogVisible, llmConfigForm, llmConfigDialogTitle, showLLMConfigDialog, saveLLMConfig, deleteLLMConfig,
|
||||||
platformConfigs, platformConfigsLoading, platformConfigsRequested, pcShowActiveOnly, showPcDialog, pcForm, pcDialogTitle, showPcDialogFn, savePcForm, editingPcPlatform,
|
platformConfigs, platformConfigsLoading, platformConfigsRequested, pcShowActiveOnly, showPcDialog, pcForm, pcDialogTitle, showPcDialogFn, savePcForm, editingPcPlatform,
|
||||||
|
|||||||
Reference in New Issue
Block a user