зеркало из https://github.com/nextcloud/forms.git
Merge pull request #327 from nextcloud/fix/new-answer-debounce
This commit is contained in:
Коммит
5151a46b9f
|
@ -79,6 +79,10 @@ export default {
|
||||||
// Dispatched for creation. Marked as synced
|
// Dispatched for creation. Marked as synced
|
||||||
this.answer.local = false
|
this.answer.local = false
|
||||||
const newAnswer = await this.debounceCreateAnswer(answer)
|
const newAnswer = await this.debounceCreateAnswer(answer)
|
||||||
|
|
||||||
|
// Forward changes, but use current answer.text to avoid erasing
|
||||||
|
// any in-between changes while creating the answer
|
||||||
|
Object.assign(newAnswer, { text: this.$refs.input.value })
|
||||||
this.$emit('update:answer', answer.id, newAnswer)
|
this.$emit('update:answer', answer.id, newAnswer)
|
||||||
} else {
|
} else {
|
||||||
this.debounceUpdateAnswer(answer)
|
this.debounceUpdateAnswer(answer)
|
||||||
|
|
Загрузка…
Ссылка в новой задаче