From 7b7178f1650c3bd54d2a8d411995f4bc10679e9d Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E6=A2=81=E7=81=8F?= Date: Wed, 29 Mar 2017 10:29:12 +0800 Subject: [PATCH] fixed #528 --- .gitignore | 1 + examples/routers/date.vue | 2 +- src/components/date-picker/picker.vue | 7 +++++-- 3 files changed, 7 insertions(+), 3 deletions(-) diff --git a/.gitignore b/.gitignore index 5d1bfef3..a541c265 100644 --- a/.gitignore +++ b/.gitignore @@ -7,6 +7,7 @@ *.bak .DS_Store node_modules/ +node_modules2/ .project .settings npm-debug.log diff --git a/examples/routers/date.vue b/examples/routers/date.vue index 4d1751c1..54f1db83 100644 --- a/examples/routers/date.vue +++ b/examples/routers/date.vue @@ -1,7 +1,7 @@ diff --git a/src/components/date-picker/picker.vue b/src/components/date-picker/picker.vue index 25c411ec..6ce22bd5 100644 --- a/src/components/date-picker/picker.vue +++ b/src/components/date-picker/picker.vue @@ -359,8 +359,11 @@ this.showClose = false; }, handleIconClick () { - if (!this.showClose) return; - this.handleClear(); + if (this.showClose) { + this.handleClear(); + } else { + this.handleFocus(); + } }, handleClear () { this.visible = false;