解決elementUI的穿梭框clearQuery方法無效
author: idongchen
modify: 2018-12-6
原因很簡單框往,2.2.0版本才有此清空功能;
如果在生產(chǎn)中的項目中不好升級到2.2.0+版本有以下解決方法闯捎。
解決方法(對于2.2.0一下版本的):
離開transfer時:
// 清空左邊搜索
this.$refs.yourTransfer.$children["0"].$children["0"]._data.currentValue = '';
// 清空右邊搜索
this.$refs.yourTransfer.$children["3"].$children["0"]._data.currentValue = '';
當然最好還是升級新版本的elementUI椰弊,官方對2.0一下版本已不在支持
歡迎關注更多內(nèi)容:mob前端組