Commit 4d8fe9d3 by 张权

表单完成

1 parent fb2e84a9
...@@ -6,7 +6,7 @@ ...@@ -6,7 +6,7 @@
<el-tabs v-model="activeName" type="card" @tab-click="handleClick"> <el-tabs v-model="activeName" type="card" @tab-click="handleClick">
<el-tab-pane label="批次管理" name="first" class="contain" style="margin: 0" id="batch"> <el-tab-pane label="批次管理" name="first" class="contain" style="margin: 0" id="batch">
<GLButton fn="批量生成权益卡" type="primary" size="small" @click="dialogVisible = true">批量生成权益卡</GLButton> <GLButton fn="批量生成权益卡" type="primary" size="small" @click="dialogVisible = true">批量生成权益卡</GLButton>
<el-form :inline="true" label-width="auto" label-position="right" style="margin-top: 20px" class="collectonForm"> <!-- <el-form :inline="true" label-width="auto" label-position="right" style="margin-top: 20px" class="collectonForm">
<el-row style="align-items: center" class="select"> <el-row style="align-items: center" class="select">
<el-form-item label="添加时间"> <el-form-item label="添加时间">
<el-date-picker v-model="batchDate" type="daterange" range-separator="至" start-placeholder="开始日期" end-placeholder="结束日期" size="small" value-format="yyyy-MM-dd"></el-date-picker> <el-date-picker v-model="batchDate" type="daterange" range-separator="至" start-placeholder="开始日期" end-placeholder="结束日期" size="small" value-format="yyyy-MM-dd"></el-date-picker>
...@@ -24,7 +24,14 @@ ...@@ -24,7 +24,14 @@
<el-button type="primary" size="small" @click="selectCollectionTable('select')" class="selectBtn">搜索</el-button> <el-button type="primary" size="small" @click="selectCollectionTable('select')" class="selectBtn">搜索</el-button>
</el-form-item> </el-form-item>
</el-row> </el-row>
</el-form> </el-form> -->
<GLCombiForm :rowNumber="1" ref="managerRef" :formObj="batchListSearch" :formData="managerForm" @handleOk="selectCollectionTable('select')" @handleRest="selectCollectionTable('reset')">
<div slot="merchant">
<el-select v-model="batchListSearch.merchantName" size="small" clearable filterable remote reserve-keyword placeholder="请输入关联门店" :remote-method="remoteMethod" :loading="loading" class="formItem">
<el-option v-for="(item, index) in options" :key="index" :label="item.merchantName" :value="item.merchantName"></el-option>
</el-select>
</div>
</GLCombiForm>
<GLTable ref="batchDetailTable" :searchForm="batchListSearch" :tableParams="batchTableParams" :getListApi="getlistMemberBatch" :beforeSearchFn="changeBatchDataFormat" :pageConf="batchPageConf" :noDataImg="url" @setTableFinishFun="setTableFinishFun"> <GLTable ref="batchDetailTable" :searchForm="batchListSearch" :tableParams="batchTableParams" :getListApi="getlistMemberBatch" :beforeSearchFn="changeBatchDataFormat" :pageConf="batchPageConf" :noDataImg="url" @setTableFinishFun="setTableFinishFun">
<span slot="auth-button" slot-scope="scope" :data="scope.scope"> <span slot="auth-button" slot-scope="scope" :data="scope.scope">
<!-- 批次管理详情弹窗按钮 --> <!-- 批次管理详情弹窗按钮 -->
...@@ -119,7 +126,7 @@ ...@@ -119,7 +126,7 @@
</el-tab-pane> </el-tab-pane>
<!--领用记录 --> <!--领用记录 -->
<el-tab-pane label="领用记录" name="second" class="contain" style="margin: 0" id="collection"> <el-tab-pane label="领用记录" name="second" class="contain" style="margin: 0" id="collection">
<el-form :inline="true" label-width="70px" label-position="right" class="collectonForm"> <!-- <el-form :inline="true" label-width="70px" label-position="right" class="collectonForm">
<el-row style="align-items: center"> <el-row style="align-items: center">
<el-form-item label="生成日期"> <el-form-item label="生成日期">
<el-date-picker v-model="colletionDate" type="daterange" range-separator="至" start-placeholder="开始日期" end-placeholder="结束日期" size="small" value-format="yyyy-MM-dd"></el-date-picker> <el-date-picker v-model="colletionDate" type="daterange" range-separator="至" start-placeholder="开始日期" end-placeholder="结束日期" size="small" value-format="yyyy-MM-dd"></el-date-picker>
...@@ -143,7 +150,15 @@ ...@@ -143,7 +150,15 @@
<el-button class="selectBtn" type="primary" size="small" @click="exportCollection">导出</el-button> <el-button class="selectBtn" type="primary" size="small" @click="exportCollection">导出</el-button>
</el-form-item> </el-form-item>
</el-row> </el-row>
</el-form> </el-form> -->
<GLCombiForm ref="collectonRef" :formObj="collectionListSearch" :formData="collectForm" @handleOk="collectionSelect('select')" @handleRest="collectionSelect('reset')">
<div slot="collectMerchant">
<el-select size="small" v-model="collectionListSearch.merchantName" clearable filterable remote reserve-keyword placeholder="请输入关联门店" :remote-method="remoteMethod" :loading="loading" class="formItem">
<el-option v-for="(item, index) in options" :key="index" :label="item.merchantName" :value="item.merchantName"></el-option>
</el-select>
</div>
</GLCombiForm>
<el-button class="selectBtn" type="primary" size="small" @click="exportCollection">导出</el-button>
<GLTable ref="collectionTable" :searchForm="collectionListSearch" :tableParams="collectionTableParams" :getListApi="listRequisitionMemberCard" :beforeSearchFn="changeCollectionDataFormat" :pageConf="pageConf" :noDataImg="url" @setTableFinishFun="setTableFinishFun"></GLTable> <GLTable ref="collectionTable" :searchForm="collectionListSearch" :tableParams="collectionTableParams" :getListApi="listRequisitionMemberCard" :beforeSearchFn="changeCollectionDataFormat" :pageConf="pageConf" :noDataImg="url" @setTableFinishFun="setTableFinishFun"></GLTable>
</el-tab-pane> </el-tab-pane>
</el-tabs> </el-tabs>
...@@ -205,11 +220,33 @@ export default { ...@@ -205,11 +220,33 @@ export default {
// 批次列表搜索项 // 批次列表搜索项
selectBatchId: '' || null, selectBatchId: '' || null,
batchListSearch: { batchListSearch: {
selectBatchId: '',
batchDate: '',
batchNo: '', batchNo: '',
merchantName: '', merchantName: '',
startTime: '', startTime: '',
endTime: '' endTime: ''
}, },
managerForm: [
{
label: '添加时间',
name: 'batchDate',
type: 'datePicker',
valueFormat: 'yyyy-MM-dd'
},
{
label: '批次',
name: 'selectBatchId',
type: 'input',
maxlength: 19
},
{
label: '门店',
name: 'merchantName',
type: 'select',
addHtml: 'merchant'
}
],
dialogVisible: false, dialogVisible: false,
activeName: 'first', activeName: 'first',
//批次管理table //批次管理table
...@@ -220,22 +257,23 @@ export default { ...@@ -220,22 +257,23 @@ export default {
tableColumns: [ tableColumns: [
{ {
label: '批次', label: '批次',
prop: 'batchNo' prop: 'batchNo',
width: '150'
}, },
{ {
label: '门店', label: '门店',
prop: 'merchantName' prop: 'merchantName'
}, },
{ {
label: '生成数量', label: '生成数量',
prop: 'num' prop: 'num',
// width: 110, width: '120'
// tagLabel: true // tagLabel: true
}, },
{ {
label: '激活数量', label: '激活数量',
prop: 'recipientCount', prop: 'recipientCount',
width: '150',
// minWidth: '200' // minWidth: '200'
formatter: cellValue => { formatter: cellValue => {
if (cellValue.recipientCount) { if (cellValue.recipientCount) {
...@@ -246,7 +284,7 @@ export default { ...@@ -246,7 +284,7 @@ export default {
} }
}, },
{ {
width: '95', width: '180',
label: '生成时间', label: '生成时间',
prop: 'createdDate', prop: 'createdDate',
formatter: cellValue => { formatter: cellValue => {
...@@ -280,7 +318,6 @@ export default { ...@@ -280,7 +318,6 @@ export default {
{ {
label: '卡号', label: '卡号',
prop: 'cardNo' prop: 'cardNo'
// minWidth: '200'
}, },
{ {
label: '激活码', label: '激活码',
...@@ -320,8 +357,33 @@ export default { ...@@ -320,8 +357,33 @@ export default {
sn: '', sn: '',
startTime: '', startTime: '',
endTime: '', endTime: '',
mobile: '' mobile: '',
colletionDate: ''
},
collectForm: [
{
label: '生成日期',
name: 'colletionDate',
type: 'datePicker',
valueFormat: 'yyyy-MM-dd'
}, },
{
label: '门店',
name: 'merchantName',
type: 'select',
addHtml: 'collectMerchant'
},
{
label: '设备SN',
name: 'sn',
type: 'input'
},
{
label: '账号',
name: 'mobile',
type: 'input'
}
],
// 领用记录表格 // 领用记录表格
collectionTableParams: { collectionTableParams: {
btnId: new Date().getTime() + parseInt(Math.random() * 1000), btnId: new Date().getTime() + parseInt(Math.random() * 1000),
...@@ -330,11 +392,12 @@ export default { ...@@ -330,11 +392,12 @@ export default {
{ {
label: '卡号', label: '卡号',
prop: 'cardNo', prop: 'cardNo',
minWidth: '200' width: '160'
}, },
{ {
label: '激活码', label: '激活码',
prop: 'activationCode' prop: 'activationCode',
width: '160'
}, },
{ {
label: '设备SN', label: '设备SN',
...@@ -343,7 +406,7 @@ export default { ...@@ -343,7 +406,7 @@ export default {
{ {
label: '账号', label: '账号',
prop: 'mobile', prop: 'mobile',
minWidth: '200', minWidth: '160',
formatter: cellValue => { formatter: cellValue => {
if (cellValue.mobile == 0) { if (cellValue.mobile == 0) {
return '' return ''
...@@ -367,19 +430,17 @@ export default { ...@@ -367,19 +430,17 @@ export default {
} }
}, },
{ {
width: '95',
label: '生成时间', label: '生成时间',
prop: 'createdDate', prop: 'createdDate',
minWidth: '200', width: '180',
formatter: cellValue => { formatter: cellValue => {
return this.date_format(cellValue.createdDate) return this.date_format(cellValue.createdDate)
} }
}, },
{ {
width: '95', width: '180',
label: '有效时间', label: '有效时间',
prop: 'validitDate', prop: 'validitDate',
minWidth: '200',
formatter: cellValue => { formatter: cellValue => {
return this.date_format(cellValue.validitDate) return this.date_format(cellValue.validitDate)
} }
...@@ -458,8 +519,8 @@ export default { ...@@ -458,8 +519,8 @@ export default {
// 批次界面搜索 // 批次界面搜索
selectCollectionTable(e) { selectCollectionTable(e) {
if (e == 'reset') { if (e == 'reset') {
this.batchDate = '' this.batchListSearch.batchDate = ''
this.selectBatchId = '' this.batchListSearch.selectBatchId = ''
this.batchListSearch.merchantName = '' this.batchListSearch.merchantName = ''
this.$apis.equityApi.getEquityCardBatchList(this.batchListSearch).then(res => { this.$apis.equityApi.getEquityCardBatchList(this.batchListSearch).then(res => {
this.$refs.batchDetailTable.refreshTable() this.$refs.batchDetailTable.refreshTable()
...@@ -636,10 +697,10 @@ export default { ...@@ -636,10 +697,10 @@ export default {
// 改变批次日期数据格式 // 改变批次日期数据格式
changeBatchDataFormat() { changeBatchDataFormat() {
return new Promise((resolve, reject) => { return new Promise((resolve, reject) => {
this.batchListSearch.endTime = this.batchDate ? this.batchDate[1] + ' 23:59:59' : '' this.batchListSearch.endTime = this.batchListSearch.batchDate ? this.batchListSearch.batchDate[1] + ' 23:59:59' : ''
this.batchListSearch.startTime = this.batchDate ? this.batchDate[0] + ' 00:00:01' : '' this.batchListSearch.startTime = this.batchListSearch.batchDate ? this.batchListSearch.batchDate[0] + ' 00:00:01' : ''
if (this.selectBatchId) { if (this.batchListSearch.selectBatchId) {
this.batchListSearch.batchNo = +this.selectBatchId this.batchListSearch.batchNo = +this.batchListSearch.selectBatchId
} else { } else {
this.batchListSearch.batchNo = null this.batchListSearch.batchNo = null
} }
...@@ -651,8 +712,8 @@ export default { ...@@ -651,8 +712,8 @@ export default {
return new Promise((resolve, reject) => { return new Promise((resolve, reject) => {
if (this.collectionListSearch.sn.length > 2 || this.collectionListSearch.sn.length < 1) { if (this.collectionListSearch.sn.length > 2 || this.collectionListSearch.sn.length < 1) {
if (this.collectionListSearch.mobile.length > 2 || this.collectionListSearch.mobile.length < 1) { if (this.collectionListSearch.mobile.length > 2 || this.collectionListSearch.mobile.length < 1) {
this.collectionListSearch.endTime = this.colletionDate ? this.colletionDate[1] + ' 23:59:59' : '' || undefined this.collectionListSearch.endTime = this.collectionListSearch.colletionDate ? this.collectionListSearch.colletionDate[1] + ' 23:59:59' : '' || undefined
this.collectionListSearch.startTime = this.colletionDate ? this.colletionDate[0] + ' 00:00:01' : '' || undefined this.collectionListSearch.startTime = this.collectionListSearch.colletionDate ? this.collectionListSearch.colletionDate[0] + ' 00:00:01' : '' || undefined
resolve() resolve()
} else { } else {
Message({ Message({
......
<template> <template>
<div class="equity-wrap"> <div class="equity-wrap">
<div class="equity-wrap contain"> <div class="equity-wrap contain">
<el-form :inline="true" style="width: 100%" :model="searchForm" label-width="70px" label-position="right"> <!-- <el-form :inline="true" style="width: 100%" :model="searchForm" label-width="70px" label-position="right">
<el-row style="display: flex; align-items: center"> <el-row style="display: flex; align-items: center">
<el-form-item size="small" label="加油日期"> <el-form-item size="small" label="加油日期">
<el-date-picker size="small" v-model="searchForm.daterange" type="daterange" range-separator="至" start-placeholder="开始日期" end-placeholder="结束日期" value-format="yyyy-MM-dd" :picker-options="pickerOptions || {}"></el-date-picker> <el-date-picker size="small" v-model="searchForm.daterange" type="daterange" range-separator="至" start-placeholder="开始日期" end-placeholder="结束日期" value-format="yyyy-MM-dd" :picker-options="pickerOptions || {}"></el-date-picker>
...@@ -24,7 +24,8 @@ ...@@ -24,7 +24,8 @@
<el-button :size="size" type="primary" @click="handleSearch">查询</el-button> <el-button :size="size" type="primary" @click="handleSearch">查询</el-button>
</el-form-item> </el-form-item>
</el-row> </el-row>
</el-form> </el-form> -->
<GLCombiForm ref="showSearch" :formObj="searchForm" :formData="searchFormData" @handleOk="handleSearch" @handleRest="handleReset"></GLCombiForm>
<GLTable v-if="flag" ref="table" :noDataImg="url" @setTableFinishFun="setTableFinishFun" :searchForm="searchFormTable" :tableParams="tableParams" :getListApi="tableParams.getListApi" :hasNum="false" :pageConf="pageConf" :beforeSearchFn="beforeSearchFn"></GLTable> <GLTable v-if="flag" ref="table" :noDataImg="url" @setTableFinishFun="setTableFinishFun" :searchForm="searchFormTable" :tableParams="tableParams" :getListApi="tableParams.getListApi" :hasNum="false" :pageConf="pageConf" :beforeSearchFn="beforeSearchFn"></GLTable>
</div> </div>
</div> </div>
...@@ -42,22 +43,73 @@ function date_format(date) { ...@@ -42,22 +43,73 @@ function date_format(date) {
var ss = date2.getSeconds() < 10 ? '0' + date2.getSeconds() : date2.getSeconds() var ss = date2.getSeconds() < 10 ? '0' + date2.getSeconds() : date2.getSeconds()
return YY + MM + DD + ' ' + hh + mm + ss return YY + MM + DD + ' ' + hh + mm + ss
} }
import url from "@/assets/empty.png" import url from '@/assets/empty.png'
// import { searchMixin } from '@/mixins' // import { searchMixin } from '@/mixins'
export default { export default {
name: '', name: '',
// mixins: [searchMixin], // mixins: [searchMixin],
data() { data() {
return { return {
url:url, url: url,
size: 'small', size: 'small',
pickerOptions: { pickerOptions: {
disabledDate(time) { disabledDate(time) {
return time.getTime() > Date.now() || time.getTime() < new Date('2017-12-31').getTime() return time.getTime() > Date.now() || time.getTime() < new Date('2017-12-31').getTime()
} }
}, },
searchFormData: [
{
label: '加油日期',
name: 'daterange',
type: 'datePicker',
valueFormat: 'yyyy-MM-dd',
isClear: true,
customPickerOptions: {
disabledDate(time) {
return time.getTime() > Date.now() || time.getTime() < new Date('2017-12-31').getTime()
}
}
},
{
label: '订单号',
name: 'orderId',
type: 'input',
isClear: true
},
{
label: '用户信息',
name: 'phone',
type: 'input',
isClear: true
},
{
label: '订单状态',
name: 'orderStatus',
type: 'select',
optionList: [
{
label: '已结算',
value: '0'
},
{
label: '待结算',
value: '1'
},
{
label: '已失效',
value: '2'
}
],
optionId: 'value',
optionLabel: 'label',
isClear: true
}
],
searchForm: { searchForm: {
orderId: '' orderId: '',
phone: '',
daterange: '',
orderStatus: ''
}, },
searchFormTable: {}, searchFormTable: {},
pageConf: { pageSize: 'pageSize', pageNum: 'pageNum', totalCount: 'total' }, pageConf: { pageSize: 'pageSize', pageNum: 'pageNum', totalCount: 'total' },
...@@ -151,7 +203,7 @@ export default { ...@@ -151,7 +203,7 @@ export default {
}, },
setTableFinishFun() { setTableFinishFun() {
//接收到的数据为空 //接收到的数据为空
if (!this.$refs.table.data.length) { if (!this.$refs?.table?.data?.length) {
this.$refs.table.setTableHeightFun() this.$refs.table.setTableHeightFun()
} }
}, },
...@@ -169,20 +221,6 @@ export default { ...@@ -169,20 +221,6 @@ export default {
} }
</script> </script>
<style lang="scss" scoped> <style lang="scss" scoped>
.el-form-item {
margin-bottom: 15px;
}
.el-range-editor.is-active,
.el-range-editor.is-active:hover {
border-color: #5850ff;
width: 215px;
}
.el-range-editor--small.el-input__inner {
width: 215px;
}
/deep/ .contain .el-input--small .el-input__inner {
width: 215px;
}
.equity-wrap .contain { .equity-wrap .contain {
margin-top: 20px; margin-top: 20px;
} }
......
...@@ -21,7 +21,7 @@ ...@@ -21,7 +21,7 @@
<el-button icon="el-icon-refresh" class="refreshBtn"></el-button> <el-button icon="el-icon-refresh" class="refreshBtn"></el-button>
</div> --> </div> -->
</div> </div>
<el-form :inline="true" style="width: 100%" :model="searchForm" label-width="70px" label-position="right"> <!-- <el-form :inline="true" style="width: 100%" :model="searchForm" label-width="70px" label-position="right">
<el-row style="display: flex; align-items: center"> <el-row style="display: flex; align-items: center">
<el-form-item size="small" label="品牌名称"> <el-form-item size="small" label="品牌名称">
<el-select size="small" v-model="searchForm.brandName" placeholder="请选择"> <el-select size="small" v-model="searchForm.brandName" placeholder="请选择">
...@@ -56,7 +56,8 @@ ...@@ -56,7 +56,8 @@
<GLButton fn="财务管理导出" :size="size" type="primary" @click="exportExcel">导出</GLButton> <GLButton fn="财务管理导出" :size="size" type="primary" @click="exportExcel">导出</GLButton>
</el-form-item> </el-form-item>
</el-row> </el-row>
</el-form> </el-form> -->
<GLCombiForm ref="showSearch" :formObj="searchForm" :formData="searchFormData" @handleOk="handleSearch" @handleRest="handleReset"></GLCombiForm>
<GLTable v-if="flag" ref="table" :noDataImg="url" @setTableFinishFun="setTableFinishFun" :searchForm="searchFormTable" :tableParams="tableParams" :getListApi="tableParams.getListApi" :hasNum="false" :pageConf="pageConf" :beforeSearchFn="beforeSearchFn"> <GLTable v-if="flag" ref="table" :noDataImg="url" @setTableFinishFun="setTableFinishFun" :searchForm="searchFormTable" :tableParams="tableParams" :getListApi="tableParams.getListApi" :hasNum="false" :pageConf="pageConf" :beforeSearchFn="beforeSearchFn">
<template slot="custom"> <template slot="custom">
<div class="table-custom exportBtn"></div> <div class="table-custom exportBtn"></div>
...@@ -66,7 +67,7 @@ ...@@ -66,7 +67,7 @@
</div> </div>
</template> </template>
<script type='text/ecmascript-6'> <script type="text/ecmascript-6">
import url from "@/assets/empty.png" import url from "@/assets/empty.png"
import { orderMixin, searchMixin } from '@/mixins' import { orderMixin, searchMixin } from '@/mixins'
export default { export default {
...@@ -85,7 +86,86 @@ export default { ...@@ -85,7 +86,86 @@ export default {
pageConf: { pageSize: 'pageSize', pageNum: 'pageNum', totalCount: 'total' }, pageConf: { pageSize: 'pageSize', pageNum: 'pageNum', totalCount: 'total' },
flag: true, flag: true,
price: 0, price: 0,
searchForm: {}, searchForm: {
brandName:'',
productName:'',
merchantName:'',
appereance:'',
orderStatus:'',
daterange:''
},
searchFormData: [
{
label: '品牌名称',
name: 'brandName',
type: 'select',
optionList: [],
optionId: 'brandName',
optionLabel: 'brandName',
isClear: true
},
{
label: '商品名称',
name: 'productName',
type: 'input',
isClear: true
},
{
label: '门店名称',
name: 'merchantName',
type: 'input',
isClear: true
},
{
label: '商品形态',
name: 'appereance',
type: 'select',
optionList: [{
label: '卡券',
value: 1
}, {
label: '直充',
value: 2
}],
optionId: 'value',
optionLabel: 'label',
isClear: true
},
{
label: '订单状态',
name: 'orderStatus',
type: 'select',
optionList: [{
label: '待收货',
value: [1, 2]
}, {
label: '已完成',
value: [3]
}, {
label: '已退款',
value: [6]
},
{
label: '售后中',
value: [4]
}],
optionId: 'value',
optionLabel: 'label',
isClear: true
},
{
label: '下单时间',
name: 'daterange',
type: 'datePicker',
valueFormat: 'yyyy-MM-dd',
isClear: true,
customPickerOptions: {
disabledDate(time) {
return time.getTime() > Date.now() || time.getTime() < new Date('2017-12-31').getTime()
}
}
}
],
searchFormTable: {}, searchFormTable: {},
tableParams: { tableParams: {
listName: 'list', listName: 'list',
...@@ -124,7 +204,8 @@ export default { ...@@ -124,7 +204,8 @@ export default {
tableColumns: [ tableColumns: [
{ {
label: '订单编号', label: '订单编号',
prop: 'orderCode' prop: 'orderCode',
width:'220'
}, },
{ {
label: '品牌名称', label: '品牌名称',
...@@ -132,6 +213,7 @@ export default { ...@@ -132,6 +213,7 @@ export default {
}, },
{ {
label: '商品形态', label: '商品形态',
width: '100',
prop: 'appearanceDesc' prop: 'appearanceDesc'
}, },
{ {
...@@ -155,6 +237,8 @@ export default { ...@@ -155,6 +237,8 @@ export default {
}, },
{ {
label: '下单渠道', label: '下单渠道',
width:'250',
line: 1,
formatter(cell) { formatter(cell) {
return `${cell.merchantName || ''}${cell.merchantName ? '-' : ''}${cell.channelName}` return `${cell.merchantName || ''}${cell.merchantName ? '-' : ''}${cell.channelName}`
} }
...@@ -169,7 +253,7 @@ export default { ...@@ -169,7 +253,7 @@ export default {
{ {
label: '下单时间', label: '下单时间',
prop: 'orderDate', prop: 'orderDate',
width: 95, width: '180',
formatter(cell) { formatter(cell) {
return cell.orderDate ? new Date(cell.orderDate).format('yyyy-MM-dd hh:mm:ss') : '- -' return cell.orderDate ? new Date(cell.orderDate).format('yyyy-MM-dd hh:mm:ss') : '- -'
} }
...@@ -178,6 +262,12 @@ export default { ...@@ -178,6 +262,12 @@ export default {
} }
} }
}, },
created(){
this.$apis.orderApi.getAllBrandList({}).then(({ data }) => {
const item = this.searchFormData.find(item => item.name==='brandName')
item.optionList = data
})
},
mounted() { mounted() {
this.getHwAccount() this.getHwAccount()
}, },
...@@ -255,22 +345,21 @@ export default { ...@@ -255,22 +345,21 @@ export default {
// <style src="@a/css/tao.css"></style> // <style src="@a/css/tao.css"></style>
</script> </script>
<style lang="scss" scoped> <style lang="scss" scoped>
.el-form-item { // .el-form-item {
margin-bottom: 15px; // margin-bottom: 15px;
} // }
.el-range-editor.is-active, // .el-range-editor.is-active,
.el-range-editor.is-active:hover { // .el-range-editor.is-active:hover {
border-color: #5850ff; // border-color: #5850ff;
width: 215px; // width: 215px;
} // }
.el-range-editor--small.el-input__inner { // .el-range-editor--small.el-input__inner {
width: 215px; // width: 215px;
} // }
/deep/ .contain .el-input--small .el-input__inner { // /deep/ .contain .el-input--small .el-input__inner {
width: 215px; // width: 215px;
} // }
.equity-wrap .contain { .equity-wrap .contain {
.topContent { .topContent {
display: flex; display: flex;
......
<template> <template>
<div class="equity-wrap"> <div class="equity-wrap">
<div class="equity-wrap contain"> <div class="equity-wrap contain">
<el-form :inline="true" style="width: 100%" :model="searchForm" label-width="90px" label-position="right"> <!-- <el-form :inline="true" style="width: 100%" :model="searchForm" label-width="90px" label-position="right">
<el-row style="display: flex; align-items: center"> <el-row style="display: flex; align-items: center">
<el-form-item size="small" label="加油日期"> <el-form-item size="small" label="加油日期">
<el-date-picker size="small" v-model="searchForm.daterange" type="daterange" range-separator="至" start-placeholder="开始日期" end-placeholder="结束日期" value-format="yyyy-MM-dd" :picker-options="pickerOptions || {}"></el-date-picker> <el-date-picker size="small" v-model="searchForm.daterange" type="daterange" range-separator="至" start-placeholder="开始日期" end-placeholder="结束日期" value-format="yyyy-MM-dd" :picker-options="pickerOptions || {}"></el-date-picker>
</el-form-item> </el-form-item>
<el-form-item size="small" label="加油供应商"> <el-form-item size="small" label="加油供应商">
<el-select size="small" :value="'团油'" placeholder="请选择"> <el-select size="small" :value="'团油'" placeholder="请选择">
<!-- <el-option v-for="item in appereanceList" :key="item.value" :label="item.label" :value="item.value"></el-option> -->
<el-option label="团油" value="团油"></el-option> <el-option label="团油" value="团油"></el-option>
</el-select> </el-select>
</el-form-item> </el-form-item>
...@@ -31,13 +30,14 @@ ...@@ -31,13 +30,14 @@
<el-button :size="size" type="primary" @click="handleExport">导出</el-button> <el-button :size="size" type="primary" @click="handleExport">导出</el-button>
</el-form-item> </el-form-item>
</el-row> </el-row>
</el-form> </el-form> -->
<GLCombiForm ref="showSearch" :formObj="searchForm" :formData="searchFormData" @handleOk="handleSearch" @handleRest="handleReset"></GLCombiForm>
<GLTable v-if="flag" ref="table" :noDataImg="url" @setTableFinishFun="setTableFinishFun" :searchForm="searchFormTable" :tableParams="tableParams" :getListApi="tableParams.getListApi" :hasNum="false" :pageConf="pageConf" :beforeSearchFn="beforeSearchFn"></GLTable> <GLTable v-if="flag" ref="table" :noDataImg="url" @setTableFinishFun="setTableFinishFun" :searchForm="searchFormTable" :tableParams="tableParams" :getListApi="tableParams.getListApi" :hasNum="false" :pageConf="pageConf" :beforeSearchFn="beforeSearchFn"></GLTable>
</div> </div>
</div> </div>
</template> </template>
<script type='text/ecmascript-6'> <script type="text/ecmascript-6">
function getExplorer() { function getExplorer() {
var ua = navigator.userAgent.toLocaleLowerCase() var ua = navigator.userAgent.toLocaleLowerCase()
var browserType = null var browserType = null
...@@ -92,7 +92,77 @@ export default { ...@@ -92,7 +92,77 @@ export default {
}, },
pageConf: { pageSize: 'pageSize', pageNum: 'pageNum', totalCount: 'total' }, pageConf: { pageSize: 'pageSize', pageNum: 'pageNum', totalCount: 'total' },
flag: true, flag: true,
searchForm: {}, searchForm: {
orderId: '',
phone: '',
daterange:'',
orderStatus:''
},
searchFormData: [
{
label: '加油日期',
name: 'daterange',
type: 'datePicker',
valueFormat: 'yyyy-MM-dd',
isClear: true,
customPickerOptions: {
disabledDate(time) {
return time.getTime() > Date.now() || time.getTime() < new Date('2017-12-31').getTime()
}
}
},
{
label: '加油供应商',
name: 'massOil',
type: 'select',
optionList: [
{
label: '团油'
}
],
optionId: 'label',
optionLabel: 'label',
isClear: true
},
{
label: '订单号',
name: 'orderId',
type: 'input',
isClear: true
},
{
label: '用户信息',
name: 'phone',
type: 'input',
isClear: true
},
{
label: '订单状态',
name: 'orderStatus',
type: 'select',
optionList: [
{
label: '已支付',
value: 1
},
{
label: '退款申请中',
value: 4
},
{
label: '已退款',
value: 5
},
{
label: '退款失败',
value: 6
}
],
optionId: 'value',
optionLabel: 'label',
isClear: true
}
],
searchFormTable: {}, searchFormTable: {},
statusList: [ statusList: [
{ {
...@@ -145,7 +215,7 @@ export default { ...@@ -145,7 +215,7 @@ export default {
{ {
label: '加油升数(L)', label: '加油升数(L)',
prop: 'litre', prop: 'litre',
width: '100' width: '150'
}, },
{ {
label: '实付金额', label: '实付金额',
...@@ -234,20 +304,20 @@ export default { ...@@ -234,20 +304,20 @@ export default {
</script> </script>
<style lang="scss" scoped> <style lang="scss" scoped>
.el-form-item { // .el-form-item {
margin-bottom: 15px; // margin-bottom: 15px;
} // }
.el-range-editor.is-active, // .el-range-editor.is-active,
.el-range-editor.is-active:hover { // .el-range-editor.is-active:hover {
border-color: #5850ff; // border-color: #5850ff;
width: 215px; // width: 215px;
} // }
.el-range-editor--small.el-input__inner { // .el-range-editor--small.el-input__inner {
width: 215px; // width: 215px;
} // }
/deep/ .contain .el-input--small .el-input__inner { // /deep/ .contain .el-input--small .el-input__inner {
width: 215px; // width: 215px;
} // }
.equity-wrap .contain { .equity-wrap .contain {
margin-top: 20px; margin-top: 20px;
} }
......
...@@ -2,7 +2,7 @@ ...@@ -2,7 +2,7 @@
<div class="equity-wrap"> <div class="equity-wrap">
<GLButton fn="新增商品" class="addGood" type="primary" icon="el-icon-plus" @click="jump">新增商品</GLButton> <GLButton fn="新增商品" class="addGood" type="primary" icon="el-icon-plus" @click="jump">新增商品</GLButton>
<div class="equity-wrap contain"> <div class="equity-wrap contain">
<el-form :inline="true" style="width: 100%" :model="searchForm" label-width="85px" label-position="right"> <!-- <el-form :inline="true" style="width: 100%" :model="searchForm" label-width="85px" label-position="right">
<el-row style="display: flex; align-items: center; margin-bottom: 2px"> <el-row style="display: flex; align-items: center; margin-bottom: 2px">
<el-form-item size="small" label="品牌名称"> <el-form-item size="small" label="品牌名称">
<el-select size="small" v-model="searchForm.brandName" filterable placeholder="请选择"> <el-select size="small" v-model="searchForm.brandName" filterable placeholder="请选择">
...@@ -12,9 +12,6 @@ ...@@ -12,9 +12,6 @@
<el-form-item size="small" label="商品名称"> <el-form-item size="small" label="商品名称">
<el-input v-model="searchForm.productName" placeholder="请输入" size="small" clearable></el-input> <el-input v-model="searchForm.productName" placeholder="请输入" size="small" clearable></el-input>
</el-form-item> </el-form-item>
<!-- <el-form-item label="门店名称">
<el-input v-model="searchForm.productName" placeholder="请输入" size="small" clearable></el-input>
</el-form-item> -->
<el-form-item size="small" label="提供方" style="margin-left: -10px"> <el-form-item size="small" label="提供方" style="margin-left: -10px">
<el-select size="small" v-model="searchForm.supplier"> <el-select size="small" v-model="searchForm.supplier">
<el-option v-for="item in supplierList" :key="item.value" :label="item.label" :value="item.value"></el-option> <el-option v-for="item in supplierList" :key="item.value" :label="item.label" :value="item.value"></el-option>
...@@ -38,7 +35,8 @@ ...@@ -38,7 +35,8 @@
<el-button :size="size" type="primary" @click="handleSearch">查询</el-button> <el-button :size="size" type="primary" @click="handleSearch">查询</el-button>
</el-form-item> </el-form-item>
</el-row> </el-row>
</el-form> </el-form> -->
<GLCombiForm ref="showSearch" :formObj="searchForm" :formData="searchFormData" @handleOk="handleSearch" @handleRest="handleReset"></GLCombiForm>
<div class="row-btns"> <div class="row-btns">
<el-button size="small" @click="toggleAll">全选</el-button> <el-button size="small" @click="toggleAll">全选</el-button>
<GLButton fn="上架商品" size="small" type="primary" @click="batchOperation(1)">上架</GLButton> <GLButton fn="上架商品" size="small" type="primary" @click="batchOperation(1)">上架</GLButton>
...@@ -56,7 +54,7 @@ ...@@ -56,7 +54,7 @@
</div> </div>
</template> </template>
<script type='text/ecmascript-6'> <script type="text/ecmascript-6">
import url from '@/assets/empty.png' import url from '@/assets/empty.png'
import { searchMixin } from '@/mixins' import { searchMixin } from '@/mixins'
export default { export default {
...@@ -68,8 +66,83 @@ export default { ...@@ -68,8 +66,83 @@ export default {
size: 'small', size: 'small',
pageConf: { pageSize: 'pageSize', pageNum: 'pageNum', totalCount: 'total' }, pageConf: { pageSize: 'pageSize', pageNum: 'pageNum', totalCount: 'total' },
flag: true, flag: true,
searchForm: {}, searchForm: {
brandName:'',
productName:'',
supplier:'',
productId:'',
status:'',
id:''
},
searchFormData: [
{
label: '品牌名称',
name: 'brandName',
type: 'select',
optionList: [
{
label: '团油'
}
],
optionId: 'label',
optionLabel: 'label',
isClear: true
},
{
label: '商品名称',
name: 'productName',
type: 'input',
isClear: true
},
{
label: '提供方',
name: 'supplier',
type: 'select',
optionList: [
{
label: '海威',
value: 'HW'
}
],
optionId: 'value',
optionLabel: 'label',
isClear: true
},
{
label: '商品编码',
name: 'productId',
type: 'input',
isClear: true
},
{
label: '商品状态',
name: 'status',
type: 'select',
optionList: [
{
label: '上架',
value: '1'
},
{
label: '下架',
value: '2'
},
{
label: '待上架',
value: '0'
}
],
optionId: 'value',
optionLabel: 'label',
isClear: true
},
{
label: '商品ID',
name: 'id',
type: 'input',
isClear: true
},
],
supplierList: [ supplierList: [
{ {
label: '海威', label: '海威',
...@@ -156,7 +229,9 @@ export default { ...@@ -156,7 +229,9 @@ export default {
methods: { methods: {
getAllBrandList() { getAllBrandList() {
this.$apis.orderApi.getAllBrandList().then(res => { this.$apis.orderApi.getAllBrandList().then(res => {
this.goodsBrandList = res.data || [] // this.goodsBrandList = res.data || []
const item = this.searchFormData.find(item => item.name==='brandName')
item.optionList = res.data
}) })
}, },
jump({ id, status }, copy) { jump({ id, status }, copy) {
...@@ -291,9 +366,6 @@ export default { ...@@ -291,9 +366,6 @@ export default {
padding: 8px 16px; padding: 8px 16px;
// margin-bottom: 20px; // margin-bottom: 20px;
} }
/deep/ .contain .el-input--small .el-input__inner {
width: 215px;
}
.row-btns { .row-btns {
margin-top: 5px; margin-top: 5px;
margin-bottom: 10px; margin-bottom: 10px;
......
<template> <template>
<div class="equity-wrap"> <div class="equity-wrap">
<div class="equity-wrap contain"> <div class="equity-wrap contain">
<el-form :inline="true" style="width: 100%" :model="searchForm" label-width="70px" label-position="right"> <!-- <el-form :inline="true" style="width: 100%" :model="searchForm" label-width="70px" label-position="right">
<el-row style="display: flex; align-items: center"> <el-row style="display: flex; align-items: center">
<el-form-item size="small" label="订单编号"> <el-form-item size="small" label="订单编号">
<el-input size="small" v-model="searchForm.orderCode" placeholder="请输入"></el-input> <el-input size="small" v-model="searchForm.orderCode" placeholder="请输入"></el-input>
...@@ -31,7 +31,9 @@ ...@@ -31,7 +31,9 @@
<el-button :size="size" type="primary" @click="handleExport">导出</el-button> <el-button :size="size" type="primary" @click="handleExport">导出</el-button>
</el-form-item> </el-form-item>
</el-row> </el-row>
</el-form> </el-form> -->
<GLCombiForm ref="showSearch" :formObj="searchForm" :formData="searchFormData" @handleOk="handleSearch" @handleRest="handleReset"></GLCombiForm>
<el-button :size="size" type="primary" @click="handleExport">导出</el-button>
<div class="choseRow"> <div class="choseRow">
<div class="choseItem" :class="{ active: currentIndex == index }" v-for="(item, index) in choseList" :key="index" @click="tabClick(index)"> <div class="choseItem" :class="{ active: currentIndex == index }" v-for="(item, index) in choseList" :key="index" @click="tabClick(index)">
{{ item }} {{ item }}
...@@ -64,7 +66,7 @@ ...@@ -64,7 +66,7 @@
</div> </div>
</template> </template>
<script type='text/ecmascript-6'> <script type="text/ecmascript-6">
import url from '@/assets/empty.png' import url from '@/assets/empty.png'
import { orderMixin, searchMixin } from '@/mixins' import { orderMixin, searchMixin } from '@/mixins'
export default { export default {
...@@ -84,7 +86,61 @@ export default { ...@@ -84,7 +86,61 @@ export default {
tabIndex: '', tabIndex: '',
flag: true, flag: true,
pageConf: { pageSize: 'pageSize', pageNum: 'pageNum', totalCount: 'total' }, pageConf: { pageSize: 'pageSize', pageNum: 'pageNum', totalCount: 'total' },
searchForm: {}, searchForm: {
orderCode:'',
brandName:'',
productName:'',
merchantName:'',
userInfo:'',
daterange:''
},
searchFormData: [
{
label: '订单编号',
name: 'orderCode',
type: 'input',
isClear: true
},
{
label: '品牌名称',
name: 'brandName',
type: 'select',
optionList: [],
optionId: 'brandName',
optionLabel: 'brandName',
isClear: true
},
{
label: '商品名称',
name: 'productName',
type: 'input',
isClear: true
},
{
label: '门店名称',
name: 'merchantName',
type: 'input',
isClear: true
},
{
label: '用户信息',
name: 'userInfo',
type: 'input',
isClear: true
},
{
label: '下单时间',
name: 'daterange',
type: 'datePicker',
valueFormat: 'yyyy-MM-dd',
isClear: true,
customPickerOptions: {
disabledDate(time) {
return time.getTime() > Date.now() || time.getTime() < new Date('2017-12-31').getTime()
}
}
},
],
searchFormTable: {}, searchFormTable: {},
tableParams: { tableParams: {
listName: 'list', listName: 'list',
...@@ -163,6 +219,12 @@ export default { ...@@ -163,6 +219,12 @@ export default {
} }
} }
}, },
created(){
this.$apis.orderApi.getAllBrandList({}).then(({ data }) => {
const item = this.searchFormData.find(item => item.name==='brandName')
item.optionList = data
})
},
mounted() {}, mounted() {},
methods: { methods: {
handleExport() { handleExport() {
...@@ -280,7 +342,6 @@ export default { ...@@ -280,7 +342,6 @@ export default {
// <style src="@a/css/tao.css"></style> // <style src="@a/css/tao.css"></style>
</script> </script>
<style lang="scss" scoped> <style lang="scss" scoped>
.equity-wrap .contain { .equity-wrap .contain {
margin-top: 20px; margin-top: 20px;
...@@ -304,20 +365,20 @@ export default { ...@@ -304,20 +365,20 @@ export default {
} }
} }
} }
.el-form-item { // .el-form-item {
margin-bottom: 15px; // margin-bottom: 15px;
} // }
.el-range-editor.is-active, // .el-range-editor.is-active,
.el-range-editor.is-active:hover { // .el-range-editor.is-active:hover {
border-color: #5850ff; // border-color: #5850ff;
width: 215px; // width: 215px;
} // }
.el-range-editor--small.el-input__inner { // .el-range-editor--small.el-input__inner {
width: 215px; // width: 215px;
} // }
/deep/ .contain .el-input--small .el-input__inner { // /deep/ .contain .el-input--small .el-input__inner {
width: 215px; // width: 215px;
} // }
// .el-tabs__nav-wrap:after { // .el-tabs__nav-wrap:after {
// display: none; // display: none;
......
...@@ -4,8 +4,8 @@ ...@@ -4,8 +4,8 @@
<el-dialog :close-on-click-modal="false" title="领卡用户明细" :visible.sync="isVisible" width="1080px" class="user-detail-dialog" @close="handleReset()"> <el-dialog :close-on-click-modal="false" title="领卡用户明细" :visible.sync="isVisible" width="1080px" class="user-detail-dialog" @close="handleReset()">
<div class="contain equity-wrap" style="margin: 20px 0px 20px 0px !important"> <div class="contain equity-wrap" style="margin: 20px 0px 20px 0px !important">
<glsx-combi-form ref="showSearch" labelWidth="120px" defaultWidth="215px" :formObj="batchListSearch" :formData="userDetailForm"> <glsx-combi-form ref="showSearch" labelWidth="120px" defaultWidth="215px" :formObj="batchListSearch" :formData="userDetailForm">
<span slot="footer" class="footer-btns"> <!-- <GLCombiForm ref="showSearch" :formObj="batchListSearch" :formData="userDetailForm" @handleOk="handleSearch" @handleRest="handleReset('reset')"></GLCombiForm> -->
</span> <span slot="footer" class="footer-btns"></span>
</glsx-combi-form> </glsx-combi-form>
<div style="padding:0 20px 20px"> <div style="padding:0 20px 20px">
<div style="float: right; margin-right: 0;margin-bottom:10px;"> <div style="float: right; margin-right: 0;margin-bottom:10px;">
...@@ -15,7 +15,7 @@ ...@@ -15,7 +15,7 @@
</div> </div>
<GLTable ref="userDetailTable" :hasNum="false" @hook:mounted="setTabelHeight" :searchForm="searchForm" :tableParams="batchTableParams" :getListApi="getListApi" :pageConf="batchPageConf" :noDataImg="url" :beforeSearchFn="beforeSearchFn"> <GLTable ref="userDetailTable" :hasNum="false" @hook:mounted="setTabelHeight" :searchForm="searchForm" :tableParams="batchTableParams" :getListApi="getListApi" :pageConf="batchPageConf" :noDataImg="url" :beforeSearchFn="beforeSearchFn">
<div slot="status" slot-scope="scope"> <div slot="status" slot-scope="scope">
<p :style="{color:scope.scope.status==1 ? '#2CCA74': '#CCC'}">{{ setStatusVal(scope.scope.status) }}</p> <p :style="{ color: scope.scope.status == 1 ? '#2CCA74' : '#CCC' }">{{ setStatusVal(scope.scope.status) }}</p>
</div> </div>
</GLTable> </GLTable>
</div> </div>
...@@ -24,7 +24,7 @@ ...@@ -24,7 +24,7 @@
</div> </div>
</template> </template>
<script type='text/ecmascript-6'> <script type="text/ecmascript-6">
import url from '@/assets/empty.png' import url from '@/assets/empty.png'
const activeTypeList = [ const activeTypeList = [
{ {
...@@ -359,15 +359,15 @@ export default { ...@@ -359,15 +359,15 @@ export default {
} }
</script> </script>
<style lang="scss" scoped> <style lang="scss" scoped>
/deep/ .user-detail-dialog{ /deep/ .user-detail-dialog {
.el-form-item{ .el-form-item {
margin-right: 0; margin-right: 0;
} }
.el-input--small .el-input__inner{ .el-input--small .el-input__inner {
width: 215px; width: 215px;
} }
.el-table__row{ .el-table__row {
.el-table__cell{ .el-table__cell {
padding: 9px 0; padding: 9px 0;
} }
} }
......
...@@ -13,10 +13,10 @@ ...@@ -13,10 +13,10 @@
<el-select size="small" v-model="searchForm.merchantName" filterable remote reserve-keyword placeholder="请输入门店名称" :remote-method="remoteMethod" :loading="loading" clearable style="margin-left: 10px"> <el-select size="small" v-model="searchForm.merchantName" filterable remote reserve-keyword placeholder="请输入门店名称" :remote-method="remoteMethod" :loading="loading" clearable style="margin-left: 10px">
<el-option v-for="(item, index) in options" :key="index" :label="item.merchantName" :value="item.merchantName"></el-option> <el-option v-for="(item, index) in options" :key="index" :label="item.merchantName" :value="item.merchantName"></el-option>
</el-select> --> </el-select> -->
<el-form :inline="true" style="width: 100%; margin-left: 10px;" :model="searchForm" label-width="108px" label-position="right"> <!-- <el-form :inline="true" style="width: 100%; margin-left: 10px;" :model="searchForm" label-width="108px" label-position="right">
<el-row style="display: flex; align-items: center"> <el-row style="display: flex; align-items: center">
<el-form-item size="small" label="搜索门店"> <el-form-item size="small" label="搜索门店">
<el-select size="small" v-model="searchForm.merchantName" remote reserve-keyword filterable placeholder="请输入门店名称" :remote-method="remoteMethod" :loading="loading" clearable > <el-select size="small" v-model="searchForm.merchantName" remote reserve-keyword filterable placeholder="请输入门店名称" :remote-method="remoteMethod" :loading="loading" clearable>
<el-option v-for="(item, index) in options" :key="index" :label="item.merchantName" :value="item.merchantName"></el-option> <el-option v-for="(item, index) in options" :key="index" :label="item.merchantName" :value="item.merchantName"></el-option>
</el-select> </el-select>
</el-form-item> </el-form-item>
...@@ -28,19 +28,20 @@ ...@@ -28,19 +28,20 @@
<el-button type="primary" size="small" style="margin-left: 20px" class="selectBtn" @click="selectStore('select')">搜索</el-button> <el-button type="primary" size="small" style="margin-left: 20px" class="selectBtn" @click="selectStore('select')">搜索</el-button>
</el-form-item> </el-form-item>
</el-row> </el-row>
</el-form> </el-form> -->
<!-- <div class="operationBtn"> <!-- <div class="operationBtn">
<el-button plain size="small" class="selectBtn" @click="selectStore('reset')">重置</el-button> <el-button plain size="small" class="selectBtn" @click="selectStore('reset')">重置</el-button>
<el-button type="primary" size="small" style="margin-left: 20px" class="selectBtn" @click="selectStore('select')">搜索</el-button> <el-button type="primary" size="small" style="margin-left: 20px" class="selectBtn" @click="selectStore('select')">搜索</el-button>
</div> --> </div> -->
</div> </div>
<GLCombiForm ref="showSearch" :rowNumber="1" :formObj="searchForm" :formData="searchFormData" @handleOk="selectStore('select')" @handleRest="selectStore('reset')"></GLCombiForm>
<div class="tableCtn"> <div class="tableCtn">
<GLTable ref="recordTable" :searchForm="searchForm" :tableParams="tableParams" :getListApi="getListApi" :pageConf="pageConf" :noDataImg="url" @setTableFinishFun="setTableFinishFun"> <GLTable ref="recordTable" :searchForm="searchForm" :tableParams="tableParams" :getListApi="getListApi" :pageConf="pageConf" :noDataImg="url" @setTableFinishFun="setTableFinishFun">
<div slot="recipientCount" slot-scope="scope"> <div slot="recipientCount" slot-scope="scope">
<p class="cursor-pointer" style="color:#5850ff" @click="handleDetail(scope.scope)">{{ scope.scope.recipientCount }}</p> <p class="cursor-pointer" style="color:#5850ff" @click="handleDetail(scope.scope)">{{ scope.scope.recipientCount }}</p>
</div> </div>
<span slot="auth-button" slot-scope="scope" :data="scope.scope"> <span slot="auth-button" slot-scope="scope" :data="scope.scope">
<GLButton fn ='权益卡管理编辑' type="text" @click="edit(scope.scope)" class="tableBtn" size="small">编辑</GLButton> <GLButton fn="权益卡管理编辑" type="text" @click="edit(scope.scope)" class="tableBtn" size="small">编辑</GLButton>
<el-button type="text" :disabled="scope.scope.tryAble == 0 ? true : false" @click="extension(scope.scope)" class="tableBtn" size="small">推广</el-button> <el-button type="text" :disabled="scope.scope.tryAble == 0 ? true : false" @click="extension(scope.scope)" class="tableBtn" size="small">推广</el-button>
<el-button type="text" @click="copy(scope.scope)" class="tableBtn" size="small">复制</el-button> <el-button type="text" @click="copy(scope.scope)" class="tableBtn" size="small">复制</el-button>
</span> </span>
...@@ -214,7 +215,7 @@ export default { ...@@ -214,7 +215,7 @@ export default {
id: 'firstImg', id: 'firstImg',
imgSrc: require('./images/card0.png'), imgSrc: require('./images/card0.png'),
src: './images/card0.png' src: './images/card0.png'
}, }
], ],
rules: { rules: {
cardClassName: [ cardClassName: [
...@@ -234,8 +235,22 @@ export default { ...@@ -234,8 +235,22 @@ export default {
// getListApi: none, // getListApi: none,
searchForm: { searchForm: {
merchantName: '', merchantName: '',
cardClassName:'' cardClassName: ''
}, },
searchFormData: [
{
label: '搜索门店',
name: 'merchantName',
type: 'input',
isClear: true
},
{
label: '权益卡名称',
name: 'cardClassName',
type: 'input',
isClear: true
}
],
tableParams: { tableParams: {
btnId: new Date().getTime() + parseInt(Math.random() * 1000), btnId: new Date().getTime() + parseInt(Math.random() * 1000),
listName: 'list', listName: 'list',
...@@ -330,8 +345,8 @@ export default { ...@@ -330,8 +345,8 @@ export default {
} }
}, },
methods: { methods: {
handleDetail(row){ handleDetail(row) {
this.$refs.detailDetailRef.show(row); this.$refs.detailDetailRef.show(row)
// this.getcardRecordList() // this.getcardRecordList()
}, },
setTableFinishFun() { setTableFinishFun() {
...@@ -471,7 +486,7 @@ export default { ...@@ -471,7 +486,7 @@ export default {
if (row.tryAble == 1) { if (row.tryAble == 1) {
;(this.value = true), (this.tryNum = row.tryNum) ;(this.value = true), (this.tryNum = row.tryNum)
} else { } else {
;(this.value = false), (this.tryNum =30) ;(this.value = false), (this.tryNum = 30)
} }
}, },
addCard(cd) { addCard(cd) {
...@@ -609,7 +624,7 @@ export default { ...@@ -609,7 +624,7 @@ export default {
margin: 0; margin: 0;
border: 0; border: 0;
} }
.card-manage .el-table__empty-text{ .card-manage .el-table__empty-text {
display: inline-block; display: inline-block;
width: 64px; width: 64px;
height: 41px; height: 41px;
...@@ -762,4 +777,3 @@ export default { ...@@ -762,4 +777,3 @@ export default {
margin-right: 20px; margin-right: 20px;
} }
</style> </style>
\ No newline at end of file \ No newline at end of file
<template> <template>
<div class="equity-wrap"> <div class="equity-wrap">
<div class="equity-wrap contain"> <div class="equity-wrap contain">
<el-form :inline="true" style="width: 100%" :model="searchForm" label-width="85px" label-position="right"> <!-- <el-form :inline="true" style="width: 100%" :model="searchForm" label-width="85px" label-position="right">
<el-row style="display: flex; align-items: center;margin-bottom:2px"> <el-row style="display: flex; align-items: center;margin-bottom:2px">
<el-form-item label="售后编号" size="small"> <el-form-item label="售后编号" size="small">
<el-input v-model="searchForm.refundCode" placeholder="请输入" size="small" clearable></el-input> <el-input v-model="searchForm.refundCode" placeholder="请输入" size="small" clearable></el-input>
...@@ -28,14 +28,14 @@ ...@@ -28,14 +28,14 @@
<el-button size="small" type="primary" @click="handleSearch">查询</el-button> <el-button size="small" type="primary" @click="handleSearch">查询</el-button>
</el-form-item> </el-form-item>
</el-row> </el-row>
</el-form> </el-form> -->
<GLCombiForm ref="showSearch" :formObj="searchForm" :formData="searchFormData" @handleOk="handleSearch" @handleRest="handleReset"></GLCombiForm>
<div class="choseRow"> <div class="choseRow">
<div class="choseItem" :class="{ active: currentIndex == index }" v-for="(item, index) in choseList" :key="index" @click="tabClick(index)"> <div class="choseItem" :class="{ active: currentIndex == index }" v-for="(item, index) in choseList" :key="index" @click="tabClick(index)">
{{ item }} {{ item }}
</div> </div>
</div> </div>
<!-- :noDataImg="url" --> <!-- :noDataImg="url" -->
<GLTable v-if="flag" :noDataImg="url" ref="table" @setTableFinishFun="setTableFinishFun" :searchForm="searchFormTable" :tableParams="tableParams" :getListApi="tableParams.getListApi" :hasNum="false" :pageConf="pageConf" :beforeSearchFn="beforeSearchFn"> <GLTable v-if="flag" :noDataImg="url" ref="table" @setTableFinishFun="setTableFinishFun" :searchForm="searchFormTable" :tableParams="tableParams" :getListApi="tableParams.getListApi" :hasNum="false" :pageConf="pageConf" :beforeSearchFn="beforeSearchFn">
<span slot="desc" slot-scope="scope"> <span slot="desc" slot-scope="scope">
...@@ -86,13 +86,13 @@ ...@@ -86,13 +86,13 @@
<script> <script>
// type='text/ecmascript-6' // type='text/ecmascript-6'
// import { orderMixin, searchMixin } from '@/mixins' // import { orderMixin, searchMixin } from '@/mixins'
import url from "@/assets/empty.png" import url from '@/assets/empty.png'
export default { export default {
name: '', name: '',
// mixins: [orderMixin, searchMixin], // mixins: [orderMixin, searchMixin],
data() { data() {
return { return {
url:url, url: url,
choseList: ['全部', '售后中', '售后完成'], choseList: ['全部', '售后中', '售后完成'],
currentIndex: 0, currentIndex: 0,
size: 'small', size: 'small',
...@@ -104,7 +104,59 @@ export default { ...@@ -104,7 +104,59 @@ export default {
pageConf: { pageSize: 'pageSize', pageNum: 'pageNum', totalCount: 'total' }, pageConf: { pageSize: 'pageSize', pageNum: 'pageNum', totalCount: 'total' },
flag: true, flag: true,
tabIndex: '', tabIndex: '',
searchForm: {}, // searchForm: {},
searchForm: {
orderCode: '',
refundCode: '',
productName: '',
merchantName: '',
userInfo: '',
daterange: ''
},
searchFormData: [
{
label: '售后编号',
name: 'refundCode',
type: 'input',
isClear: true
},
{
label: '订单编号',
name: 'orderCode',
type: 'input',
isClear: true
},
{
label: '商品名称',
name: 'productName',
type: 'input',
isClear: true
},
{
label: '门店名称',
name: 'merchantName',
type: 'input',
isClear: true
},
{
label: '用户信息',
name: 'userInfo',
type: 'input',
isClear: true
},
{
label: '下单时间',
name: 'daterange',
type: 'datePicker',
valueFormat: 'yyyy-MM-dd',
isClear: true,
customPickerOptions: {
disabledDate(time) {
return time.getTime() > Date.now() || time.getTime() < new Date('2017-12-31').getTime()
}
}
}
],
searchFormTable: {}, searchFormTable: {},
tableParams: { tableParams: {
listName: 'list', listName: 'list',
...@@ -181,24 +233,23 @@ export default { ...@@ -181,24 +233,23 @@ export default {
}, },
mounted() {}, mounted() {},
methods: { methods: {
getHttpsImgUrl(url){ getHttpsImgUrl(url) {
if (!url) {
if(!url){
return '' return ''
} }
var flag=url.startsWith("http:") var flag = url.startsWith('http:')
// console.log(flag,'快快快') // console.log(flag,'快快快')
if(flag){ if (flag) {
var newurl= url.replace("http:","https:") var newurl = url.replace('http:', 'https:')
//去掉http自动带的端口 :7060,https不能有 //去掉http自动带的端口 :7060,https不能有
var startPos=newurl.lastIndexOf(":") var startPos = newurl.lastIndexOf(':')
var endPos=newurl.indexOf("/",startPos) var endPos = newurl.indexOf('/', startPos)
var preStr=newurl.substring(0,startPos) var preStr = newurl.substring(0, startPos)
var afterStr=newurl.substring(endPos) var afterStr = newurl.substring(endPos)
// console.log(preStr,'前部分') // console.log(preStr,'前部分')
// console.log(afterStr,'后部分') // console.log(afterStr,'后部分')
var finalStr=preStr+afterStr var finalStr = preStr + afterStr
// console.log(finalStr,'6777777') // console.log(finalStr,'6777777')
return finalStr return finalStr
} }
...@@ -338,7 +389,7 @@ export default { ...@@ -338,7 +389,7 @@ export default {
.el-range-editor--small.el-input__inner { .el-range-editor--small.el-input__inner {
width: 215px; width: 215px;
} }
/deep/ .contain .el-input--small .el-input__inner { // /deep/ .contain .el-input--small .el-input__inner {
width: 215px; // width: 215px;
} // }
</style> </style>
Markdown is supported
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!