diff --git a/src/components/timer.vue b/src/components/timer.vue
index 2314a88..b441d66 100644
--- a/src/components/timer.vue
+++ b/src/components/timer.vue
@@ -46,6 +46,7 @@
export default {
data() {
return {
+ submitting:false,
startTime:0,
savedPreviousSeconds:0,
totalSeconds:0,
@@ -68,6 +69,11 @@
formatSeconds,
submit(event){
event.preventDefault();
+ if(this.submitting){
+ return
+ } else {
+ this.submitting = true
+ }
const reqBody = {
description:description.value,
seconds: this.totalSeconds,
@@ -97,6 +103,9 @@
this.manualSeconds = 0
window.localStorage.setItem('lastTotalSeconds', this.totalSeconds);
this.$emit('loggedTime', reqBody)
+ this.submitting = false
+ },()=>{
+ this.submitting = false
});
},
@@ -238,7 +247,7 @@
-
+