|
@@ -117,19 +117,37 @@
|
|
></el-table-column>
|
|
></el-table-column>
|
|
<el-table-column label="操作">
|
|
<el-table-column label="操作">
|
|
<template slot-scope="{ row }">
|
|
<template slot-scope="{ row }">
|
|
- <el-button
|
|
|
|
- size="mini"
|
|
|
|
- type="primary"
|
|
|
|
- @click="handleOpenChannel(row)"
|
|
|
|
- v-if="row.parkId != 0"
|
|
|
|
- >查看车道</el-button
|
|
|
|
- >
|
|
|
|
- <el-button size="mini" type="warning" @click="handleEdit(row)"
|
|
|
|
- >编辑</el-button
|
|
|
|
- >
|
|
|
|
- <el-button size="mini" type="danger" @click="handleDelete(row)"
|
|
|
|
- >删除</el-button
|
|
|
|
- >
|
|
|
|
|
|
+ <el-row>
|
|
|
|
+ <el-col>
|
|
|
|
+ <el-link
|
|
|
|
+ type="primary"
|
|
|
|
+ @click="handleOpenChannel(row)"
|
|
|
|
+ v-if="row.parkId != 0"
|
|
|
|
+ >查看车道</el-link
|
|
|
|
+ >-
|
|
|
|
+ <el-popover
|
|
|
|
+ placement="left"
|
|
|
|
+ width="300"
|
|
|
|
+ trigger="click"
|
|
|
|
+ @show="openQRCode(row)"
|
|
|
|
+ @hide="closeQRCode(row)"
|
|
|
|
+ >
|
|
|
|
+ <div
|
|
|
|
+ :ref="'qrcode_' + row.id"
|
|
|
|
+ style="width: 300px; height: 300px"
|
|
|
|
+ ></div>
|
|
|
|
+ <el-link type="primary" :underline="false" slot="reference"
|
|
|
|
+ >缴费二维码</el-link
|
|
|
|
+ >
|
|
|
|
+ </el-popover>
|
|
|
|
+ </el-col>
|
|
|
|
+ </el-row>
|
|
|
|
+ <el-row>
|
|
|
|
+ <el-col>
|
|
|
|
+ <el-link type="warning" @click="handleEdit(row)">编辑</el-link>-
|
|
|
|
+ <el-link type="danger" @click="handleDelete(row)">删除</el-link>
|
|
|
|
+ </el-col>
|
|
|
|
+ </el-row>
|
|
</template>
|
|
</template>
|
|
</el-table-column>
|
|
</el-table-column>
|
|
</el-table>
|
|
</el-table>
|
|
@@ -150,6 +168,7 @@
|
|
<parkingChannel-list
|
|
<parkingChannel-list
|
|
v-if="showChannelModal"
|
|
v-if="showChannelModal"
|
|
:parkId="parkId"
|
|
:parkId="parkId"
|
|
|
|
+ :companyId="companyId"
|
|
@close="onDetailModalClose"
|
|
@close="onDetailModalClose"
|
|
></parkingChannel-list>
|
|
></parkingChannel-list>
|
|
</div>
|
|
</div>
|
|
@@ -159,6 +178,7 @@ import Constant from "@/constant";
|
|
import ParkingInfoDetail from "./parkingInfo-detail";
|
|
import ParkingInfoDetail from "./parkingInfo-detail";
|
|
import ParkingChannelList from "./parkingChannel-list";
|
|
import ParkingChannelList from "./parkingChannel-list";
|
|
import parkingInfoApi from "@/api/base/parkingInfo";
|
|
import parkingInfoApi from "@/api/base/parkingInfo";
|
|
|
|
+import QRCode from "qrcodejs2";
|
|
import NProgress from "nprogress"; // progress bar
|
|
import NProgress from "nprogress"; // progress bar
|
|
import "nprogress/nprogress.css"; // progress bar style
|
|
import "nprogress/nprogress.css"; // progress bar style
|
|
import SelectTree from "@/components/SelectTree";
|
|
import SelectTree from "@/components/SelectTree";
|
|
@@ -287,6 +307,7 @@ export default {
|
|
},
|
|
},
|
|
handleOpenChannel(record) {
|
|
handleOpenChannel(record) {
|
|
this.parkId = record.parkId;
|
|
this.parkId = record.parkId;
|
|
|
|
+ this.companyId = record.companyId;
|
|
this.showChannelModal = true;
|
|
this.showChannelModal = true;
|
|
},
|
|
},
|
|
handleDelete(record) {
|
|
handleDelete(record) {
|
|
@@ -350,6 +371,28 @@ export default {
|
|
this.changePage(this.pageIndex);
|
|
this.changePage(this.pageIndex);
|
|
}
|
|
}
|
|
},
|
|
},
|
|
|
|
+ openQRCode(record) {
|
|
|
|
+ //el.innerHTML = "";
|
|
|
|
+ var self = this;
|
|
|
|
+ self.$refs["qrcode_" + record.id].innerHTML = "";
|
|
|
|
+ //非设备扫码
|
|
|
|
+ var qrtext =
|
|
|
|
+ process.env.VUE_APP_PARKING_PAY_ULR + "?companyId=" + record.companyId;
|
|
|
|
+
|
|
|
|
+ var el = self.$refs["qrcode_" + record.id];
|
|
|
|
+
|
|
|
|
+ var qr = new QRCode(el, {
|
|
|
|
+ text: qrtext,
|
|
|
|
+ width: 300,
|
|
|
|
+ height: 300,
|
|
|
|
+ colorDark: "#333333", //二维码颜色
|
|
|
|
+ colorLight: "#ffffff", //二维码背景色
|
|
|
|
+ correctLevel: QRCode.CorrectLevel.L, //容错率,L/M/H
|
|
|
|
+ });
|
|
|
|
+ },
|
|
|
|
+ closeQRCode(record) {
|
|
|
|
+ self.$refs["qrcode_" + record.id].innerHTML = "";
|
|
|
|
+ },
|
|
},
|
|
},
|
|
mounted: function () {
|
|
mounted: function () {
|
|
this.changePage(1);
|
|
this.changePage(1);
|