diff --git a/nezha-fronted/src/components/common/searchInput.vue b/nezha-fronted/src/components/common/searchInput.vue index 39cde5097..e3bebd884 100644 --- a/nezha-fronted/src/components/common/searchInput.vue +++ b/nezha-fronted/src/components/common/searchInput.vue @@ -182,15 +182,6 @@ } }, watch: { - searchMsg: { - deep: true, - immediate: true, - handler(n, o) { - this.$nextTick(() => { - this.clear_input(); - }) - } - }, select_list: { //监听下拉列表 handler(newData, oldData) { diff --git a/nezha-fronted/src/components/page/config/dc.vue b/nezha-fronted/src/components/page/config/dc.vue index 99199f93a..98133a73f 100644 --- a/nezha-fronted/src/components/page/config/dc.vue +++ b/nezha-fronted/src/components/page/config/dc.vue @@ -501,12 +501,13 @@ this.currentShowDc=dc; this.cabSearchLabel={idcId:this.currentShowDc.id}; this.getCabinetDatas(); + let temp=this; + setTimeout(function(){temp.$refs.cabSearchInput.clear_input();},100) }, getCabinetDatas:function(){ this.$get('/cabinet',this.cabSearchLabel).then(response=>{ if(response.code==200 && response.msg=='success'){ this.cabinetDatas=response.data.list; - console.log(this.cabinetDatas) } }) }, @@ -537,6 +538,8 @@ back:function(){ this.tabShow=1; this.getTableData(); + let temp=this; + setTimeout(function(){temp.$refs.searchInput.clear_input();},100) }, cabSearch:function(obj){ this.cabSearchLabel={idcId:this.currentShowDc.id};