Answer the question
In order to leave comments, you need to log in
Date setting bug with manual input?
There is a date and time input, where through watch I set the current time, but when I start manually entering the date, moment js updates the date, but there is a glitch that it returns the current time again, who can tell what kind of glitch is so incomprehensible?
template
<b-form-input
id="receive_datetime"
:type="`datetime-local`"
v-model="editedItem.receive_datetime"
></b-form-input>
"editedItem.receive_datetime": function(value) {
this.editedItem.receive_datetime = value ?
this.$moment(value).format('YYYY-MM-DDTHH:mm') :
this.$moment.utc().local().format('YYYY-MM-DDTHH:mm')
},
Answer the question
In order to leave comments, you need to log in
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question