feat: 为文档库添加文档类型显示功能
All checks were successful
deploy to server / build-and-deploy (push) Successful in 3m10s
All checks were successful
deploy to server / build-and-deploy (push) Successful in 3m10s
- 功能添加:在文档列表中,当未指定文档类型时,在标题右侧显示文档类型 - 查询更改:产品查询添加文档类型查询方法 - mapper更改:productDocumentView添加文档类型
This commit is contained in:
@ -7,7 +7,17 @@
|
||||
@click="handleClick(doc.fileId)"
|
||||
>
|
||||
<div class="document-info">
|
||||
<h3>{{ doc.title }}</h3>
|
||||
<div class="document-title">
|
||||
<h3>
|
||||
{{ doc.title }}
|
||||
<span v-if="showCategory && doc.type" class="document-category">
|
||||
|
|
||||
</span>
|
||||
<span v-if="showCategory && doc.type" class="document-category">
|
||||
{{ doc.type.name }}
|
||||
</span>
|
||||
</h3>
|
||||
</div>
|
||||
<div class="document-content">
|
||||
<span v-if="doc.size" class="document-meta"
|
||||
>{{ $t('document-meta.size') }}: {{ formatFileSize(doc.size) }}
|
||||
@ -28,6 +38,10 @@
|
||||
type: Array as () => Array<ProductDocumentView>,
|
||||
default: () => [],
|
||||
},
|
||||
showCategory: {
|
||||
type: Boolean,
|
||||
default: true,
|
||||
},
|
||||
});
|
||||
|
||||
const localePath = useLocalePath();
|
||||
@ -63,6 +77,15 @@
|
||||
color: var(--el-text-color-secondary);
|
||||
}
|
||||
|
||||
.document-title {
|
||||
margin-bottom: 0.5rem;
|
||||
}
|
||||
|
||||
.document-category {
|
||||
font-size: 0.75rem;
|
||||
color: var(--el-text-color-secondary);
|
||||
}
|
||||
|
||||
.download-button {
|
||||
margin-left: auto;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user