@@ -144,9 +144,9 @@
-
-
-
+
+
+
diff --git a/addons/education_base/models/__pycache__/academic_year.cpython-312.pyc b/addons/education_base/models/__pycache__/academic_year.cpython-312.pyc
index dfcf72c..3e4207f 100644
Binary files a/addons/education_base/models/__pycache__/academic_year.cpython-312.pyc and b/addons/education_base/models/__pycache__/academic_year.cpython-312.pyc differ
diff --git a/addons/education_base/models/__pycache__/campus.cpython-312.pyc b/addons/education_base/models/__pycache__/campus.cpython-312.pyc
index af914d8..11fb730 100644
Binary files a/addons/education_base/models/__pycache__/campus.cpython-312.pyc and b/addons/education_base/models/__pycache__/campus.cpython-312.pyc differ
diff --git a/addons/education_base/models/academic_year.py b/addons/education_base/models/academic_year.py
index 7965d17..29f5fec 100644
--- a/addons/education_base/models/academic_year.py
+++ b/addons/education_base/models/academic_year.py
@@ -49,11 +49,12 @@ class AcademicYear(models.Model):
if existing:
raise ValidationError('Only one academic year can be marked as current for a company.')
- @api.model
- def create(self, vals):
- if vals.get('state') == 'active':
- vals['current_year'] = True
- return super().create(vals)
+ @api.model_create_multi
+ def create(self, vals_list):
+ for vals in vals_list:
+ if vals.get('state') == 'active':
+ vals['current_year'] = True
+ return super().create(vals_list)
def action_activate(self):
for rec in self:
diff --git a/addons/education_base/models/campus.py b/addons/education_base/models/campus.py
index 8cfaa70..e550f8e 100644
--- a/addons/education_base/models/campus.py
+++ b/addons/education_base/models/campus.py
@@ -40,11 +40,12 @@ class EducationCampus(models.Model):
if similar:
raise ValidationError('Campus name must be unique within a company.')
- @api.model
- def create(self, vals):
- if vals.get('code'):
- vals['code'] = vals['code'].strip().upper()
- return super().create(vals)
+ @api.model_create_multi
+ def create(self, vals_list):
+ for vals in vals_list:
+ if vals.get('code'):
+ vals['code'] = vals['code'].strip().upper()
+ return super().create(vals_list)
def write(self, vals):
if 'code' in vals and vals.get('code'):
diff --git a/addons/education_dashboard/static/src/js/education_dashboard.js b/addons/education_dashboard/static/src/js/education_dashboard.js
index d7e840a..355a60b 100644
--- a/addons/education_dashboard/static/src/js/education_dashboard.js
+++ b/addons/education_dashboard/static/src/js/education_dashboard.js
@@ -4,10 +4,10 @@ import { registry } from "@web/core/registry";
import { Component, onWillStart, onMounted, useState, useRef } from "@odoo/owl";
import { useService } from "@web/core/utils/hooks";
import { loadJS } from "@web/core/assets";
+import { rpc } from "@web/core/network/rpc";
class EducationDashboard extends Component {
setup() {
- this.rpc = useService("rpc");
this.actionService = useService("action");
this.state = useState({
kpis: {},
@@ -38,7 +38,7 @@ class EducationDashboard extends Component {
for (const [k, v] of Object.entries(this.state.filters)) {
params[k] = v ? parseInt(v) : null;
}
- const data = await this.rpc("/web/education/dashboard/kpis", params);
+ const data = await rpc("/web/education/dashboard/kpis", params);
this.state.kpis = data;
}
diff --git a/addons/education_finance/models/__pycache__/fee_category.cpython-312.pyc b/addons/education_finance/models/__pycache__/fee_category.cpython-312.pyc
index 95c8b7c..60593a1 100644
Binary files a/addons/education_finance/models/__pycache__/fee_category.cpython-312.pyc and b/addons/education_finance/models/__pycache__/fee_category.cpython-312.pyc differ
diff --git a/addons/education_finance/models/__pycache__/student_payment.cpython-312.pyc b/addons/education_finance/models/__pycache__/student_payment.cpython-312.pyc
index 124d066..31ab915 100644
Binary files a/addons/education_finance/models/__pycache__/student_payment.cpython-312.pyc and b/addons/education_finance/models/__pycache__/student_payment.cpython-312.pyc differ
diff --git a/addons/education_finance/models/fee_category.py b/addons/education_finance/models/fee_category.py
index 6d9a1c1..38474e9 100644
--- a/addons/education_finance/models/fee_category.py
+++ b/addons/education_finance/models/fee_category.py
@@ -36,11 +36,12 @@ class EducationFeeCategory(models.Model):
if similar:
raise ValidationError('Fee category name must be unique within a company.')
- @api.model
- def create(self, vals):
- if vals.get('code'):
- vals['code'] = vals['code'].strip().upper()
- return super().create(vals)
+ @api.model_create_multi
+ def create(self, vals_list):
+ for vals in vals_list:
+ if vals.get('code'):
+ vals['code'] = vals['code'].strip().upper()
+ return super().create(vals_list)
def write(self, vals):
if 'code' in vals and vals.get('code'):
diff --git a/addons/education_finance/models/student_payment.py b/addons/education_finance/models/student_payment.py
index 3738a16..e59efe4 100644
--- a/addons/education_finance/models/student_payment.py
+++ b/addons/education_finance/models/student_payment.py
@@ -89,8 +89,9 @@ class EducationStudentPayment(models.Model):
ledger_entries.unlink()
rec.status = 'cancelled'
- @api.model
- def create(self, vals):
- if not vals.get('receipt_number') or vals.get('receipt_number') == '/':
- vals['receipt_number'] = self.env['ir.sequence'].next_by_code('education.student.payment') or '/'
- return super().create(vals)
+ @api.model_create_multi
+ def create(self, vals_list):
+ for vals in vals_list:
+ if not vals.get('receipt_number') or vals.get('receipt_number') == '/':
+ vals['receipt_number'] = self.env['ir.sequence'].next_by_code('education.student.payment') or '/'
+ return super().create(vals_list)
diff --git a/addons/education_portal/views/payment_transaction_views.xml b/addons/education_portal/views/payment_transaction_views.xml
index 7034028..421ac1d 100644
--- a/addons/education_portal/views/payment_transaction_views.xml
+++ b/addons/education_portal/views/payment_transaction_views.xml
@@ -76,9 +76,9 @@
-
-
-
+
+
+
diff --git a/addons/education_student/models/__pycache__/academic_config.cpython-312.pyc b/addons/education_student/models/__pycache__/academic_config.cpython-312.pyc
index 63fc885..bec00e1 100644
Binary files a/addons/education_student/models/__pycache__/academic_config.cpython-312.pyc and b/addons/education_student/models/__pycache__/academic_config.cpython-312.pyc differ
diff --git a/addons/education_student/models/__pycache__/student.cpython-312.pyc b/addons/education_student/models/__pycache__/student.cpython-312.pyc
index dce8476..a9abb3e 100644
Binary files a/addons/education_student/models/__pycache__/student.cpython-312.pyc and b/addons/education_student/models/__pycache__/student.cpython-312.pyc differ
diff --git a/addons/education_student/models/academic_config.py b/addons/education_student/models/academic_config.py
index 1fc4aa9..cf8a45c 100644
--- a/addons/education_student/models/academic_config.py
+++ b/addons/education_student/models/academic_config.py
@@ -35,11 +35,12 @@ class EducationBatch(models.Model):
if similar:
raise ValidationError('Batch name must be unique within a company.')
- @api.model
- def create(self, vals):
- if vals.get('code'):
- vals['code'] = vals['code'].strip().upper()
- return super().create(vals)
+ @api.model_create_multi
+ def create(self, vals_list):
+ for vals in vals_list:
+ if vals.get('code'):
+ vals['code'] = vals['code'].strip().upper()
+ return super().create(vals_list)
def write(self, vals):
if 'code' in vals and vals.get('code'):
@@ -78,11 +79,12 @@ class EducationSemester(models.Model):
if similar:
raise ValidationError('Semester name must be unique within a company.')
- @api.model
- def create(self, vals):
- if vals.get('code'):
- vals['code'] = vals['code'].strip().upper()
- return super().create(vals)
+ @api.model_create_multi
+ def create(self, vals_list):
+ for vals in vals_list:
+ if vals.get('code'):
+ vals['code'] = vals['code'].strip().upper()
+ return super().create(vals_list)
def write(self, vals):
if 'code' in vals and vals.get('code'):
@@ -121,11 +123,12 @@ class EducationSection(models.Model):
if similar:
raise ValidationError('Section name must be unique within a company.')
- @api.model
- def create(self, vals):
- if vals.get('code'):
- vals['code'] = vals['code'].strip().upper()
- return super().create(vals)
+ @api.model_create_multi
+ def create(self, vals_list):
+ for vals in vals_list:
+ if vals.get('code'):
+ vals['code'] = vals['code'].strip().upper()
+ return super().create(vals_list)
def write(self, vals):
if 'code' in vals and vals.get('code'):
diff --git a/addons/education_student/models/student.py b/addons/education_student/models/student.py
index 03bc13d..0393e98 100644
--- a/addons/education_student/models/student.py
+++ b/addons/education_student/models/student.py
@@ -249,15 +249,16 @@ class EducationStudent(models.Model):
def action_cancel(self):
self.write({'status': 'cancelled', 'leave_date': fields.Date.today()})
- @api.model
- def create(self, vals):
- if not vals.get('admission_number') or vals.get('admission_number') == '/':
- vals['admission_number'] = self.env['ir.sequence'].next_by_code('education.student.admission') or '/'
- if not vals.get('student_id') or vals.get('student_id') == '/':
- vals['student_id'] = self.env['ir.sequence'].next_by_code('education.student.id') or '/'
- if vals.get('student_id'):
- vals['student_id'] = vals['student_id'].strip().upper()
- return super().create(vals)
+ @api.model_create_multi
+ def create(self, vals_list):
+ for vals in vals_list:
+ if not vals.get('admission_number') or vals.get('admission_number') == '/':
+ vals['admission_number'] = self.env['ir.sequence'].next_by_code('education.student.admission') or '/'
+ if not vals.get('student_id') or vals.get('student_id') == '/':
+ vals['student_id'] = self.env['ir.sequence'].next_by_code('education.student.id') or '/'
+ if vals.get('student_id'):
+ vals['student_id'] = vals['student_id'].strip().upper()
+ return super().create(vals_list)
def write(self, vals):
if 'student_id' in vals and vals.get('student_id'):
diff --git a/addons/education_student/views/student_views.xml b/addons/education_student/views/student_views.xml
index c366dac..8b3d9a9 100644
--- a/addons/education_student/views/student_views.xml
+++ b/addons/education_student/views/student_views.xml
@@ -32,7 +32,7 @@
-
+
@@ -278,9 +278,9 @@
-
-
-
+
+
+