mirror of
https://github.com/songquanpeng/one-api.git
synced 2025-11-14 20:23:46 +08:00
🐛 fix usage error & web channel edit label error
This commit is contained in:
@@ -70,13 +70,13 @@ const EditModal = ({ open, channelId, onCancel, onOk }) => {
|
||||
|
||||
const initChannel = (typeValue) => {
|
||||
if (typeConfig[typeValue]?.inputLabel) {
|
||||
setInputLabel({ ...inputLabel, ...typeConfig[typeValue].inputLabel });
|
||||
setInputLabel({ ...defaultConfig.inputLabel, ...typeConfig[typeValue].inputLabel });
|
||||
} else {
|
||||
setInputLabel(defaultConfig.inputLabel);
|
||||
}
|
||||
|
||||
if (typeConfig[typeValue]?.prompt) {
|
||||
setInputPrompt({ ...inputPrompt, ...typeConfig[typeValue].prompt });
|
||||
setInputPrompt({ ...defaultConfig.prompt, ...typeConfig[typeValue].prompt });
|
||||
} else {
|
||||
setInputPrompt(defaultConfig.prompt);
|
||||
}
|
||||
|
||||
@@ -78,11 +78,15 @@ const typeConfig = {
|
||||
}
|
||||
},
|
||||
18: {
|
||||
inputLabel: {
|
||||
other: '版本号'
|
||||
},
|
||||
input: {
|
||||
models: ['SparkDesk']
|
||||
},
|
||||
prompt: {
|
||||
key: '按照如下格式输入:APPID|APISecret|APIKey'
|
||||
key: '按照如下格式输入:APPID|APISecret|APIKey',
|
||||
other: '请输入版本号,例如:v3.1'
|
||||
}
|
||||
},
|
||||
19: {
|
||||
@@ -104,8 +108,14 @@ const typeConfig = {
|
||||
}
|
||||
},
|
||||
25: {
|
||||
inputLabel: {
|
||||
other: '版本号'
|
||||
},
|
||||
input: {
|
||||
models: ['gemini-pro']
|
||||
},
|
||||
prompt: {
|
||||
other: '请输入版本号,例如:v1'
|
||||
}
|
||||
}
|
||||
};
|
||||
|
||||
Reference in New Issue
Block a user