This commit is contained in:
parent
adba793b86
commit
e693d9b8be
|
|
@ -146,7 +146,7 @@
|
|||
//配置跨域
|
||||
"proxy" : {
|
||||
"/api" : {
|
||||
"target" : "http://192.168.1.7:9005",
|
||||
"target" : "http://speed-bl.renyizhi.cc",
|
||||
"changeOrigin" : true,
|
||||
"secure" : false
|
||||
}
|
||||
|
|
|
|||
|
|
@ -14,7 +14,7 @@
|
|||
</view>
|
||||
<view class="reset" @click="emptydata">重置</view>
|
||||
</view>
|
||||
<scroll-view :scroll-y="true" class="scroll-view" @scrolltolower='bottomingOut'>
|
||||
<scroll-view :scroll-y="true" :scroll-top="scroll" class="scroll-view" @scrolltolower='bottomingOut'>
|
||||
<view v-for="item in list" class="item" @click="openinfo(item.encoding)">
|
||||
<view class="left">
|
||||
<view class="t">
|
||||
|
|
@ -111,8 +111,11 @@
|
|||
queryDate:queryDate.value,
|
||||
vehicleNumber:vehicleNumber.value
|
||||
}).then(r=>{
|
||||
|
||||
list.value=list.value.concat(r.data.data);
|
||||
hasNextPage.value=r.data.hasNextPage;
|
||||
}).catch(res=>{
|
||||
console.log(res,'错误了')
|
||||
})
|
||||
}
|
||||
// 重置
|
||||
|
|
@ -125,6 +128,8 @@
|
|||
pageNum.value=1;
|
||||
list.value=[];
|
||||
}
|
||||
let _clet;
|
||||
|
||||
// 触底
|
||||
function bottomingOut(){
|
||||
if(hasNextPage.value){
|
||||
|
|
|
|||
|
|
@ -96,6 +96,20 @@
|
|||
getinfo()
|
||||
}
|
||||
}
|
||||
|
||||
// 监听推送数据
|
||||
let _clet;
|
||||
uni.onSkt("SERCHNEWDATA", (res) => {
|
||||
// console.log(res)
|
||||
// scroll.value=10;
|
||||
list.value = [...res, ...list.value]
|
||||
// clearTimeout(_clet)
|
||||
// _clet=setTimeout(()=>{
|
||||
// scroll.value=0;
|
||||
// },500)
|
||||
// 预警列表接收推送数据
|
||||
})
|
||||
|
||||
// 重置
|
||||
function reset(){
|
||||
hasNextPage.value=true;
|
||||
|
|
|
|||
|
|
@ -181,6 +181,9 @@
|
|||
|
||||
function show() {
|
||||
getinfo()
|
||||
// #ifdef APP
|
||||
uni.setAppBadgeNumber(0)
|
||||
// #endif
|
||||
}
|
||||
|
||||
const itemanimation=ref(false)
|
||||
|
|
|
|||
Loading…
Reference in New Issue