This commit is contained in:
saeid
2019-04-29 19:39:39 +04:30
parent a8a6780c17
commit 3cced107bb
26 changed files with 36 additions and 75999 deletions
@@ -195,7 +195,12 @@ export default {
}
},
async submitForm() {
const result = await ApiService.post(urls.storeTestResult, this.formData);
if (this.$route.params.testResult) {
const result = await ApiService.put(urls.updateTestResult(this.$route.params.testResult), this.formData);
} else {
const result = await ApiService.post(urls.storeTestResult, this.formData);
}
if (result && result.status == 200) {
this.$router.push({name: 'Dashboard'})
}