|
@@ -1,3 +1,4 @@
|
|
|
|
|
+<script src="../../main.js"></script>
|
|
|
<template>
|
|
<template>
|
|
|
<a-card :bordered="false">
|
|
<a-card :bordered="false">
|
|
|
<!-- 查询区域 -->
|
|
<!-- 查询区域 -->
|
|
@@ -117,7 +118,7 @@
|
|
|
<a-button
|
|
<a-button
|
|
|
type="primary"
|
|
type="primary"
|
|
|
icon="printer"
|
|
icon="printer"
|
|
|
- v-print="'#table'"
|
|
|
|
|
|
|
+ v-print="'#tableCopy'"
|
|
|
>打印</a-button>
|
|
>打印</a-button>
|
|
|
</span>
|
|
</span>
|
|
|
</a-col>
|
|
</a-col>
|
|
@@ -158,7 +159,7 @@
|
|
|
>
|
|
>
|
|
|
<template #footer >
|
|
<template #footer >
|
|
|
<a-table
|
|
<a-table
|
|
|
- ref="table"
|
|
|
|
|
|
|
+ ref="innerTableCopy"
|
|
|
size="middle"
|
|
size="middle"
|
|
|
:pagination="false"
|
|
:pagination="false"
|
|
|
:columns="columns.filter(item => item.show)"
|
|
:columns="columns.filter(item => item.show)"
|
|
@@ -278,9 +279,144 @@
|
|
|
</span>
|
|
</span>
|
|
|
</a-table>
|
|
</a-table>
|
|
|
</div>
|
|
</div>
|
|
|
|
|
+ <div>
|
|
|
|
|
+ <a-table
|
|
|
|
|
+ id="tableCopy"
|
|
|
|
|
+ ref="tableCopy"
|
|
|
|
|
+ size="middle"
|
|
|
|
|
+ v-show="false"
|
|
|
|
|
+ :scroll="{ x: true }"
|
|
|
|
|
+ bordered
|
|
|
|
|
+ rowKey="id"
|
|
|
|
|
+ :columns="columns.slice(0,-1).filter(item => item.show)"
|
|
|
|
|
+ :dataSource="dataSource"
|
|
|
|
|
+ :pagination="false"
|
|
|
|
|
+ class="guestorders"
|
|
|
|
|
+ @change="handleTableChange"
|
|
|
|
|
+ >
|
|
|
|
|
+ <template #footer >
|
|
|
|
|
+ <a-table
|
|
|
|
|
+ ref="innerTableCopy"
|
|
|
|
|
+ size="middle"
|
|
|
|
|
+ :pagination="false"
|
|
|
|
|
+ :columns="columns.slice(0,-1).filter(item => item.show)"
|
|
|
|
|
+ :dataSource="totalData"
|
|
|
|
|
+ :showHeader="false"
|
|
|
|
|
+ class="nei_tabel_bottom"
|
|
|
|
|
+ style="padding: 0px; height: 50px"
|
|
|
|
|
+ ></a-table>
|
|
|
|
|
+ </template>
|
|
|
|
|
+
|
|
|
|
|
+ <template slot="roomName" slot-scope="text, record">
|
|
|
|
|
+ <span :class="record.yuE < 0 ? 'textColor' : ''">
|
|
|
|
|
+ {{ text ? text : '排房' }}
|
|
|
|
|
+ </span>
|
|
|
|
|
+ </template>
|
|
|
|
|
+ <template slot="layoutName" slot-scope="text, record">
|
|
|
|
|
+ <span :class="record.yuE < 0 ? 'textColor' : ''">
|
|
|
|
|
+ {{ text }}
|
|
|
|
|
+ </span>
|
|
|
|
|
+ </template>
|
|
|
|
|
+ <template slot="customerName" slot-scope="text, record">
|
|
|
|
|
+ <span :class="record.yuE < 0 ? 'textColor' : ''">
|
|
|
|
|
+ {{ record.customerName + '/' + record.customerPhone }}
|
|
|
|
|
+ </span>
|
|
|
|
|
+ </template>
|
|
|
|
|
+ <template slot="settleType" slot-scope="text, record">
|
|
|
|
|
+ <span :class="record.yuE < 0 ? 'textColor' : ''">
|
|
|
|
|
+ {{ getSettleTypeText(record) }}
|
|
|
|
|
+ </span>
|
|
|
|
|
+ </template>
|
|
|
|
|
+ <template slot="customerType" slot-scope="text, record">
|
|
|
|
|
+ <span :class="record.yuE < 0 ? 'textColor' : ''">
|
|
|
|
|
+ {{ getCustomerTypeText(record) }}
|
|
|
|
|
+ </span>
|
|
|
|
|
+ </template>
|
|
|
|
|
+ <template slot="customerSource" slot-scope="text, record">
|
|
|
|
|
+ <span :class="record.yuE < 0 ? 'textColor' : ''">
|
|
|
|
|
+ {{ getCustomerSourceText(record) }}
|
|
|
|
|
+ </span>
|
|
|
|
|
+ </template>
|
|
|
|
|
+ <template slot="otype" slot-scope="text, record">
|
|
|
|
|
+ <span :class="record.yuE < 0 ? 'textColor' : ''">
|
|
|
|
|
+ {{ getOtypeText(record) }}
|
|
|
|
|
+ </span>
|
|
|
|
|
+ </template>
|
|
|
|
|
+ <template slot="arrivalTime" slot-scope="text, record">
|
|
|
|
|
+ <span :class="record.yuE < 0 ? 'textColor' : ''">
|
|
|
|
|
+ {{ text }}
|
|
|
|
|
+ </span>
|
|
|
|
|
+ </template>
|
|
|
|
|
+ <template slot="dueOutTime" slot-scope="text, record">
|
|
|
|
|
+ <span :class="record.yuE < 0 ? 'textColor' : ''">
|
|
|
|
|
+ {{ text }}
|
|
|
|
|
+ </span>
|
|
|
|
|
+ </template>
|
|
|
|
|
+ <template slot="price" slot-scope="text, record">
|
|
|
|
|
+ <span :class="record.yuE < 0 ? 'textColor' : ''">
|
|
|
|
|
+ {{ record.livingDayPrices && record.livingDayPrices.length > 0 ? record.livingDayPrices[0].price : '--' }}
|
|
|
|
|
+ </span>
|
|
|
|
|
+ </template>
|
|
|
|
|
+ <template slot="consumption" slot-scope="text, record">
|
|
|
|
|
+ <span :class="record.yuE < 0 ? 'textColor' : ''">
|
|
|
|
|
+ {{ record.yushou - record.yuE }}
|
|
|
|
|
+ </span>
|
|
|
|
|
+ </template>
|
|
|
|
|
+ <template slot="yushou" slot-scope="text, record">
|
|
|
|
|
+ <span :class="record.yuE < 0 ? 'textColor' : ''">
|
|
|
|
|
+ {{ text }}
|
|
|
|
|
+ </span>
|
|
|
|
|
+ </template>
|
|
|
|
|
+ <template slot="yuE" slot-scope="text, record">
|
|
|
|
|
+ <span :class="record.yuE < 0 ? 'textColor' : ''">
|
|
|
|
|
+ {{ record.yuE }}
|
|
|
|
|
+ </span>
|
|
|
|
|
+ </template>
|
|
|
|
|
+ <template slot="htmlSlot" slot-scope="text">
|
|
|
|
|
+ <div v-html="text"></div>
|
|
|
|
|
+ </template>
|
|
|
|
|
+ <template slot="imgSlot" slot-scope="text, record">
|
|
|
|
|
+ <span
|
|
|
|
|
+ v-if="!text"
|
|
|
|
|
+ style="font-size: 12px; font-style: italic"
|
|
|
|
|
+ >无图片</span
|
|
|
|
|
+ >
|
|
|
|
|
+ <img
|
|
|
|
|
+ v-else
|
|
|
|
|
+ :src="getImgView(text)"
|
|
|
|
|
+ :preview="record.id"
|
|
|
|
|
+ height="25px"
|
|
|
|
|
+ alt=""
|
|
|
|
|
+ style="max-width: 80px; font-size: 12px; font-style: italic"
|
|
|
|
|
+ />
|
|
|
|
|
+ </template>
|
|
|
|
|
+ <template slot="fileSlot" slot-scope="text">
|
|
|
|
|
+ <span
|
|
|
|
|
+ v-if="!text"
|
|
|
|
|
+ style="font-size: 12px; font-style: italic"
|
|
|
|
|
+ >无文件</span
|
|
|
|
|
+ >
|
|
|
|
|
+ <a-button
|
|
|
|
|
+ v-else
|
|
|
|
|
+ :ghost="true"
|
|
|
|
|
+ type="primary"
|
|
|
|
|
+ icon="download"
|
|
|
|
|
+ size="small"
|
|
|
|
|
+ @click="downloadFile(text)"
|
|
|
|
|
+ >
|
|
|
|
|
+ 下载
|
|
|
|
|
+ </a-button>
|
|
|
|
|
+ </template>
|
|
|
|
|
+
|
|
|
|
|
+ <span slot="action" slot-scope="text, record">
|
|
|
|
|
+ <a @click="handleInfo(record)">查看</a>
|
|
|
|
|
+ <a-divider v-if="record.settleType !== -1" type="vertical" />
|
|
|
|
|
+ <a v-if="record.settleType !== -1" @click="cancelLeaveNotSettle(record)">撤销结账</a>
|
|
|
|
|
+ </span>
|
|
|
|
|
+ </a-table>
|
|
|
|
|
+ </div>
|
|
|
<bill-room-info-modal
|
|
<bill-room-info-modal
|
|
|
ref="ModalBillRoomInfo"
|
|
ref="ModalBillRoomInfo"
|
|
|
- @ok="modalLockRoomFormOk"
|
|
|
|
|
></bill-room-info-modal>
|
|
></bill-room-info-modal>
|
|
|
|
|
|
|
|
</a-card>
|
|
</a-card>
|
|
@@ -293,7 +429,6 @@ import { JeecgListMixin } from '@/mixins/JeecgListMixin'
|
|
|
import BillRoomInfoModal from './modules/checkIn/BillRoomInfoModal.vue'
|
|
import BillRoomInfoModal from './modules/checkIn/BillRoomInfoModal.vue'
|
|
|
import { postAction, getAction } from '@/api/manage'
|
|
import { postAction, getAction } from '@/api/manage'
|
|
|
|
|
|
|
|
-const date = new Date()
|
|
|
|
|
export default {
|
|
export default {
|
|
|
name: 'CesOrderMessageList',
|
|
name: 'CesOrderMessageList',
|
|
|
mixins: [JeecgListMixin, mixinDevice],
|
|
mixins: [JeecgListMixin, mixinDevice],
|
|
@@ -420,7 +555,9 @@ export default {
|
|
|
totalData: [
|
|
totalData: [
|
|
|
{
|
|
{
|
|
|
orderNo: '合计',
|
|
orderNo: '合计',
|
|
|
- consumption: 0
|
|
|
|
|
|
|
+ consumption: 0,
|
|
|
|
|
+ yushou: 0,
|
|
|
|
|
+ yuE: 0
|
|
|
}
|
|
}
|
|
|
],
|
|
],
|
|
|
url: {
|
|
url: {
|
|
@@ -477,25 +614,15 @@ export default {
|
|
|
watch: {
|
|
watch: {
|
|
|
dataSource(val, old) {
|
|
dataSource(val, old) {
|
|
|
let allSum = 0
|
|
let allSum = 0
|
|
|
|
|
+ let allYushou = 0
|
|
|
|
|
+ let allYuE = 0
|
|
|
val.forEach(e => {
|
|
val.forEach(e => {
|
|
|
- allSum += e.yushou - e.yuE
|
|
|
|
|
|
|
+ allYushou += e.yushou
|
|
|
|
|
+ allYuE += e.yuE
|
|
|
})
|
|
})
|
|
|
- this.totalData[0].consumption = allSum;
|
|
|
|
|
- // handler(newValue, oldValue) {
|
|
|
|
|
- // newValue.forEach((e, index) => {
|
|
|
|
|
- // this.$watch(
|
|
|
|
|
- // () => e.money,
|
|
|
|
|
- // (newName, oldName) => {
|
|
|
|
|
- // let num = e.num == null ? 1 : e.num
|
|
|
|
|
- // let payable = e.money * num * this.model.roomIds.length
|
|
|
|
|
- // e.payable = payable
|
|
|
|
|
- // // this.$set(e,'relMoney', payable)
|
|
|
|
|
- // e.relMoney = payable
|
|
|
|
|
- // }
|
|
|
|
|
- // )
|
|
|
|
|
- // })
|
|
|
|
|
- // },
|
|
|
|
|
- // deep: true // 监听数组的变化需要设置 deep 为 true
|
|
|
|
|
|
|
+ this.totalData[0].consumption = allYushou - allYuE
|
|
|
|
|
+ this.totalData[0].yushou = allYushou
|
|
|
|
|
+ this.totalData[0].yuE = allYuE
|
|
|
}
|
|
}
|
|
|
},
|
|
},
|
|
|
computed: {
|
|
computed: {
|
|
@@ -593,4 +720,11 @@ export default {
|
|
|
.nei_tabel_bottom .ant-table-tbody > tr > td{
|
|
.nei_tabel_bottom .ant-table-tbody > tr > td{
|
|
|
border: none !important;
|
|
border: none !important;
|
|
|
}
|
|
}
|
|
|
|
|
+
|
|
|
|
|
+@media print {
|
|
|
|
|
+ .guestorders {
|
|
|
|
|
+ display: block !important;
|
|
|
|
|
+ /* Add your custom styles for printing */
|
|
|
|
|
+ }
|
|
|
|
|
+}
|
|
|
</style>
|
|
</style>
|