summaryrefslogtreecommitdiff
path: root/httemplate/browse
diff options
context:
space:
mode:
authorBrian Medley <bpm@snafu.org>2012-04-22 10:48:40 -0500
committerBrian Medley <bpm@snafu.org>2012-04-22 10:48:40 -0500
commitccc2208b2b7d09a9b1671846bc76a060649e64a4 (patch)
treec90b3efe732136247aafb0ba758a67b3eb527ade /httemplate/browse
parent7dd79523c75c3cd238fb1c0cb7ccb346a6569811 (diff)
support coordinates in gui, #15655
Diffstat (limited to 'httemplate/browse')
-rw-r--r--httemplate/browse/tower.html16
1 files changed, 15 insertions, 1 deletions
diff --git a/httemplate/browse/tower.html b/httemplate/browse/tower.html
index 7767a3c36..7f096a748 100644
--- a/httemplate/browse/tower.html
+++ b/httemplate/browse/tower.html
@@ -8,9 +8,10 @@
'count_query' => 'SELECT COUNT(*) FROM tower',
'disableable' => 1,
'disabled_statuspos' => 1,
- 'header' => [ 'Name', 'Sectors', ],
+ 'header' => [ 'Name', 'Sectors', 'Coordinates'],
'fields' => [ $tower_sub,
$sector_sub,
+ $coord_sub,
],
'links' => [ ],
)
@@ -49,6 +50,19 @@ my $num_svc_links = sub {
},
};
+my $coord_sub = sub {
+ my $tower = shift;
+
+ my $coords = $m->scomp("/elements/coord-links.html", $tower->latitude, $tower->longitude, $tower->towername);
+
+ [
+ [
+ { 'data' => "Latitude: " . $tower->latitude . "<br>Longitude: " . $tower->longitude, },
+ { 'data' => $coords, 'link' => "Coordinates", },
+ ],
+ ]
+};
+
my $tower_sub = sub {
my $tower = shift;
my $sectors = join(',',