Commit 63dde208 authored by 李苏's avatar 李苏 💬

修改调用接口,定时查询

parent e7a162c0
......@@ -194,6 +194,84 @@
Yszx
},
mounted() {
this.mounted()
/* 刷新频率*/
const DELAY=1000*60*30
this.DELAYNUM=setInterval(()=>{
this.mounted()
},DELAY)
},
destroyed() {
clearInterval(this.DELAYNUM)
},
data() {
return {
/* 定时器id*/
DELAYNUM:null,
/* 两区农电预算一览 */
lqndylName1: '',
lqndylName2: '',
lhName1: '',
lhName2: '',
/* 两区农电预算一览*/
hapm: 1,
/* 加载蒙层*/
isLoading: true,
dialog: {
showDialog: false,
DialogTitle: '测试',
DialogWidth: '40vw'
},
listData: [{
data: 112,
title: '百度'
},
{
data: 112,
title: '谷歌'
},
{
data: 112,
title: '高德'
},
{
data: 112,
title: '医院'
},
{
data: 112,
title: '测试'
},
{
data: 112,
title: '呵呵'
},
{
data: 112,
title: '测速3'
},
{
data: 112,
title: '价格'
},
{
data: 112,
title: '苏州'
},
{
data: 112,
title: '测试1'
},
{
data: 112,
title: '测试2'
}
]
}
},
methods: {
mounted(){
/*初始化*/
/* 地图后端数据*/
doQueryRepDetail({
"sjlx": 'HJ'
......@@ -253,6 +331,7 @@
}
});
})
this.isLoading = false
}
})
......@@ -260,81 +339,10 @@
this.initLqnd2()
this.initslt()
this.isLoading = false
},
data() {
return {
/* 两区农电预算一览 */
lqndylName1: '',
lqndylName2: '',
lhName1: '',
lhName2: '',
/* 两区农电预算一览*/
hapm: 1,
/* 加载蒙层*/
isLoading: true,
dialog: {
showDialog: false,
DialogTitle: '测试',
DialogWidth: '40vw'
},
listData: [{
data: 112,
title: '百度'
},
{
data: 112,
title: '谷歌'
},
{
data: 112,
title: '高德'
},
{
data: 112,
title: '医院'
},
{
data: 112,
title: '测试'
},
{
data: 112,
title: '呵呵'
},
{
data: 112,
title: '测速3'
},
{
data: 112,
title: '价格'
},
{
data: 112,
title: '苏州'
},
{
data: 112,
title: '测试1'
},
{
data: 112,
title: '测试2'
}
]
}
},
methods: {
initLqnd() {
this.$post('hafms/yszhcxlog/query', {
this.$post('hafms/yszhcxlog/queryRepDetail', {
lx: 'A'
}).then(res => {
if (res && res.success && res.data.records && res.data.records.length > 0) {
let newData = res.data.records[0]
this.$post('hafms/yszhcxlog/queryDetail', {
mid: newData.id,
}).then(res => {
if (res.success && res.data.records) {
const {
......@@ -358,17 +366,10 @@
}
}
})
}
})
},
initLqnd2() {
this.$post('hafms/yszhcxlog/query', {
this.$post('hafms/yszhcxlog/queryRepDetail', {
lx: 'B'
}).then(res => {
if (res && res.success && res.data.records && res.data.records.length > 0) {
let newData = res.data.records[0]
this.$post('hafms/yszhcxlog/queryDetail', {
mid: newData.id,
}).then(res => {
if (res.success && res.data.records) {
const {
......@@ -392,9 +393,6 @@
}
}
})
}
})
},
/* 地图标记
淮安供电公司本部,金湖县供电公司,盱眙县供电公司,洪泽县供电公司,涟水县供电公司
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment