|
@@ -68,6 +68,10 @@
|
|
|
<span v-if="record.productEntity.productTypeName2 || record.productEntity.productTypeName3">{{ record.productEntity.productTypeName2 }} {{ record.productEntity.productTypeName3 ? '>' : '' }} {{ record.productEntity.productTypeName3 }}</span>
|
|
|
<span v-else>--</span>
|
|
|
</template>
|
|
|
+ <!-- 变更状态 -->
|
|
|
+ <span slot="productStatus" slot-scope="text, record">
|
|
|
+ <a-switch checkedChildren="启用" unCheckedChildren="禁用" v-model="record.loginFlag" @change="changeFlagHandle(text, record)"/>
|
|
|
+ </span>
|
|
|
<!-- 省级价变更后 -->
|
|
|
<template slot="afterProvincePrice" slot-scope="text, record">
|
|
|
<span v-if="record.afterProvincePrice || record.afterProvincePrice==0" :class="record.beforeProvincePrice != record.afterProvincePrice ? 'red' : ''">{{ toThousands(record.afterProvincePrice) }}</span>
|
|
@@ -166,53 +170,54 @@ export default {
|
|
|
{ title: '品牌', dataIndex: 'productEntity.productBrandName', width: 120, align: 'center', customRender: function (text) { return text || '--' } },
|
|
|
{ title: '产品分类', scopedSlots: { customRender: 'productType' }, width: 120, align: 'center' },
|
|
|
{ title: '单位', dataIndex: 'productEntity.unit', width: 50, align: 'center', customRender: function (text) { return text || '--' } },
|
|
|
- { title: '变更原因', dataIndex: 'changeReason', width: 70, align: 'center', customRender: function (text) { return text || '--' }, ellipsis: true }
|
|
|
+ { title: '变更原因', dataIndex: 'changeReason', width: 70, align: 'center', customRender: function (text) { return text || '--' }, ellipsis: true },
|
|
|
+ { title: '变更状态', scopedSlots: { customRender: 'productStatus' }, width: 70, align: 'center' }
|
|
|
]
|
|
|
- arr.push({
|
|
|
- title: '省级价',
|
|
|
- dataIndex: 'sdtermindfaldsdPrice',
|
|
|
- align: 'center',
|
|
|
- children: [
|
|
|
- { title: '变更前', dataIndex: 'beforeProvincePrice', width: 70, align: 'right', customRender: function (text) { return ((text || text == 0) ? _this.toThousands(text) : '--') } },
|
|
|
- { title: '变更后', scopedSlots: { customRender: 'afterProvincePrice' }, width: 70, align: 'center' }
|
|
|
- ]
|
|
|
- })
|
|
|
- arr.push({
|
|
|
- title: '市级价',
|
|
|
- dataIndex: 'sdterminaldsdPrice',
|
|
|
- align: 'center',
|
|
|
- children: [
|
|
|
- { title: '变更前', dataIndex: 'beforeCityPrice', width: 70, align: 'right', customRender: function (text) { return ((text || text == 0) ? _this.toThousands(text) : '--') } },
|
|
|
- { title: '变更后', scopedSlots: { customRender: 'afterCityPrice' }, width: 70, align: 'center' }
|
|
|
- ]
|
|
|
- })
|
|
|
- arr.push({
|
|
|
- title: '特约价',
|
|
|
- dataIndex: 'gterminaldsdPrice',
|
|
|
- align: 'center',
|
|
|
- children: [
|
|
|
- { title: '变更前', dataIndex: 'beforeSpecialPrice', width: 70, align: 'right', customRender: function (text) { return ((text || text == 0) ? _this.toThousands(text) : '--') } },
|
|
|
- { title: '变更后', scopedSlots: { customRender: 'afterSpecialPrice' }, width: 70, align: 'center' }
|
|
|
- ]
|
|
|
- })
|
|
|
- arr.push({
|
|
|
- title: '终端价',
|
|
|
- dataIndex: 'hterminaldsdPrice',
|
|
|
- align: 'center',
|
|
|
- children: [
|
|
|
- { title: '变更前', dataIndex: 'beforeTerminalPrice', width: 70, align: 'right', customRender: function (text) { return ((text || text == 0) ? _this.toThousands(text) : '--') } },
|
|
|
- { title: '变更后', scopedSlots: { customRender: 'afterTerminalPrice' }, width: 70, align: 'center' }
|
|
|
- ]
|
|
|
- })
|
|
|
- arr.push({
|
|
|
- title: '车主价',
|
|
|
- dataIndex: 'sterminaldsdPrice',
|
|
|
- align: 'center',
|
|
|
- children: [
|
|
|
- { title: '变更前', dataIndex: 'beforeCarOwnersPrice', width: 70, align: 'right', customRender: function (text) { return ((text || text == 0) ? _this.toThousands(text) : '--') } },
|
|
|
- { title: '变更后', scopedSlots: { customRender: 'afterCarOwnersPrice' }, width: 70, align: 'center' }
|
|
|
- ]
|
|
|
- })
|
|
|
+ arr.push({
|
|
|
+ title: '省级价',
|
|
|
+ dataIndex: 'sdtermindfaldsdPrice',
|
|
|
+ align: 'center',
|
|
|
+ children: [
|
|
|
+ { title: '变更前', dataIndex: 'beforeProvincePrice', width: 70, align: 'right', customRender: function (text) { return ((text || text == 0) ? _this.toThousands(text) : '--') } },
|
|
|
+ { title: '变更后', scopedSlots: { customRender: 'afterProvincePrice' }, width: 70, align: 'center' }
|
|
|
+ ]
|
|
|
+ })
|
|
|
+ arr.push({
|
|
|
+ title: '市级价',
|
|
|
+ dataIndex: 'sdterminaldsdPrice',
|
|
|
+ align: 'center',
|
|
|
+ children: [
|
|
|
+ { title: '变更前', dataIndex: 'beforeCityPrice', width: 70, align: 'right', customRender: function (text) { return ((text || text == 0) ? _this.toThousands(text) : '--') } },
|
|
|
+ { title: '变更后', scopedSlots: { customRender: 'afterCityPrice' }, width: 70, align: 'center' }
|
|
|
+ ]
|
|
|
+ })
|
|
|
+ arr.push({
|
|
|
+ title: '特约价',
|
|
|
+ dataIndex: 'gterminaldsdPrice',
|
|
|
+ align: 'center',
|
|
|
+ children: [
|
|
|
+ { title: '变更前', dataIndex: 'beforeSpecialPrice', width: 70, align: 'right', customRender: function (text) { return ((text || text == 0) ? _this.toThousands(text) : '--') } },
|
|
|
+ { title: '变更后', scopedSlots: { customRender: 'afterSpecialPrice' }, width: 70, align: 'center' }
|
|
|
+ ]
|
|
|
+ })
|
|
|
+ arr.push({
|
|
|
+ title: '终端价',
|
|
|
+ dataIndex: 'hterminaldsdPrice',
|
|
|
+ align: 'center',
|
|
|
+ children: [
|
|
|
+ { title: '变更前', dataIndex: 'beforeTerminalPrice', width: 70, align: 'right', customRender: function (text) { return ((text || text == 0) ? _this.toThousands(text) : '--') } },
|
|
|
+ { title: '变更后', scopedSlots: { customRender: 'afterTerminalPrice' }, width: 70, align: 'center' }
|
|
|
+ ]
|
|
|
+ })
|
|
|
+ arr.push({
|
|
|
+ title: '车主价',
|
|
|
+ dataIndex: 'sterminaldsdPrice',
|
|
|
+ align: 'center',
|
|
|
+ children: [
|
|
|
+ { title: '变更前', dataIndex: 'beforeCarOwnersPrice', width: 70, align: 'right', customRender: function (text) { return ((text || text == 0) ? _this.toThousands(text) : '--') } },
|
|
|
+ { title: '变更后', scopedSlots: { customRender: 'afterCarOwnersPrice' }, width: 70, align: 'center' }
|
|
|
+ ]
|
|
|
+ })
|
|
|
return arr
|
|
|
}
|
|
|
},
|
|
@@ -307,6 +312,24 @@ export default {
|
|
|
setTableH () {
|
|
|
const tableSearchH = this.$refs.tableSearch.offsetHeight
|
|
|
this.tableHeight = window.innerHeight - tableSearchH - 233
|
|
|
+ },
|
|
|
+ // 修改状态
|
|
|
+ changeFlagHandle (text, record) {
|
|
|
+ // const _data = {
|
|
|
+ // id: record.id,
|
|
|
+ // flag: record.loginFlag ? '1' : '0'
|
|
|
+ // }
|
|
|
+ // this.spinning = true
|
|
|
+ // updateEnableStatus(_data).then(res => {
|
|
|
+ // if (res.status == 200) {
|
|
|
+ // this.$message.success(res.message)
|
|
|
+ // this.$refs.table.refresh()
|
|
|
+ // this.spinning = false
|
|
|
+ // } else {
|
|
|
+ // this.$refs.table.refresh()
|
|
|
+ // this.spinning = false
|
|
|
+ // }
|
|
|
+ // })
|
|
|
}
|
|
|
},
|
|
|
watch: {
|