Display error with page validation (#486)

This commit is contained in:
Chirag Chhatrala 2024-07-16 02:50:56 +05:30 committed by GitHub
parent 59c8a85824
commit 9a17787f76
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194
1 changed files with 6 additions and 2 deletions

View File

@ -109,8 +109,8 @@
:color="form.color" :color="form.color"
:theme="theme" :theme="theme"
class="mt-2 px-8 mx-1" class="mt-2 px-8 mx-1"
@click.stop="nextPage"
:loading="dataForm.busy" :loading="dataForm.busy"
@click.stop="nextPage"
> >
{{ currentFieldsPageBreak.next_btn_text }} {{ currentFieldsPageBreak.next_btn_text }}
</open-form-button> </open-form-button>
@ -461,7 +461,11 @@ export default {
this.currentFieldGroupIndex += 1 this.currentFieldGroupIndex += 1
this.dataForm.busy = false this.dataForm.busy = false
window.scrollTo({top: 0, behavior: 'smooth'}) window.scrollTo({top: 0, behavior: 'smooth'})
}).catch(err => { }).catch(error => {
console.error(error)
if (error && error.data && error.data.message) {
useAlert().error(error.data.message)
}
this.dataForm.busy = false this.dataForm.busy = false
}) })
return false return false