Commit 8e23600b by 李长胜

提交表格重置不良效果

1 parent caf0d47c
...@@ -75,7 +75,7 @@ ...@@ -75,7 +75,7 @@
</el-form-item> </el-form-item>
</el-row> </el-row>
</el-form> </el-form>
<GLTable ref="memberCenterRef" :searchForm="searchFormTable" :tableParams="tableParams" :getListApi="getListApi" :pageConf="pageConf" :beforeSearchFn="beforeSearchFn"> <GLTable v-if="isReload" ref="memberCenterRef" @setTableFinishFun="setTableFinishFun" :searchForm="searchFormTable" :tableParams="tableParams" :getListApi="getListApi" :pageConf="pageConf" :beforeSearchFn="beforeSearchFn">
<span slot="accountName" slot-scope="scope"> <span slot="accountName" slot-scope="scope">
<div>{{ scope.scope.accountName }}</div> <div>{{ scope.scope.accountName }}</div>
<div>{{ scope.scope.mobile }}</div> <div>{{ scope.scope.mobile }}</div>
...@@ -135,6 +135,7 @@ export default { ...@@ -135,6 +135,7 @@ export default {
// }, 1000) // }, 1000)
} }
return { return {
isReload: true,
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()
...@@ -190,12 +191,11 @@ export default { ...@@ -190,12 +191,11 @@ export default {
}, },
{ {
label: '开通方式', label: '开通方式',
prop: 'activeTypeDesc', prop: 'activeTypeDesc'
}, },
{ {
label: '开通日期', label: '开通日期',
prop: 'activeTime', prop: 'activeTime'
// addHtml: 'activeTime' // addHtml: 'activeTime'
}, },
...@@ -286,7 +286,6 @@ export default { ...@@ -286,7 +286,6 @@ export default {
this.ruleForm.price = res[0].price this.ruleForm.price = res[0].price
this.ruleForm.marketPrice = res[0].marketPrice this.ruleForm.marketPrice = res[0].marketPrice
this.ruleForm.linkUrl = res[0].url this.ruleForm.linkUrl = res[0].url
}) })
}, },
openEditWrap() { openEditWrap() {
...@@ -333,16 +332,21 @@ export default { ...@@ -333,16 +332,21 @@ export default {
}) })
}, },
handleReset() { handleReset() {
// this.searchForm = { this.isReload = false
// name: '',
// status: '-1'
// }
this.searchForm = {} this.searchForm = {}
this.handleSearch() this.$nextTick(() => {
this.isReload = true
})
}, },
handleSearch() { handleSearch() {
this.$refs.memberCenterRef.refreshTable() this.$refs.memberCenterRef.refreshTable()
}, },
setTableFinishFun() {
//接收到的数据为空
if (!this.$refs.memberCenterRef.data.length) {
this.$refs.memberCenterRef.setTableHeightFun()
}
},
handleClose() { handleClose() {
this.isDialogVisible = !this.isDialogVisible this.isDialogVisible = !this.isDialogVisible
}, },
...@@ -439,7 +443,7 @@ export default { ...@@ -439,7 +443,7 @@ export default {
} }
.editForm { .editForm {
padding-top: 0px; padding-top: 0px;
.cardNameInput{ .cardNameInput {
width: 423px; width: 423px;
} }
} }
......
...@@ -2,15 +2,15 @@ ...@@ -2,15 +2,15 @@
<div class="live-room"> <div class="live-room">
<div class="live-room container"> <div class="live-room container">
<div class="flex"> <div class="flex">
<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> <el-row>
<el-form-item size="small" label="订单编号"> <el-form-item size="small" label="订单编号">
<el-input :size="size" v-model="searchForm.orderCode" placeholder="请输入订单编号" clearable></el-input> <el-input :size="size" v-model="searchForm.orderCode" placeholder="请输入订单编号" clearable></el-input>
</el-form-item> </el-form-item>
<el-form-item size="small" label="名称" style="margin-left:20px"> <el-form-item size="small" label="名称" style="margin-left: 20px">
<el-input :size="size" v-model="searchForm.packageName" placeholder="请输入名称" clearable></el-input> <el-input :size="size" v-model="searchForm.packageName" placeholder="请输入名称" clearable></el-input>
</el-form-item> </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.orderType" placeholder="请选择"> <el-select size="small" v-model="searchForm.orderType" placeholder="请选择">
<el-option v-for="item in orderTypeList" :key="item.dictValue" :label="item.dictLabel" :value="item.dictValue"></el-option> <el-option v-for="item in orderTypeList" :key="item.dictValue" :label="item.dictLabel" :value="item.dictValue"></el-option>
</el-select> </el-select>
...@@ -24,7 +24,7 @@ ...@@ -24,7 +24,7 @@
<el-date-picker :size="size" v-model="searchForm.daterange" type="daterange" value-format="yyyy-MM-dd" range-separator="至" start-placeholder="开始日期" end-placeholder="结束日期" :picker-options="pickerOptions || {}"></el-date-picker> <el-date-picker :size="size" v-model="searchForm.daterange" type="daterange" value-format="yyyy-MM-dd" range-separator="至" start-placeholder="开始日期" end-placeholder="结束日期" :picker-options="pickerOptions || {}"></el-date-picker>
</el-form-item> </el-form-item>
<el-form-item size="small" style="float:right"> <el-form-item size="small" style="float: right">
<el-button :size="size" type="primary" @click="handleSearch">查询</el-button> <el-button :size="size" type="primary" @click="handleSearch">查询</el-button>
<el-button :size="size" @click="handleReset">重置</el-button> <el-button :size="size" @click="handleReset">重置</el-button>
</el-form-item> </el-form-item>
...@@ -36,12 +36,12 @@ ...@@ -36,12 +36,12 @@
{{ item }} {{ item }}
</div> </div>
</div> </div>
<GLTable ref="memberOrderRef" :searchForm="searchFormTable" :tableParams="tableParams" :getListApi="getListApi" :pageConf="pageConf" :beforeSearchFn="beforeSearchFn"> <GLTable ref="memberOrderRef" v-if="isReload" @setTableFinishFun="setTableFinishFun" :searchForm="searchFormTable" :tableParams="tableParams" :getListApi="getListApi" :pageConf="pageConf" :beforeSearchFn="beforeSearchFn">
<!-- <span slot="shareImgUrl" slot-scope="scope"> <!-- <span slot="shareImgUrl" slot-scope="scope">
<img class="img-60" :src="scope.scope.shareImgUrl" /> <img class="img-60" :src="scope.scope.shareImgUrl" />
</span> --> </span> -->
<span class="table-btns" slot="auth-button" slot-scope="scope" :data="scope.scope"> <span class="table-btns" slot="auth-button" slot-scope="scope" :data="scope.scope">
<el-button type="text" @click="handleDetail(scope.scope)" v-if="scope.scope.orderType==1">详情</el-button> <el-button type="text" @click="handleDetail(scope.scope)" v-if="scope.scope.orderType == 1">详情</el-button>
</span> </span>
</GLTable> </GLTable>
</div> </div>
...@@ -54,6 +54,7 @@ import { getOrderListApi } from '@/api/modules/order' ...@@ -54,6 +54,7 @@ import { getOrderListApi } from '@/api/modules/order'
export default { export default {
data() { data() {
return { return {
isReload: true,
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()
...@@ -202,9 +203,21 @@ export default { ...@@ -202,9 +203,21 @@ export default {
handleSearch() { handleSearch() {
this.$refs.memberOrderRef.refreshTable() this.$refs.memberOrderRef.refreshTable()
}, },
setTableFinishFun() {
//接收到的数据为空
if (!this.$refs.memberOrderRef.data.length) {
this.$refs.memberOrderRef.setTableHeightFun()
}
},
handleReset() { handleReset() {
this.isReload = false
this.currentIndex = 1
this.searchForm = {} this.searchForm = {}
this.handleSearch() this.searchForm.orderStatus = '' //默认查询全部
// this.handleSearch()
this.$nextTick(() => {
this.isReload = true
})
} }
} }
} }
......
...@@ -37,7 +37,7 @@ ...@@ -37,7 +37,7 @@
</el-row> </el-row>
</el-form> </el-form>
</div> </div>
<GLTable ref="memberRecordRef" @setTableFinishFun="setTableFinishFun" :searchForm="searchFormTable" :tableParams="tableParams" :getListApi="getListApi" :pageConf="pageConf" :beforeSearchFn="beforeSearchFn"> <GLTable ref="memberRecordRef" v-if="isReload" @setTableFinishFun="setTableFinishFun" :searchForm="searchFormTable" :tableParams="tableParams" :getListApi="getListApi" :pageConf="pageConf" :beforeSearchFn="beforeSearchFn">
<span slot="verificationTime" slot-scope="scope"> <span slot="verificationTime" slot-scope="scope">
<span>{{ dateFormatFun(scope.scope.verificationTime) }}</span> <span>{{ dateFormatFun(scope.scope.verificationTime) }}</span>
</span> </span>
...@@ -53,6 +53,7 @@ export default { ...@@ -53,6 +53,7 @@ export default {
name: 'record', name: 'record',
data() { data() {
return { return {
isReload:true,
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()
...@@ -68,7 +69,7 @@ export default { ...@@ -68,7 +69,7 @@ export default {
userReq: '', userReq: '',
verificationOperator: '', verificationOperator: '',
orderCode: '', orderCode: '',
merchantId: 44184606 merchantId: 0
}, },
// 44187877 // 44187877
searchFormTable: {}, searchFormTable: {},
...@@ -115,10 +116,18 @@ export default { ...@@ -115,10 +116,18 @@ export default {
addHtml: 'verificationTime' addHtml: 'verificationTime'
} }
] ]
} },
merchantId: 0
} }
}, },
created () {
if (window.__POWERED_BY_QIANKUN__) {
//运行在qiankun容器中
this.merchantId = this.$globalState.session.merchantId
this.searchForm.merchantId=this.merchantId
}
},
methods: { methods: {
dateFormatFun(date) { dateFormatFun(date) {
return dateFormat(date) return dateFormat(date)
...@@ -143,15 +152,7 @@ export default { ...@@ -143,15 +152,7 @@ export default {
this.$refs.memberRecordRef.setTableHeightFun() this.$refs.memberRecordRef.setTableHeightFun()
} }
}, },
// handleShare(row) {
// getLiveShareApi({ id: row.id }).then(res => {
// console.log(res)
// this.isShareVisible = !this.isShareVisible
// this.shareForm = res
// })
// },
handleShareClose() { handleShareClose() {
// this.handleShare()
this.isShareVisible = !this.isShareVisible this.isShareVisible = !this.isShareVisible
}, },
...@@ -186,8 +187,13 @@ export default { ...@@ -186,8 +187,13 @@ export default {
this.$refs.memberRecordRef.refreshTable() this.$refs.memberRecordRef.refreshTable()
}, },
handleReset() { handleReset() {
this.searchForm = { merchantId: 44184606 } // this.searchForm = { merchantId: 44184606 }
this.handleSearch() // this.handleSearch()
this.isReload=false
this.searchForm={ merchantId: this.merchantId }
this.$nextTick(()=>{
this.isReload=true
})
} }
} }
} }
......
...@@ -18,7 +18,7 @@ ...@@ -18,7 +18,7 @@
</el-form-item> </el-form-item>
</el-row> </el-row>
</el-form> </el-form>
<GLTable ref="memberServiceRef" @setTableFinishFun="setTableFinishFun" :searchForm="searchForm" :tableParams="tableParams" :getListApi="getListApi" :pageConf="pageConf" :beforeSearchFn="beforeSearchFn"> <GLTable v-if="isReload" ref="memberServiceRef" @setTableFinishFun="setTableFinishFun" :searchForm="searchForm" :tableParams="tableParams" :getListApi="getListApi" :pageConf="pageConf" :beforeSearchFn="beforeSearchFn">
<span slot="effectiveType" slot-scope="scope"> <span slot="effectiveType" slot-scope="scope">
<span>{{ toLabelText(scope.scope) }}</span> <span>{{ toLabelText(scope.scope) }}</span>
</span> </span>
...@@ -57,6 +57,7 @@ export default { ...@@ -57,6 +57,7 @@ export default {
}, },
data() { data() {
return { return {
isReload:true,
isFirstShow: false, isFirstShow: false,
panelContent: '会员服务:是由门店根据自店服务项目创建的线上服务券,如“一年十二次洗车券”、“陶瓷镀膜”等,客户购买后可到店出示服务券享受服务,门店扫码进行次数核销。', panelContent: '会员服务:是由门店根据自店服务项目创建的线上服务券,如“一年十二次洗车券”、“陶瓷镀膜”等,客户购买后可到店出示服务券享受服务,门店扫码进行次数核销。',
size: 'small', size: 'small',
...@@ -164,14 +165,19 @@ export default { ...@@ -164,14 +165,19 @@ export default {
}, },
handleReset() { handleReset() {
this.isReload=false
this.searchForm = { couponName: '', merchantId: this.merchantId, discountType:7 } this.searchForm = { couponName: '', merchantId: this.merchantId, discountType:7 }
this.handleSearch() // this.handleSearch()
this.$nextTick(()=>{
this.isReload=true
})
}, },
handleSearch() { handleSearch() {
this.$refs.memberServiceRef.refreshTable() this.$refs.memberServiceRef.refreshTable()
}, },
setTableFinishFun(content) { setTableFinishFun(content) {
console.log(content, this.$refs.memberServiceRef.data.length, '获取数据') // console.log(content, this.$refs.memberServiceRef.data.length, '获取数据')
//接收到的数据为空 //接收到的数据为空
if (!this.$refs.memberServiceRef.data.length) { if (!this.$refs.memberServiceRef.data.length) {
this.$refs.memberServiceRef.setTableHeightFun() this.$refs.memberServiceRef.setTableHeightFun()
......
...@@ -6,7 +6,7 @@ ...@@ -6,7 +6,7 @@
<el-button :size="size" type="primary" @click="handleCreate" icon="el-icon-plus">创建套餐</el-button> <el-button :size="size" type="primary" @click="handleCreate" icon="el-icon-plus">创建套餐</el-button>
<el-button :size="size" @click="isDialogVisible = true">查看示例效果</el-button> <el-button :size="size" @click="isDialogVisible = true">查看示例效果</el-button>
</div> </div>
<GLTable ref="memberSetMealRef" :searchForm="searchForm" :tableParams="tableParams" :getListApi="getListApi" :pageConf="pageConf" :beforeSearchFn="beforeSearchFn"> <GLTable ref="memberSetMealRef" @setTableFinishFun="setTableFinishFun" :searchForm="searchForm" :tableParams="tableParams" :getListApi="getListApi" :pageConf="pageConf" :beforeSearchFn="beforeSearchFn">
<span slot="list" slot-scope="scope"> <span slot="list" slot-scope="scope">
<div v-for="(item, index) in scope.scope.list" :key="index">{{ item.couponName }}×{{ item.serviceQuantity }}</div> <div v-for="(item, index) in scope.scope.list" :key="index">{{ item.couponName }}×{{ item.serviceQuantity }}</div>
</span> </span>
...@@ -30,17 +30,13 @@ ...@@ -30,17 +30,13 @@
<glsx-dialog title="示例效果" width="1142px" :hasScroll="false" :noBtnOk="true" :noCancel="true" :noClose="false" btnSize="small" :isVisible="isDialogVisible" :showClose="false" @closeDialog="handleClose" @confirmDialog="handleClose"> <glsx-dialog title="示例效果" width="1142px" :hasScroll="false" :noBtnOk="true" :noCancel="true" :noClose="false" btnSize="small" :isVisible="isDialogVisible" :showClose="false" @closeDialog="handleClose" @confirmDialog="handleClose">
<div class="content-body"> <div class="content-body">
<div class="content-item col1"> <div class="content-item col1">
<div class="subTitle"> <div class="subTitle">1、管理后台先创建套餐</div>
1、管理后台先创建套餐
</div>
<div class="imageWrap"> <div class="imageWrap">
<img src="@/assets/table.png" alt="" /> <img src="@/assets/table.png" alt="" />
</div> </div>
</div> </div>
<div class="content-item col2"> <div class="content-item col2">
<div class="subTitle"> <div class="subTitle">2、小程序端进行展示</div>
2、小程序端进行展示
</div>
<div class="twoImageWrap"> <div class="twoImageWrap">
<img src="@/assets/card1.png" alt="" /> <img src="@/assets/card1.png" alt="" />
<img src="@/assets/card2.png" alt="" /> <img src="@/assets/card2.png" alt="" />
...@@ -120,7 +116,7 @@ export default { ...@@ -120,7 +116,7 @@ export default {
isDialogVisible: false isDialogVisible: false
} }
}, },
created () { created() {
this.getLoginCountFun() this.getLoginCountFun()
}, },
methods: { methods: {
...@@ -143,6 +139,13 @@ export default { ...@@ -143,6 +139,13 @@ export default {
handleSearch() { handleSearch() {
this.$refs.memberSetMealRef.refreshTable() this.$refs.memberSetMealRef.refreshTable()
}, },
setTableFinishFun() {
//接收到的数据为空
if (!this.$refs.memberSetMealRef.data.length) {
this.$refs.memberSetMealRef.setTableHeightFun()
}
},
//创建套餐 //创建套餐
handleCreate() { handleCreate() {
this.$router.push('/memberCenter/setmealAddUpdate') this.$router.push('/memberCenter/setmealAddUpdate')
...@@ -223,13 +226,12 @@ export default { ...@@ -223,13 +226,12 @@ export default {
} }
/deep/ .el-dialog__header { /deep/ .el-dialog__header {
.main-title{ .main-title {
font-size: 16px; font-size: 16px;
font-weight: 700; font-weight: 700;
color: #000000; color: #000000;
} }
} }
/deep/ .el-dialog__body { /deep/ .el-dialog__body {
border-top: 1px solid #e6e6e6; border-top: 1px solid #e6e6e6;
...@@ -249,13 +251,14 @@ export default { ...@@ -249,13 +251,14 @@ export default {
font-weight: 700; font-weight: 700;
color: #000000; color: #000000;
} }
.imageWrap,.twoImageWrap{ .imageWrap,
.twoImageWrap {
margin-left: 25px; margin-left: 25px;
img{ img {
border: 1.5px solid rgba(0, 0, 0, 0.03); border: 1.5px solid rgba(0, 0, 0, 0.03);
box-shadow: 0px 10px 20px 0px rgba(0, 0, 0, 0.03); box-shadow: 0px 10px 20px 0px rgba(0, 0, 0, 0.03);
} }
img+img{ img + img {
margin-left: 22px; margin-left: 22px;
} }
} }
......
Markdown is supported
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!