diff --git a/src/views/model/list/ModelCard.vue b/src/views/model/list/ModelCard.vue index 16aa61c..fd1883e 100644 --- a/src/views/model/list/ModelCard.vue +++ b/src/views/model/list/ModelCard.vue @@ -62,6 +62,8 @@ function normalizeCards(modelList: any[] = []): ModelItem[] { const card: ModelItem = { id: modelCard.id, title: modelCard.name, + unitName: modelCard.unitName, + systemName: modelCard.systemName, version: modelCard.version, icon: statusIcons[statusIndex], value: 1, @@ -81,6 +83,12 @@ function normalizeCards(modelList: any[] = []): ModelItem[] { return cardList } +function getSubtitle(item: ModelItem) { + const unitText = item.unitName ? `${item.unitName}` : (props.unitId != null ? `${props.unitId}号机组` : '未选择机组') + const systemText = item.systemName || (props.systemId != null ? `系统${props.systemId}` : '未选择系统') + return `${unitText} · ${systemText}` +} + async function fetchModelList(queryParams: ModelCardQueryParams, append: boolean) { if (listLoading.value) return @@ -196,37 +204,62 @@ onBeforeUnmount(() => { :loading="loading || (listLoading && !modelCardList.length)" :hoverable="true" class="model-card" - :style="{ borderLeft: `6px solid ${item.statusColor}` }" @click="changeModel(item.id, item.version)" > -
-
- {{ item.title }} +
+
+
+
+ {{ item.title }} +
+
+ {{ getSubtitle(item) }} +
+
+
+ + + +
+
+ +
+ {{ item.algorithm || '未知算法' }} + {{ item.version || 'v-test' }} + {{ item.createTime || '--' }}
-
- - - + +
+
+
+ 创建人 + {{ item.creator || '未知' }} +
+
+ 创建时间 + {{ item.createTime || '--' }} +
+
+
+ +
+ +
+
+
+ + {{ item.status === '已下装' ? '最近已校验' : '未校验' }} +
+
+
+ + +
-
-
- - - {{ item.creator || '未知' }} - - - - {{ item.createTime || '--' }} - -
-
-