From 9d7589ddc4323b5831e72ae6bfa0d6ba3d6b3393 Mon Sep 17 00:00:00 2001 From: Cris Date: Thu, 7 Jul 2022 10:18:40 +0200 Subject: [PATCH] Added DB methods to get ECTS Summen by schulische/berufliche Qualifikation --- .../education/Lehrveranstaltung_model.php | 31 +++++++++++++++++++ 1 file changed, 31 insertions(+) diff --git a/application/models/education/Lehrveranstaltung_model.php b/application/models/education/Lehrveranstaltung_model.php index 392c50ff6..f54443955 100644 --- a/application/models/education/Lehrveranstaltung_model.php +++ b/application/models/education/Lehrveranstaltung_model.php @@ -440,4 +440,35 @@ class Lehrveranstaltung_model extends DB_Model return $this->execQuery($qry, array($student_uid, $student_uid)); } + + /** + * Get ECTS Summe aller bisher schulisch begruendeten angerechneten LVs. + * Derzeit wird auch jede Anrechnung, die nicht beruflich ist, als schulisch angenommen. + * + * @param $student_uid + * @return array|stdClass|null + */ + public function getEctsSumSchulisch($student_uid, $prestudent_id, $studiengang_kz) + { + $qry = ' + SELECT get_ects_summe_schulisch(?, ?, ?) AS ectsSumSchulisch + '; + + return $this->execQuery($qry, array($student_uid, $prestudent_id, $studiengang_kz)); + } + + /** + * Get ECTS Summe aller bisher beruflich angerechneten LVs. + * + * @param $student_uid + * @return array|stdClass|null + */ + public function getEctsSumBeruflich($student_uid) + { + $qry = ' + SELECT get_ects_summe_beruflich(?) AS ectsSumBeruflich + '; + + return $this->execQuery($qry, array($student_uid)); + } }