refactor: 移除 relay 服务中的 model 参数,Dify /chat-messages 不需要此字段

This commit is contained in:
2026-04-22 16:18:44 +08:00
parent 5722c75536
commit 69d948de88
3 changed files with 5 additions and 14 deletions

View File

@@ -194,9 +194,6 @@
.success-text { color: #86efac; }
.warn-text { color: #fcd34d; }
/* Model select */
#model { margin-bottom: 20px; }
/* Streaming indicator */
.streaming-indicator {
display: none;
@@ -256,10 +253,6 @@
<label>Dify API 密钥</label>
<input type="password" id="apiKey" placeholder="app-xxxxxxxx" />
</div>
<div class="field">
<label>模型名称</label>
<input type="text" id="modelName" placeholder="dify" />
</div>
</div>
<div class="btn-row">
@@ -286,7 +279,6 @@
// ── Helpers ────────────────────────────────────────────────
const relayUrl = () => document.getElementById('relayUrl').value.replace(/\/$/, '');
const apiKey = () => document.getElementById('apiKey').value.trim();
const model = () => document.getElementById('modelName').value.trim() || 'dify';
function setStatus(type, text) {
const dot = document.getElementById('statusDot');
@@ -354,7 +346,6 @@
setStatus('idle', '请求中…');
const payload = {
model: model(),
stream: false,
messages: [
{ role: 'user', content: '你好,请用一句话介绍自己。' }