Blame view

src/views/proportion/proportion.vue 2.82 KB
dc36257f   wwk   后端页面
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
  <template>
  	<div class="container" style="padding: 10px;">
  		<el-form :inline="true" :model="model" class="demo-form-inline">
  		  <el-form-item label="预约ID" v-if="false">
  		    <el-input v-model="model.RecordId" placeholder="预约ID"></el-input>
  		  </el-form-item>
  		  <el-form-item label="用户ID">
  		    <el-input v-model="model.UserId" placeholder="用户ID"></el-input>
  		  </el-form-item>
  		  <el-form-item label="用户名" >
  		    <el-input v-model="model.KeyWord" placeholder="用户名"></el-input>
  		  </el-form-item>
  		  <el-form-item>
  		    <el-button type="primary" @click="onSubmit">查询</el-button>
  		  </el-form-item>
  		</el-form>
  		<el-table :data="DetailModel" border style="width: 100%">
  			<el-table-column fixed prop="date" label="ID" v-if="false">
  				<template slot-scope="scope">
  					{{scope.row.id}}
  				</template>
  			</el-table-column>
  			<el-table-column fixed prop="date" label="预约ID">
  				<template slot-scope="scope">
  					{{scope.row.RecordId}}
  				</template>
  			</el-table-column>
  			<el-table-column prop="name" label="分成金额">
  				<<template slot-scope="scope">
  					¥{{scope.row.Money/100}}
  				</template>
  			</el-table-column>
  			<el-table-column prop="province" label="用户">
  				<<template slot-scope="scope">
  					{{scope.row.OperatinUser}}
  				</template>
  			</el-table-column>
  			<el-table-column prop="city" label="添加时间">
  				<<template slot-scope="scope">
  					{{scope.row.AddTime}}
  				</template>
  			</el-table-column>
  			<el-table-column prop="address" label="用户ID">
  				<<template slot-scope="scope">
  					{{scope.row.UserId}}
  				</template>
  			</el-table-column>
  		</el-table>
  		<el-pagination background layout="prev, pager, next" :total="model.TotalCount" style="text-align: right;margin-top: 10px;" @current-page="Pages">
  		</el-pagination>
  	</div>
  </template>
  
  <script>
  	import {
  		GetListIncomeDetails
  	} from '../../api/incomeDetails.js'
  	import utils from '../../utils/utils.js'
  	export default {
  		data() {
  			return {
  		
  				model: {
  					"RecordId": 0,
  					"UserId": 0,
  					"KeyWord": "",
  					"TotalCount": 0,
  					"PageIndex": 1,
  					"PageSize": 20,
  					"Sort": [{
  						"Field": "",
  						"Type": 0
  					}]
  				},
  				DetailModel:[],
  				
  			}
  		},
  		created() {
  		this.ShowDetail()
  		},
  		methods: {
  			// 提交查询
  			onSubmit(){
  				this.ShowDetail()
  			},
  			Pages(e){
  				this.model.PageIndex=e
  				this.ShowDetail()
  			},
  			handleClick(row) {
  				console.log(row);
  			},
  			//查询所有分成数据
  			ShowDetail() {
  				GetListIncomeDetails(this.model).then(res => {
  					console.log('分成数据', res)
  					res.data.data.rows.forEach((item,index)=>{
  						item.AddTime=utils.formatTime(item.AddTime,"yyyy-MM-dd HH:mm:ss")
  					})
  					this.DetailModel=res.data.data.rows
  					this.model.TotalCount=res.data.data.total
  				})
  			}
  		},
  
  	}
  </script>
  
  <style>
  </style>