|
@@ -0,0 +1,207 @@
|
|
|
+<template>
|
|
|
+ <div class="cityResource-tableSetting">
|
|
|
+
|
|
|
+ <el-card>
|
|
|
+ <el-form ref="tableFormData" class="topFormStyle2" :inline="true" :model="tableFormData" label-width="120px">
|
|
|
+ <el-form-item label="表格时间选择" >
|
|
|
+ <el-date-picker
|
|
|
+ v-model="tableFormData.startTime"
|
|
|
+ type="date"
|
|
|
+ placeholder="开始时间"
|
|
|
+ prefix-icon="dateIcon"
|
|
|
+ format="yyyy/MM/dd"
|
|
|
+ value-format="yyyy-MM-dd"
|
|
|
+ >
|
|
|
+ </el-date-picker>
|
|
|
+ <el-date-picker
|
|
|
+ style="width: 200px;margin-left: 15px;"
|
|
|
+ v-model="tableFormData.endTime"
|
|
|
+ type="date"
|
|
|
+ placeholder="结束时间"
|
|
|
+ prefix-icon="dateIcon"
|
|
|
+ format="yyyy/MM/dd"
|
|
|
+ value-format="yyyy-MM-dd"
|
|
|
+ >
|
|
|
+ </el-date-picker>
|
|
|
+ </el-form-item>
|
|
|
+ <el-form-item style="float: right;margin-right: 20px;">
|
|
|
+ <el-button style="width: 100px;" type="primary" @click="searchTableData">确定时间</el-button>
|
|
|
+ </el-form-item>
|
|
|
+ </el-form>
|
|
|
+ <el-table
|
|
|
+ :data="tableData"
|
|
|
+ :header-cell-style="rowClass"
|
|
|
+ :row-style="rowStyle"
|
|
|
+ style="width: 100%">
|
|
|
+ <el-table-column
|
|
|
+ prop="id"
|
|
|
+ label="id"
|
|
|
+ align="center"
|
|
|
+ width="auto">
|
|
|
+ </el-table-column>
|
|
|
+ <el-table-column
|
|
|
+ prop="areaName"
|
|
|
+ label="区域名称"
|
|
|
+ align="center"
|
|
|
+ width="auto">
|
|
|
+ </el-table-column>
|
|
|
+ <el-table-column
|
|
|
+ prop="transactionAmount"
|
|
|
+ label="交易金额"
|
|
|
+ align="center"
|
|
|
+ width="auto">
|
|
|
+ <template slot-scope="scope">
|
|
|
+ <span>{{ scope.row.transactionAmount }} 元</span>
|
|
|
+ </template>
|
|
|
+ </el-table-column>
|
|
|
+ <el-table-column
|
|
|
+ prop="saveAmount"
|
|
|
+ label="节约金额"
|
|
|
+ align="center"
|
|
|
+ width="auto">
|
|
|
+ <template slot-scope="scope">
|
|
|
+ <span>{{ scope.row.saveAmount }} 元</span>
|
|
|
+ </template>
|
|
|
+ </el-table-column>
|
|
|
+ <el-table-column
|
|
|
+ prop="transactionCount"
|
|
|
+ label="交易宗数"
|
|
|
+ align="center"
|
|
|
+ width="auto">
|
|
|
+ <template slot-scope="scope">
|
|
|
+ <span>{{ scope.row.transactionCount }} 件</span>
|
|
|
+ </template>
|
|
|
+ </el-table-column>
|
|
|
+ <el-table-column
|
|
|
+ prop="transactionType"
|
|
|
+ label="交易类别"
|
|
|
+ align="center"
|
|
|
+ width="auto">
|
|
|
+ <template slot-scope="scope">
|
|
|
+ <div>
|
|
|
+ <!-- 根据 transactionType 的值来渲染不同的内容 -->
|
|
|
+ <span v-if="scope.row.transactionType === 0">工程建设</span>
|
|
|
+ <span v-else-if="scope.row.transactionType === 1">政府采购</span>
|
|
|
+ <span v-else-if="scope.row.transactionType === 2">土地矿权</span>
|
|
|
+ <span v-else-if="scope.row.transactionType === 3">资源财产</span>
|
|
|
+ <span v-else-if="scope.row.transactionType === 4">其他交易</span>
|
|
|
+ </div>
|
|
|
+ </template>
|
|
|
+ </el-table-column>
|
|
|
+ <el-table-column
|
|
|
+ prop="statDate"
|
|
|
+ label="统计时间"
|
|
|
+ align="center"
|
|
|
+ width="auto">
|
|
|
+ </el-table-column>
|
|
|
+ <el-table-column
|
|
|
+ prop="budgetAmount"
|
|
|
+ label="预算金额"
|
|
|
+ align="center"
|
|
|
+ width="auto">
|
|
|
+ <template slot-scope="scope">
|
|
|
+ <span>{{ scope.row.budgetAmount }} 元</span>
|
|
|
+ </template>
|
|
|
+ </el-table-column>
|
|
|
+ </el-table>
|
|
|
+
|
|
|
+ <el-row>
|
|
|
+ <el-col :span="20">
|
|
|
+ <comp-page
|
|
|
+ @handleCurrentChange="handleCurrentChange"
|
|
|
+ :current-page="page"
|
|
|
+ :totalCount="totalCount"
|
|
|
+ style="margin-left: 18px;margin-top: 20px"
|
|
|
+ ></comp-page>
|
|
|
+ </el-col>
|
|
|
+ </el-row>
|
|
|
+ </el-card>
|
|
|
+ </div>
|
|
|
+ </template>
|
|
|
+
|
|
|
+ <script>
|
|
|
+ import compPage from 'pkgs/components/pagination/index';
|
|
|
+ import {areaTransactionList} from './areaTransactionList.js'
|
|
|
+ import ElSwitch from "element-ui/packages/switch/src/component";
|
|
|
+
|
|
|
+ export default {
|
|
|
+ name: 'areaTransactionList',
|
|
|
+ data() {
|
|
|
+ return {
|
|
|
+ tableFormData: {
|
|
|
+ startTime: '',
|
|
|
+ endTime: '',
|
|
|
+ },
|
|
|
+ typeSelect: 'date',
|
|
|
+ dateFormat: 'yyyy-MM-dd',
|
|
|
+ page: 1,
|
|
|
+ totalCount: 20,
|
|
|
+ pageSize: 5,
|
|
|
+ tableData: [],
|
|
|
+ optionRole: [],
|
|
|
+ }
|
|
|
+ },
|
|
|
+ components: {
|
|
|
+ ElSwitch,
|
|
|
+ compPage
|
|
|
+ },
|
|
|
+ watch: {
|
|
|
+ mouseOver(newVal) {
|
|
|
+ if (newVal === true) this.buttClass = 'another';
|
|
|
+ else this.buttClass = 'white'
|
|
|
+ }
|
|
|
+ },
|
|
|
+ mounted() {
|
|
|
+ this.getTableData();
|
|
|
+ this.getRole();
|
|
|
+ },
|
|
|
+ methods: {
|
|
|
+ /** 表格获取数据 */
|
|
|
+ getTableData: function () {
|
|
|
+ areaTransactionList.getAreaTransactionList({pageNum: this.page, pageSize: 5, startDate: this.tableFormData.startTime, endDate: this.tableFormData.endTime}).then(res => {
|
|
|
+ this.tableData = res.data.result;
|
|
|
+ this.totalCount = res.data.pageMessage.total;
|
|
|
+ this.page = res.data.pageMessage.pageNum;
|
|
|
+ })
|
|
|
+ },
|
|
|
+ /** 分页 */
|
|
|
+ handleCurrentChange: function (val) {
|
|
|
+ this.page = val;
|
|
|
+ this.getTableData();
|
|
|
+ },
|
|
|
+ /**确认时间,查询表格数据*/
|
|
|
+ searchTableData: function () {
|
|
|
+ this.getTableData();
|
|
|
+ },
|
|
|
+ }
|
|
|
+ }
|
|
|
+ </script>
|
|
|
+ <style scoped>
|
|
|
+ .el-card {
|
|
|
+ border-radius: 0;
|
|
|
+ background-color: white;
|
|
|
+ }
|
|
|
+
|
|
|
+ .el-tag {
|
|
|
+ border-radius: 0;
|
|
|
+ font-size: 12.5px;
|
|
|
+ border-color: #d8d8d8;
|
|
|
+ width: 80%;
|
|
|
+ height: 36px;
|
|
|
+ color: #333333;
|
|
|
+ padding-top: 4px;
|
|
|
+ padding-left: 17px;
|
|
|
+ background-color: gainsboro;
|
|
|
+ }
|
|
|
+
|
|
|
+ .another {
|
|
|
+ background-color: #3448a1;
|
|
|
+ float: right;
|
|
|
+ margin-top: 20px;
|
|
|
+ color: #ffffff;
|
|
|
+ }
|
|
|
+ .cityResource-tableSetting {
|
|
|
+ background-color: white;
|
|
|
+ padding-bottom: 20px;
|
|
|
+ }
|
|
|
+ </style>
|