|
|
|
@ -11,8 +11,8 @@
|
|
|
|
|
|
|
|
|
|
<!-- 操作按钮区域 -->
|
|
|
|
|
<div class="table-operator">
|
|
|
|
|
<a-button @click="handleAdd" type="primary" icon="plus">新增</a-button>
|
|
|
|
|
<a-button type="primary" icon="download" @click="handleExportXls('评论')">导出</a-button>
|
|
|
|
|
<a-button @click="handleAdd" v-has="'erp:bbs:add'" type="primary" icon="plus">新增</a-button>
|
|
|
|
|
<a-button type="primary" icon="download" @click="handleExportXls('评价')">导出</a-button>
|
|
|
|
|
<a-upload name="file" :showUploadList="false" :multiple="false" :headers="tokenHeader" :action="importExcelUrl" @change="handleImportExcel">
|
|
|
|
|
<a-button type="primary" icon="import">导入</a-button>
|
|
|
|
|
</a-upload>
|
|
|
|
@ -68,7 +68,7 @@
|
|
|
|
|
</template>
|
|
|
|
|
|
|
|
|
|
<span slot="action" slot-scope="text, record">
|
|
|
|
|
<a @click="handleEdit(record)">编辑</a>
|
|
|
|
|
<a v-has="'erp:bbs:edit'" @click="handleEdit(record)">编辑</a>
|
|
|
|
|
|
|
|
|
|
<a-divider type="vertical" />
|
|
|
|
|
<a-dropdown>
|
|
|
|
@ -79,7 +79,7 @@
|
|
|
|
|
</a-menu-item>
|
|
|
|
|
<a-menu-item>
|
|
|
|
|
<a-popconfirm title="确定删除吗?" @confirm="() => handleDelete(record.id)">
|
|
|
|
|
<a>删除</a>
|
|
|
|
|
<a v-has="'erp:bbs:delete'">删除</a>
|
|
|
|
|
</a-popconfirm>
|
|
|
|
|
</a-menu-item>
|
|
|
|
|
</a-menu>
|
|
|
|
@ -95,101 +95,132 @@
|
|
|
|
|
|
|
|
|
|
<script>
|
|
|
|
|
|
|
|
|
|
import '@/assets/less/TableExpand.less'
|
|
|
|
|
import { mixinDevice } from '@/utils/mixin'
|
|
|
|
|
import { JeecgListMixin } from '@/mixins/JeecgListMixin'
|
|
|
|
|
import BbsModal from './modules/BbsModal'
|
|
|
|
|
import '@/assets/less/TableExpand.less'
|
|
|
|
|
import { mixinDevice } from '@/utils/mixin'
|
|
|
|
|
import { JeecgListMixin } from '@/mixins/JeecgListMixin'
|
|
|
|
|
import BbsModal from './modules/BbsModal'
|
|
|
|
|
|
|
|
|
|
export default {
|
|
|
|
|
name: 'BbsList',
|
|
|
|
|
mixins:[JeecgListMixin, mixinDevice],
|
|
|
|
|
components: {
|
|
|
|
|
BbsModal
|
|
|
|
|
},
|
|
|
|
|
data () {
|
|
|
|
|
return {
|
|
|
|
|
description: '评论管理页面',
|
|
|
|
|
// 表头
|
|
|
|
|
columns: [
|
|
|
|
|
{
|
|
|
|
|
title: '#',
|
|
|
|
|
dataIndex: '',
|
|
|
|
|
key:'rowIndex',
|
|
|
|
|
width:60,
|
|
|
|
|
align:"center",
|
|
|
|
|
customRender:function (t,r,index) {
|
|
|
|
|
return parseInt(index)+1;
|
|
|
|
|
}
|
|
|
|
|
},
|
|
|
|
|
{
|
|
|
|
|
title:'内容',
|
|
|
|
|
align:"center",
|
|
|
|
|
dataIndex: 'content'
|
|
|
|
|
},
|
|
|
|
|
{
|
|
|
|
|
title:'用户id',
|
|
|
|
|
align:"center",
|
|
|
|
|
dataIndex: 'userId'
|
|
|
|
|
},
|
|
|
|
|
{
|
|
|
|
|
title:'产品',
|
|
|
|
|
align:"center",
|
|
|
|
|
dataIndex: 'goodsName'
|
|
|
|
|
},
|
|
|
|
|
{
|
|
|
|
|
title:'备注',
|
|
|
|
|
align:"center",
|
|
|
|
|
dataIndex: 'remark'
|
|
|
|
|
},
|
|
|
|
|
{
|
|
|
|
|
title:'评论人',
|
|
|
|
|
align:"center",
|
|
|
|
|
dataIndex: 'userName'
|
|
|
|
|
},
|
|
|
|
|
{
|
|
|
|
|
title: '操作',
|
|
|
|
|
dataIndex: 'action',
|
|
|
|
|
align:"center",
|
|
|
|
|
fixed:"right",
|
|
|
|
|
width:147,
|
|
|
|
|
scopedSlots: { customRender: 'action' }
|
|
|
|
|
export default {
|
|
|
|
|
name: 'BbsList',
|
|
|
|
|
mixins:[JeecgListMixin, mixinDevice],
|
|
|
|
|
components: {
|
|
|
|
|
BbsModal
|
|
|
|
|
},
|
|
|
|
|
data () {
|
|
|
|
|
return {
|
|
|
|
|
description: '评价管理页面',
|
|
|
|
|
// 表头
|
|
|
|
|
columns: [
|
|
|
|
|
{
|
|
|
|
|
title: '#',
|
|
|
|
|
dataIndex: '',
|
|
|
|
|
key:'rowIndex',
|
|
|
|
|
width:60,
|
|
|
|
|
align:"center",
|
|
|
|
|
customRender:function (t,r,index) {
|
|
|
|
|
return parseInt(index)+1;
|
|
|
|
|
}
|
|
|
|
|
],
|
|
|
|
|
url: {
|
|
|
|
|
list: "/erp/bbs/list",
|
|
|
|
|
delete: "/erp/bbs/delete",
|
|
|
|
|
deleteBatch: "/erp/bbs/deleteBatch",
|
|
|
|
|
exportXlsUrl: "/erp/bbs/exportXls",
|
|
|
|
|
importExcelUrl: "erp/bbs/importExcel",
|
|
|
|
|
|
|
|
|
|
},
|
|
|
|
|
dictOptions:{},
|
|
|
|
|
superFieldList:[],
|
|
|
|
|
}
|
|
|
|
|
},
|
|
|
|
|
created() {
|
|
|
|
|
{
|
|
|
|
|
title:'内容',
|
|
|
|
|
align:"center",
|
|
|
|
|
dataIndex: 'content'
|
|
|
|
|
},
|
|
|
|
|
{
|
|
|
|
|
title:'评论时间',
|
|
|
|
|
align:"center",
|
|
|
|
|
dataIndex: 'createTime'
|
|
|
|
|
},
|
|
|
|
|
{
|
|
|
|
|
title:'物流打分',
|
|
|
|
|
align:"center",
|
|
|
|
|
dataIndex: 'deliveryScore'
|
|
|
|
|
},
|
|
|
|
|
{
|
|
|
|
|
title:'商品打分',
|
|
|
|
|
align:"center",
|
|
|
|
|
dataIndex: 'qualityScore'
|
|
|
|
|
},
|
|
|
|
|
{
|
|
|
|
|
title:'服务打分',
|
|
|
|
|
align:"center",
|
|
|
|
|
dataIndex: 'serviceScore'
|
|
|
|
|
},
|
|
|
|
|
{
|
|
|
|
|
title:'推荐打分',
|
|
|
|
|
align:"center",
|
|
|
|
|
dataIndex: 'suggestScore'
|
|
|
|
|
},
|
|
|
|
|
{
|
|
|
|
|
title:'图片url',
|
|
|
|
|
align:"center",
|
|
|
|
|
dataIndex: 'url',
|
|
|
|
|
scopedSlots: {customRender: 'imgSlot'}
|
|
|
|
|
},
|
|
|
|
|
{
|
|
|
|
|
title:'产品',
|
|
|
|
|
align:"center",
|
|
|
|
|
dataIndex: 'goodsName'
|
|
|
|
|
},
|
|
|
|
|
{
|
|
|
|
|
title:'备注',
|
|
|
|
|
align:"center",
|
|
|
|
|
dataIndex: 'remark'
|
|
|
|
|
},
|
|
|
|
|
{
|
|
|
|
|
title:'评论人',
|
|
|
|
|
align:"center",
|
|
|
|
|
dataIndex: 'userName'
|
|
|
|
|
},
|
|
|
|
|
{
|
|
|
|
|
title: '操作',
|
|
|
|
|
dataIndex: 'action',
|
|
|
|
|
align:"center",
|
|
|
|
|
fixed:"right",
|
|
|
|
|
width:147,
|
|
|
|
|
scopedSlots: { customRender: 'action' }
|
|
|
|
|
}
|
|
|
|
|
],
|
|
|
|
|
url: {
|
|
|
|
|
list: "/erp/bbs/list",
|
|
|
|
|
delete: "/erp/bbs/delete",
|
|
|
|
|
deleteBatch: "/erp/bbs/deleteBatch",
|
|
|
|
|
exportXlsUrl: "/erp/bbs/exportXls",
|
|
|
|
|
importExcelUrl: "erp/bbs/importExcel",
|
|
|
|
|
|
|
|
|
|
},
|
|
|
|
|
dictOptions:{},
|
|
|
|
|
superFieldList:[],
|
|
|
|
|
}
|
|
|
|
|
},
|
|
|
|
|
created() {
|
|
|
|
|
this.getSuperFieldList();
|
|
|
|
|
},
|
|
|
|
|
computed: {
|
|
|
|
|
importExcelUrl: function(){
|
|
|
|
|
return `${window._CONFIG['domianURL']}/${this.url.importExcelUrl}`;
|
|
|
|
|
},
|
|
|
|
|
computed: {
|
|
|
|
|
importExcelUrl: function(){
|
|
|
|
|
return `${window._CONFIG['domianURL']}/${this.url.importExcelUrl}`;
|
|
|
|
|
},
|
|
|
|
|
},
|
|
|
|
|
methods: {
|
|
|
|
|
initDictConfig(){
|
|
|
|
|
},
|
|
|
|
|
methods: {
|
|
|
|
|
initDictConfig(){
|
|
|
|
|
},
|
|
|
|
|
getSuperFieldList(){
|
|
|
|
|
let fieldList=[];
|
|
|
|
|
fieldList.push({type:'string',value:'content',text:'内容',dictCode:''})
|
|
|
|
|
fieldList.push({type:'string',value:'userId',text:'用户id',dictCode:''})
|
|
|
|
|
fieldList.push({type:'string',value:'goodsName',text:'产品',dictCode:''})
|
|
|
|
|
fieldList.push({type:'string',value:'remark',text:'备注',dictCode:''})
|
|
|
|
|
fieldList.push({type:'string',value:'userName',text:'评论人',dictCode:''})
|
|
|
|
|
this.superFieldList = fieldList
|
|
|
|
|
}
|
|
|
|
|
getSuperFieldList(){
|
|
|
|
|
let fieldList=[];
|
|
|
|
|
fieldList.push({type:'string',value:'content',text:'内容',dictCode:''})
|
|
|
|
|
fieldList.push({type:'datetime',value:'createTime',text:'评论时间'})
|
|
|
|
|
fieldList.push({type:'string',value:'deliveryScore',text:'物流打分,满分5星',dictCode:''})
|
|
|
|
|
fieldList.push({type:'string',value:'qualityScore',text:'商品打分,满分5星',dictCode:''})
|
|
|
|
|
fieldList.push({type:'string',value:'erviceScore',text:'服务打分,满分5星',dictCode:''})
|
|
|
|
|
fieldList.push({type:'string',value:'suggestScore',text:'是否推荐打分,满分5星',dictCode:''})
|
|
|
|
|
fieldList.push({type:'string',value:'url',text:'图片url',dictCode:''})
|
|
|
|
|
fieldList.push({type:'string',value:'goodsName',text:'产品',dictCode:''})
|
|
|
|
|
fieldList.push({type:'string',value:'remark',text:'备注',dictCode:''})
|
|
|
|
|
fieldList.push({type:'string',value:'userName',text:'评论人',dictCode:''})
|
|
|
|
|
this.superFieldList = fieldList
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
</script>
|
|
|
|
|
<style scoped>
|
|
|
|
|
@import '~@assets/less/common.less';
|
|
|
|
|
@import '~@assets/less/common.less';
|
|
|
|
|
</style>
|