Skip to content

Commit

Permalink
Fixed #5783 - The table header with geocoded objects is not visible
Browse files Browse the repository at this point in the history
  • Loading branch information
cameronblaikie committed Oct 11, 2018
1 parent 553ce8f commit cac4c57
Show file tree
Hide file tree
Showing 3 changed files with 20 additions and 4 deletions.
4 changes: 2 additions & 2 deletions modules/jjwg_Maps/controller.php
Expand Up @@ -130,8 +130,8 @@ public function action_geocoded_counts()
}
$responses['Approximate'] = 'APPROXIMATE';
$responses['Empty'] = 'Empty';
$this->bean->geocoded_headings[] = 'Approximate';
$this->bean->geocoded_headings[] = 'Empty';
$this->bean->geocoded_headings[] = 'APPROXIMATE';
$this->bean->geocoded_headings[] = 'EMPTY';

// foreach module
foreach ($this->settings['valid_geocode_modules'] as $module_type) {
Expand Down
8 changes: 8 additions & 0 deletions modules/jjwg_Maps/language/en_us.lang.php
Expand Up @@ -79,6 +79,14 @@
$mod_strings['LBL_GEOCODED_COUNTS'] = 'Module Geocoded Counts';
$mod_strings['LBL_CRON_URL'] = 'Cron URL:';
$mod_strings['LBL_MODULE_HEADING'] = 'Module';

$mod_strings['LBL_N/A'] = 'N/A';
$mod_strings['LBL_ZERO_RESULTS'] = 'Zero Results';
$mod_strings['LBL_OK'] = 'Ok';
$mod_strings['LBL_INVALID_REQUEST'] = 'Invalid Request';
$mod_strings['LBL_APPROXIMATE'] = 'Approximate';
$mod_strings['LBL_EMPTY'] = 'Empty';

$mod_strings['LBL_MODULE_TOTAL_HEADING'] = 'Total';
$mod_strings['LBL_MODULE_RESET_HEADING'] = 'Reset';
$mod_strings['LBL_GEOCODED_COUNTS_DESCRIPTION'] = 'The table shown belown shows the number of module objects geocoded, grouped by geocoding response. Keep in mind that the standard Google Maps usage limit is 2500 requests per day . This module will cache the addresses geocoding information during processing to reduce the overall number of requests needed.';
Expand Down
12 changes: 10 additions & 2 deletions modules/jjwg_Maps/views/view.geocoded_counts.php
Expand Up @@ -39,15 +39,20 @@ public function display()
echo '<br /><br />';
}

echo '<table cellspacing="0" cellpadding="0" border="0" class="list view" style="width: 50% !important;"><tbody>';
echo '<div class="list-view-rounded-corners">';

echo '<table cellspacing="0" cellpadding="0" border="0" class="list view" style="width: 50% !important;">';
echo '<thead>';
echo '<tr><th>'.$GLOBALS['mod_strings']['LBL_MODULE_HEADING'].'</th>';
foreach ($this->bean->geocoded_headings as $heading) {
echo '<th>'.$heading.'</th>';
echo '<th>'.$GLOBALS['mod_strings']['LBL_'.$heading].'</th>';
}
echo '<th>'.$GLOBALS['mod_strings']['LBL_MODULE_TOTAL_HEADING'].'</th>';
echo '<th>'.$GLOBALS['mod_strings']['LBL_MODULE_RESET_HEADING'].'</th>';
echo '</tr>'."\n";
echo '</thead>';

echo '<tbody>';
foreach ($GLOBALS['jjwg_config']['valid_geocode_modules'] as $module) {
$geocode_url = './index.php?module=jjwg_Maps&action=geocode_addresses&display_module='.$module;
$reset_url = './index.php?module=jjwg_Maps&action=reset_geocoding&display_module='.$module;
Expand All @@ -63,6 +68,9 @@ public function display()
}

echo '</tbody></table>';

echo '</div>';

echo '<br /><br />';

// Custom Entry Point Registry:
Expand Down

0 comments on commit cac4c57

Please sign in to comment.