65 lines
1.1 KiB
Plaintext
65 lines
1.1 KiB
Plaintext
import { h } from 'vue';
|
|
import { Tag,Avatar } from 'ant-design-vue';
|
|
|
|
export const columns = [
|
|
{
|
|
title: 'ID',
|
|
dataIndex: 'id',
|
|
width: 100,
|
|
},
|
|
{
|
|
title: '位置描述',
|
|
dataIndex: 'description',
|
|
width: 250,
|
|
customRender({ record }) {
|
|
return record.description + ">>" + record.location;
|
|
},
|
|
},
|
|
{
|
|
title: '推荐类型',
|
|
dataIndex: 'typeText',
|
|
},
|
|
{
|
|
title: '推荐ID',
|
|
dataIndex: 'typeId',
|
|
},
|
|
{
|
|
title: '推荐图片',
|
|
dataIndex: 'image',
|
|
customRender({ record }) {
|
|
return h(Avatar, {
|
|
size: 48,
|
|
src: record.image,
|
|
shape: 'square',
|
|
fit: 'fill',
|
|
});
|
|
},
|
|
width: 120,
|
|
},
|
|
{
|
|
title: '推荐标题',
|
|
dataIndex: 'typeTitle',
|
|
width: 200,
|
|
},
|
|
{
|
|
title: '排序',
|
|
dataIndex: 'sort',
|
|
},
|
|
{
|
|
title: '创建人',
|
|
dataIndex: 'createUser',
|
|
},
|
|
{
|
|
title: '创建时间',
|
|
dataIndex: 'createTime',
|
|
width: 180,
|
|
},
|
|
{
|
|
title: '操作',
|
|
fixed:'right',
|
|
dataIndex: 'action',
|
|
key: 'action',
|
|
width: 200,
|
|
},
|
|
];
|