|
@@ -6,25 +6,30 @@
|
|
<a-row :gutter="48">
|
|
<a-row :gutter="48">
|
|
<a-col :lg="6" :sm="12">
|
|
<a-col :lg="6" :sm="12">
|
|
<a-form-item label="结算时间:">
|
|
<a-form-item label="结算时间:">
|
|
- <a-range-picker style="width:100%" v-model="queryOrderDate" format="YYYY-MM-DD" :placeholder="['开始时间', '结束时间']" />
|
|
|
|
|
|
+ <a-range-picker
|
|
|
|
+ style="width:100%"
|
|
|
|
+ :disabledDate="disabledDate"
|
|
|
|
+ v-model="queryOrderDate"
|
|
|
|
+ format="YYYY-MM-DD"
|
|
|
|
+ :placeholder="['开始时间', '结束时间']" />
|
|
</a-form-item>
|
|
</a-form-item>
|
|
</a-col>
|
|
</a-col>
|
|
<a-col :lg="6" :sm="12">
|
|
<a-col :lg="6" :sm="12">
|
|
<a-form-item label="结算单号">
|
|
<a-form-item label="结算单号">
|
|
- <a-input class="full-width" v-model="queryParam.number" :maxLength="11" placeholder="请输入" allowClear />
|
|
|
|
|
|
+ <a-input class="full-width" v-model="queryParam.settleNo" placeholder="请输入" allowClear />
|
|
</a-form-item>
|
|
</a-form-item>
|
|
</a-col>
|
|
</a-col>
|
|
<a-col :lg="6" :sm="12">
|
|
<a-col :lg="6" :sm="12">
|
|
- <a-button type="primary" @click="$refs.table.refresh(true)">查询</a-button>
|
|
|
|
|
|
+ <a-button type="primary" @click="refresh">查询</a-button>
|
|
<a-button style="margin-left: 8px" @click="resetSearchForm">重置</a-button>
|
|
<a-button style="margin-left: 8px" @click="resetSearchForm">重置</a-button>
|
|
</a-col>
|
|
</a-col>
|
|
</a-row>
|
|
</a-row>
|
|
</a-form>
|
|
</a-form>
|
|
</div>
|
|
</div>
|
|
- <a-divider style="margin-top: 0;"/>
|
|
|
|
|
|
+ <a-divider />
|
|
<!-- 合计 -->
|
|
<!-- 合计 -->
|
|
<a-alert type="info" showIcon style="margin-bottom:15px">
|
|
<a-alert type="info" showIcon style="margin-bottom:15px">
|
|
- <div class="ftext" slot="message">总计:<span>{{ 3 }}</span> 单,实收<span>¥{{ 2900 }}</span> 元</div>
|
|
|
|
|
|
+ <div class="ftext" slot="message">共<span>{{ orderTotal }}</span>单,实收<span>¥{{ amountTotal }}</span>元</div>
|
|
</a-alert>
|
|
</a-alert>
|
|
<!-- 列表 -->
|
|
<!-- 列表 -->
|
|
<div>
|
|
<div>
|
|
@@ -37,7 +42,7 @@
|
|
:data="loadData">
|
|
:data="loadData">
|
|
<template slot="action" slot-scope="text, record">
|
|
<template slot="action" slot-scope="text, record">
|
|
<!-- <a-icon type="eye" title="查看" :style="{ fontSize: '20px', color: '#e29e14', padding: '0 10px' }" @click="handleDetail(record)" /> -->
|
|
<!-- <a-icon type="eye" title="查看" :style="{ fontSize: '20px', color: '#e29e14', padding: '0 10px' }" @click="handleDetail(record)" /> -->
|
|
- <a-button type="primary" @click="handleDetail(record)">查看</a-button>
|
|
|
|
|
|
+ <a-button type="primary" @click="handleDetail(record)">详情</a-button>
|
|
</template>
|
|
</template>
|
|
</s-table>
|
|
</s-table>
|
|
</div>
|
|
</div>
|
|
@@ -52,12 +57,13 @@ import {
|
|
STable,
|
|
STable,
|
|
VSelect
|
|
VSelect
|
|
} from '@/components'
|
|
} from '@/components'
|
|
-// import {
|
|
|
|
-// listCustomerBundle
|
|
|
|
-// } from '@/api/customerBundle'
|
|
|
|
|
|
+import {
|
|
|
|
+ settlementRecordsList,
|
|
|
|
+ settlementRecordsListTotal
|
|
|
|
+} from '@/api/FinancialManagement'
|
|
import PaySettlementRecordsDetailsModal from './PaySettlementRecordsDetailsModal.vue'
|
|
import PaySettlementRecordsDetailsModal from './PaySettlementRecordsDetailsModal.vue'
|
|
export default {
|
|
export default {
|
|
- name: 'PaySettlementRecordsList',
|
|
|
|
|
|
+ name: 'SettlementRecordsList',
|
|
components: {
|
|
components: {
|
|
VSelect,
|
|
VSelect,
|
|
STable,
|
|
STable,
|
|
@@ -66,32 +72,33 @@ export default {
|
|
data () {
|
|
data () {
|
|
return {
|
|
return {
|
|
loadData: parameter => {
|
|
loadData: parameter => {
|
|
- // const searchData = Object.assign(parameter, this.queryParam)
|
|
|
|
- // console.log(this.queryOrderDate, 'this.queryOrderDate')
|
|
|
|
- // if (this.queryOrderDate && this.queryOrderDate.length) {
|
|
|
|
- // searchData.beginDate = moment(this.queryOrderDate[0]).format('YYYY-MM-DD')
|
|
|
|
- // searchData.endDate = moment(this.queryOrderDate[1]).format('YYYY-MM-DD')
|
|
|
|
- // } else {
|
|
|
|
- // searchData.beginDate = ''
|
|
|
|
- // searchData.endDate = ''
|
|
|
|
- // }
|
|
|
|
- // return listCustomerBundle(searchData).then(res => {
|
|
|
|
- // const no = (res.pageNo - 1) * res.pageSize
|
|
|
|
- // for (let i = 0; i < res.list.length; i++) {
|
|
|
|
- // const _item = res.list[i]
|
|
|
|
- // _item.no = no + i + 1
|
|
|
|
- // }
|
|
|
|
- // return res
|
|
|
|
- // })
|
|
|
|
|
|
+ const searchData = Object.assign(parameter, this.queryParam)
|
|
|
|
+ console.log(this.queryOrderDate, 'this.queryOrderDate')
|
|
|
|
+ if (this.queryOrderDate && this.queryOrderDate.length) {
|
|
|
|
+ searchData.beginDate = moment(this.queryOrderDate[0]).format('YYYY-MM-DD')
|
|
|
|
+ searchData.endDate = moment(this.queryOrderDate[1]).format('YYYY-MM-DD')
|
|
|
|
+ } else {
|
|
|
|
+ searchData.beginDate = ''
|
|
|
|
+ searchData.endDate = ''
|
|
|
|
+ }
|
|
|
|
+ return settlementRecordsList(searchData).then(res => {
|
|
|
|
+ const no = (res.data.pageNo - 1) * res.data.pageSize
|
|
|
|
+ for (let i = 0; i < res.data.list.length; i++) {
|
|
|
|
+ const _item = res.data.list[i]
|
|
|
|
+ _item.no = no + i + 1
|
|
|
|
+ }
|
|
|
|
+ return res.data
|
|
|
|
+ })
|
|
},
|
|
},
|
|
queryOrderDate: undefined,
|
|
queryOrderDate: undefined,
|
|
queryParam: {
|
|
queryParam: {
|
|
- number: '',
|
|
|
|
|
|
+ settleNo: '',
|
|
beginDate: '',
|
|
beginDate: '',
|
|
- endDate: '',
|
|
|
|
- orderFlag: ''
|
|
|
|
|
|
+ endDate: ''
|
|
},
|
|
},
|
|
- itemId: null, // 每条数据id
|
|
|
|
|
|
+ orderTotal: 0, // 订单数量
|
|
|
|
+ amountTotal: 0, // 实收总金额
|
|
|
|
+ itemId: '', // 每条数据id
|
|
openModalDetails: false, // 默认关闭详情弹窗
|
|
openModalDetails: false, // 默认关闭详情弹窗
|
|
columns: [{
|
|
columns: [{
|
|
title: '序号',
|
|
title: '序号',
|
|
@@ -101,19 +108,19 @@ export default {
|
|
},
|
|
},
|
|
{
|
|
{
|
|
title: '结算单号',
|
|
title: '结算单号',
|
|
- dataIndex: 'aaa',
|
|
|
|
|
|
+ dataIndex: 'settleNo',
|
|
width: '150px',
|
|
width: '150px',
|
|
align: 'center'
|
|
align: 'center'
|
|
},
|
|
},
|
|
{
|
|
{
|
|
title: '结算时间',
|
|
title: '结算时间',
|
|
- dataIndex: 'orderDate',
|
|
|
|
|
|
+ dataIndex: 'settleDate',
|
|
width: '150px',
|
|
width: '150px',
|
|
align: 'center'
|
|
align: 'center'
|
|
},
|
|
},
|
|
{
|
|
{
|
|
title: '结算订单数',
|
|
title: '结算订单数',
|
|
- dataIndex: 'custMobile',
|
|
|
|
|
|
+ dataIndex: 'orderNum',
|
|
width: '150px',
|
|
width: '150px',
|
|
align: 'center',
|
|
align: 'center',
|
|
scopedSlots: {
|
|
scopedSlots: {
|
|
@@ -121,8 +128,8 @@ export default {
|
|
}
|
|
}
|
|
},
|
|
},
|
|
{
|
|
{
|
|
- title: '结算订单总金额(¥)',
|
|
|
|
- dataIndex: 'bundleName',
|
|
|
|
|
|
+ title: '结算金额',
|
|
|
|
+ dataIndex: 'realAmount',
|
|
align: 'center',
|
|
align: 'center',
|
|
width: '150px'
|
|
width: '150px'
|
|
},
|
|
},
|
|
@@ -139,29 +146,73 @@ export default {
|
|
}
|
|
}
|
|
},
|
|
},
|
|
methods: {
|
|
methods: {
|
|
|
|
+ // 禁止不可选日期
|
|
|
|
+ disabledDate (current) {
|
|
|
|
+ return current && current > moment().endOf('day')
|
|
|
|
+ },
|
|
// 查看详情
|
|
// 查看详情
|
|
handleDetail (record) {
|
|
handleDetail (record) {
|
|
- this.itemId = record.id
|
|
|
|
|
|
+ this.itemId = record.settleNo
|
|
console.log(this.itemId)
|
|
console.log(this.itemId)
|
|
this.openModalDetails = true
|
|
this.openModalDetails = true
|
|
},
|
|
},
|
|
|
|
+ // 查询
|
|
|
|
+ refresh () {
|
|
|
|
+ this.$refs.table.refresh(true)
|
|
|
|
+ this.getListTotal()
|
|
|
|
+ },
|
|
// 重置
|
|
// 重置
|
|
resetSearchForm () {
|
|
resetSearchForm () {
|
|
this.queryOrderDate = undefined
|
|
this.queryOrderDate = undefined
|
|
this.queryParam = {
|
|
this.queryParam = {
|
|
- number: '',
|
|
|
|
|
|
+ settleNo: '',
|
|
beginDate: '',
|
|
beginDate: '',
|
|
- endDate: '',
|
|
|
|
- orderFlag: '',
|
|
|
|
- custMobile: '',
|
|
|
|
- bundleName: '',
|
|
|
|
- vehicleNumber: ''
|
|
|
|
|
|
+ endDate: ''
|
|
}
|
|
}
|
|
this.$refs.table.refresh(true)
|
|
this.$refs.table.refresh(true)
|
|
|
|
+ this.getListTotal()
|
|
|
|
+ },
|
|
|
|
+ // 合计
|
|
|
|
+ getListTotal () {
|
|
|
|
+ const params = {
|
|
|
|
+ settleNo: this.queryParam.settleNo,
|
|
|
|
+ beginDate: this.queryParam.beginDate,
|
|
|
|
+ endDate: this.queryParam.endDate
|
|
|
|
+ }
|
|
|
|
+ if (this.queryOrderDate && this.queryOrderDate.length) {
|
|
|
|
+ params.beginDate = moment(this.queryOrderDate[0]).format('YYYY-MM-DD')
|
|
|
|
+ params.endDate = moment(this.queryOrderDate[1]).format('YYYY-MM-DD')
|
|
|
|
+ } else {
|
|
|
|
+ params.beginDate = ''
|
|
|
|
+ params.endDate = ''
|
|
|
|
+ }
|
|
|
|
+ // params.beginDate == null ? params.beginDate = getDate.getToday().starttime : null
|
|
|
|
+ // params.endDate == null ? params.endDate = getDate.getToday().endtime : null
|
|
|
|
+ settlementRecordsListTotal(params).then(res => {
|
|
|
|
+ if (res.status == 200) {
|
|
|
|
+ if (res.data) {
|
|
|
|
+ this.orderTotal = res.data.orderNum || 0
|
|
|
|
+ this.amountTotal = res.data.amount || 0
|
|
|
|
+ } else {
|
|
|
|
+ this.orderTotal = 0
|
|
|
|
+ this.amountTotal = 0
|
|
|
|
+ }
|
|
|
|
+ }
|
|
|
|
+ })
|
|
}
|
|
}
|
|
|
|
+
|
|
|
|
+ },
|
|
|
|
+ beforeRouteEnter (to, from, next) {
|
|
|
|
+ next(vm => {
|
|
|
|
+ vm.resetSearchForm()
|
|
|
|
+ })
|
|
}
|
|
}
|
|
}
|
|
}
|
|
</script>
|
|
</script>
|
|
|
|
|
|
-<style>
|
|
|
|
|
|
+<style scoped>
|
|
|
|
+ .ftext span {
|
|
|
|
+ color: #fa8c16;
|
|
|
|
+ font-weight: bold;
|
|
|
|
+ }
|
|
</style>
|
|
</style>
|