1.<el-table :data="unlockCodedetailsDatas" ref="refTable" style="width: 100%;height:250px;" class="detailTable">:加class唯一标识
2.nextTick(() => {
document.querySelector('.detailTable .el-table__body-wrapper .el-scrollbar__wrap')?.addEventListener('scroll', onScollbar)
})获取到class并且增加滚动监听事件
3.const onScollbar = (e) => {
const { target } = e
const { scrollTop, clientHeight, scrollHeight } = target
if (scrollTop + clientHeight + 50 >= scrollHeight) {
detailDatas.limit += 10
getunlockCode()
}
}滚动到底调用加快条数或者分页递增