fix: do no execute send_notification bg job from batch immediately

This commit is contained in:
Jannat Patel
2026-01-19 18:17:40 +05:30
parent 2d4bf49ab9
commit 66486a5a1c
2 changed files with 1 additions and 9 deletions

View File

@@ -3,14 +3,6 @@
frappe.ui.form.on("LMS Batch", {
onload: function (frm) {
frm.set_query("student", "students", function (doc) {
return {
filters: {
ignore_user_type: 1,
},
};
});
frm.set_query("reference_doctype", "timetable", function () {
let doctypes = ["Course Lesson", "LMS Quiz", "LMS Assignment"];
return {

View File

@@ -37,7 +37,7 @@ class LMSBatch(Document):
def on_update(self):
if self.has_value_changed("published") and self.published:
frappe.enqueue(send_notification_for_published_batch, batch=self, now=True)
frappe.enqueue(send_notification_for_published_batch, batch=self)
def autoname(self):
if not self.name: