From 952715bd02e18e3120d37b0d2fc4d4a1a3343868 Mon Sep 17 00:00:00 2001 From: AlexMendozaPrado Date: Sun, 1 Dec 2024 17:51:25 -0600 Subject: [PATCH] Feature: First approach Karma Tab functionality, for finishing quizzes, leaving reviews --- .gitignore | 3 ++ eLearning_upgraded/__manifest__.py | 5 +-- .../__pycache__/__init__.cpython-310.pyc | Bin 236 -> 0 bytes .../__pycache__/__init__.cpython-37.pyc | Bin 230 -> 0 bytes eLearning_upgraded/models/__init__.py | 4 ++- eLearning_upgraded/models/slide_channel.py | 7 ++++ .../models/slide_slide_partner.py | 30 ++++++++++++++++++ .../views/slide_channel_views.xml | 14 ++++++++ odoo.conf | 17 +++++----- 9 files changed, 69 insertions(+), 11 deletions(-) delete mode 100644 eLearning_upgraded/__pycache__/__init__.cpython-310.pyc delete mode 100644 eLearning_upgraded/__pycache__/__init__.cpython-37.pyc create mode 100644 eLearning_upgraded/models/slide_channel.py create mode 100644 eLearning_upgraded/models/slide_slide_partner.py create mode 100644 eLearning_upgraded/views/slide_channel_views.xml diff --git a/.gitignore b/.gitignore index 9f11b75..1c19942 100644 --- a/.gitignore +++ b/.gitignore @@ -1 +1,4 @@ .idea/ +__pycache__/ +odoo/custom-addons/wizelineacademy-academy-lms/eLearning_upgraded/__pycache__ +eLearning_upgraded/__pycache__/ \ No newline at end of file diff --git a/eLearning_upgraded/__manifest__.py b/eLearning_upgraded/__manifest__.py index 274e892..7831fc2 100644 --- a/eLearning_upgraded/__manifest__.py +++ b/eLearning_upgraded/__manifest__.py @@ -9,7 +9,7 @@ """, 'company': 'systemBlue', 'website' : 'https://github.com/oszac/Sistemas-de-Software/wiki', - 'depends' : ['website_slides', 'auth_oauth', 'auth_signup_upgraded'], + 'depends' : ['website_slides', 'auth_oauth', 'auth_signup_upgraded', 'gamification'], 'data' : [ 'security/ir.model.access.csv', 'wizard/import_course_view.xml', @@ -23,7 +23,8 @@ 'views/course_language_view.xml', 'views/course_audience_view.xml', 'views/course_main_lecturers_tab.xml', - 'data/skills_data.xml' + 'data/skills_data.xml', + 'views/slide_channel_views.xml', ], 'assets': { 'web.assets_frontend': [ diff --git a/eLearning_upgraded/__pycache__/__init__.cpython-310.pyc b/eLearning_upgraded/__pycache__/__init__.cpython-310.pyc deleted file mode 100644 index 4e63b9ad6de82313a42847ea95cc1c30917c757f..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 236 zcmd1j<>g`k0zSQRBs}hS+{4|+wF%*GJDq;o_D;bJdL2MB5E7-*?4GF(ox6CO$qhFS8^*Uaz3?7KaVc38guyb|4oOvj7Pm1_4F@Y127D diff --git a/eLearning_upgraded/__pycache__/__init__.cpython-37.pyc b/eLearning_upgraded/__pycache__/__init__.cpython-37.pyc deleted file mode 100644 index 8898de627566d0fda65cf71a4deb897b140cd621..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 230 zcmXwz!K%VQ3`J*JeTb-E;KFTPh#91>2PbhGK#g+KyzZqJQKsb^BKSf-5tN z7s$;CT#~!)cH2s-H#(e#GXMPYUxC0%+Vw?Hq0UvIk6L>Ugo9%s9L6eYytP;&UH=po zDR-Xk*)wI_MPaSjU*b^YrMT(Y%O~E>A+cy-R@p&J1-Xg|lFej1o~~h!)`BCx5rdd4 rq=>e3K);l7nU!aAy_`8kLNF#Pv&xv! 0: + user._add_karma( + karma, + source=record.slide_id, + reason=_("Lección completada: %s" % record.slide_id.name) + ) diff --git a/eLearning_upgraded/views/slide_channel_views.xml b/eLearning_upgraded/views/slide_channel_views.xml new file mode 100644 index 0000000..3668bba --- /dev/null +++ b/eLearning_upgraded/views/slide_channel_views.xml @@ -0,0 +1,14 @@ + + + + slide.channel.form.view.inherit.karma + slide.channel + + + + + + + + + diff --git a/odoo.conf b/odoo.conf index ae34242..84c17fc 100644 --- a/odoo.conf +++ b/odoo.conf @@ -1,9 +1,10 @@ [options] -admin_passwd = 12345 -db_host = False -db_port = False -db_user = aylin.reyes -db_password = -dbfilter = ^academy.*$ -db_list = True -addons_path = /Users/aylin.reyes/Documents/Odoo-community/odoo/addons,/Users/aylin.reyes/wizelineacademy-academy-lms \ No newline at end of file +db_user = alexadmin +db_password = alexadmin +db_name = odoo +db_host = localhost +db_port = 5432 +admin_passwd = admin +xmlrpc_port = 8069 +addons_path = C:/Users/Alejandro/Odoo17/odoo/addons,C:\Users\Alejandro\Odoo17\odoo\custom-addons\wizelineacademy-academy-lms +