diff --git a/website/public/scout/scripts.js b/website/public/scout/scripts.js index 0bfff4f9..5e4f5afe 100644 --- a/website/public/scout/scripts.js +++ b/website/public/scout/scripts.js @@ -243,7 +243,7 @@ function processAndAppendReturn(data, newloc) { } else if (questions[j][1]['type'] == 'stepper') { document.getElementById(newloc + j.toString()).innerHTML += "" + (questions[j][1]['defaultValue']).toString() + ""; } else if (questions[j][1]['type'] == 'label') { - document.getElementById(newloc + j.toString()).innerHTML += "" + (0).toString() + ""; + document.getElementById(newloc + j.toString()).innerHTML += "" + (questions[j][1]['defaultValue']).toString() + ""; } else if (questions[j][1]['type'] == 'slider') { document.getElementById(newloc + j.toString()).innerHTML += "  " + questions[j][1]['min'] + "  "; document.getElementById(newloc + j.toString()).innerHTML += ""; @@ -392,7 +392,7 @@ function subReport() { } catch (e) { } - firebase.firestore().collection("data").doc('team-' + document.getElementById('tns').value).collection(currentComp).doc("team-" + teamNum).collection('matches').doc('match-' + matchNum).set(push, { + firebase.firestore().collection("data").doc('team-' + document.getElementById('tns').value).collection(currentComp).doc("team-" + teamNum).collection('matches').doc('match-' + matchNum).set(push, {merge:true}).then(function() { alert('Submitted!') setTimeout(function() { window.location.href = '../scout';