From aa20a1e532aa82bc6a82f19232a71cf7f6aa4817 Mon Sep 17 00:00:00 2001 From: mengxiong10 <15623530290@163.com> Date: Thu, 14 Mar 2019 21:00:16 +0800 Subject: [PATCH] fix: type input don't change the value (#266) --- src/index.vue | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/src/index.vue b/src/index.vue index 58f2f95..b407003 100644 --- a/src/index.vue +++ b/src/index.vue @@ -535,6 +535,9 @@ export default { const keyCode = event.keyCode // Tab 9 or Enter 13 if (keyCode === 9 || keyCode === 13) { + // ie emit the watch before the change event + this.handleChange() + this.userInput = null this.popupVisible = false event.stopPropagation() } @@ -543,8 +546,8 @@ export default { this.userInput = event.target.value }, handleChange () { - const value = this.text if (this.editable && this.userInput !== null) { + const value = this.text const checkDate = this.$refs.calendarPanel.isDisabledTime if (!value) { this.clearDate()