Commit 4d8fe9d3 by 张权

表单完成

1 parent fb2e84a9
......@@ -6,7 +6,7 @@
<el-tabs v-model="activeName" type="card" @tab-click="handleClick">
<el-tab-pane label="批次管理" name="first" class="contain" style="margin: 0" id="batch">
<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-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>
......@@ -24,7 +24,14 @@
<el-button type="primary" size="small" @click="selectCollectionTable('select')" class="selectBtn">搜索</el-button>
</el-form-item>
</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">
<span slot="auth-button" slot-scope="scope" :data="scope.scope">
<!-- 批次管理详情弹窗按钮 -->
......@@ -119,7 +126,7 @@
</el-tab-pane>
<!--领用记录 -->
<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-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>
......@@ -143,7 +150,15 @@
<el-button class="selectBtn" type="primary" size="small" @click="exportCollection">导出</el-button>
</el-form-item>
</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>
</el-tab-pane>
</el-tabs>
......@@ -205,11 +220,33 @@ export default {
// 批次列表搜索项
selectBatchId: '' || null,
batchListSearch: {
selectBatchId: '',
batchDate: '',
batchNo: '',
merchantName: '',
startTime: '',
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,
activeName: 'first',
//批次管理table
......@@ -220,22 +257,23 @@ export default {
tableColumns: [
{
label: '批次',
prop: 'batchNo'
prop: 'batchNo',
width: '150'
},
{
label: '门店',
prop: 'merchantName'
},
{
label: '生成数量',
prop: 'num'
// width: 110,
prop: 'num',
width: '120'
// tagLabel: true
},
{
label: '激活数量',
prop: 'recipientCount',
width: '150',
// minWidth: '200'
formatter: cellValue => {
if (cellValue.recipientCount) {
......@@ -246,7 +284,7 @@ export default {
}
},
{
width: '95',
width: '180',
label: '生成时间',
prop: 'createdDate',
formatter: cellValue => {
......@@ -280,7 +318,6 @@ export default {
{
label: '卡号',
prop: 'cardNo'
// minWidth: '200'
},
{
label: '激活码',
......@@ -320,8 +357,33 @@ export default {
sn: '',
startTime: '',
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: {
btnId: new Date().getTime() + parseInt(Math.random() * 1000),
......@@ -330,11 +392,12 @@ export default {
{
label: '卡号',
prop: 'cardNo',
minWidth: '200'
width: '160'
},
{
label: '激活码',
prop: 'activationCode'
prop: 'activationCode',
width: '160'
},
{
label: '设备SN',
......@@ -343,7 +406,7 @@ export default {
{
label: '账号',
prop: 'mobile',
minWidth: '200',
minWidth: '160',
formatter: cellValue => {
if (cellValue.mobile == 0) {
return ''
......@@ -367,19 +430,17 @@ export default {
}
},
{
width: '95',
label: '生成时间',
prop: 'createdDate',
minWidth: '200',
width: '180',
formatter: cellValue => {
return this.date_format(cellValue.createdDate)
}
},
{
width: '95',
width: '180',
label: '有效时间',
prop: 'validitDate',
minWidth: '200',
formatter: cellValue => {
return this.date_format(cellValue.validitDate)
}
......@@ -458,8 +519,8 @@ export default {
// 批次界面搜索
selectCollectionTable(e) {
if (e == 'reset') {
this.batchDate = ''
this.selectBatchId = ''
this.batchListSearch.batchDate = ''
this.batchListSearch.selectBatchId = ''
this.batchListSearch.merchantName = ''
this.$apis.equityApi.getEquityCardBatchList(this.batchListSearch).then(res => {
this.$refs.batchDetailTable.refreshTable()
......@@ -636,10 +697,10 @@ export default {
// 改变批次日期数据格式
changeBatchDataFormat() {
return new Promise((resolve, reject) => {
this.batchListSearch.endTime = this.batchDate ? this.batchDate[1] + ' 23:59:59' : ''
this.batchListSearch.startTime = this.batchDate ? this.batchDate[0] + ' 00:00:01' : ''
if (this.selectBatchId) {
this.batchListSearch.batchNo = +this.selectBatchId
this.batchListSearch.endTime = this.batchListSearch.batchDate ? this.batchListSearch.batchDate[1] + ' 23:59:59' : ''
this.batchListSearch.startTime = this.batchListSearch.batchDate ? this.batchListSearch.batchDate[0] + ' 00:00:01' : ''
if (this.batchListSearch.selectBatchId) {
this.batchListSearch.batchNo = +this.batchListSearch.selectBatchId
} else {
this.batchListSearch.batchNo = null
}
......@@ -651,8 +712,8 @@ export default {
return new Promise((resolve, reject) => {
if (this.collectionListSearch.sn.length > 2 || this.collectionListSearch.sn.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.startTime = this.colletionDate ? this.colletionDate[0] + ' 00:00:01' : '' || undefined
this.collectionListSearch.endTime = this.collectionListSearch.colletionDate ? this.collectionListSearch.colletionDate[1] + ' 23:59:59' : '' || undefined
this.collectionListSearch.startTime = this.collectionListSearch.colletionDate ? this.collectionListSearch.colletionDate[0] + ' 00:00:01' : '' || undefined
resolve()
} else {
Message({
......
<template>
<div class="equity-wrap">
<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-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>
......@@ -24,8 +24,9 @@
<el-button :size="size" type="primary" @click="handleSearch">查询</el-button>
</el-form-item>
</el-row>
</el-form>
<GLTable v-if="flag" ref="table" :noDataImg="url" @setTableFinishFun="setTableFinishFun" :searchForm="searchFormTable" :tableParams="tableParams" :getListApi="tableParams.getListApi" :hasNum="false" :pageConf="pageConf" :beforeSearchFn="beforeSearchFn"></GLTable>
</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>
</div>
</div>
</template>
......@@ -42,22 +43,73 @@ function date_format(date) {
var ss = date2.getSeconds() < 10 ? '0' + date2.getSeconds() : date2.getSeconds()
return YY + MM + DD + ' ' + hh + mm + ss
}
import url from "@/assets/empty.png"
import url from '@/assets/empty.png'
// import { searchMixin } from '@/mixins'
export default {
name: '',
// mixins: [searchMixin],
data() {
return {
url:url,
url: url,
size: 'small',
pickerOptions: {
disabledDate(time) {
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: {
orderId: ''
orderId: '',
phone: '',
daterange: '',
orderStatus: ''
},
searchFormTable: {},
pageConf: { pageSize: 'pageSize', pageNum: 'pageNum', totalCount: 'total' },
......@@ -151,7 +203,7 @@ export default {
},
setTableFinishFun() {
//接收到的数据为空
if (!this.$refs.table.data.length) {
if (!this.$refs?.table?.data?.length) {
this.$refs.table.setTableHeightFun()
}
},
......@@ -169,20 +221,6 @@ export default {
}
</script>
<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 {
margin-top: 20px;
}
......
......@@ -8,8 +8,8 @@
<div class="balanceWrap">
<span>账户余额</span>
<div>
<span>{{ price }}</span>
<span>{{ price }}</span>
<span class="yuan">元</span>
</div>
</div>
......@@ -21,7 +21,7 @@
<el-button icon="el-icon-refresh" class="refreshBtn"></el-button>
</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-form-item size="small" label="品牌名称">
<el-select size="small" v-model="searchForm.brandName" placeholder="请选择">
......@@ -56,8 +56,9 @@
<GLButton fn="财务管理导出" :size="size" type="primary" @click="exportExcel">导出</GLButton>
</el-form-item>
</el-row>
</el-form>
<GLTable v-if="flag" ref="table" :noDataImg="url" @setTableFinishFun="setTableFinishFun" :searchForm="searchFormTable" :tableParams="tableParams" :getListApi="tableParams.getListApi" :hasNum="false" :pageConf="pageConf" :beforeSearchFn="beforeSearchFn">
</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">
<template slot="custom">
<div class="table-custom exportBtn"></div>
</template>
......@@ -66,8 +67,8 @@
</div>
</template>
<script type='text/ecmascript-6'>
import url from "@/assets/empty.png"
<script type="text/ecmascript-6">
import url from "@/assets/empty.png"
import { orderMixin, searchMixin } from '@/mixins'
export default {
name: '',
......@@ -85,7 +86,86 @@ export default {
pageConf: { pageSize: 'pageSize', pageNum: 'pageNum', totalCount: 'total' },
flag: true,
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: {},
tableParams: {
listName: 'list',
......@@ -124,7 +204,8 @@ export default {
tableColumns: [
{
label: '订单编号',
prop: 'orderCode'
prop: 'orderCode',
width:'220'
},
{
label: '品牌名称',
......@@ -132,6 +213,7 @@ export default {
},
{
label: '商品形态',
width: '100',
prop: 'appearanceDesc'
},
{
......@@ -155,6 +237,8 @@ export default {
},
{
label: '下单渠道',
width:'250',
line: 1,
formatter(cell) {
return `${cell.merchantName || ''}${cell.merchantName ? '-' : ''}${cell.channelName}`
}
......@@ -169,7 +253,7 @@ export default {
{
label: '下单时间',
prop: 'orderDate',
width: 95,
width: '180',
formatter(cell) {
return cell.orderDate ? new Date(cell.orderDate).format('yyyy-MM-dd hh:mm:ss') : '- -'
}
......@@ -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() {
this.getHwAccount()
},
......@@ -255,22 +345,21 @@ export default {
// <style src="@a/css/tao.css"></style>
</script>
<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;
}
// .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 {
.topContent {
display: flex;
......
<template>
<div class="equity-wrap">
<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-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-form-item>
<el-form-item size="small" label="加油供应商">
<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-select>
</el-form-item>
......@@ -31,13 +30,14 @@
<el-button :size="size" type="primary" @click="handleExport">导出</el-button>
</el-form-item>
</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>
</div>
</div>
</template>
<script type='text/ecmascript-6'>
<script type="text/ecmascript-6">
function getExplorer() {
var ua = navigator.userAgent.toLocaleLowerCase()
var browserType = null
......@@ -92,7 +92,77 @@ export default {
},
pageConf: { pageSize: 'pageSize', pageNum: 'pageNum', totalCount: 'total' },
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: {},
statusList: [
{
......@@ -145,7 +215,7 @@ export default {
{
label: '加油升数(L)',
prop: 'litre',
width: '100'
width: '150'
},
{
label: '实付金额',
......@@ -234,20 +304,20 @@ export default {
</script>
<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;
}
// .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 {
margin-top: 20px;
}
......
......@@ -2,7 +2,7 @@
<div class="equity-wrap">
<GLButton fn="新增商品" class="addGood" type="primary" icon="el-icon-plus" @click="jump">新增商品</GLButton>
<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-form-item size="small" label="品牌名称">
<el-select size="small" v-model="searchForm.brandName" filterable placeholder="请选择">
......@@ -12,9 +12,6 @@
<el-form-item size="small" label="商品名称">
<el-input v-model="searchForm.productName" placeholder="请输入" size="small" clearable></el-input>
</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-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>
......@@ -38,7 +35,8 @@
<el-button :size="size" type="primary" @click="handleSearch">查询</el-button>
</el-form-item>
</el-row>
</el-form>
</el-form> -->
<GLCombiForm ref="showSearch" :formObj="searchForm" :formData="searchFormData" @handleOk="handleSearch" @handleRest="handleReset"></GLCombiForm>
<div class="row-btns">
<el-button size="small" @click="toggleAll">全选</el-button>
<GLButton fn="上架商品" size="small" type="primary" @click="batchOperation(1)">上架</GLButton>
......@@ -56,7 +54,7 @@
</div>
</template>
<script type='text/ecmascript-6'>
<script type="text/ecmascript-6">
import url from '@/assets/empty.png'
import { searchMixin } from '@/mixins'
export default {
......@@ -68,8 +66,83 @@ export default {
size: 'small',
pageConf: { pageSize: 'pageSize', pageNum: 'pageNum', totalCount: 'total' },
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: [
{
label: '海威',
......@@ -156,7 +229,9 @@ export default {
methods: {
getAllBrandList() {
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) {
......@@ -291,11 +366,8 @@ export default {
padding: 8px 16px;
// margin-bottom: 20px;
}
/deep/ .contain .el-input--small .el-input__inner {
width: 215px;
}
.row-btns {
margin-top: 5px;
margin-bottom: 10px;
}
</style>
\ No newline at end of file
</style>
<template>
<div class="equity-wrap">
<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-form-item size="small" label="订单编号">
<el-input size="small" v-model="searchForm.orderCode" placeholder="请输入"></el-input>
......@@ -31,7 +31,9 @@
<el-button :size="size" type="primary" @click="handleExport">导出</el-button>
</el-form-item>
</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="choseItem" :class="{ active: currentIndex == index }" v-for="(item, index) in choseList" :key="index" @click="tabClick(index)">
{{ item }}
......@@ -64,7 +66,7 @@
</div>
</template>
<script type='text/ecmascript-6'>
<script type="text/ecmascript-6">
import url from '@/assets/empty.png'
import { orderMixin, searchMixin } from '@/mixins'
export default {
......@@ -84,7 +86,61 @@ export default {
tabIndex: '',
flag: true,
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: {},
tableParams: {
listName: 'list',
......@@ -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() {},
methods: {
handleExport() {
......@@ -280,8 +342,7 @@ export default {
// <style src="@a/css/tao.css"></style>
</script>
<style lang="scss" scoped>
<style lang="scss" scoped>
.equity-wrap .contain {
margin-top: 20px;
.choseRow {
......@@ -304,20 +365,20 @@ export default {
}
}
}
.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;
}
// .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;
// }
// .el-tabs__nav-wrap:after {
// display: none;
......@@ -361,4 +422,4 @@ export default {
// font-size: 14px;
// margin: 0 68px 30px 0;
// }
</style>
\ No newline at end of file
</style>
<template>
<div>
<!-- 领卡用户明细 -->
<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">
<glsx-combi-form ref="showSearch" labelWidth="120px" defaultWidth="215px" :formObj="batchListSearch" :formData="userDetailForm">
<span slot="footer" class="footer-btns">
</span>
</glsx-combi-form>
<div style="padding:0 20px 20px">
<div style="float: right; margin-right: 0;margin-bottom:10px;">
<el-button size="small" @click="handleReset('reset')">重置</el-button>
<el-button size="small" type="primary" @click="handleSearch">查询</el-button>
<el-button type="primary" size="small" @click="handleExport" class="selectBtn">导出</el-button>
</div>
<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">
<p :style="{color:scope.scope.status==1 ? '#2CCA74': '#CCC'}">{{ setStatusVal(scope.scope.status) }}</p>
</div>
</GLTable>
<div>
<!-- 领卡用户明细 -->
<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">
<glsx-combi-form ref="showSearch" labelWidth="120px" defaultWidth="215px" :formObj="batchListSearch" :formData="userDetailForm">
<!-- <GLCombiForm ref="showSearch" :formObj="batchListSearch" :formData="userDetailForm" @handleOk="handleSearch" @handleRest="handleReset('reset')"></GLCombiForm> -->
<span slot="footer" class="footer-btns"></span>
</glsx-combi-form>
<div style="padding:0 20px 20px">
<div style="float: right; margin-right: 0;margin-bottom:10px;">
<el-button size="small" @click="handleReset('reset')">重置</el-button>
<el-button size="small" type="primary" @click="handleSearch">查询</el-button>
<el-button type="primary" size="small" @click="handleExport" class="selectBtn">导出</el-button>
</div>
<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">
<p :style="{ color: scope.scope.status == 1 ? '#2CCA74' : '#CCC' }">{{ setStatusVal(scope.scope.status) }}</p>
</div>
</GLTable>
</div>
</el-dialog>
</div>
</div>
</el-dialog>
</div>
</template>
<script type='text/ecmascript-6'>
<script type="text/ecmascript-6">
import url from '@/assets/empty.png'
const activeTypeList = [
{
......@@ -54,7 +54,7 @@ const activeTypeList = [
{
confId: 5,
confName: '绑定挪车贴'
},
},
{
confId: 6,
confName: '付费开通'
......@@ -129,7 +129,7 @@ export default {
{
confId: 5,
confName: '挪车贴绑定激活'
},
},
{
confId: 6,
confName: '购买权益卡激活'
......@@ -152,7 +152,7 @@ export default {
},
],
},
userDetailForm:[
{
label: '用户信息',
......@@ -345,10 +345,10 @@ export default {
handleReset(type){
this.batchListSearch = {
mobile:'',
merchantName:'',
activeType:'',
status:'',
activeTime: [],
merchantName:'',
activeType:'',
status:'',
activeTime: [],
memberType:''
}
if(type==='reset'){
......@@ -359,17 +359,17 @@ export default {
}
</script>
<style lang="scss" scoped>
/deep/ .user-detail-dialog{
.el-form-item{
/deep/ .user-detail-dialog {
.el-form-item {
margin-right: 0;
}
.el-input--small .el-input__inner{
.el-input--small .el-input__inner {
width: 215px;
}
.el-table__row{
.el-table__cell{
.el-table__row {
.el-table__cell {
padding: 9px 0;
}
}
}
</style>
\ No newline at end of file
</style>
......@@ -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-option v-for="(item, index) in options" :key="index" :label="item.merchantName" :value="item.merchantName"></el-option>
</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-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-select>
</el-form-item>
......@@ -28,19 +28,20 @@
<el-button type="primary" size="small" style="margin-left: 20px" class="selectBtn" @click="selectStore('select')">搜索</el-button>
</el-form-item>
</el-row>
</el-form>
</el-form> -->
<!-- <div class="operationBtn">
<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>
</div> -->
</div>
<GLCombiForm ref="showSearch" :rowNumber="1" :formObj="searchForm" :formData="searchFormData" @handleOk="selectStore('select')" @handleRest="selectStore('reset')"></GLCombiForm>
<div class="tableCtn">
<GLTable ref="recordTable" :searchForm="searchForm" :tableParams="tableParams" :getListApi="getListApi" :pageConf="pageConf" :noDataImg="url" @setTableFinishFun="setTableFinishFun">
<div slot="recipientCount" slot-scope="scope">
<p class="cursor-pointer" style="color:#5850ff" @click="handleDetail(scope.scope)">{{ scope.scope.recipientCount }}</p>
</div>
<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" @click="copy(scope.scope)" class="tableBtn" size="small">复制</el-button>
</span>
......@@ -94,9 +95,9 @@
<el-radio-group v-model="ruleForm.effectiveType">
<el-radio label="1" @change="e => controlSwitch(e, 'disable')">永久有效</el-radio>
<el-radio label="2" @change="e => controlSwitch(e, 'input')">
<span style="margin-right:10px">领取时起</span>
<span style="margin-right:10px">领取时起</span>
<el-input-number v-model="effectiveNum" controls-position="right" :min="1" :max="999" id="month" :disabled="ruleForm.effectiveType !== '2'" size="mini" change=""></el-input-number>
<span style="margin-left:10px">天内有效</span>
<span style="margin-left:10px">天内有效</span>
</el-radio>
</el-radio-group>
</el-form-item>
......@@ -214,7 +215,7 @@ export default {
id: 'firstImg',
imgSrc: require('./images/card0.png'),
src: './images/card0.png'
},
}
],
rules: {
cardClassName: [
......@@ -234,8 +235,22 @@ export default {
// getListApi: none,
searchForm: {
merchantName: '',
cardClassName:''
cardClassName: ''
},
searchFormData: [
{
label: '搜索门店',
name: 'merchantName',
type: 'input',
isClear: true
},
{
label: '权益卡名称',
name: 'cardClassName',
type: 'input',
isClear: true
}
],
tableParams: {
btnId: new Date().getTime() + parseInt(Math.random() * 1000),
listName: 'list',
......@@ -330,8 +345,8 @@ export default {
}
},
methods: {
handleDetail(row){
this.$refs.detailDetailRef.show(row);
handleDetail(row) {
this.$refs.detailDetailRef.show(row)
// this.getcardRecordList()
},
setTableFinishFun() {
......@@ -471,7 +486,7 @@ export default {
if (row.tryAble == 1) {
;(this.value = true), (this.tryNum = row.tryNum)
} else {
;(this.value = false), (this.tryNum =30)
;(this.value = false), (this.tryNum = 30)
}
},
addCard(cd) {
......@@ -609,7 +624,7 @@ export default {
margin: 0;
border: 0;
}
.card-manage .el-table__empty-text{
.card-manage .el-table__empty-text {
display: inline-block;
width: 64px;
height: 41px;
......@@ -756,10 +771,9 @@ export default {
border-top: 1px solid #e6e6e6;
}
.addCardsDialog .el-radio {
color: #606266;
font-weight: 500;
cursor: pointer;
margin-right: 20px;
color: #606266;
font-weight: 500;
cursor: pointer;
margin-right: 20px;
}
</style>
\ No newline at end of file
<template>
<div class="equity-wrap">
<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-form-item label="售后编号" size="small">
<el-input v-model="searchForm.refundCode" placeholder="请输入" size="small" clearable></el-input>
......@@ -28,21 +28,21 @@
<el-button size="small" type="primary" @click="handleSearch">查询</el-button>
</el-form-item>
</el-row>
</el-form>
</el-form> -->
<GLCombiForm ref="showSearch" :formObj="searchForm" :formData="searchFormData" @handleOk="handleSearch" @handleRest="handleReset"></GLCombiForm>
<div class="choseRow">
<div class="choseItem" :class="{ active: currentIndex == index }" v-for="(item, index) in choseList" :key="index" @click="tabClick(index)">
{{ item }}
</div>
</div>
<!-- :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">
<div class="refund-box">
<div class="refund-img-box">
<!-- getHttpsImgUrl(scope.scope.img) -->
<img :src="scope.scope.img" alt="" />
<img :src="scope.scope.img" alt="" />
</div>
<div>{{ scope.scope.reason }}</div>
</div>
......@@ -74,7 +74,7 @@
<div class="refund-title">{{ scope.scope.orderCode }}</div>
</div>
</span>
<span slot="stores" slot-scope="scope">
<span slot="stores" slot-scope="scope">
<div class="refund-box">
<div class="refund-title">{{ scope.scope.merchantName }}</div>
</div>
......@@ -86,13 +86,13 @@
<script>
// type='text/ecmascript-6'
// import { orderMixin, searchMixin } from '@/mixins'
import url from "@/assets/empty.png"
import url from '@/assets/empty.png'
export default {
name: '',
// mixins: [orderMixin, searchMixin],
data() {
return {
url:url,
url: url,
choseList: ['全部', '售后中', '售后完成'],
currentIndex: 0,
size: 'small',
......@@ -104,7 +104,59 @@ export default {
pageConf: { pageSize: 'pageSize', pageNum: 'pageNum', totalCount: 'total' },
flag: true,
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: {},
tableParams: {
listName: 'list',
......@@ -181,28 +233,27 @@ export default {
},
mounted() {},
methods: {
getHttpsImgUrl(url){
if(!url){
getHttpsImgUrl(url) {
if (!url) {
return ''
}
var flag=url.startsWith("http:")
var flag = url.startsWith('http:')
// console.log(flag,'快快快')
if(flag){
var newurl= url.replace("http:","https:")
//去掉http自动带的端口 :7060,https不能有
var startPos=newurl.lastIndexOf(":")
var endPos=newurl.indexOf("/",startPos)
var preStr=newurl.substring(0,startPos)
var afterStr=newurl.substring(endPos)
// console.log(preStr,'前部分')
// console.log(afterStr,'后部分')
var finalStr=preStr+afterStr
// console.log(finalStr,'6777777')
return finalStr
}
return url
if (flag) {
var newurl = url.replace('http:', 'https:')
//去掉http自动带的端口 :7060,https不能有
var startPos = newurl.lastIndexOf(':')
var endPos = newurl.indexOf('/', startPos)
var preStr = newurl.substring(0, startPos)
var afterStr = newurl.substring(endPos)
// console.log(preStr,'前部分')
// console.log(afterStr,'后部分')
var finalStr = preStr + afterStr
// console.log(finalStr,'6777777')
return finalStr
}
return url
},
tabClick(index) {
this.currentIndex = index
......@@ -338,7 +389,7 @@ export default {
.el-range-editor--small.el-input__inner {
width: 215px;
}
/deep/ .contain .el-input--small .el-input__inner {
width: 215px;
}
// /deep/ .contain .el-input--small .el-input__inner {
// width: 215px;
// }
</style>
Markdown is supported
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!