From a4a595129d1a4525fc422367a6941f2143bdf608 Mon Sep 17 00:00:00 2001 From: Rogier Neeleman Date: Tue, 5 Apr 2016 21:52:51 +0200 Subject: [PATCH] Overzicht hield geen rekening met rondes. --- application/controllers/Dashboard.php | 2 +- application/models/Dashboard_model.php | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/application/controllers/Dashboard.php b/application/controllers/Dashboard.php index c20e8af..0730078 100644 --- a/application/controllers/Dashboard.php +++ b/application/controllers/Dashboard.php @@ -54,7 +54,7 @@ class Dashboard extends CI_Controller $vragen = $this->Dashboard_model->get_vragen($lijst['id']); foreach ($vragen as $vraag) { - $aantal = $this->Dashboard_model->get_antwoorden($vraag['id']); + $aantal = $this->Dashboard_model->get_antwoorden($vraag['id'])/$lijst['ronde']; $beantwoord = $beantwoord + $aantal; } if (($subgroepen*count($vragen)) == 0) { diff --git a/application/models/Dashboard_model.php b/application/models/Dashboard_model.php index bc08082..be26a78 100644 --- a/application/models/Dashboard_model.php +++ b/application/models/Dashboard_model.php @@ -61,7 +61,7 @@ class Dashboard_model extends CI_Model public function get_lijsten() { - $this->db->select('id, naam'); + $this->db->select('id, naam, ronde'); $this->db->from('lijst'); $this->db->where('jaar', date('Y')); $this->db->where('regioid', $this->session->regio);