Commit 1df1973b authored by guoyou's avatar guoyou

租车订单管理

parent f9c92f4c
...@@ -728,8 +728,7 @@ export const asyncRouterMap = [{ ...@@ -728,8 +728,7 @@ export const asyncRouterMap = [{
component: _import('statistics/orderStatistics'), component: _import('statistics/orderStatistics'),
name: '订单统计', name: '订单统计',
authority: 'orderStatistics' authority: 'orderStatistics'
}, }, {
{
path: 'vehicleStatistics', path: 'vehicleStatistics',
component: _import('statistics/vehicleStatistics'), component: _import('statistics/vehicleStatistics'),
name: '车辆统计', name: '车辆统计',
...@@ -749,6 +748,11 @@ export const asyncRouterMap = [{ ...@@ -749,6 +748,11 @@ export const asyncRouterMap = [{
component: _import('financial/staffPerformance'), component: _import('financial/staffPerformance'),
name: '员工业绩报表', name: '员工业绩报表',
authority: 'staffPerformance' authority: 'staffPerformance'
}, {
path: 'memberPerformance',
component: _import('financial/memberPerformance'),
name: '会员统计报表',
authority: 'memberPerformance'
} }
] ]
} }
......
<template>
<div class="app-container calendar-list-container" v-loading="loading">
<el-row style="border-bottom:1px dashed #ccc;padding-bottom:20px">
<el-date-picker v-model="time" type="daterange" placeholder="选择日期范围" @change="changeTime"></el-date-picker>
<el-select v-model="listquery.userPostionId" clearable placeholder="请选择类型" @change="changeStaff">
<el-option v-for="item in options" :key="item.id" :label="item.name" :value="item.id"></el-option>
</el-select>
<el-button type="primary" :loading="excelLoading" @click="downloadExcel">导出报表</el-button>
</el-row>
<div class="information">
<h4>数据概况</h4>
<ul>
<li>
<p>{{information.staffNum}}</p>
<p>会员订单数(单)</p>
</li>
<li>
<p>{{information.totalRoyaltyAmount}}</p>
<p>会员费(元)</p>
</li>
<li>
<p class="memberClass">钻石会员:3单/600.00.00元</p>
<p class="memberClass">黄金会员:3单/600.00.00元</p>
<p class="memberClass">普通会员:3单/600.00.00元</p>
</li>
</ul>
</div>
<el-table :data="tableData" border style="width: 100%" header-align="center" height="450">
<el-table-column prop="name" label="类型" align="center"></el-table-column>
<el-table-column prop="companyNames" label="时间" align="center"></el-table-column>
<el-table-column prop="postionNames" label="订单号" align="center"></el-table-column>
<el-table-column prop="phone" label="会员等级" align="center"></el-table-column>
<el-table-column prop="sellAmount" label="会员姓名" align="center"></el-table-column>
<el-table-column prop="royaltyAmount" label="会员电话" align="center"></el-table-column>
<el-table-column label="邀约人/电话" align="center">
<template scope="scope">
<span>{{scope.row.memberOrderNum}} / {{scope.row.memberAmount}}</span>
</template>
</el-table-column>
<el-table-column label="实付金额" align="center">
<template scope="scope">
<span>{{scope.row.rentVehicleOrderNum}} / {{scope.row.rentVehicleAmount}}</span>
</template>
</el-table-column>
</el-table>
<el-pagination
@size-change="handleSizeChange"
@current-change="handleCurrentChange"
:current-page.sync="listquery.page"
:page-sizes="[10,20,30, 50]"
:page-size="listquery.limit"
layout="total, sizes, prev, pager, next, jumper"
:total="total"
style="margin-top:20px"
></el-pagination>
</div>
</template>
<script>
import { total_statistics, getDate } from 'api/statistics'
import { getrewardSetting } from 'api/purseManage'
export default {
created() {
this.statistics()
this.getList()
},
data() {
return {
loading: false,
total: null,
information: {},
time: [],
tableData: [], //表格数据
excelLoading: false, //导出loading
options: [{
id:'0',
name:'首次购买'
},{
id:'1',
name:'续费'
},{
id:'2',
name:'激活'
},{
id:'3',
name:'付费'
}], //身份
listquery: {
startDate: null, //开始日期
endDate: null, //结束日期
userPostionId: null, //身份
page: 1,
limit: 10
}
}
},
methods: {
handleSizeChange(val) {
this.listquery.limit = val
this.getList()
},
handleCurrentChange(val) {
this.listquery.page = val
this.getList()
},
//时间筛选
changeTime(val, value) {
this.listquery.page = 1
if (!!val) {
let value = val.split(' - ')
this.listquery.startDate = value[0] + ' 00:00:00'
this.listquery.endDate = value[1] + ' 23:59:59'
this.getList()
this.statistics()
} else {
this.listquery.startDate = null
this.listquery.endDate = null
this.getList()
this.statistics()
}
},
//身份筛选
changeStaff() {
this.listquery.page = 1
this.getList()
this.statistics()
},
//统计数据
statistics() {
total_statistics(this.listquery).then(data => {
this.information = data.data
})
},
//列表数据
getList() {
this.loading = true
getDate(this.listquery).then(data => {
if (data.status == 200) {
this.tableData = data.data.data
this.total = data.data.totalCount
}
setTimeout(() => {
this.loading = false
}, 300)
})
},
//导出
downloadExcel() {
this.excelLoading = true
}
}
}
</script>
<style scoped>
.information {
border: 1px solid #ccc;
margin: 20px 0;
padding: 10px 20px;
}
.information h4 {
color: #333;
font-size: 16px;
font-weight: normal;
}
.information ul {
padding: 0;
border-top: 1px solid #eee;
padding: 10px 30px;
overflow: hidden;
}
.information li {
list-style: none;
text-align: center;
float: left;
width: 33.33%;
border-right: 1px solid #eee;
}
.information li:last-child {
border: none;
}
.memberClass{
font-size: 14px;
}
</style>
\ No newline at end of file
...@@ -173,7 +173,7 @@ export default { ...@@ -173,7 +173,7 @@ export default {
//获取身份 //获取身份
getrewardSettingFn() { getrewardSettingFn() {
getrewardSetting().then(data => { getrewardSetting().then(data => {
this.options = data.data this.options = data.data.filter(item => item.id != 6)
}) })
}, },
//导出 //导出
......
...@@ -32,7 +32,7 @@ ...@@ -32,7 +32,7 @@
</el-col> </el-col>
</el-row> </el-row>
</el-form> </el-form>
<el-table :data="list" border fit highlight-current-row style="width: 100%" v-loading="loading"> <el-table :data="list" border fit highlight-current-row v-loading="loading">
<el-table-column align="center" label="时间"> <el-table-column align="center" label="时间">
<template scope="scope"> <template scope="scope">
<span>{{scope.row.timeSlot}}</span> <span>{{scope.row.timeSlot}}</span>
...@@ -99,6 +99,7 @@ export default { ...@@ -99,6 +99,7 @@ export default {
loading: false, loading: false,
total: null, total: null,
list: [], list: [],
scrollTop: '',
// 统计时间筛选 // 统计时间筛选
listQuery: { listQuery: {
time: 'null', time: 'null',
...@@ -211,6 +212,7 @@ export default { ...@@ -211,6 +212,7 @@ export default {
setTimeout(() => { setTimeout(() => {
this.loading = false this.loading = false
}, 300) }, 300)
document.documentElement.scrollTop = 0
}) })
} }
} }
......
...@@ -223,10 +223,23 @@ ...@@ -223,10 +223,23 @@
class="el-button el-button--text el-button--small" class="el-button el-button--text el-button--small"
@click="handleViolatePrice(scope.row)" @click="handleViolatePrice(scope.row)"
>取消订单</el-button> >取消订单</el-button>
<el-button
size="small"
v-if="scope.row.status == 2"
class="el-button el-button--text el-button--small"
@click="breakRecord(scope.row)"
>违约金记录</el-button>
</template> </template>
</el-table-column> </el-table-column>
</el-table> </el-table>
<!-- 违约金记录 -->
<el-dialog title="违约金记录" :visible.sync="breakRecordPop">
<p>取消时间:{{breakRecordData.time}}</p>
<p>违约金额:{{breakRecordData.violateAmount}}</p>
<p>违约内容:{{breakRecordData.violateDesc}}</p>
</el-dialog>
<!--违章查询弹框--> <!--违章查询弹框-->
<Illegal :row="currentRow" v-if="illegalVisible" v-on:illegalEvent="illegalEvent"></Illegal> <Illegal :row="currentRow" v-if="illegalVisible" v-on:illegalEvent="illegalEvent"></Illegal>
<!--查看详情弹框--> <!--查看详情弹框-->
...@@ -602,6 +615,8 @@ export default { ...@@ -602,6 +615,8 @@ export default {
}, },
data() { data() {
return { return {
breakRecordData:{},//违约金记录数据
breakRecordPop:false,//违约金记录弹窗
activeRecord:null, activeRecord:null,
isInline: false, isInline: false,
pictureList: [], pictureList: [],
...@@ -975,6 +990,26 @@ export default { ...@@ -975,6 +990,26 @@ export default {
} }
}, },
methods: { methods: {
//违约金记录
breakRecord(row){
let param = {
"orderNo":row.orderNo,
"flag" : true
}
orderDetail(param).then(data=>{
if (data.status == 200) {
if (!!data.data.orderRentVehicleDetail.costDetailExtend) {
let info = JSON.parse(data.data.orderRentVehicleDetail.costDetailExtend)
this.breakRecordData.time = data.data.updTime,
this.breakRecordData.violateAmount = info.violateAmount
this.breakRecordData.violateDesc = info.violateDesc
this.breakRecordPop = true;
}else{
this.$message.error('暂无违约金记录')
}
}
})
},
//取消订单 //取消订单
cancel(row, changeViolateAmount) { cancel(row, changeViolateAmount) {
let that = this let that = this
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment