|
|
|
@@ -3,9 +3,9 @@ |
|
|
|
* @Date: 2024-04-16 13:58:08 |
|
|
|
* @Description: 服务版本详情 |
|
|
|
*/ |
|
|
|
import FullScreenFrame from '@/components/FullScreenFrame'; |
|
|
|
import KFIcon from '@/components/KFIcon'; |
|
|
|
import PageTitle from '@/components/PageTitle'; |
|
|
|
import SubAreaTitle from '@/components/SubAreaTitle'; |
|
|
|
import { getServiceVersionInfoReq } from '@/services/modelDeployment'; |
|
|
|
import { to } from '@/utils/promise'; |
|
|
|
import { useParams } from '@umijs/max'; |
|
|
|
@@ -18,6 +18,7 @@ import { ServiceVersionData } from '../types'; |
|
|
|
import styles from './index.less'; |
|
|
|
|
|
|
|
export enum ModelDeploymentTabKey { |
|
|
|
Basic = 'Basic', // 基本信息 |
|
|
|
Predict = 'Predict', // 预测 |
|
|
|
Guide = 'Guide', // 调用指南 |
|
|
|
Log = 'Log', // 服务日志 |
|
|
|
@@ -43,10 +44,23 @@ function ServiceVersionInfo() { |
|
|
|
}, [id]); |
|
|
|
|
|
|
|
const tabItems = [ |
|
|
|
{ |
|
|
|
key: ModelDeploymentTabKey.Basic, |
|
|
|
label: '基本信息', |
|
|
|
icon: <KFIcon type="icon-jibenxinxi" />, |
|
|
|
children: <VersionBasicInfo info={versionInfo} />, |
|
|
|
}, |
|
|
|
{ |
|
|
|
key: ModelDeploymentTabKey.Predict, |
|
|
|
label: '预测', |
|
|
|
icon: <KFIcon type="icon-yuce" />, |
|
|
|
children: ( |
|
|
|
<div style={{ height: '100%', width: '100%' }}> |
|
|
|
{versionInfo?.page_path && ( |
|
|
|
<FullScreenFrame url={versionInfo?.page_path}></FullScreenFrame> |
|
|
|
)} |
|
|
|
</div> |
|
|
|
), |
|
|
|
}, |
|
|
|
{ |
|
|
|
key: ModelDeploymentTabKey.Guide, |
|
|
|
@@ -66,12 +80,6 @@ function ServiceVersionInfo() { |
|
|
|
<div className={styles['service-version-info']}> |
|
|
|
<PageTitle title="服务版本详情"></PageTitle> |
|
|
|
<div className={styles['service-version-info__content']}> |
|
|
|
<SubAreaTitle |
|
|
|
title="基本信息" |
|
|
|
image={require('@/assets/img/mirror-basic.png')} |
|
|
|
style={{ marginBottom: '26px' }} |
|
|
|
></SubAreaTitle> |
|
|
|
<VersionBasicInfo info={versionInfo} /> |
|
|
|
<div className={styles['service-version-info__content__tabs']}> |
|
|
|
<Tabs items={tabItems} /> |
|
|
|
</div> |
|
|
|
|