Skip to content

Commit

Permalink
fixing stuff
Browse files Browse the repository at this point in the history
  • Loading branch information
ronan18 committed May 15, 2019
1 parent 8139c87 commit b94a5f5
Show file tree
Hide file tree
Showing 2 changed files with 52 additions and 38 deletions.
58 changes: 29 additions & 29 deletions .firebase/hosting.ZGlzdA.cache
Original file line number Diff line number Diff line change
@@ -1,29 +1,29 @@
manifest.json,1557727436053,721a426c60e6486214f345f6bf4d2b44f7ba9af24db72b9ec9054d6e72e41e96
index.html,1557727436053,7ba3d74941f1de9799065ab801d51014899188ce0a47205297c7fe28ef01a86c
precache-manifest.c8716beb348f1ba410c890244e324e38.js,1557727436053,44e4e6bc9cf5281b51bff650c1842095ac358e0b36e80583e1129c94622f356b
robots.txt,1557727436053,c17e70846d7031bb27102edfb33b59d1e3e40a8e8e8097af75b7766e7fffc250
service-worker.js,1557727436053,a1ec17bcafcde3ce7619328f3f612781b80d1b7fa64f3f8bc2d55cf8e0e7aac8
sw.js,1557727436053,dad372a43e87c2da9706f07d169e59c4b15b980969d6b03f955146b38754f00e
css/chunk-vendors.de600c15.css,1557727436069,10741e9c2637c2412e6c8f4275f8b2b9b4c3acd38dbdf6cae10bf0590d83352c
css/app.60cd7312.css,1557727436053,a7d5e0a377ba343201c68ca4871095e3b88e64a4869d58410487dadb689cd234
img/logo.82ddb218.svg,1557727436069,521a4804500844370dc5806c96a0968d515ad7a8c0fc2e140363bb9926343d69
img/done.037fdb77.svg,1557727436053,1d9f9dacb30b1d171388b89ecc2b70fa6ca2e90f9fd8565bf6ae52e69e8a8c9c
img/icons/android-chrome-192x192.png,1557727436070,97e1127ad8db90e0349c838ecf9351fc0c370f9606f6ab309fe17444d26a9d59
img/icons/apple-touch-icon-120x120.png,1557727436069,13e4908bb32e2ca95e375ca720887ef85057fb3872d6f028c63ba22df9b12ed9
img/icons/apple-touch-icon-152x152.png,1557727436070,879d14ef1bd94f81c11ca6fa51ebca226bf6c88c86447aaf560752528e144067
img/icons/apple-touch-icon-180x180.png,1557727436070,ca5a8e637d730848e77716ed970da1a4a5fe9d3b4be21e43f33cf5ebcaf03e7d
img/icons/apple-touch-icon-60x60.png,1557727436071,a27014cb4410df491f64e3b5411987418ff6d729b351056a3de84e744c681a52
img/icons/apple-touch-icon-76x76.png,1557727436070,65d6c498ad60f94b338df3f1f4551303ec84306ecb1c7e615ed64489fffc8b28
favicon.ico,1557727436053,3fbfded31bb8316b434c4fc555c3facdf5cfb5f97b18b2d3b845a443df83be12
img/icons/apple-touch-icon.png,1557727436070,08b37da608cf827a037d8f600a01a32b2f74728291e679b03679fd3619da3a43
img/icons/favicon-16x16.png,1557727436070,563096b119e9b3f8060292a6fc3e091e2a98ee0d1c94ca99de941f78c7fa077c
img/icons/favicon-32x32.png,1557727436071,f5a182df55d21b93c27ec89bd600abe40f3fac23df563e4cfc9efd5edd248886
img/icons/msapplication-icon-144x144.png,1557727436070,27b3b62de2e36ac452e86079762d3cfd37c33dc8cbde0a7c5657e5a7c32d971a
img/icons/mstile-150x150.png,1557727436070,ea1dc2c1c63ffe2668cacc9d170cee33b50a2d58e1591b8399004629e3c1ae67
js/app.edde745d.js,1557727436069,be83a5dd22754fe1370de15ea5cfaeccf2c0b99703464ba67988ac48c9ced323
img/icons/safari-pinned-tab.svg,1557727436070,0858aec0c8ea5d0b50b2bfca81dbef78aa3039b295a7c11386b8d3c378f35326
img/sign.72c4aeb5.svg,1557727436069,6aeafa4e0068ce630a86685bb33a958f22e0f3bf576534020f88ce4e38f2ab60
js/app.edde745d.js.map,1557727436069,c061a669dbb03d85d7c392c6735bb0f458b5fd630ede2d5d9aae215d93b69383
img/icons/android-chrome-512x512.png,1557727436071,07426bba3be5f2ea36f5a6f543b71bfb02277982e28e22509fd85f4f998aefff
js/chunk-vendors.3f4c3856.js,1557727436070,52068c736ffe44f9f35eb4f00d4bfc74ea71e9027d37583e232ab91c249e6763
js/chunk-vendors.3f4c3856.js.map,1557727436071,be62d6dc951bcfd72d3cf32ef6265f48b0ab19934fce75cf190bec8546c33a2d
manifest.json,1557904203628,721a426c60e6486214f345f6bf4d2b44f7ba9af24db72b9ec9054d6e72e41e96
precache-manifest.0fd39e858e45f0e11f054afa32361412.js,1557904203629,ac5eb562c7432b5cd5a8a6fedd11b4110d88cc0ee2138479f0fcfd99ed0f8048
index.html,1557904203629,8703e30a5c1d45c5b8ef2864956aabaa586490fd355decec51f8a0d8a341d9f6
robots.txt,1557904203628,c17e70846d7031bb27102edfb33b59d1e3e40a8e8e8097af75b7766e7fffc250
service-worker.js,1557904203629,12695168c3f53881c93b0781992c241042de28346317a8df3ead5d1280573110
sw.js,1557904203629,dad372a43e87c2da9706f07d169e59c4b15b980969d6b03f955146b38754f00e
css/chunk-vendors.de600c15.css,1557904203654,10741e9c2637c2412e6c8f4275f8b2b9b4c3acd38dbdf6cae10bf0590d83352c
css/app.60cd7312.css,1557904203630,a7d5e0a377ba343201c68ca4871095e3b88e64a4869d58410487dadb689cd234
img/logo.82ddb218.svg,1557904203655,521a4804500844370dc5806c96a0968d515ad7a8c0fc2e140363bb9926343d69
img/icons/android-chrome-192x192.png,1557904203657,97e1127ad8db90e0349c838ecf9351fc0c370f9606f6ab309fe17444d26a9d59
img/icons/apple-touch-icon-120x120.png,1557904203656,13e4908bb32e2ca95e375ca720887ef85057fb3872d6f028c63ba22df9b12ed9
img/done.037fdb77.svg,1557904203629,1d9f9dacb30b1d171388b89ecc2b70fa6ca2e90f9fd8565bf6ae52e69e8a8c9c
img/icons/apple-touch-icon-152x152.png,1557904203647,879d14ef1bd94f81c11ca6fa51ebca226bf6c88c86447aaf560752528e144067
img/icons/apple-touch-icon-180x180.png,1557904203656,ca5a8e637d730848e77716ed970da1a4a5fe9d3b4be21e43f33cf5ebcaf03e7d
img/icons/apple-touch-icon-60x60.png,1557904203655,a27014cb4410df491f64e3b5411987418ff6d729b351056a3de84e744c681a52
img/icons/apple-touch-icon-76x76.png,1557904203656,65d6c498ad60f94b338df3f1f4551303ec84306ecb1c7e615ed64489fffc8b28
img/icons/favicon-16x16.png,1557904203656,563096b119e9b3f8060292a6fc3e091e2a98ee0d1c94ca99de941f78c7fa077c
img/icons/apple-touch-icon.png,1557904203656,08b37da608cf827a037d8f600a01a32b2f74728291e679b03679fd3619da3a43
img/icons/favicon-32x32.png,1557904203656,f5a182df55d21b93c27ec89bd600abe40f3fac23df563e4cfc9efd5edd248886
img/icons/msapplication-icon-144x144.png,1557904203656,27b3b62de2e36ac452e86079762d3cfd37c33dc8cbde0a7c5657e5a7c32d971a
img/icons/mstile-150x150.png,1557904203656,ea1dc2c1c63ffe2668cacc9d170cee33b50a2d58e1591b8399004629e3c1ae67
js/app.98e3fc7d.js,1557904203647,6bc5ed48460907436f8c76d79a305999f7869215b818d7d87d9af0055038b5c6
favicon.ico,1557904203629,3fbfded31bb8316b434c4fc555c3facdf5cfb5f97b18b2d3b845a443df83be12
img/icons/safari-pinned-tab.svg,1557904203657,0858aec0c8ea5d0b50b2bfca81dbef78aa3039b295a7c11386b8d3c378f35326
img/sign.72c4aeb5.svg,1557904203654,6aeafa4e0068ce630a86685bb33a958f22e0f3bf576534020f88ce4e38f2ab60
js/app.98e3fc7d.js.map,1557904203655,665e84e13c5b89e266794e7df236b03a0a6d7c77b2a2c0f706770c3b8443c019
img/icons/android-chrome-512x512.png,1557904203657,07426bba3be5f2ea36f5a6f543b71bfb02277982e28e22509fd85f4f998aefff
js/chunk-vendors.3f4c3856.js,1557904203656,52068c736ffe44f9f35eb4f00d4bfc74ea71e9027d37583e232ab91c249e6763
js/chunk-vendors.3f4c3856.js.map,1557904203656,be62d6dc951bcfd72d3cf32ef6265f48b0ab19934fce75cf190bec8546c33a2d
32 changes: 23 additions & 9 deletions src/views/step3.vue
Original file line number Diff line number Diff line change
Expand Up @@ -55,24 +55,38 @@
},
methods: {
fileChange(e) {
// console.log(e.target.files[0], e.target.name, e.target.files)
// console.log(e.target.files[0], e.target.name, e.target.files)
if (e.target.files.length === 1) {
if (e.target.files[0].type.substring(0, 6) === "image/" || e.target.files[0].type === "application/pdf") {
if (e.target.files[0].size / 1024 / 1024 <= 10) {
this.error = false
this.uploading = true;
this.isInitial = false;
console.log(e.target.files[0], e.target.name, 'uploading')
this.$firebase.storage().ref('waivers/' + this.$route.params.id).put(e.target.files[0]).then(snap => {
this.$firebase.firestore().collection('people').doc(this.id).get().then(person => {
person = person.data()
person.waiverStatus = 1;
person.waiverImage = 'waivers/' + this.$route.params.id
person.waiverUploaded = Date.now()
this.$firebase.firestore().collection('people').doc(this.id).set(person).then(() => {
this.$router.push('/success/' + this.id)
console.log(snap)
fetch('https://api.hyphen-hacks.com/api/v1/waiveruploaded', {
method: 'post',
headers: {
'Accept': 'application/json',
'Content-Type': 'application/json'
},
body: JSON.stringify({
waiverStatus: 1,
waiverImage: 'waivers/' + this.$route.params.id,
waiverUploaded: Date.now(),
id: this.$route.params.id
})
}).then(resp => resp.json()).then(resp => {
if (resp.success) {
this.$router.push('/success/' + this.id)
} else {
this.error = 'Uh Oh! Error While Sending Data To Server' + this.error.message
this.uploading = false;
this.isInitial = true;
}
})
}).catch(e => {
console.log(e)
this.error = 'Uh Oh! Error While Uploading' + e.message
Expand Down

0 comments on commit b94a5f5

Please sign in to comment.