mirror of
https://github.com/frappe/erpnext.git
synced 2026-05-27 08:54:45 +00:00
Merge pull request #17908 from scmmishra/education-test-fixes
test: fix fixtures for program and course
This commit is contained in:
@@ -1,17 +1,14 @@
|
|||||||
[
|
[
|
||||||
{
|
{
|
||||||
"course_name": "_Test Course",
|
"course_name": "TC100",
|
||||||
"course_code": "TC100",
|
|
||||||
"course_abbreviation": "TC"
|
"course_abbreviation": "TC"
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
"course_name": "_Test Course 1",
|
"course_name": "TC101",
|
||||||
"course_code": "TC101",
|
|
||||||
"course_abbreviation": "TC1"
|
"course_abbreviation": "TC1"
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
"course_name": "_Test Course 2",
|
"course_name": "TC102",
|
||||||
"course_code": "TC102",
|
|
||||||
"course_abbreviation": "TC2"
|
"course_abbreviation": "TC2"
|
||||||
}
|
}
|
||||||
]
|
]
|
||||||
@@ -1,13 +1,11 @@
|
|||||||
[
|
[
|
||||||
{
|
{
|
||||||
"program_name": "_Test Program 1",
|
"program_name": "_TP1",
|
||||||
"program_code": "_TP1",
|
|
||||||
"description": "Test Description",
|
"description": "Test Description",
|
||||||
"program_abbreviation": "TP1"
|
"program_abbreviation": "TP1"
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
"program_name": "_Test Program 2",
|
"program_name": "_TP2",
|
||||||
"program_code": "_TP2",
|
|
||||||
"description": "Test Description",
|
"description": "Test Description",
|
||||||
"program_abbreviation": "TP2"
|
"program_abbreviation": "TP2"
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -66,7 +66,7 @@ class ProgramEnrollment(Document):
|
|||||||
msgprint(_("Fee Records Created - {0}").format(comma_and(fee_list)))
|
msgprint(_("Fee Records Created - {0}").format(comma_and(fee_list)))
|
||||||
|
|
||||||
def get_courses(self):
|
def get_courses(self):
|
||||||
return frappe.db.sql('''select course, course_name from `tabProgram Course` where parent = %s and required = 1''', (self.program), as_dict=1)
|
return frappe.db.sql('''select course from `tabProgram Course` where parent = %s and required = 1''', (self.program), as_dict=1)
|
||||||
|
|
||||||
def create_course_enrollments(self):
|
def create_course_enrollments(self):
|
||||||
student = frappe.get_doc("Student", self.student)
|
student = frappe.get_doc("Student", self.student)
|
||||||
|
|||||||
Reference in New Issue
Block a user