diff --git a/nezha-fronted/src/components/common/js/tools.js b/nezha-fronted/src/components/common/js/tools.js index fb55fe01a..9fbdca9ba 100644 --- a/nezha-fronted/src/components/common/js/tools.js +++ b/nezha-fronted/src/components/common/js/tools.js @@ -1101,7 +1101,7 @@ export const loadMore = { bind (el, binding) { console.log(el, binding, el.parentNode, 'bind') // 获取element,定义scroll - const selectDom = binding.dom ? el.querySelector(binding.dom) : el + const selectDom = binding.value.dom ? el.querySelector(binding.value.dom) : el heightLoad = bus.debounce(function () { if (!el.hasMore) { return @@ -1117,8 +1117,7 @@ export const loadMore = { el.hasMore = binding.value.hasMore }, unbind (el, binding) { - const selectDom = binding.dom ? el.querySelector(binding.dom) : el - console.log(selectDom, 'unbind') + const selectDom = binding.value.dom ? el.querySelector(binding.value.dom) : el if (selectDom) { selectDom.removeEventListener('scroll', heightLoad) } diff --git a/nezha-fronted/src/components/common/searchBox/searchBox.vue b/nezha-fronted/src/components/common/searchBox/searchBox.vue index c90f4f2af..6e155cc82 100644 --- a/nezha-fronted/src/components/common/searchBox/searchBox.vue +++ b/nezha-fronted/src/components/common/searchBox/searchBox.vue @@ -15,7 +15,7 @@
{{tag.i18n}}: - {{value}} , + {{value}} ,
@@ -112,12 +112,12 @@ - + - - + + @@ -135,6 +135,7 @@ allow-create default-first-option :filter-method="dialogValueListSet" + :popper-append-to-body="false" v-loadMore="{ load: dialogValueListLoad, hasMore: valueListInfo.total > valueList.length, @@ -162,13 +163,14 @@ v-loadMore="{ load: dialogValueListLoad, hasMore: false, - dom: '.el-select-dropdown .el-select-dropdown__wrap' + dom: '.el-select-dropdown__wrap .el-scrollbar__wrap' }" + :popper-append-to-body="false" ref="dialogValueSelect" > @@ -767,6 +769,7 @@ export default { this.dialogValueListLoad() }, dialogValueListLoad () { + this.contentShow('') if (this.editDialogObj.type == 'enum') { this.valueList = this.oldValueList.filter(item => item.label.indexOf(this.dialogSraechStr) !== -1) return