continue unifying views
This commit is contained in:
@@ -110,7 +110,12 @@
|
||||
ans: answers
|
||||
}
|
||||
|
||||
postAnswers(ans);
|
||||
let json = {
|
||||
eid: {{exam.pk}},
|
||||
answers: JSON.stringify([ans]),
|
||||
};
|
||||
|
||||
postAnswers(json);
|
||||
|
||||
})
|
||||
});
|
||||
@@ -125,7 +130,7 @@
|
||||
|
||||
function postAnswers(ans) {
|
||||
console.log(ans);
|
||||
$.post("{% url 'physics:exam_answers_submit' %}", JSON.stringify(ans)).done((data) => {
|
||||
$.post("{% url 'physics:exam_answers_submit' %}", ans, null, "json").done((data) => {
|
||||
console.log(data);
|
||||
if (data.success) {
|
||||
let ret = confirm(
|
||||
|
||||
Reference in New Issue
Block a user