Skip to content

Commit

Permalink
fix(ZMS-3436): add 300ms delay before releasing timeslot after
Browse files Browse the repository at this point in the history
  • Loading branch information
Tom Fink authored and Tom Fink committed Nov 25, 2024
1 parent 1d9cdf0 commit 3236dae
Showing 1 changed file with 4 additions and 5 deletions.
9 changes: 4 additions & 5 deletions frontend/src/components/TheCalendar.vue
Original file line number Diff line number Diff line change
Expand Up @@ -257,10 +257,7 @@ export default {
})
},
handleTimeSlotSelection: function (timeSlot) {
if (this.isLoading) {
console.log("nope");
return;
}
if (this.isLoading) return;
this.selectedTimeSlot = timeSlot;
this.showCaptcha = this.captchaDetails.captchaEnabled && (this.provider.scope) && (this.provider.scope.captchaActivatedRequired) && (this.provider.scope.captchaActivatedRequired === '1');
if (this.showCaptcha) {
Expand Down Expand Up @@ -308,7 +305,9 @@ export default {
this.timeSlotError = this.$t('noAppointmentsAvailable')
})
.finally(() => {
this.isLoading = false
setTimeout(() => {
this.isLoading = false;
}, 300);
});
if (!this.timeSlotError && oldAppointment && !this.$store.state.isRebooking) {
Expand Down

0 comments on commit 3236dae

Please sign in to comment.