From 9f9fc578e5ba70649ff8031cc16aa6a05caccf9a Mon Sep 17 00:00:00 2001 From: Alan Jack Pippin Date: Tue, 4 Apr 2006 22:18:34 -0600 Subject: [PATCH] Fixed bug related to how the eqpresppi district was being chosen. --- inc/class.eq.inc.php | 14 ++++++++++---- 1 file changed, 10 insertions(+), 4 deletions(-) diff --git a/inc/class.eq.inc.php b/inc/class.eq.inc.php index d9a58fa..aab3ffd 100644 --- a/inc/class.eq.inc.php +++ b/inc/class.eq.inc.php @@ -875,10 +875,16 @@ class eq $i=0; while ($this->db->next_record()) { - $districts[$i]['district'] = $this->db->f('district'); - $districts[$i]['name'] = $this->db->f('name'); - $districts[$i]['supervisor'] = $this->db->f('supervisor'); - if($eqpresppi == 0) { $i++; } + if($eqpresppi == 1 && $this->db->f('district') == 1) { + $districts[$i]['district'] = $this->db->f('district'); + $districts[$i]['name'] = $this->db->f('name'); + $districts[$i]['supervisor'] = $this->db->f('supervisor'); + } else if($eqpresppi == 0) { + $districts[$i]['district'] = $this->db->f('district'); + $districts[$i]['name'] = $this->db->f('name'); + $districts[$i]['supervisor'] = $this->db->f('supervisor'); + $i++; + } } $sql = "SELECT * FROM eq_elder where valid=1 ORDER BY elder ASC"; -- 2.34.1