This commit is contained in:
梁灏 2017-03-29 10:29:12 +08:00
parent f7674b5b74
commit 7b7178f165
3 changed files with 7 additions and 3 deletions

1
.gitignore vendored
View file

@ -7,6 +7,7 @@
*.bak
.DS_Store
node_modules/
node_modules2/
.project
.settings
npm-debug.log

View file

@ -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>

View file

@ -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;