Commit d7293cc4 by chenwq

不区分平台;核销记录列表

1 parent f8cc12b1
......@@ -23,7 +23,7 @@ export async function bootstrap({ history, common, messenger, globalState, route
Vue.prototype.$message = message
Vue.prototype.$messageBox = messageBox
// 集团版集团账号
Vue.prototype.$isGroupUp = globalState.session.merchantModel == 1 && globalState.session.accountLevel != 4
Vue.prototype.$isGroupUp = globalState.session.accountLevel != 4
Vue.prototype.$http = new common.Http({ response, request, sign, secret, alert: message.error, headers: { token: globalState.session.token } })
Vue.prototype.$http2 = new common.Http({ response, request: request2, sign, secret, alert: message.error, headers: { token: globalState.session.token } })
Vue.prototype.$http_merchant = new common.Http({ response, request: request_merchant, sign, secret, alert: message.error, headers: { token: globalState.session.token } })
......
......@@ -5,8 +5,13 @@
</div>
<div class="container">
<glsx-combi-form ref="showSearch" :formObj="searchForm" :formData="searchFormData"></glsx-combi-form>
<glsx-combi-form ref="showSearch" :formObj="searchForm" :formData="searchFormDataTwo"></glsx-combi-form>
<glsx-combi-form ref="showSearch" :formObj="searchForm" :formData="searchFormDataThree">
<glsx-combi-form ref="showSearch" :formObj="searchForm" :formData="searchFormDataTwo">
<span v-if="!$isGroupUp" slot="footer" class="footer-btns">
<el-button :size="size" @click="handleReset">重置</el-button>
<el-button :size="size" type="primary" @click="handleSearch">查询</el-button>
</span>
</glsx-combi-form>
<glsx-combi-form v-if="$isGroupUp" ref="showSearch" :formObj="searchForm" :formData="searchFormDataThree">
<span slot="footer" class="footer-btns">
<el-button :size="size" @click="handleReset">重置</el-button>
<el-button :size="size" type="primary" @click="handleSearch">查询</el-button>
......@@ -106,6 +111,7 @@ export default {
verificationOperator: '',
orderCode: '',
merchantId: 0,
packageId: '',
discountType: '',
discountTypes: [2, 3, 4, 7]
},
......@@ -131,6 +137,7 @@ export default {
{
label: '券类型',
name: 'discountType',
labelWidth: 56,
type: 'select',
optionList: [],
optionId: 'confId',
......@@ -141,13 +148,10 @@ export default {
searchFormDataTwo: [
{
label: '核销门店',
name: 'verificationMerchantId',
type: 'select',
name: 'verificationMerchantName',
type: 'input',
isHide: false,
optionList: [],
optionId: 'confId',
optionLabel: 'confName',
optionsName: 'discountTypeList'
maxlength: 50
},
{
label: '核销人',
......@@ -155,7 +159,7 @@ export default {
type: 'input',
isHide: false,
labelWidth: 56,
maxlength: 11
maxlength: 50
},
{
label: '用户',
......@@ -166,17 +170,6 @@ export default {
maxlength: 11
},
{
label: '券来源',
name: 'packageId',
type: 'select',
optionList: [],
optionId: 'confId',
optionLabel: 'confName',
optionsName: 'packageList'
}
],
searchFormDataThree: [
{
label: '核销日期',
name: 'daterange',
type: 'datePicker',
......@@ -184,6 +177,18 @@ export default {
pickerOptions: 'beforeRangePickerOptions'
}
],
searchFormDataThree: [
{
label: '券来源',
name: 'packageId',
labelWidth: 56,
type: 'select',
optionList: [],
optionId: 'id',
optionLabel: 'packageName',
optionsName: 'packageList'
}
],
// 表格组件
getListApi: this.$apis.couponManage.getVerificationListApi,
pageConf: { pageSize: 'pageSize', pageNum: 'pageNum', totalCount: 'total' },
......@@ -228,7 +233,7 @@ export default {
label: '券来源',
prop: 'packageName',
formatter: cellValue => {
return cellValue.packageName || '-'
return cellValue.packageName || cellValue.directionalGiftName || '-'
}
},
{
......@@ -301,11 +306,13 @@ export default {
this.merchantId = this.$globalState.session.merchantId
this.searchForm.merchantId = this.merchantId
}
console.log(this.$globalState.session)
if (this.$isGroupUp) {
this.getPackageList()
}
this.showOrHideAttr('searchFormDataTwo', this.$isGroupUp ? '核销人' : '核销门店', true)
this.deleteAttr(this.$isGroupUp ? '核销人' : '核销门店')
!this.$isGroupUp && this.showOrHideAttr('searchFormDataThree', '券来源', true)
this.deleteAttr(this.$isGroupUp ? ['核销人'] : ['核销门店'])
},
mounted() {
......@@ -317,14 +324,16 @@ export default {
let idx = this[formName].findIndex(item => item.label == label)
this[formName][idx].isHide = isHide
},
deleteAttr(label) {
let idx = this.tableParams.tableColumns.findIndex(item => item.label == label)
this.tableParams.tableColumns.splice(idx, 1)
deleteAttr(labelList) {
labelList.forEach(i => {
let idx = this.tableParams.tableColumns.findIndex(item => item.label == i)
this.tableParams.tableColumns.splice(idx, 1)
})
},
getPackageList() {
this.$apis.couponManage.getPackageListApi({ pageNum: 1, pageSize: 9999 }).then(res => {
this.baseData.packageList = res.list
this.getOptionsList('searchFormDataTwo', true, 'packageId')
this.getOptionsList('searchFormDataThree', true, 'packageId')
})
},
// 跳转到礼包领取详情页
......@@ -479,6 +488,7 @@ export default {
userReq: '',
verificationOperator: '',
orderCode: '',
packageId: '',
discountType: '',
discountTypes: [2, 3, 4, 7]
}
......
Markdown is supported
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!