Quellcode durchsuchen

统计报表停车场部分

zaijin vor 3 Jahren
Ursprung
Commit
beb6a3271c

+ 6 - 0
common/apiurl.js

@@ -59,14 +59,20 @@ export const apiurl = {
 		getRoadSpaceListUrl: '/admin/report/space',
 		// 获取欠费统计接口
 		getArrearsReportTotalUrl: '/admin/report/owetotal',
+		// 获取欠费统计(停车场)接口
+		getParkingArrearsReportTotalUrl: '/admin/report/parkowetotal',
 		// 获取欠费统计列表接口
 		getArrearsReportListUrl: '/admin/report/owe',
+		// 获取欠费统计列表(停车场)接口
+		getParkingArrearsReportListUrl: '/admin/report/parkowe',
 		// 获取营收统计接口
 		getIncomeTotalUrl: '/admin/report/incometotal',
 		// 获取营收列表接口
 		getIncomeListUrl: '/admin/report/income',
 		// 获取实收应收分析列表接口
 		getReallyReceivableListUrl: '/admin/report/amt',
+		// 获取实收应收分析列表(停车场)接口
+		getParkingReallyReceivableListUrl: '/admin/report/parkamt',
 		// 获取考勤统计列表接口
 		getPunchListUrl: '/admin/report/punch',
 		// 获取停车场实收统计接口

+ 14 - 0
common/http.api.js

@@ -121,11 +121,21 @@ const install = (Vue, vm) => {
 			.getArrearsReportTotalUrl, {
 				params
 			}),
+		// 获取欠费统计(停车场)
+		getParkingArrearsReportTotalApi: (params = {}) => vm.$u.http.get(apiurl.statisticalReport
+			.getParkingArrearsReportTotalUrl, {
+				params
+			}),
 		// 获取欠费统计列表
 		getArrearsReportListApi: (params = {}) => vm.$u.http.get(apiurl.statisticalReport
 			.getArrearsReportListUrl, {
 				params
 			}),
+		// 获取欠费统计列表(停车场)
+		getParkingArrearsReportListApi: (params = {}) => vm.$u.http.get(apiurl.statisticalReport
+			.getParkingArrearsReportListUrl, {
+				params
+			}),
 		// 获取营收统计
 		getIncomeTotalApi: (params = {}) => vm.$u.http.get(apiurl.statisticalReport.getIncomeTotalUrl, {
 			params
@@ -138,6 +148,10 @@ const install = (Vue, vm) => {
 		getReallyReceivableListApi: (params = {}) => vm.$u.http.get(apiurl.statisticalReport.getReallyReceivableListUrl, {
 			params
 		}),
+		// 获取实收应收分析列表(停车场)
+		getParkingReallyReceivableListApi: (params = {}) => vm.$u.http.get(apiurl.statisticalReport.getParkingReallyReceivableListUrl, {
+			params
+		}),
 		// 获取考勤统计列表
 		getPunchListApi: (params = {}) => vm.$u.http.get(apiurl.statisticalReport.getPunchListUrl, {
 			params

+ 73 - 4
pages/dataOverview/statisticalReport/components/arrearsReport.vue

@@ -1,6 +1,22 @@
 <!-- 欠费统计 -->
 <template>
 	<view class="container">
+		<view class="tab">
+			<u-tabs
+				:list="tabList"
+				lineColor="#fff"
+				:activeStyle="{
+					color: '#fff',
+					fontWeight: 'bold',
+					transform: 'scale(1.05)'
+				}"
+				:inactiveStyle="{
+					color: '#000',
+					transform: 'scale(1)'
+				}"
+				@click="tabClick">
+			</u-tabs>
+		</view>
 		<view class="table">
 			<view class="table-date" v-if="currentDate">{{ currentDate.join(' 至 ') }}</view>
 			<view class="table-box">
@@ -45,12 +61,28 @@
 					total: 0,
 					list: []
 				},
+				tabCurName: 'road',
 				currentDate: [],
 				beginTime: undefined,
-				endTime: undefined
+				endTime: undefined,
+				tabList: [
+					{ name: '路段', value: 'road' },
+					{ name: '停车场', value: 'parking' }
+				]
 			}
 		},
 		methods: {
+			tabClick(item) {
+				this.tabCurName = item.value
+				this.tableData.current = 1
+				if (this.tabCurName === 'road') {
+					this.getArreasReportTotal()
+					this.getArreasReportList()
+				} else {
+					this.getParkingArreasReportTotal()
+					this.getParkingArreasReportList()
+				}
+			},
 			getData(data) {
 				if (data.length) {
 					this.beginTime = data[0]
@@ -58,8 +90,13 @@
 				}
 				this.currentDate = data
 				this.tableData.current = 1
-				this.getArreasReportTotal()
-				this.getArreasReportList()
+				if (this.tabCurName === 'road') {
+					this.getArreasReportTotal()
+					this.getArreasReportList()
+				} else {
+					this.getParkingArreasReportTotal()
+					this.getParkingArreasReportList()
+				}
 			},
 			getArreasReportTotal() {
 				uni.$u.api.statisticalReportApi.getArrearsReportTotalApi({
@@ -71,6 +108,16 @@
 					}
 				})
 			},
+			getParkingArreasReportTotal() {
+				uni.$u.api.statisticalReportApi.getParkingArrearsReportTotalApi({
+					beginTime: this.beginTime,
+					endTime: this.endTime
+				}).then(res => {
+					if (res.code === 200) {
+						this.totalData = res.data
+					}
+				})
+			},
 			getArreasReportList() {
 				this.loading = true
 				uni.$u.api.statisticalReportApi.getArrearsReportListApi({
@@ -86,9 +133,28 @@
 					this.loading = false
 				})
 			},
+			getParkingArreasReportList() {
+				this.loading = true
+				uni.$u.api.statisticalReportApi.getParkingArrearsReportListApi({
+					beginTime: this.beginTime,
+					endTime: this.endTime,
+					pageNum: this.tableData.current,
+					pageSize: 10
+				}).then(res => {
+					if (res.code === 200) {
+						this.tableData.list = res.rows
+						this.tableData.total = res.total
+					}
+					this.loading = false
+				})
+			},
 			pageChange(cur) {
 				this.tableData.current = cur
-				this.getArreasReportList()
+				if (this.tabCurName === 'road') {
+					this.getArreasReportList()
+				} else {
+					this.getParkingArreasReportList()
+				}
 			}
 		}
 	}
@@ -96,5 +162,8 @@
 
 <style lang="scss" scoped>
 	@import './report.scss';
+	.tab {
+		margin-bottom: 10px;
+	}
 </style>
 

+ 39 - 1
pages/dataOverview/statisticalReport/components/reallyReceivable.vue

@@ -1,6 +1,22 @@
 <!-- 应收实收分析 -->
 <template>
 	<view class="container">
+		<view class="tab">
+			<u-tabs
+				:list="tabList"
+				lineColor="#fff"
+				:activeStyle="{
+					color: '#fff',
+					fontWeight: 'bold',
+					transform: 'scale(1.05)'
+				}"
+				:inactiveStyle="{
+					color: '#000',
+					transform: 'scale(1)'
+				}"
+				@click="tabClick">
+			</u-tabs>
+		</view>
 		<view class="table">
 			<view class="table-date" v-if="params.queryDate">{{ params.title }}</view>
 			<view class="table-box">
@@ -83,10 +99,23 @@
 					queryDate: '',
 					title: ''
 				},
-				loading: false
+				loading: false,
+				tabCurName: 'road',
+				tabList: [
+					{ name: '路段', value: 'road' },
+					{ name: '停车场', value: 'parking' }
+				]
 			}
 		},
 		methods: {
+			tabClick(item) {
+				this.tabCurName = item.value
+				if (this.tabCurName === 'road') {
+					this.getReallyReceivableList()
+				} else {
+					this.getParkingReallyReceivableList()
+				}
+			},
 			getData(obj) {
 				this.params = obj
 				this.getReallyReceivableList()
@@ -99,6 +128,15 @@
 					}
 					this.loading = false
 				})
+			},
+			getParkingReallyReceivableList() {
+				this.loading = true
+				uni.$u.api.statisticalReportApi.getParkingReallyReceivableListApi(this.params).then(res => {
+					if (res.code === 200) {
+						this.tableData.list = res.data.itemList
+					}
+					this.loading = false
+				})
 			}
 		}
 	}

+ 1 - 1
pages/dataOverview/statisticalReport/components/revenueReport.vue

@@ -28,7 +28,7 @@
 				type: Array,
 				default: () => {
 					return [{
-							field: '路段名称',
+							field: '停车场/路段',
 							width: 120,
 							key: 'roadName'
 						},