Skip to content

Commit bf47770

Browse files
committed
[bugfix] Avoid duplicate modification event
1 parent 82cf937 commit bf47770

File tree

1 file changed

+5
-2
lines changed

1 file changed

+5
-2
lines changed

src/components/common/EditableLabelDuration.vue

Lines changed: 5 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -27,8 +27,10 @@
2727
},
2828
methods: {
2929
updateValue: function () {
30-
this.g.edit = false;
31-
this.callback(this.g.value)
30+
if (this.g.edit) {
31+
this.g.edit = false;
32+
this.callback(this.g.value)
33+
}
3234
},
3335
edit: function () {
3436
this.g.edit = true;
@@ -43,6 +45,7 @@
4345
input {
4446
text-align: center;
4547
}
48+
4649
.btn-edit {
4750
margin-left: 0.3em;
4851
margin-right: 0.3em;

0 commit comments

Comments
 (0)