master
fanluyan 2 years ago
parent cb1fde7cf3
commit 5e38d5e48a

@ -5,9 +5,9 @@
<div class="content-box"> <div class="content-box">
<div class="content"> <div class="content">
<transition name="move" mode="out-in"> <transition name="move" mode="out-in">
<keep-alive> <!-- <keep-alive> -->
<router-view></router-view> <router-view></router-view>
</keep-alive> <!-- </keep-alive> -->
</transition> </transition>
</div> </div>
</div> </div>

@ -664,3 +664,23 @@ export function issueApk(data) {
data, data,
}); });
} }
//全局设置线缆绘制
export function getMarkEnableStatus(data) {
return request({
url: "/api/getMarkEnableStatus",
method: "post",
data,
});
}
//全局更新设置线缆绘制
export function updateMarkEnableStatus(data) {
return request({
url: "/api/updateMarkEnableStatus",
method: "post",
data,
headers: {
"Content-Type": "application/x-www-form-urlencoded;charset=UTF-8",
},
});
}

@ -2,19 +2,22 @@
<el-dialog <el-dialog
title="历史图片" title="历史图片"
:visible.sync="isShow" :visible.sync="isShow"
:close-on-click-modal="false" class="historyPic"
width="80%" width="1192px"
@close="handleclose"
> >
<el-carousel <div v-loading="loading">
:loop="false" <el-carousel
:autoplay="false" :loop="false"
height="600px" :autoplay="false"
indicator-position="none" height="650px"
> indicator-position="none"
<el-carousel-item v-for="(item, index) in imglist" :key="index"> >
<el-image :src="item.path" fit="contain"></el-image> <el-carousel-item v-for="(item, index) in imglist" :key="index">
</el-carousel-item> <el-image :src="item.path" fit="contain"></el-image>
</el-carousel> </el-carousel-item>
</el-carousel>
</div>
</el-dialog> </el-dialog>
</template> </template>
<script> <script>
@ -28,6 +31,7 @@ export default {
pageSize: 10, // pageSize: 10, //
total: 0, // total: 0, //
selectnr: "", // selectnr: "", //
loadingpic: true,
}; };
}, },
mounted() {}, mounted() {},
@ -35,12 +39,14 @@ export default {
// //
getdataform(val) { getdataform(val) {
this.selectnr = val; this.selectnr = val;
this.loadingpic = true;
getHistoryList({ getHistoryList({
channelId: this.selectnr.channelId, channelId: this.selectnr.channelId,
termId: this.selectnr.termId, termId: this.selectnr.termId,
pageindex: this.page, pageindex: this.page,
pagesize: this.pageSize, pagesize: this.pageSize,
}).then((res) => { }).then((res) => {
this.loadingpic = false;
this.imglist = res.data.list; this.imglist = res.data.list;
this.total = res.data.total; this.total = res.data.total;
}); });
@ -58,7 +64,7 @@ export default {
}).then((res) => { }).then((res) => {
this.imglist.push(res.data.list); this.imglist.push(res.data.list);
this.total = res.data.total; this.total = res.data.total;
console.log(this.imglist) console.log(this.imglist);
console.log(e); console.log(e);
}); });
} }
@ -68,12 +74,24 @@ export default {
}, },
hide() { hide() {
this.isShow = false; this.isShow = false;
this.imglist = [];
},
handleclose() {
this.isShow = false;
this.imglist = [];
}, },
}, },
}; };
</script> </script>
<style lang="less" scoped> <style lang="less">
.imgnr { .historyPic {
height: 600px; .el-image {
width: 1152px;
height: 648px;
img {
width: 1152px;
height: 648px;
}
}
} }
</style> </style>

@ -165,13 +165,18 @@
</div> </div>
<div class="alarmPic"> <div class="alarmPic">
<div class="imgshow" @click="handleBigPicbox(selectRow)"> <div class="imgshow" @click="handleBigPicbox(selectRow)">
<div
class="picshow"
v-if="selectRow.path !== '' && tableData.length !== 0"
>
<img ref="picJpg" :src="photoPic" />
<canvas id="myCanvas" class="myCanvas" ref="myCanvas"></canvas>
</div>
<img <img
ref="picJpg" ref="picJpg"
:src="photoPic" src="../../assets/img/nopic.jpg"
v-if="selectRow.path !== '' && tableData.length !== 0" v-if="selectRow.path == '' || tableData.length == 0"
/> />
<img ref="picJpg" src="../../assets/img/nopic.jpg" v-else />
<canvas id="myCanvas" class="myCanvas" ref="myCanvas"></canvas>
</div> </div>
<div class="editorBtn"> <div class="editorBtn">
<el-button <el-button
@ -225,10 +230,10 @@ export default {
gtOptions: [{ id: 0, name: "全部" }], // gtOptions: [{ id: 0, name: "全部" }], //
gjOptions: [{ id: 0, label: -1, name: "全部" }], // gjOptions: [{ id: 0, label: -1, name: "全部" }], //
formdata: { formdata: {
dyId: "", dyId: 0,
lineId: "", lineId: 0,
towerId: "", towerId: 0,
label: "", label: -1,
timeVal: "", timeVal: "",
}, },
photoPic: "", photoPic: "",
@ -253,8 +258,9 @@ export default {
new Date(new Date().toLocaleDateString()).getTime(), new Date(new Date().toLocaleDateString()).getTime(),
new Date().getTime(), new Date().getTime(),
]); ]);
// this.getTableList();
this.getSearchdy(); this.getSearchdy();
this.getTableList();
}, },
methods: { methods: {
handleBigPicbox(val) { handleBigPicbox(val) {
@ -311,17 +317,12 @@ export default {
console.log(this.gjOptions); console.log(this.gjOptions);
this.formdata.label = this.gjOptions[0].label; this.formdata.label = this.gjOptions[0].label;
console.log(this.formdata.label); console.log(this.formdata.label);
this.getTableList();
}) })
.catch((err) => {}); .catch((err) => {});
}, },
// //
getTableList() { getTableList() {
this.loading = true; this.loading = true;
// this.$set(this.formdata, "dyId", this.page);
// this.$set(this.formdata, "label", this.page);
// this.$set(this.formdata, "lineId", this.page);
// this.$set(this.formdata, "towerId", this.page);
this.$set(this.formdata, "pageindex", this.page); this.$set(this.formdata, "pageindex", this.page);
this.$set(this.formdata, "pagesize", this.pageSize); this.$set(this.formdata, "pagesize", this.pageSize);
this.$set(this.formdata, "starttime", this.formdata.timeVal[0]); this.$set(this.formdata, "starttime", this.formdata.timeVal[0]);
@ -334,12 +335,10 @@ export default {
this.photoPic = res.data.list[0].path; this.photoPic = res.data.list[0].path;
this.selectRow = res.data.list[0]; this.selectRow = res.data.list[0];
console.log(this.selectRow); console.log(this.selectRow);
this.drawline(this.selectRow);
this.$nextTick(() => { // ref myTableref
// ref myTableref this.$refs.multipleTable.setCurrentRow(this.selectRow);
this.$refs.multipleTable.setCurrentRow(this.selectRow); this.handleRowClick(this.selectRow);
this.handleRowClick(this.selectRow);
});
}) })
.catch((err) => { .catch((err) => {
console.log(err); console.log(err);
@ -416,7 +415,9 @@ export default {
}); });
}, 300); }, 300);
} }
this.drawline(row); this.$nextTick(() => {
this.drawline(row);
});
}, },
// //
handleCommandpic() { handleCommandpic() {
@ -484,7 +485,7 @@ export default {
}, },
}; };
</script> </script>
<style lang="less" scoped> <style lang="less">
.alarmHandBox { .alarmHandBox {
width: calc(100% - 32px); width: calc(100% - 32px);
height: calc(100% - 32px); height: calc(100% - 32px);
@ -597,6 +598,12 @@ export default {
width: 100%; width: 100%;
height: 100%; height: 100%;
position: relative; position: relative;
.picshow {
width: 100%;
height: 100%;
position: relative;
}
img { img {
width: 100%; width: 100%;
height: 100%; height: 100%;

@ -166,7 +166,7 @@
</template> </template>
<script> <script>
import { getCoordinate } from "@/utils/api/index"; import { getCoordinate, updateMarkEnableStatus } from "@/utils/api/index";
export default { export default {
components: {}, components: {},
props: { props: {
@ -206,6 +206,7 @@ export default {
num: "", num: "",
showBigpic: false, showBigpic: false,
flagline: true, flagline: true,
markEnable: "",
}; };
}, },
mounted() { mounted() {
@ -226,7 +227,10 @@ export default {
this.localPoints = res.data.list; this.localPoints = res.data.list;
this.color = res.data.color; this.color = res.data.color;
this.num = res.data.boderWidth; this.num = res.data.boderWidth;
this.drawline(); this.markEnable = res.data.markEnable;
if (this.markEnable === 1) {
this.drawline();
}
}) })
.catch((err) => {}); .catch((err) => {});
}, },
@ -248,6 +252,11 @@ export default {
openline() { openline() {
this.flagline = true; this.flagline = true;
console.log("11111111111111111111111111", this.flagline); console.log("11111111111111111111111111", this.flagline);
updateMarkEnableStatus({
status: 1,
}).then((res) => {
console.log(res);
});
this.drawline(); this.drawline();
}, },
drawline() { drawline() {
@ -288,6 +297,11 @@ export default {
handelClear() { handelClear() {
this.ctx.clearRect(0, 0, this.canvas.width, this.canvas.height); this.ctx.clearRect(0, 0, this.canvas.width, this.canvas.height);
this.flagline = false; this.flagline = false;
updateMarkEnableStatus({
status: 0,
}).then((res) => {
console.log(res);
});
}, },
getphotoList() { getphotoList() {
this.fiveList = this.terminalPhoto.slice( this.fiveList = this.terminalPhoto.slice(
@ -358,7 +372,10 @@ export default {
.then((res) => { .then((res) => {
console.log(res); console.log(res);
this.localPoints = res.data.list; this.localPoints = res.data.list;
this.drawline(); if (this.markEnable === 1) {
this.drawline();
}
// this.drawline();
}) })
.catch((err) => {}); .catch((err) => {});
}, },
@ -384,7 +401,10 @@ export default {
.then((res) => { .then((res) => {
console.log(res); console.log(res);
this.localPoints = res.data.list; this.localPoints = res.data.list;
this.drawline(); if (this.markEnable === 1) {
this.drawline();
}
// this.drawline();
}) })
.catch((err) => {}); .catch((err) => {});
}, },
@ -405,7 +425,10 @@ export default {
.then((res) => { .then((res) => {
console.log(res); console.log(res);
this.localPoints = res.data.list; this.localPoints = res.data.list;
this.drawline(); if (this.markEnable === 1) {
this.drawline();
}
// this.drawline();
}) })
.catch((err) => {}); .catch((err) => {});
}, },

@ -41,7 +41,11 @@
show-overflow-tooltip show-overflow-tooltip
></el-table-column> ></el-table-column>
<el-table-column prop="order" label="排序号"></el-table-column> <el-table-column prop="order" label="排序号">
<template slot-scope="scope">
{{ scope.row.order == null ? 0 : scope.row.order }}
</template>
</el-table-column>
<el-table-column fixed="right" label="操作" width="200"> <el-table-column fixed="right" label="操作" width="200">
<template slot-scope="scope"> <template slot-scope="scope">

@ -38,7 +38,12 @@
</div> </div>
</template> </template>
<script> <script>
import { getAlarmTypeList, updateAlarmTypeList } from "@/utils/api/index"; import {
getAlarmTypeList,
updateAlarmTypeList,
getMarkEnableStatus,
updateMarkEnableStatus,
} from "@/utils/api/index";
export default { export default {
components: {}, components: {},
@ -51,8 +56,22 @@ export default {
}, },
created() { created() {
this.getalarmList(); this.getalarmList();
this.getmark();
}, },
methods: { methods: {
//
getmark() {
getMarkEnableStatus()
.then((res) => {
console.log(res);
if (res.data === 1) {
this.lineValue = true;
} else {
this.lineValue = false;
}
})
.catch((err) => {});
},
//线 //线
showLine(val) { showLine(val) {
if (val) { if (val) {
@ -60,9 +79,16 @@ export default {
} else { } else {
this.lineNum = 0; this.lineNum = 0;
} }
updateMarkEnableStatus({
status: this.lineNum,
})
.then((res) => {
console.log(res);
})
.catch((err) => {});
console.log(val, this.lineNum, "开关"); console.log(val, this.lineNum, "开关");
}, },
//
getalarmList() { getalarmList() {
getAlarmTypeList().then((res) => { getAlarmTypeList().then((res) => {
console.log(res); console.log(res);

@ -29,7 +29,7 @@ module.exports = defineConfig({
"/api": { "/api": {
//表示拦截以/api开头的请求路径 //表示拦截以/api开头的请求路径
target: "http://47.96.238.157:8093", //阿里云服务器环境 target: "http://47.96.238.157:8093", //阿里云服务器环境
// target: "http://180.166.218.222:40080", //dell //target: "http://180.166.218.222:40080", //dell
changOrigin: true, //是否开启跨域 changOrigin: true, //是否开启跨域
pathRewrite: { pathRewrite: {
"^/api": "", //重写api把api变成空字符因为我们真正请求的路径是没有api的 "^/api": "", //重写api把api变成空字符因为我们真正请求的路径是没有api的

Loading…
Cancel
Save