|
@@ -1,16 +1,43 @@
|
|
<template>
|
|
<template>
|
|
<div class="app-container">
|
|
<div class="app-container">
|
|
|
|
+ <!-- 顶部操作区域 -->
|
|
|
|
+ <div class="filter-container">
|
|
|
|
+ <div class="filter-control">
|
|
|
|
+ <span>手机号:</span>
|
|
|
|
+ <el-input
|
|
|
|
+ style="width: 200px"
|
|
|
|
+ v-model="listQuery.mobile"
|
|
|
|
+ placeholder="手机号"
|
|
|
|
+ clearable
|
|
|
|
+ maxlength="11"
|
|
|
|
+ @keyup.enter.native="getList"
|
|
|
|
+ @clear="getList"
|
|
|
|
+ />
|
|
|
|
+ </div>
|
|
|
|
+ <div class="filter-control">
|
|
|
|
+ <el-button type="primary" @click="getList"> 查询 </el-button>
|
|
|
|
+ </div>
|
|
|
|
+ </div>
|
|
<!-- 列表 -->
|
|
<!-- 列表 -->
|
|
<el-table v-loading="isLoading" :data="list" border style="width: 100%" height="660">
|
|
<el-table v-loading="isLoading" :data="list" border style="width: 100%" height="660">
|
|
- <el-table-column prop="ticketId" label="票根号" align="center" />
|
|
|
|
- <el-table-column prop="name" label="购票人姓名" align="center">
|
|
|
|
|
|
+ <el-table-column prop="ticketId" label="票根号" align="center">
|
|
|
|
+ <template slot-scope="{ row }">
|
|
|
|
+ {{ row.ticketId ? row.ticketId : '---' }}
|
|
|
|
+ </template>
|
|
|
|
+ </el-table-column>
|
|
|
|
+ <el-table-column prop="name" label="姓名" align="center">
|
|
<template slot-scope="{ row }">
|
|
<template slot-scope="{ row }">
|
|
{{ row.name ? row.name : '---' }}
|
|
{{ row.name ? row.name : '---' }}
|
|
</template>
|
|
</template>
|
|
</el-table-column>
|
|
</el-table-column>
|
|
- <el-table-column prop="userId" label="采美机构绑定状态" align="center">
|
|
|
|
|
|
+ <el-table-column prop="mobile" label="手机号" align="center">
|
|
|
|
+ <template slot-scope="{ row }">
|
|
|
|
+ {{ row.mobile ? row.mobile : '---' }}
|
|
|
|
+ </template>
|
|
|
|
+ </el-table-column>
|
|
|
|
+ <el-table-column prop="userId" label="绑定状态" align="center">
|
|
<template slot-scope="{ row }">
|
|
<template slot-scope="{ row }">
|
|
- <el-tag v-if="row.userId" type="success" size="small">已绑定</el-tag>
|
|
|
|
|
|
+ <el-tag v-if="row.ticketId && row.userId" type="success" size="small">已绑定</el-tag>
|
|
<el-tag v-else type="info" size="small">未绑定</el-tag>
|
|
<el-tag v-else type="info" size="small">未绑定</el-tag>
|
|
</template>
|
|
</template>
|
|
</el-table-column>
|
|
</el-table-column>
|
|
@@ -27,7 +54,7 @@
|
|
</el-table-column>
|
|
</el-table-column>
|
|
<el-table-column prop="shopIds" label="打卡进度" align="center">
|
|
<el-table-column prop="shopIds" label="打卡进度" align="center">
|
|
<template slot-scope="{ row }">
|
|
<template slot-scope="{ row }">
|
|
- <el-tag v-if="row.shopIds" type="success" size="small">已完成</el-tag>
|
|
|
|
|
|
+ <el-tag v-if="handleShopIds(row.shopIds)" type="success" size="small">已完成</el-tag>
|
|
<el-tag v-else type="info" size="small">未完成</el-tag>
|
|
<el-tag v-else type="info" size="small">未完成</el-tag>
|
|
</template>
|
|
</template>
|
|
</el-table-column>
|
|
</el-table-column>
|
|
@@ -56,9 +83,9 @@
|
|
<zi-dialog v-if="dialogVisible" ref="ziDialog" :user-id="handleUserId" @cancel="handleCancel" />
|
|
<zi-dialog v-if="dialogVisible" ref="ziDialog" :user-id="handleUserId" @cancel="handleCancel" />
|
|
<!-- 修改礼品领取状态 -->
|
|
<!-- 修改礼品领取状态 -->
|
|
<el-dialog title="修改礼品领取状态" :visible.sync="dialogFormVisible" width="500px">
|
|
<el-dialog title="修改礼品领取状态" :visible.sync="dialogFormVisible" width="500px">
|
|
- <el-form ref="dataForm" :model="renewCustome" :rules="rules" label-position="right">
|
|
|
|
|
|
+ <el-form ref="dataForm" label-position="right">
|
|
<el-form-item prop="status">
|
|
<el-form-item prop="status">
|
|
- <el-radio v-model="renewCustome.status" :label="0">已领取</el-radio>
|
|
|
|
|
|
+ <el-radio v-model="giftFlag" :label="1" border>已领取</el-radio>
|
|
</el-form-item>
|
|
</el-form-item>
|
|
</el-form>
|
|
</el-form>
|
|
<div slot="footer" class="dialog-footer">
|
|
<div slot="footer" class="dialog-footer">
|
|
@@ -70,7 +97,7 @@
|
|
</template>
|
|
</template>
|
|
|
|
|
|
<script>
|
|
<script>
|
|
-import { getZylTicketList, postZylUpdateGift } from '@/api/activity/activity'
|
|
|
|
|
|
+import { getZylTicketList, postZylUpdateGift,getZylTicketDetail } from '@/api/activity/activity'
|
|
import ZiDialog from './components/zi-dialog'
|
|
import ZiDialog from './components/zi-dialog'
|
|
export default {
|
|
export default {
|
|
name: 'CustomerList',
|
|
name: 'CustomerList',
|
|
@@ -81,7 +108,8 @@ export default {
|
|
isLoading: true,
|
|
isLoading: true,
|
|
listQuery: {
|
|
listQuery: {
|
|
pageNum: 1,
|
|
pageNum: 1,
|
|
- pageSize: 20
|
|
|
|
|
|
+ pageSize: 20,
|
|
|
|
+ mobile:''
|
|
},
|
|
},
|
|
list: [],
|
|
list: [],
|
|
total: 0,
|
|
total: 0,
|
|
@@ -89,9 +117,9 @@ export default {
|
|
dialogFormVisible: false,
|
|
dialogFormVisible: false,
|
|
handleUserId: '',
|
|
handleUserId: '',
|
|
renewCustome: {
|
|
renewCustome: {
|
|
- id: '',
|
|
|
|
- status: ''
|
|
|
|
|
|
+ userId:0
|
|
},
|
|
},
|
|
|
|
+ giftFlag:0,
|
|
rules: {
|
|
rules: {
|
|
status: [{ required: true, message: '请设置统计状态', trigger: 'blur' }]
|
|
status: [{ required: true, message: '请设置统计状态', trigger: 'blur' }]
|
|
}
|
|
}
|
|
@@ -110,6 +138,21 @@ export default {
|
|
this.listQuery.pageNum = 1
|
|
this.listQuery.pageNum = 1
|
|
this.getZylTicketList()
|
|
this.getZylTicketList()
|
|
},
|
|
},
|
|
|
|
+ // 判断是否全部打卡
|
|
|
|
+ handleShopIds(shopIds){
|
|
|
|
+ let flag = false
|
|
|
|
+ const defaultShop = [2,3,4,5,7,8,9,10]
|
|
|
|
+ if(shopIds){
|
|
|
|
+ const shopIdsArr = shopIds.split(',').map(Number)
|
|
|
|
+ console.log('shopIdsArr',shopIdsArr)
|
|
|
|
+ if(shopIdsArr.length === defaultShop.length ){
|
|
|
|
+ flag = true
|
|
|
|
+ }else{
|
|
|
|
+ flag = false
|
|
|
|
+ }
|
|
|
|
+ }
|
|
|
|
+ return flag
|
|
|
|
+ },
|
|
// 获取机构列表
|
|
// 获取机构列表
|
|
async getZylTicketList() {
|
|
async getZylTicketList() {
|
|
try {
|
|
try {
|
|
@@ -128,17 +171,12 @@ export default {
|
|
},
|
|
},
|
|
// 修改礼品领取状态
|
|
// 修改礼品领取状态
|
|
handleChangeState(row) {
|
|
handleChangeState(row) {
|
|
|
|
+ this.renewCustome.userId = row.userId
|
|
this.dialogFormVisible = true
|
|
this.dialogFormVisible = true
|
|
},
|
|
},
|
|
// 确认修改礼品领取状态
|
|
// 确认修改礼品领取状态
|
|
handleConfirm() {
|
|
handleConfirm() {
|
|
- this.$refs['dataForm'].validate((valid) => {
|
|
|
|
- if (valid) {
|
|
|
|
- this.postZylUpdateGift(this.renewCustome)
|
|
|
|
- } else {
|
|
|
|
- return false
|
|
|
|
- }
|
|
|
|
- })
|
|
|
|
|
|
+ this.postZylUpdateGift(this.renewCustome)
|
|
},
|
|
},
|
|
// 统计状态
|
|
// 统计状态
|
|
async postZylUpdateGift(params) {
|
|
async postZylUpdateGift(params) {
|