mirror of
https://github.com/frappe/erpnext.git
synced 2026-06-06 21:59:13 +00:00
don't request another ajax call if one is pending (#9620)
This commit is contained in:
committed by
Rushabh Mehta
parent
35ecab6a52
commit
77aa4762b8
@@ -135,6 +135,7 @@ schools.StudentsEditor = Class.extend({
|
|||||||
frappe.confirm(__("Do you want to update attendance?<br>Present: {0}\
|
frappe.confirm(__("Do you want to update attendance?<br>Present: {0}\
|
||||||
<br>Absent: {1}", [students_present.length, students_absent.length]),
|
<br>Absent: {1}", [students_present.length, students_absent.length]),
|
||||||
function() { //ifyes
|
function() { //ifyes
|
||||||
|
if(!frappe.request.ajax_count) {
|
||||||
frappe.call({
|
frappe.call({
|
||||||
method: "erpnext.schools.api.mark_attendance",
|
method: "erpnext.schools.api.mark_attendance",
|
||||||
freeze: true,
|
freeze: true,
|
||||||
@@ -151,6 +152,7 @@ schools.StudentsEditor = Class.extend({
|
|||||||
frm.trigger("student_group");
|
frm.trigger("student_group");
|
||||||
}
|
}
|
||||||
});
|
});
|
||||||
|
}
|
||||||
},
|
},
|
||||||
function() { //ifno
|
function() { //ifno
|
||||||
$(me.wrapper.find(".btn-mark-att")).attr("disabled", false);
|
$(me.wrapper.find(".btn-mark-att")).attr("disabled", false);
|
||||||
|
|||||||
Reference in New Issue
Block a user