拍照装置复位

master
liuyi 2 years ago
parent df34a6f986
commit 7d576c03d7

@ -295,6 +295,16 @@ export function deleteTerminalJoggle(data) {
}); });
} }
//装置复位
export function resetTerminalApi(data) {
return request({
url: "/api/resetTerminal",
method: "post",
data,
headers:{ 'Content-Type': 'application/x-www-form-urlencoded;charset=UTF-8' }
});
}
//图像采集装置设置 列表 //图像采集装置设置 列表
export function getImageResolutionListJoggle(data) { export function getImageResolutionListJoggle(data) {
return request({ return request({

@ -5,6 +5,7 @@
:visible.sync="isShow" :visible.sync="isShow"
:close-on-click-modal="false" :close-on-click-modal="false"
width="660px" width="660px"
@close="handleclose"
> >
<el-form <el-form
label-position="left" label-position="left"
@ -35,7 +36,7 @@
</el-option> </el-option>
</el-select> </el-select>
</el-form-item> </el-form-item>
<el-form-item label="装置ID" prop="cmdid" required> <el-form-item label="装置ID" prop="cmdid">
<el-input v-model="formInfo.cmdid" auto-complete="on"></el-input> <el-input v-model="formInfo.cmdid" auto-complete="on"></el-input>
</el-form-item> </el-form-item>
<!-- <el-form-item label="显示名:" prop="displayName" required> <!-- <el-form-item label="显示名:" prop="displayName" required>
@ -119,10 +120,15 @@ export default {
}, },
}; };
}, },
mounted() {},
created() {},
watch: {},
methods: { methods: {
// //
getdataform(val) { getdataform(val) {
console.log(val); console.log(val);
this.getLine();
this.getChannel();
if (val == null) { if (val == null) {
return (this.formInfo = { return (this.formInfo = {
channelVal: [], channelVal: [],
@ -170,7 +176,7 @@ export default {
.then((res) => { .then((res) => {
this.isShow = false; this.isShow = false;
this.$message.success("修改成功"); this.$message.success("修改成功");
this.$parent.lineList(); this.$parent.terminalList();
}) })
.catch((err) => { .catch((err) => {
this.$message.error("修改失败"); this.$message.error("修改失败");
@ -232,13 +238,10 @@ export default {
hide() { hide() {
this.isShow = false; this.isShow = false;
}, },
}, handleclose(){
mounted() {}, this.$parent.terminalList();
created() { }
this.getChannel(); }
this.getLine();
},
watch: {},
}; };
</script> </script>
<style lang="less"> <style lang="less">

@ -100,7 +100,7 @@
>修改</el-button >修改</el-button
> >
<el-button type="text">装置复位</el-button> <el-button type="text" @click.native.stop="handleDeviceReset(scope.row)">装置复位</el-button>
<el-button type="text">远程升级</el-button> <el-button type="text">远程升级</el-button>
<el-button <el-button
type="text" type="text"
@ -131,7 +131,7 @@
</div> </div>
</template> </template>
<script> <script>
import { getTerminalJoggle, deleteTerminalJoggle } from "@/utils/api/index"; import { getTerminalJoggle, deleteTerminalJoggle, resetTerminalApi } from "@/utils/api/index";
import moment from "moment"; import moment from "moment";
import addPhotoDialog from "./components/addPhotoDialog.vue"; import addPhotoDialog from "./components/addPhotoDialog.vue";
export default { export default {
@ -191,16 +191,24 @@ export default {
handleAddPhoto() { handleAddPhoto() {
this.photoDialogTitle = "新增"; this.photoDialogTitle = "新增";
this.$refs.addPhotoDialogref.display(); this.$refs.addPhotoDialogref.display();
//this.$refs.addlineDialogref.getdataform(null); this.$refs.addPhotoDialogref.getdataform(null);
}, },
//handleResive 线 //handleResive 线
handleRevisePhoto(data) { handleRevisePhoto(data) {
this.photoDialogTitle = "修改"; this.photoDialogTitle = "修改";
this.$refs.addPhotoDialogref.display(); this.$refs.addPhotoDialogref.display();
console.log(data);
this.$refs.addPhotoDialogref.getdataform(data); this.$refs.addPhotoDialogref.getdataform(data);
}, },
//
handleDeviceReset(data){
resetTerminalApi({ cmId: data.cmdid }).then((res) => {
if (res.code == 200) {
this.$message({ message: "装置已复位", type: "success" });
}else{
this.$message({ message: res.msg, type: "error" });
}
}).catch((err) => {});
},
// //handleAddPhoto // //handleAddPhoto
// handleAddPhoto() { // handleAddPhoto() {

@ -78,7 +78,6 @@ export default {
.then((res) => { .then((res) => {
this.infornr = res.data; this.infornr = res.data;
this.queryTime = res.data.queryTime; this.queryTime = res.data.queryTime;
console.log(this.queryTime);
this.timer = window.setInterval(() => { this.timer = window.setInterval(() => {
this.getNewListData(val); this.getNewListData(val);
}, 10000); }, 10000);
@ -105,7 +104,6 @@ export default {
}, },
display() { display() {
this.isShow = true; this.isShow = true;
console.log("aaaaa");
getTerminalInfoJoggle() getTerminalInfoJoggle()
.then(() => {}) .then(() => {})
.catch((err) => {}); .catch((err) => {});

Loading…
Cancel
Save