mirror of
https://github.com/fawney19/Aether.git
synced 2026-10-08 10:27:46 +08:00
fix frontend openai responses alias display
This commit is contained in:
@@ -125,7 +125,7 @@
|
||||
:key="fmt"
|
||||
class="text-[10px] px-1.5 py-0.5 rounded bg-muted text-muted-foreground whitespace-nowrap"
|
||||
>
|
||||
{{ API_FORMAT_SHORT[fmt] || fmt }}
|
||||
{{ formatApiFormatShort(fmt) }}
|
||||
</span>
|
||||
</template>
|
||||
</div>
|
||||
@@ -472,8 +472,14 @@ import { updateProvider, updateProviderKey } from '@/api/endpoints'
|
||||
import { getProvidersSummary, type ProviderWithEndpointsSummary } from '@/api/endpoints'
|
||||
import { adminApi } from '@/api/admin'
|
||||
import { batchQueryBalance, type ActionResultResponse, type BalanceInfo } from '@/api/providerOps'
|
||||
import { API_FORMAT_SHORT } from '@/api/endpoints/types'
|
||||
import { sortApiFormats, groupApiFormats, parseApiFormat, API_FORMAT_KIND_LABELS } from '@/api/endpoints/types/api-format'
|
||||
import {
|
||||
sortApiFormats,
|
||||
groupApiFormats,
|
||||
parseApiFormat,
|
||||
API_FORMAT_KIND_LABELS,
|
||||
formatApiFormatShort,
|
||||
normalizeApiFormatAlias,
|
||||
} from '@/api/endpoints/types/api-format'
|
||||
import { log } from '@/utils/logger'
|
||||
|
||||
interface KeyWithMeta {
|
||||
@@ -893,7 +899,7 @@ const groupedFormats = computed(() => {
|
||||
|
||||
// 获取格式的 kind 显示名称
|
||||
function formatKind(format: string): string {
|
||||
const { kind } = parseApiFormat(format)
|
||||
const { kind } = parseApiFormat(normalizeApiFormatAlias(format))
|
||||
return API_FORMAT_KIND_LABELS[kind] || kind || format
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user