Skip to content

Commit

Permalink
fixed iview#528
Browse files Browse the repository at this point in the history
  • Loading branch information
icarusion committed Mar 29, 2017
1 parent f7674b5 commit 7b7178f
Show file tree
Hide file tree
Showing 3 changed files with 7 additions and 3 deletions.
1 change: 1 addition & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,7 @@
*.bak
.DS_Store
node_modules/
node_modules2/
.project
.settings
npm-debug.log
Expand Down
2 changes: 1 addition & 1 deletion examples/routers/date.vue
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
<template>
<div>
{{ val1 }}
<Date-picker v-model="val1" type="daterange" placeholder="选择日期" style="width: 200px"></Date-picker>
<Date-picker v-model="val1" type="date" placeholder="选择日期" style="width: 200px"></Date-picker>
<div @click="val1 = '2017-03-02'">change</div>
</div>
</template>
Expand Down
7 changes: 5 additions & 2 deletions src/components/date-picker/picker.vue
Original file line number Diff line number Diff line change
Expand Up @@ -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;
Expand Down

0 comments on commit 7b7178f

Please sign in to comment.