master
fanluyan 2 years ago
parent c6b205a5c4
commit 03c1faef63

@ -45,9 +45,9 @@
class="custom-tree-node" class="custom-tree-node"
slot-scope="{ data }" slot-scope="{ data }"
> >
<span class="mr10">{{ data.name }}</span> <span class="mr10">{{ data.name }}--{{ data.id }}</span>
<el-tag size="mini" type="success" v-if="zzsuccess" <el-tag size="mini" type="success" v-if="zzsuccess"
>装置下发</el-tag >装置下发成功</el-tag
> >
<el-tag size="mini" v-if="zzpending"></el-tag> <el-tag size="mini" v-if="zzpending"></el-tag>
<el-tag size="mini" type="danger" v-if="zzerror" <el-tag size="mini" type="danger" v-if="zzerror"

@ -19,18 +19,37 @@
:value="item.channelid" :value="item.channelid"
></el-option> ></el-option>
</el-select> </el-select>
<el-button type="primary" @click="inquirebtn()"></el-button> <el-button
:loading="searchloading"
type="primary"
@click="inquirebtn()"
>查询</el-button
>
</div> </div>
<div class="flexno bt30"> <div class="flexno bt30">
<div class="wt80">色彩选择:</div> <div class="wt80">色彩选择:</div>
<el-select v-model="capturenr.color" class="wt280" :disabled="true" > <el-select v-model="capturenr.color" class="wt280" :disabled="true">
<el-option v-for="item in colorlist" :key="item.id" :label="item.name" :value="item.id" ></el-option> <el-option
v-for="item in colorlist"
:key="item.id"
:label="item.name"
:value="item.id"
></el-option>
</el-select> </el-select>
</div> </div>
<div class="flexno bt30"> <div class="flexno bt30">
<div class="wt80">图像分辨率:</div> <div class="wt80">图像分辨率:</div>
<el-select v-model="capturenr.resolution" class="wt280" :disabled="true" > <el-select
<el-option v-for="item in ratiolist" :key="item.id" :label="item.name" :value="item.id" ></el-option> v-model="capturenr.resolution"
class="wt280"
:disabled="true"
>
<el-option
v-for="item in ratiolist"
:key="item.id"
:label="item.name"
:value="item.id"
></el-option>
</el-select> </el-select>
</div> </div>
<div class="flexno bt30"> <div class="flexno bt30">
@ -152,6 +171,7 @@ export default {
return { return {
loading: false, loading: false,
isShow: false, isShow: false,
searchloading: false,
activeName: "1", // activeName: "1", //
accesslist: [], // accesslist: [], //
colorlist: [ colorlist: [
@ -221,6 +241,7 @@ export default {
// //
inquirebtn() { inquirebtn() {
this.loading = true; this.loading = true;
this.searchloading = true;
getPhotoParamApi({ getPhotoParamApi({
channelId: this.selaccess, channelId: this.selaccess,
cmdId: this.selcmdId, cmdId: this.selcmdId,
@ -232,7 +253,7 @@ export default {
this.timer = window.setInterval(() => { this.timer = window.setInterval(() => {
this.inquirenr(); this.inquirenr();
this.i++; this.i++;
}, 10000); }, 1000);
} else { } else {
this.$message.error(res.code.msg); this.$message.error(res.code.msg);
} }
@ -251,11 +272,16 @@ export default {
if (res.code == 200) { if (res.code == 200) {
this.capturenr = res.data; this.capturenr = res.data;
if (res.data.isNew == true) { if (res.data.isNew == true) {
this.searchloading = false;
this.i = 0;
this.$message.success("查询已更新"); this.$message.success("查询已更新");
clearInterval(this.timer); clearInterval(this.timer);
this.timer = null; this.timer = null;
} else if (this.i > 9) { } else if (this.i > 9) {
this.searchloading = false;
this.i = 0;
this.$message.warning("暂无响应,请稍后再试!"); this.$message.warning("暂无响应,请稍后再试!");
clearInterval(this.timer); clearInterval(this.timer);
this.timer = null; this.timer = null;
} }
@ -295,6 +321,8 @@ export default {
this.isShow = false; this.isShow = false;
}, },
handleclose() { handleclose() {
this.searchloading = false;
this.i = 0;
clearInterval(this.timer); clearInterval(this.timer);
this.timer = null; this.timer = null;
}, },

@ -100,16 +100,17 @@ export default {
if (res.code == 200) { if (res.code == 200) {
this.infornr = res.data; this.infornr = res.data;
if (res.data.isNew == true) { if (res.data.isNew == true) {
this.i = 0;
this.$message.success("装置信息已更新"); this.$message.success("装置信息已更新");
clearInterval(this.timer); clearInterval(this.timer);
} else if(this.i > 9) { } else if (this.i > 9) {
this.i = 0;
this.$message.warning("暂无响应,请稍后再试!"); this.$message.warning("暂无响应,请稍后再试!");
clearInterval(this.timer); clearInterval(this.timer);
} }
} else { } else {
this.$message.error(res.code.msg); this.$message.error(res.code.msg);
} }
}) })
.catch((err) => {}); .catch((err) => {});
}, },
@ -120,7 +121,9 @@ export default {
this.isShow = false; this.isShow = false;
}, },
handleclose() { handleclose() {
this.i = 0;
clearInterval(this.timer); clearInterval(this.timer);
this.timer = null;
}, },
}, },
}; };

Loading…
Cancel
Save