diff --git a/application/models/Wpx.php b/application/models/Wpx.php index 686a61a10..1027828f7 100644 --- a/application/models/Wpx.php +++ b/application/models/Wpx.php @@ -127,6 +127,13 @@ class WPX extends CI_Model { $sql .= $this->addOrbitToQuery($postdata, $bindings); + if ($band == 'SAT') { + if ($postdata['sat'] != 'All') { + $sql .= " and col_sat_name = ?"; + $bindings[] = $postdata['sat']; + } + } + $sql .= " ) AS s ) AS t ) as x"; @@ -231,6 +238,13 @@ class WPX extends CI_Model { $sql .= $this->addOrbitToQuery($postdata,$bindings); + if ($band == 'SAT') { + if ($postdata['sat'] != 'All') { + $sql .= " and col_sat_name = ?"; + $bindings[] = $postdata['sat']; + } + } + $sql .= " ) AS s ) AS t ) as x"; @@ -434,6 +448,13 @@ class WPX extends CI_Model { } $sql .= $this->addContinentsToQuery($postdata); + if ($band == 'SAT') { + if ($postdata['sat'] != 'All') { + $sql .= " and col_sat_name = ?"; + $bindings[] = $postdata['sat']; + } + } + $sql .= " ) AS s ) AS t ) as x @@ -497,9 +518,9 @@ class WPX extends CI_Model { $binding[]=$band; } else { if ($band == 'All' || $band == 'Total') { - $sql .= " and col_prop_mode !='SAT'"; + $sql .=" and (col_prop_mode!='SAT' or col_prop_mode is null)"; } else { - $sql .= " and col_prop_mode !='SAT'"; + $sql .=" and (col_prop_mode!='SAT' or col_prop_mode is null)"; $sql .= " and col_band = ?"; $binding[]=$band; } diff --git a/application/views/awards/wpx/index.php b/application/views/awards/wpx/index.php index 54111f4c1..de65487dc 100644 --- a/application/views/awards/wpx/index.php +++ b/application/views/awards/wpx/index.php @@ -10,8 +10,8 @@