From 4fd7af053be6ff65ca95b3fd8b8a8fd88c57f906 Mon Sep 17 00:00:00 2001 From: pateljannat Date: Wed, 2 Jun 2021 16:47:17 +0530 Subject: [PATCH] fix: tests --- community/lms/doctype/exercise/exercise.py | 2 +- .../web_form/add_a_new_batch/add_a_new_batch.json | 12 ++++++------ 2 files changed, 7 insertions(+), 7 deletions(-) diff --git a/community/lms/doctype/exercise/exercise.py b/community/lms/doctype/exercise/exercise.py index 7b7439d6..ed92d173 100644 --- a/community/lms/doctype/exercise/exercise.py +++ b/community/lms/doctype/exercise/exercise.py @@ -57,7 +57,7 @@ class Exercise(Document): solution=code) doc.insert(ignore_permissions=True) - if not course.is_mentor(frappe.session.user): + if not (course.is_mentor(frappe.session.user) or frappe.flags.in_test): update_progress(self.lesson) return doc diff --git a/community/lms/web_form/add_a_new_batch/add_a_new_batch.json b/community/lms/web_form/add_a_new_batch/add_a_new_batch.json index e1785069..76735390 100644 --- a/community/lms/web_form/add_a_new_batch/add_a_new_batch.json +++ b/community/lms/web_form/add_a_new_batch/add_a_new_batch.json @@ -19,7 +19,7 @@ "is_standard": 1, "login_required": 1, "max_attachment_size": 0, - "modified": "2021-04-30 11:22:18.188712", + "modified": "2021-06-02 15:52:06.383260", "modified_by": "Administrator", "module": "LMS", "name": "add-a-new-batch", @@ -38,13 +38,13 @@ { "allow_read_on_all_link_options": 0, "fieldname": "course", - "fieldtype": "Data", - "hidden": 0, + "fieldtype": "Link", + "hidden": 1, "label": "Course", "max_length": 0, "max_value": 0, - "options": "", - "read_only": 1, + "options": "LMS Course", + "read_only": 0, "reqd": 0, "show_in_filter": 0 }, @@ -111,4 +111,4 @@ "show_in_filter": 0 } ] -} +} \ No newline at end of file