Skip to content
Browse files

Added map count in list

  • Loading branch information...
1 parent a24dd91 commit a07b75f0595eb5deeaebcbf6ce1d0fe3eac8ff3d @dshorthouse committed Jun 4, 2012
Showing with 5 additions and 2 deletions.
  1. +5 −2 lib/mapprservice.usermaps.class.php
View
7 lib/mapprservice.usermaps.class.php
@@ -154,7 +154,10 @@ private function index_maps() {
$b = "";
if(isset($_GET['q'])) {
if($this->_uid == 1) { $b = "WHERE "; }
- $where['title'] = $b."LOWER(m.title) LIKE '%".$this->_db->escape($_GET['q'])."%'";
+ $where['where'] = $b."LOWER(m.title) LIKE '%".$this->_db->escape($_GET['q'])."%'";
+ if($this->_uid == 1) {
+ $where['where'] .= " OR LOWER(u.username) LIKE '%".$this->_db->escape($_GET['q'])."%'";
+ }
}
$sql = "
@@ -179,7 +182,7 @@ private function index_maps() {
$output .= '<table class="grid-usermaps">' . "\n";
$output .= '<thead>' . "\n";
$output .= '<tr>' . "\n";
- $output .= '<th class="left-align">'._("Title").' <input type="text" id="filter-mymaps" size="25" maxlength="35" value="" name="filter-mymap" /></th>';
+ $output .= '<th class="left-align">'._("Title").' <input type="text" id="filter-mymaps" size="25" maxlength="35" value="" name="filter-mymap" /> '.$this->_db->affected_rows.' of '.$total['total'].'</th>';
$output .= '<th class="center-align">'._("Created").'</th>';
$output .= '<th class="center-align">'._("Updated").'</th>';
$output .= '<th class="actions">'._("Actions");

0 comments on commit a07b75f

Please sign in to comment.
Something went wrong with that request. Please try again.