This commit is contained in:
duanliang
2025-04-23 08:19:30 +08:00
parent df98711a38
commit 55ca8b0e74
3 changed files with 12 additions and 2 deletions

View File

@@ -107,8 +107,9 @@
watch( watch(
() => props.dataList, () => props.dataList,
(newVal) => { (newVal) => {
console.log(chartVal.value,newVal,'newValnewValnewValnewValnewVal')
aIndex+=1 aIndex+=1
if(aIndex>=3&&!newVal.length){ if(aIndex>=3&&!newVal.length){
condShow.value = 1 condShow.value = 1
} }

View File

@@ -47,6 +47,7 @@
condShow.value = 1 condShow.value = 1
} }
if (val.length > 0) { if (val.length > 0) {
condShow.value = 2
setTimeout(() => { setTimeout(() => {
init() init()
}, 1000) }, 1000)

View File

@@ -116,13 +116,21 @@
let res = await getHotNewApi() let res = await getHotNewApi()
hotNewList.value = res.data hotNewList.value = res.data
} }
let timer = null
onMounted(() => { onMounted(() => {
getStop() getStop()
getHotNew() getHotNew()
getTotal() getTotal()
timer = setInterval(()=>{
getState() getState()
},2000)
getLineChart() getLineChart()
}) })
onUnmounted(() => {
if (timer) clearInterval(timer)
})
</script> </script>
<style scoped lang="scss"> <style scoped lang="scss">