点位列表
This commit is contained in:
@ -32,12 +32,12 @@ export default {
|
||||
// 设置上传的请求头部
|
||||
headers: { Authorization: "Bearer " + getToken() },
|
||||
// 上传的地址
|
||||
url: process.env.VUE_APP_BASE_API + "/system/user/importData"
|
||||
url: process.env.VUE_APP_BASE_API + "/ems/pointMatch/importData"
|
||||
},
|
||||
}
|
||||
},
|
||||
methods:{
|
||||
showDialog(row){
|
||||
showDialog(){
|
||||
this.show = true;
|
||||
},
|
||||
//关闭弹窗 重置数据
|
||||
|
||||
@ -13,6 +13,12 @@
|
||||
</el-form-item>
|
||||
</el-form>
|
||||
<el-button type="primary" @click="addDevice" native-type="button">新增设备</el-button>
|
||||
<el-button
|
||||
@click="uploadPointDetail"
|
||||
type="success"
|
||||
plain>
|
||||
上传点位清单
|
||||
</el-button>
|
||||
<el-table
|
||||
class="common-table"
|
||||
:data="tableData"
|
||||
@ -50,7 +56,7 @@
|
||||
<el-table-column
|
||||
fixed="right"
|
||||
label="操作"
|
||||
width="350">
|
||||
width="250">
|
||||
<template slot-scope="scope">
|
||||
<el-button
|
||||
@click="pointDetail(scope.row)"
|
||||
@ -65,13 +71,6 @@
|
||||
size="mini">
|
||||
下载点位清单
|
||||
</el-button>
|
||||
<el-button
|
||||
@click="uploadPointDetail(scope.row)"
|
||||
type="success"
|
||||
plain
|
||||
size="mini">
|
||||
上传点位清单
|
||||
</el-button>
|
||||
<br>
|
||||
<el-button
|
||||
@click="editDevice(scope.row)"
|
||||
@ -123,6 +122,7 @@ import {formatNumber} from "@/filters/ems";
|
||||
import PointTable from './PointTable.vue'
|
||||
import AddDevice from "./AddDevice.vue";
|
||||
import PointUpload from "./PointUpload.vue";
|
||||
import {download} from "@/utils/request";
|
||||
export default {
|
||||
name: "Sblb",
|
||||
components:{AddDevice,PointTable,PointUpload},
|
||||
@ -168,12 +168,15 @@ export default {
|
||||
this.$refs.pointTable.showTable(row)
|
||||
},
|
||||
// 下载点位清单
|
||||
downloadPointDetail(row){
|
||||
|
||||
downloadPointDetail({siteId,deviceCategory,deviceName}){
|
||||
this.download('ems/pointMatch/export', {
|
||||
siteId,
|
||||
deviceCategory
|
||||
}, `点位清单_${deviceName}_${new Date().getTime()}.xlsx`)
|
||||
},
|
||||
// 上传点位清单
|
||||
uploadPointDetail(row){
|
||||
this.$refs.pointUpload.showDialog(row)
|
||||
uploadPointDetail(){
|
||||
this.$refs.pointUpload.showDialog()
|
||||
},
|
||||
clearEditDeviceData(){
|
||||
this.mode = '';
|
||||
|
||||
Reference in New Issue
Block a user