feat:
This commit is contained in:
parent
5fdf926324
commit
5169f08197
@ -1,5 +1,10 @@
|
|||||||
<template>
|
<template>
|
||||||
<el-card shadow="always" class="card-box" @mouseenter="cardEnter()" @mouseleave="cardLeave()">
|
<el-card
|
||||||
|
shadow="always"
|
||||||
|
class="card-box"
|
||||||
|
@mouseenter="cardEnter()"
|
||||||
|
@mouseleave="cardLeave()"
|
||||||
|
>
|
||||||
<div class="card-header">
|
<div class="card-header">
|
||||||
<slot name="header">
|
<slot name="header">
|
||||||
<div class="title flex align-center">
|
<div class="title flex align-center">
|
||||||
@ -44,7 +49,7 @@ const props = withDefaults(
|
|||||||
*/
|
*/
|
||||||
showIcon?: boolean
|
showIcon?: boolean
|
||||||
}>(),
|
}>(),
|
||||||
{ title: '标题', description: '', showIcon: true }
|
{ title: '标题', description: '', showIcon: true, border: true }
|
||||||
)
|
)
|
||||||
|
|
||||||
const show = ref(false)
|
const show = ref(false)
|
||||||
@ -61,7 +66,6 @@ function cardLeave() {
|
|||||||
position: relative;
|
position: relative;
|
||||||
min-height: var(--card-min-height);
|
min-height: var(--card-min-height);
|
||||||
min-width: var(--card-min-width);
|
min-width: var(--card-min-width);
|
||||||
border: 1px solid #ffffff;
|
|
||||||
border-radius: 8px;
|
border-radius: 8px;
|
||||||
.description {
|
.description {
|
||||||
display: -webkit-box;
|
display: -webkit-box;
|
||||||
|
|||||||
@ -2,14 +2,8 @@
|
|||||||
<LayoutContainer header="模版管理">
|
<LayoutContainer header="模版管理">
|
||||||
<div class="template-manage flex main-calc-height">
|
<div class="template-manage flex main-calc-height">
|
||||||
<div class="template-manage__left p-8 border-r">
|
<div class="template-manage__left p-8 border-r">
|
||||||
<h4 class="p-16">供应商</h4>
|
<h4 class="p-16" style="padding-bottom: 8px">供应商</h4>
|
||||||
|
<common-list :data="provider_list" v-loading="loading" @click="clickListHandle">
|
||||||
<common-list
|
|
||||||
:data="provider_list"
|
|
||||||
class="mt-8"
|
|
||||||
v-loading="loading"
|
|
||||||
@click="clickListHandle"
|
|
||||||
>
|
|
||||||
<template #default="{ row, index }">
|
<template #default="{ row, index }">
|
||||||
<div class="flex" v-if="index === 0">
|
<div class="flex" v-if="index === 0">
|
||||||
<AppIcon
|
<AppIcon
|
||||||
@ -27,8 +21,8 @@
|
|||||||
</common-list>
|
</common-list>
|
||||||
</div>
|
</div>
|
||||||
<div class="template-manage__right p-24" v-loading="list_model_loading">
|
<div class="template-manage__right p-24" v-loading="list_model_loading">
|
||||||
<h3>{{ active_provider?.name }}</h3>
|
<h4>{{ active_provider?.name }}</h4>
|
||||||
<div class="flex-between mt-8">
|
<div class="flex-between mt-16 mb-8">
|
||||||
<el-button type="primary" @click="openCreateModel(active_provider)">创建模型</el-button>
|
<el-button type="primary" @click="openCreateModel(active_provider)">创建模型</el-button>
|
||||||
<el-input
|
<el-input
|
||||||
v-model="model_search_form.name"
|
v-model="model_search_form.name"
|
||||||
@ -39,10 +33,19 @@
|
|||||||
/>
|
/>
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
<el-row :gutter="15" v-for="row in model_split_list">
|
<el-row :gutter="15" v-for="(row, index) in model_split_list" :key="index">
|
||||||
<el-col :xs="24" :sm="24" :md="12" :lg="12" :xl="12" class="mt-8" v-for="model in row">
|
<el-col
|
||||||
<ModelVue @change="list_model" :model="model" :provider_list="provider_list">
|
:xs="24"
|
||||||
</ModelVue>
|
:sm="24"
|
||||||
|
:md="12"
|
||||||
|
:lg="12"
|
||||||
|
:xl="12"
|
||||||
|
class="mt-8"
|
||||||
|
v-for="(model, i) in row"
|
||||||
|
:key="i"
|
||||||
|
>
|
||||||
|
<ModelCard @change="list_model" :model="model" :provider_list="provider_list">
|
||||||
|
</ModelCard>
|
||||||
</el-col>
|
</el-col>
|
||||||
</el-row>
|
</el-row>
|
||||||
</div>
|
</div>
|
||||||
@ -59,7 +62,7 @@ import ModelApi from '@/api/model'
|
|||||||
import type { Provider, Model } from '@/api/type/model'
|
import type { Provider, Model } from '@/api/type/model'
|
||||||
|
|
||||||
import AppIcon from '@/components/icons/AppIcon.vue'
|
import AppIcon from '@/components/icons/AppIcon.vue'
|
||||||
import ModelVue from '@/views/template/component/Model.vue'
|
import ModelCard from '@/views/template/component/ModelCard.vue'
|
||||||
import { splitArray } from '@/utils/common'
|
import { splitArray } from '@/utils/common'
|
||||||
import CreateModel from '@/views/template/component/CreateModel.vue'
|
import CreateModel from '@/views/template/component/CreateModel.vue'
|
||||||
import SelectProvider from '@/views/template/component/SelectProvider.vue'
|
import SelectProvider from '@/views/template/component/SelectProvider.vue'
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user