From 14ce5d7e235f601692fa47726560ebe8fc462cc6 Mon Sep 17 00:00:00 2001 From: Jannat Patel Date: Wed, 18 Sep 2024 11:49:38 +0530 Subject: [PATCH 01/15] fix: url for lesson help videos --- frontend/src/components/Modals/ExplanationVideos.vue | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/frontend/src/components/Modals/ExplanationVideos.vue b/frontend/src/components/Modals/ExplanationVideos.vue index 35c0cfb39..2dbf920c0 100644 --- a/frontend/src/components/Modals/ExplanationVideos.vue +++ b/frontend/src/components/Modals/ExplanationVideos.vue @@ -27,8 +27,8 @@ const props = defineProps({ }) const file = computed(() => { - if (props.type == 'youtube') return '/Youtube.mp4' - if (props.type == 'quiz') return '/Quiz.mp4' - if (props.type == 'upload') return '/Upload.mp4' + if (props.type == 'youtube') return '/assets/lms/frontend/Youtube.mp4' + if (props.type == 'quiz') return '/assets/lms/frontend/Quiz.mp4' + if (props.type == 'upload') return '/assets/lms/frontend/Upload.mp4' }) From 3cda563583e63721d0f321dacc951a280a55d2cf Mon Sep 17 00:00:00 2001 From: Jannat Patel Date: Wed, 18 Sep 2024 14:46:29 +0530 Subject: [PATCH 02/15] fix: padding of settings modal --- frontend/src/components/Modals/Settings.vue | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/frontend/src/components/Modals/Settings.vue b/frontend/src/components/Modals/Settings.vue index 77be067d7..4abe89a8d 100644 --- a/frontend/src/components/Modals/Settings.vue +++ b/frontend/src/components/Modals/Settings.vue @@ -30,7 +30,7 @@
Date: Thu, 19 Sep 2024 14:19:55 +0530 Subject: [PATCH 03/15] fix: evaluator name issue --- .../lms_certificate_request/lms_certificate_request.py | 2 ++ lms/patches.txt | 2 +- .../v2_0/delete_certificate_request_notification.py | 8 +++++++- 3 files changed, 10 insertions(+), 2 deletions(-) diff --git a/lms/lms/doctype/lms_certificate_request/lms_certificate_request.py b/lms/lms/doctype/lms_certificate_request/lms_certificate_request.py index ab88fc085..c172f2dc3 100644 --- a/lms/lms/doctype/lms_certificate_request/lms_certificate_request.py +++ b/lms/lms/doctype/lms_certificate_request/lms_certificate_request.py @@ -13,6 +13,7 @@ get_datetime, nowtime, get_time, + get_fullname, ) from lms.lms.utils import get_evaluator import json @@ -32,6 +33,7 @@ def after_insert(self): def set_evaluator(self): if not self.evaluator: self.evaluator = get_evaluator(self.course, self.batch_name) + self.evaluator_name = get_fullname(self.evaluator) def validate_unavailability(self): if self.evaluator: diff --git a/lms/patches.txt b/lms/patches.txt index 74a76ef96..e03d48f4b 100644 --- a/lms/patches.txt +++ b/lms/patches.txt @@ -90,4 +90,4 @@ lms.patches.v1_0.set_published_on lms.patches.v2_0.fix_progress_percentage lms.patches.v2_0.add_discussion_topic_titles lms.patches.v2_0.sidebar_settings -lms.patches.v2_0.delete_certificate_request_notification \ No newline at end of file +lms.patches.v2_0.delete_certificate_request_notification #18-09-2024 \ No newline at end of file diff --git a/lms/patches/v2_0/delete_certificate_request_notification.py b/lms/patches/v2_0/delete_certificate_request_notification.py index 53b907df3..b7a8ed767 100644 --- a/lms/patches/v2_0/delete_certificate_request_notification.py +++ b/lms/patches/v2_0/delete_certificate_request_notification.py @@ -2,4 +2,10 @@ def execute(): - frappe.db.delete("Notification", "Certificate Request Creation") + delete_notification("Certificate Request Creation") + delete_notification("Certificate Request Reminder") + + +def delete_notification(notification_name): + if frappe.db.exists("Notification", notification_name): + frappe.db.delete("Notification", notification_name) From 75a90e1f39792967ae13c9a4464d4587a75e4807 Mon Sep 17 00:00:00 2001 From: frappe-pr-bot Date: Fri, 20 Sep 2024 16:04:14 +0000 Subject: [PATCH 04/15] chore: update POT file --- lms/locale/main.pot | 42 +++++++++++++++++++++--------------------- 1 file changed, 21 insertions(+), 21 deletions(-) diff --git a/lms/locale/main.pot b/lms/locale/main.pot index ba4524cfd..2f119a1a0 100644 --- a/lms/locale/main.pot +++ b/lms/locale/main.pot @@ -7,8 +7,8 @@ msgid "" msgstr "" "Project-Id-Version: Frappe LMS VERSION\n" "Report-Msgid-Bugs-To: jannat@frappe.io\n" -"POT-Creation-Date: 2024-09-13 16:04+0000\n" -"PO-Revision-Date: 2024-09-13 16:04+0000\n" +"POT-Creation-Date: 2024-09-20 16:04+0000\n" +"PO-Revision-Date: 2024-09-20 16:04+0000\n" "Last-Translator: jannat@frappe.io\n" "Language-Team: jannat@frappe.io\n" "MIME-Version: 1.0\n" @@ -212,7 +212,7 @@ msgstr "" msgid "Assessment Type" msgstr "" -#: lms/doctype/lms_batch/lms_batch.py:71 +#: lms/doctype/lms_batch/lms_batch.py:66 msgid "Assessment {0} has already been added to this batch." msgstr "" @@ -387,7 +387,7 @@ msgstr "" msgid "Batch Updated" msgstr "" -#: lms/doctype/lms_batch/lms_batch.py:42 +#: lms/doctype/lms_batch/lms_batch.py:37 msgid "Batch end date cannot be before the batch start date" msgstr "" @@ -948,11 +948,11 @@ msgstr "" msgid "Course Title" msgstr "" -#: lms/doctype/lms_batch/lms_batch.py:327 +#: lms/doctype/lms_batch/lms_batch.py:324 msgid "Course already added to the batch." msgstr "" -#: lms/doctype/lms_batch/lms_batch.py:60 +#: lms/doctype/lms_batch/lms_batch.py:55 msgid "Course {0} has already been added to this batch." msgstr "" @@ -1248,7 +1248,7 @@ msgstr "" msgid "Enrolled successfully" msgstr "" -#: lms/doctype/lms_batch/lms_batch.py:92 +#: lms/doctype/lms_batch/lms_batch.py:89 msgid "Enrollment Confirmation for the Next Training Batch" msgstr "" @@ -1297,7 +1297,7 @@ msgstr "" msgid "Evaluation Request" msgstr "" -#: lms/doctype/lms_batch/lms_batch.py:89 +#: lms/doctype/lms_batch/lms_batch.py:73 msgid "Evaluation end date cannot be less than the batch end date." msgstr "" @@ -2788,7 +2788,7 @@ msgstr "" msgid "Please click on the following button to set your new password" msgstr "" -#: lms/doctype/lms_batch/lms_batch.py:238 +#: lms/doctype/lms_batch/lms_batch.py:235 msgid "Please enable Zoom Settings to use this feature." msgstr "" @@ -3165,19 +3165,19 @@ msgstr "" msgid "Route" msgstr "" -#: lms/doctype/lms_batch/lms_batch.py:167 +#: lms/doctype/lms_batch/lms_batch.py:164 msgid "Row #{0} Date cannot be outside the batch duration." msgstr "" -#: lms/doctype/lms_batch/lms_batch.py:162 +#: lms/doctype/lms_batch/lms_batch.py:159 msgid "Row #{0} End time cannot be outside the batch duration." msgstr "" -#: lms/doctype/lms_batch/lms_batch.py:144 +#: lms/doctype/lms_batch/lms_batch.py:141 msgid "Row #{0} Start time cannot be greater than or equal to end time." msgstr "" -#: lms/doctype/lms_batch/lms_batch.py:153 +#: lms/doctype/lms_batch/lms_batch.py:150 msgid "Row #{0} Start time cannot be outside the batch duration." msgstr "" @@ -3524,7 +3524,7 @@ msgstr "" msgid "Student Name" msgstr "" -#: lms/doctype/lms_batch/lms_batch.py:49 +#: lms/doctype/lms_batch/lms_batch.py:44 msgid "Student {0} has already been added to this batch." msgstr "" @@ -3697,7 +3697,7 @@ msgstr "" msgid "The course {0} is now available on {1}." msgstr "" -#: lms/doctype/lms_certificate_request/lms_certificate_request.py:51 +#: lms/doctype/lms_certificate_request/lms_certificate_request.py:53 msgid "The evaluator of this course is unavailable from {0} to {1}. Please select a date after {1}" msgstr "" @@ -3705,7 +3705,7 @@ msgstr "" msgid "The quiz has a time limit. For each question you will be given {0} seconds." msgstr "" -#: lms/doctype/lms_certificate_request/lms_certificate_request.py:69 +#: lms/doctype/lms_certificate_request/lms_certificate_request.py:71 msgid "The slot is already booked by another participant." msgstr "" @@ -3713,7 +3713,7 @@ msgstr "" msgid "The status of your application has changed." msgstr "" -#: lms/doctype/lms_batch/lms_batch.py:135 +#: lms/doctype/lms_batch/lms_batch.py:132 msgid "There are no seats available in this batch." msgstr "" @@ -4106,7 +4106,7 @@ msgstr "" msgid "Write a review" msgstr "" -#: lms/doctype/lms_certificate_request/lms_certificate_request.py:93 +#: lms/doctype/lms_certificate_request/lms_certificate_request.py:95 msgid "You already have an evaluation on {0} at {1} for the course {2}." msgstr "" @@ -4139,11 +4139,11 @@ msgstr "" msgid "You can find their resume attached to this email." msgstr "" -#: lms/doctype/lms_certificate_request/lms_certificate_request.py:113 +#: lms/doctype/lms_certificate_request/lms_certificate_request.py:115 msgid "You cannot schedule evaluations after {0}." msgstr "" -#: lms/doctype/lms_certificate_request/lms_certificate_request.py:102 +#: lms/doctype/lms_certificate_request/lms_certificate_request.py:104 msgid "You cannot schedule evaluations for past slots." msgstr "" @@ -4208,7 +4208,7 @@ msgstr "" msgid "Your evaluation for the course {0} has been scheduled on {1} at {2} {3}." msgstr "" -#: lms/doctype/lms_certificate_request/lms_certificate_request.py:123 +#: lms/doctype/lms_certificate_request/lms_certificate_request.py:125 msgid "Your evaluation slot has been booked" msgstr "" From 7c90ca4040f1b5a414395f0c9d55e389e695c5b7 Mon Sep 17 00:00:00 2001 From: Jannat Patel Date: Fri, 20 Sep 2024 22:15:59 +0530 Subject: [PATCH 05/15] feat: category in settings --- frontend/src/components/Categories.vue | 102 + frontend/src/components/Modals/Settings.vue | 11 + frontend/src/pages/Batches.vue | 4 +- lms/fixtures/custom_field.json | 6494 +++++++++++++------ lms/fixtures/lms_category.json | 51 + lms/hooks.py | 2 +- 6 files changed, 4647 insertions(+), 2017 deletions(-) create mode 100644 frontend/src/components/Categories.vue create mode 100644 lms/fixtures/lms_category.json diff --git a/frontend/src/components/Categories.vue b/frontend/src/components/Categories.vue new file mode 100644 index 000000000..6349108c3 --- /dev/null +++ b/frontend/src/components/Categories.vue @@ -0,0 +1,102 @@ + + diff --git a/frontend/src/components/Modals/Settings.vue b/frontend/src/components/Modals/Settings.vue index 4abe89a8d..a0f80c5d5 100644 --- a/frontend/src/components/Modals/Settings.vue +++ b/frontend/src/components/Modals/Settings.vue @@ -38,6 +38,11 @@ :description="activeTab.description" v-model:show="show" /> + { description: 'Manage the members of your learning system', icon: 'UserRoundPlus', }, + { + label: 'Categories', + description: 'Manage the members of your learning system', + icon: 'Network', + }, { label: 'Payment Gateway', icon: 'DollarSign', diff --git a/frontend/src/pages/Batches.vue b/frontend/src/pages/Batches.vue index 77e73c5d4..26d3892fa 100644 --- a/frontend/src/pages/Batches.vue +++ b/frontend/src/pages/Batches.vue @@ -8,12 +8,12 @@ :items="[{ label: __('Batches'), route: { name: 'Batches' } }]" />
-
+