fix: api info example

This commit is contained in:
jialin
2025-11-20 11:47:09 +08:00
parent 8f9562d6a4
commit de882dc62e
7 changed files with 27 additions and 14 deletions
@@ -114,7 +114,7 @@ const ApiAccessInfo = ({ open, data, onClose }: ApiAccessInfoProps) => {
if (!data.generic_proxy) {
return `${window.location.origin}/${GPUSTACK_API}`;
}
return getProxyEndPoint(data.categories || []);
return `${window.location.origin}${MODEL_PROXY}/<YOUR_API_PATH>`;
}, [data]);
const isRanker = useMemo(() => {
@@ -164,11 +164,7 @@ const ApiAccessInfo = ({ open, data, onClose }: ApiAccessInfoProps) => {
></dd>
</dl>
</Tips>
{data.generic_proxy && (
<div style={{ paddingLeft: 20, marginBottom: 12 }}>
{GenericProxyCommandCode}
</div>
)}
<ApiAccessInfoWrapper>
<span className="label">
{intl.formatMessage({ id: 'models.table.apiAccessInfo.endpoint' })}
@@ -224,6 +220,11 @@ const ApiAccessInfo = ({ open, data, onClose }: ApiAccessInfoProps) => {
</CreateButton>
</span>
</ApiAccessInfoWrapper>
{data.generic_proxy && (
<div style={{ paddingLeft: 20, marginTop: 12 }}>
{GenericProxyCommandCode}
</div>
)}
</ScrollerModal>
);
};