|
|
@@ -235,7 +235,7 @@
|
|
|
</el-table-column>
|
|
|
<el-table-column
|
|
|
prop="orderNo"
|
|
|
- min-width="180"
|
|
|
+ min-width="190"
|
|
|
label="订单号">
|
|
|
</el-table-column>
|
|
|
<el-table-column
|
|
|
@@ -343,7 +343,7 @@
|
|
|
</template>
|
|
|
</el-table-column> -->
|
|
|
<el-table-column
|
|
|
- width="80"
|
|
|
+ width="120"
|
|
|
label="操作">
|
|
|
<template slot-scope="scope">
|
|
|
<!-- <el-button
|
|
|
@@ -359,6 +359,10 @@
|
|
|
type="text"
|
|
|
v-if="scope.row.isSelfOrder === 0 && hasPermission('order-cancel')"
|
|
|
@click="showRefundOrder(scope.row)">退单</el-button>
|
|
|
+ <el-button
|
|
|
+ type="text"
|
|
|
+ v-if="scope.row.isSelfOrder === 0 && hasPermission('order-manual-check')"
|
|
|
+ @click="showManualCheckOrder(scope.row)">核销</el-button>
|
|
|
</template>
|
|
|
</el-table-column>
|
|
|
</el-table>
|
|
|
@@ -483,11 +487,94 @@
|
|
|
</div>
|
|
|
</ElDialog>
|
|
|
|
|
|
+ <ElDialog
|
|
|
+ title="核销"
|
|
|
+ v-model="manualCheckDialogVisible"
|
|
|
+ width="80%"
|
|
|
+ @close="manualCheckDialogVisible=false;manualCheckTicketNoSearch=''">
|
|
|
+ <div
|
|
|
+ class="search-area"
|
|
|
+ style="margin: 20px;display: flex;align-items: center;justify-content: space-between;">
|
|
|
+ <div class="name">
|
|
|
+ <span style="margin-right: 10px;">票号搜索</span>
|
|
|
+ <el-input v-model="manualCheckTicketNoSearch"></el-input>
|
|
|
+ </div>
|
|
|
+ </div>
|
|
|
+ <div
|
|
|
+ class="table-wrap"
|
|
|
+ style="padding: 20px;">
|
|
|
+ <el-table
|
|
|
+ border
|
|
|
+ :data="(currentItem.ticketList || []).filter(v => v.ticketNo.includes(manualCheckTicketNoSearch))"
|
|
|
+ @selection-change="handleManualCheckSelectionChange">
|
|
|
+ <el-table-column
|
|
|
+ type="selection"
|
|
|
+ fixed
|
|
|
+ :selectable="isManualCheckRowSelectable"
|
|
|
+ width="55">
|
|
|
+ </el-table-column>
|
|
|
+ <el-table-column
|
|
|
+ min-width="260"
|
|
|
+ prop="ticketInfo"
|
|
|
+ label="票信息">
|
|
|
+ <template slot-scope="scope">
|
|
|
+ <div class=""><span>票号:</span>{{ scope.row.ticketNo }}</div>
|
|
|
+ <div class=""><span>票种:</span>{{ scope.row.ticketTypeName }}</div>
|
|
|
+ <div class=""><span>金额:</span>{{ scope.row.price }}</div>
|
|
|
+ <div class=""><span>状态:</span>
|
|
|
+ <el-tag :type="ticketStatus[scope.row.status]&&ticketStatus[scope.row.status].color">
|
|
|
+ {{ ticketStatus[scope.row.status]&&ticketStatus[scope.row.status].label }}
|
|
|
+ </el-tag>
|
|
|
+ </div>
|
|
|
+ </template>
|
|
|
+ </el-table-column>
|
|
|
+ <el-table-column
|
|
|
+ prop="playDateBegin"
|
|
|
+ width="180"
|
|
|
+ label="游玩时间">
|
|
|
+ <template slot-scope="scope">
|
|
|
+ {{ scope.row.playDateBegin || scope.row.playDateEnd ? `${scope.row.playDateBegin || ''} - ${scope.row.playDateEnd || ''}` : "无限制" }}
|
|
|
+ </template>
|
|
|
+ </el-table-column>
|
|
|
+ <el-table-column
|
|
|
+ min-width="210"
|
|
|
+ prop="guestInfo"
|
|
|
+ label="游客信息">
|
|
|
+ <template slot-scope="scope">
|
|
|
+ <div class=""><span>姓名:</span>{{ scope.row.guestName }}</div>
|
|
|
+ <div class=""><span>手机号:</span>{{ scope.row.guestPhone }}</div>
|
|
|
+ <div class=""><span>证件类型:</span>{{ papersType[scope.row.guestIdentifyType] }}</div>
|
|
|
+ <div class=""><span>证件号码:</span>{{ scope.row.guestIdentify }}</div>
|
|
|
+ </template>
|
|
|
+ </el-table-column>
|
|
|
+ <el-table-column
|
|
|
+ min-width="260"
|
|
|
+ prop="ticketCheckInfo"
|
|
|
+ label="检票信息">
|
|
|
+ <template slot-scope="scope">
|
|
|
+ <div class=""><span>检票人数:</span>{{ scope.row.checkNum }}</div>
|
|
|
+ <div class=""><span>首次检票时间:</span>{{ scope.row.firstCheckTime }}</div>
|
|
|
+ <div class=""><span>核销通知:</span>{{ scope.row.isCheckSend ? '已通知' : '未通知' }}</div>
|
|
|
+ <div class=""><span>通知成功时间:</span>{{ scope.row.checkSendTime }}</div>
|
|
|
+ </template>
|
|
|
+ </el-table-column>
|
|
|
+ </el-table>
|
|
|
+ </div>
|
|
|
+ <div
|
|
|
+ class="dialog-footer"
|
|
|
+ style="padding: 20px; text-align: right;">
|
|
|
+ <el-button @click="manualCheckDialogVisible = false">取消</el-button>
|
|
|
+ <el-button
|
|
|
+ type="primary"
|
|
|
+ @click="submitManualCheckOrder">确定</el-button>
|
|
|
+ </div>
|
|
|
+ </ElDialog>
|
|
|
+
|
|
|
<TicketInfo ref="ticketInfo"></TicketInfo>
|
|
|
</div>
|
|
|
</template>
|
|
|
<script>
|
|
|
-import { getOrderList, getOtaSourceList, cancelOrder } from '@/api/order'
|
|
|
+import { getOrderList, getOtaSourceList, cancelOrder, checkTicket } from '@/api/order'
|
|
|
import { getTicketTypeList } from '@/api/ticketType'
|
|
|
import ElDialog from '@/components/Dialog'
|
|
|
import OrderDialog from './orderList/OrderDialog'
|
|
|
@@ -508,11 +595,14 @@ export default {
|
|
|
data () {
|
|
|
return {
|
|
|
refundOrderDialogVisible: false,
|
|
|
+ manualCheckDialogVisible: false,
|
|
|
refundOrderInfo: {
|
|
|
ticketCancelRequestList: []
|
|
|
},
|
|
|
ticketNoSearch: '',
|
|
|
+ manualCheckTicketNoSearch: '',
|
|
|
multipleSelection: [],
|
|
|
+ manualCheckSelection: [],
|
|
|
papersType: IDENTIFY_TYPES,
|
|
|
ticketTypeList: [],
|
|
|
otaSourceList: [],
|
|
|
@@ -645,12 +735,21 @@ export default {
|
|
|
isRowSelectable (row, index) {
|
|
|
return true
|
|
|
},
|
|
|
+ isManualCheckRowSelectable (row, index) {
|
|
|
+ return row.status === 'WAIT_USE' || row.status === 'PART_USE'
|
|
|
+ },
|
|
|
showRefundOrder (item) {
|
|
|
this.currentItem = item
|
|
|
this.refundOrderDialogVisible = true
|
|
|
this.ticketNoSearch = ''
|
|
|
this.multipleSelection = []
|
|
|
},
|
|
|
+ showManualCheckOrder (item) {
|
|
|
+ this.currentItem = item
|
|
|
+ this.manualCheckDialogVisible = true
|
|
|
+ this.manualCheckTicketNoSearch = ''
|
|
|
+ this.manualCheckSelection = []
|
|
|
+ },
|
|
|
submitRefundOrder (item) {
|
|
|
this.$confirm('确定退票?', '提示', {
|
|
|
confirmButtonText: '确定',
|
|
|
@@ -676,6 +775,41 @@ export default {
|
|
|
})
|
|
|
})
|
|
|
},
|
|
|
+ handleManualCheckSelectionChange (val) {
|
|
|
+ this.manualCheckSelection = val
|
|
|
+ },
|
|
|
+ submitManualCheckOrder () {
|
|
|
+ if (!this.currentItem || !this.currentItem.id) return
|
|
|
+ if (!this.manualCheckSelection.length) {
|
|
|
+ this.$message.warning('请选择需要核销的门票')
|
|
|
+ return
|
|
|
+ }
|
|
|
+ this.$confirm('确定核销?', '提示', {
|
|
|
+ confirmButtonText: '确定',
|
|
|
+ cancelButtonText: '取消',
|
|
|
+ type: 'warning'
|
|
|
+ }).then(() => {
|
|
|
+ this.loading = true
|
|
|
+ const ticketList = this.manualCheckSelection.map(v => {
|
|
|
+ return {
|
|
|
+ ticketId: v.id
|
|
|
+ }
|
|
|
+ })
|
|
|
+
|
|
|
+ checkTicket({
|
|
|
+ orderId: this.currentItem.id,
|
|
|
+ ticketManualCheckRequestList: ticketList
|
|
|
+ }).then(() => {
|
|
|
+ this.loading = false
|
|
|
+ this.$message.success('核销成功')
|
|
|
+ this.manualCheckDialogVisible = false
|
|
|
+ this.manualCheckTicketNoSearch = ''
|
|
|
+ this.getOrderList('', true)
|
|
|
+ }).catch(() => {
|
|
|
+ this.loading = false
|
|
|
+ })
|
|
|
+ })
|
|
|
+ },
|
|
|
showGuestInfo (item) {
|
|
|
this.currentItem = item
|
|
|
this.guestDialogVisible = true
|
|
|
@@ -699,9 +833,9 @@ export default {
|
|
|
})
|
|
|
})
|
|
|
},
|
|
|
- handelExport () {
|
|
|
+ handelExport (params) {
|
|
|
this.form.export = true
|
|
|
- getOrderList(this.form).then(res => {
|
|
|
+ getOrderList(params).then(res => {
|
|
|
this.$confirm('导出成功,是否去下载页', '提示', {
|
|
|
confirmButtonText: '确定',
|
|
|
cancelButtonText: '取消',
|