@ -1,6 +1,7 @@
< template >
< WeatherAndTime :mall-code ="mallCode" / >
< ScrollList ref = "scrollList" :customer-list ="customerList" :mall-code ="mallCode" / >
< img src = "./assets/images/back_index_icon.svg" class = "fixed bottom-3 left-3 w-28 h-12" alt = "" @click ="back" / >
< / template >
< script setup lang = "ts" >
import { onMounted , onBeforeUnmount , ref , toRefs , shallowRef } from 'vue'
@ -38,12 +39,16 @@ onMounted(() => {
_getCustomerList ( )
timer = setInterval ( ( ) => {
_getCustomerList ( )
scrollList . value ? . scrollTo ( 0 , 1000 , false )
scrollList . value . swiper ? . value ? . scrollTo ( 0 , 1000 , false )
} , 1000 * 60 )
} )
onBeforeUnmount ( ( ) => {
clearInterval ( timer )
} )
function back ( ) {
scrollList . value . swiper ? . value ? . scrollTo ( 0 , 1000 , false )
}
< / script >
< style >