fix: amount validation for course

This commit is contained in:
Jannat Patel
2024-11-25 14:36:32 +05:30
parent 83338a56c0
commit d49d638253

View File

@@ -53,7 +53,7 @@ class LMSCourse(Document):
frappe.throw(_("Please install the Payments app to create a paid courses."))
def validate_amount_and_currency(self):
if self.paid_course and (not self.amount and not self.currency):
if self.paid_course and (not self.course_price and not self.currency):
frappe.throw(_("Amount and currency are required for paid courses."))
def on_update(self):