Commit 066eaf12 authored by cinwell.li's avatar cinwell.li Committed by FuryBean

DatePicker: fix prevent clear value when readonly is true, fixed #1238 (#1326)

parent 2f675096
...@@ -328,12 +328,14 @@ export default { ...@@ -328,12 +328,14 @@ export default {
methods: { methods: {
handleMouseEnterIcon() { handleMouseEnterIcon() {
if (this.readonly || this.disabled) return;
if (!this.valueIsEmpty) { if (!this.valueIsEmpty) {
this.showClose = true; this.showClose = true;
} }
}, },
handleClickIcon() { handleClickIcon() {
if (this.readonly || this.disabled) return;
if (this.valueIsEmpty) { if (this.valueIsEmpty) {
this.pickerVisible = !this.pickerVisible; this.pickerVisible = !this.pickerVisible;
} else { } else {
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment