|
@@ -3,7 +3,7 @@
|
|
|
<a-spin :spinning="spinning" tip="Loading...">
|
|
|
<!-- 搜索条件 -->
|
|
|
<div ref="tableSearch" class="table-page-search-wrapper">
|
|
|
- <a-form layout="inline" @keyup.enter.native="$refs.table.refresh(true)">
|
|
|
+ <a-form layout="inline" @keyup.enter.native="$refs.table.refresh(true)" id="couponDetails-form">
|
|
|
<a-row :gutter="15">
|
|
|
<a-col :md="6" :sm="24">
|
|
|
<a-form-item label="券名称/券副标题">
|
|
@@ -12,15 +12,15 @@
|
|
|
</a-col>
|
|
|
<a-col :md="6" :sm="24">
|
|
|
<a-form-item label="客户名称">
|
|
|
- <selectCust ref="custList" :isValidateEnabled="true" id="couponDetails-customerSn" @change="custChange" v-model="queryParam.customerSn"></selectCust>
|
|
|
+ <selectCust ref="custList" id="couponDetails-customerSn" :isValidateEnabled="true" @change="custChange" v-model="queryParam.customerSn"></selectCust>
|
|
|
</a-form-item>
|
|
|
</a-col>
|
|
|
<a-col :md="6" :sm="24">
|
|
|
<a-form-item label="券状态">
|
|
|
<v-select
|
|
|
+ id="couponDetails-ticketState"
|
|
|
v-model="queryParam.ticketState"
|
|
|
ref="sourceType"
|
|
|
- id="couponDetails-ticketState"
|
|
|
code="TICKET_STATE"
|
|
|
placeholder="请选择优惠券使用状态"
|
|
|
allowClear></v-select>
|
|
@@ -72,35 +72,36 @@
|
|
|
|
|
|
<script>
|
|
|
import { commonMixin } from '@/utils/mixin'
|
|
|
-import { ticketQueryPage } from '@/api/ticket'
|
|
|
+// 组件
|
|
|
import { STable, VSelect } from '@/components'
|
|
|
import selectCust from '@/views/common/selectCust.vue'
|
|
|
import writeOffModal from './writeOffModal.vue'
|
|
|
+// 接口
|
|
|
+import { ticketQueryPage } from '@/api/ticket'
|
|
|
|
|
|
export default {
|
|
|
- name: 'UrgentOffsetList',
|
|
|
+ name: 'CouponDetails',
|
|
|
components: { STable, VSelect, writeOffModal, selectCust },
|
|
|
mixins: [commonMixin],
|
|
|
data () {
|
|
|
return {
|
|
|
spinning: false,
|
|
|
- tableHeight: 0,
|
|
|
+ tableHeight: 0, // 表格高度
|
|
|
openModal: false, // 核销弹窗
|
|
|
- openShowModal: false, // 促销展示弹窗
|
|
|
- time: [],
|
|
|
- queryParam: { // 查询条件
|
|
|
- queryWord: undefined,
|
|
|
- customerSn: undefined,
|
|
|
- ticketState: undefined
|
|
|
- },
|
|
|
- writeOffObj: null,
|
|
|
- descInfo: '', // 促销描述
|
|
|
disabled: false, // 查询、重置按钮是否可操作
|
|
|
+ // 查询条件
|
|
|
+ queryParam: {
|
|
|
+ queryWord: undefined, // 券名称/券副标题
|
|
|
+ customerSn: undefined, // 客户名称sn
|
|
|
+ ticketState: undefined// 券状态
|
|
|
+ },
|
|
|
+ writeOffObj: null, // 核销弹窗回显数据
|
|
|
+ // 表头
|
|
|
columns: [
|
|
|
- { title: '序号', dataIndex: 'no', width: '4%', align: 'center' },
|
|
|
+ { title: '序号', dataIndex: 'no', width: '60px', align: 'center' },
|
|
|
{ title: '销售单号', dataIndex: 'usedBizNo', width: '12%', align: 'center', customRender: function (text) { return text || '--' } },
|
|
|
{ title: '客户名称', dataIndex: 'customerName', width: '20%', align: 'center', customRender: function (text) { return text || '--' }, ellipsis: true },
|
|
|
- { title: '货架名称', dataIndex: 'customerName', width: '20%', align: 'center', customRender: function (text) { return text || '--' }, ellipsis: true },
|
|
|
+ { title: '货架名称', dataIndex: 'shelfName', width: '20%', align: 'center', customRender: function (text) { return text || '--' }, ellipsis: true },
|
|
|
{ title: '券名称', dataIndex: 'ruleName', width: '20%', align: 'center', customRender: function (text) { return text || '--' }, ellipsis: true },
|
|
|
{ title: '券副标题', dataIndex: 'ruleTitle', width: '20%', align: 'center', customRender: function (text) { return text || '--' } },
|
|
|
{ title: '券金额', dataIndex: 'ticketValue', width: '10%', align: 'right', customRender: text => { return text || text == 0 ? this.toThousands(text, 2) : '--' } },
|
|
@@ -113,6 +114,7 @@ export default {
|
|
|
loadData: parameter => {
|
|
|
this.disabled = true
|
|
|
this.spinning = true
|
|
|
+ // 获取优惠券列表数据 有分页
|
|
|
return ticketQueryPage(Object.assign(parameter, this.queryParam)).then(res => {
|
|
|
let data
|
|
|
if (res.status == 200) {
|