模板库 图片预览

This commit is contained in:
yanran200730
2024-10-31 21:03:06 +08:00
parent b3c7dde44f
commit 57d58cdad3
2 changed files with 14 additions and 4 deletions

View File

@@ -192,10 +192,19 @@
:total="templateTotal"
:current.sync="searchTemplate.current"
:size.sync="searchTemplate.size"
style="margin-top: 8px;"
height="400"
height="480"
@getList="getTemplateList"
v-loading="templateLoading">
<el-table-column slot="img" label="预览图" align="center">
<template v-slot="{ row }">
<el-image
style="width: 200px; height: 200px"
fit="contain"
:src="row.previewUrl"
:preview-src-list="[row.previewUrl]">
</el-image>
</template>
</el-table-column>
<el-table-column slot="options" label="操作" align="center" width="200">
<template v-slot="{ row }">
<div class="table-options">
@@ -323,7 +332,8 @@
tableData: [],
total: 0,
templateColConfigs: [
{ prop: 'name', label: '模板名称', align: 'left' }
{ prop: 'name', label: '模板名称', align: 'left' },
{ slot: 'img'}
],
templateLoading: false
}

View File

@@ -68,7 +68,7 @@
<template v-slot="{ row }">
<div class="table-options">
<el-button type="text" @click="toAddSku(row.id)">管理SKU</el-button>
<el-button type="text" @click="savePDF(row.id)">保存PDF</el-button>
<!-- <el-button type="text" @click="savePDF(row.id)">保存PDF</el-button> -->
<el-button type="text" @click="toAdd(row.id)">编辑</el-button>
<el-button type="text" @click="remove(row.id)">删除</el-button>
</div>