community-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From n...@apache.org
Subject svn commit: r1745916 - in /comdev/nearby_people/templates: base.html base_map.html map.html people.html
Date Sat, 28 May 2016 18:29:53 GMT
Author: nick
Date: Sat May 28 18:29:53 2016
New Revision: 1745916

URL: http://svn.apache.org/viewvc?rev=1745916&view=rev
Log:
Common base template for map view pages

Added:
    comdev/nearby_people/templates/base_map.html
Modified:
    comdev/nearby_people/templates/base.html
    comdev/nearby_people/templates/map.html
    comdev/nearby_people/templates/people.html

Modified: comdev/nearby_people/templates/base.html
URL: http://svn.apache.org/viewvc/comdev/nearby_people/templates/base.html?rev=1745916&r1=1745915&r2=1745916&view=diff
==============================================================================
--- comdev/nearby_people/templates/base.html (original)
+++ comdev/nearby_people/templates/base.html Sat May 28 18:29:53 2016
@@ -3,24 +3,24 @@
 <html xmlns="http://www.w3.org/1999/xhtml">
 
 <head>
-	<title>Nearby Apache People {% block title %}{% endblock %}</title>
-        <link media="screen, projection" type="text/css" href="http://community.apache.org/style/compressed.css"
rel="stylesheet">
-        <link media="screen, projection" type="text/css" href="http://community.apache.org/style/style.css"
rel="stylesheet">
-	{% block extrahead %}
-	{% endblock %}
+   <title>Nearby Apache People {% block title %}{% endblock %}</title>
+   <link media="screen, projection" type="text/css" href="http://community.apache.org/style/compressed.css"
rel="stylesheet">
+   <link media="screen, projection" type="text/css" href="http://community.apache.org/style/style.css"
rel="stylesheet">
+   {% block extrahead %}
+   {% endblock %}
 </head>
 
 <body class="{% block bodyclass %}{% endblock %}">
-    <div class="container">
+  <div class="container">
     <hr class="space col"/> 
-     <div class="block">
-       <div class="column span-24"> 
-		<div id="header">
+    <div class="block">
+      <div class="column span-24"> 
+         <div id="header">
             <h1>Nearby Apache People</h1>
             <p class="alt">
             Brought to you by the <a href="http://community.apache.org">Apache Community
Development Project</a>.
             </p>
-		</div>
+         </div>
       </div>
     </div>
     <div id="menu">
@@ -36,8 +36,8 @@
       </table>
     </div>
 		
-		<div id="content">
-            <p class="highlight">{% block heading %}{% endblock %}</p>
+    <div id="content">
+         <p class="highlight">{% block heading %}{% endblock %}</p>
 			{% if messages %}
 				<ul class="messages">
 				{% for message in messages %}
@@ -48,8 +48,8 @@
 			
 			{% block content %}
 			{% endblock %}
-		</div>
-	</div>
     </div>
+   </div>
+  </div>
 </body>
 </html>

Added: comdev/nearby_people/templates/base_map.html
URL: http://svn.apache.org/viewvc/comdev/nearby_people/templates/base_map.html?rev=1745916&view=auto
==============================================================================
--- comdev/nearby_people/templates/base_map.html (added)
+++ comdev/nearby_people/templates/base_map.html Sat May 28 18:29:53 2016
@@ -0,0 +1,67 @@
+{% extends "base.html" %}
+{% load distances %}
+{% load emails %}
+
+{% block extrahead %}
+<script type="text/javascript" src="http://www.google.com/jsapi?key={{gmaps_key}}"></script>
+<script type="text/javascript" charset="utf-8">
+    google.load("maps", "2.x");
+    google.load("jquery", "1.3.1");
+</script>
+
+<script type="text/javascript" charset="utf-8">
+<!--
+var markers = [];
+var map;
+
+function createMarker(name,lat,lng,link,projects,avatar,email) {
+    var point = new GLatLng(lat,lng);
+    var options = { title: name }; // appears when cursor hovers over marker
+    var marker = new GMarker(point,options);
+    GEvent.addListener(marker, "click", function() {
+      var msg = "<h3>" + name + "</h3>";
+      if (avatar != "None") {
+          msg = msg + "<img src='" + avatar + "' alt='Image of " + name + "'/>";
+      }
+      msg = msg + " <ul>";
+      for (var i = 0; i < projects.length; i++) {
+    	  msg = msg + "<li>" + projects[i] + "</li>";
+    	};
+      msg = msg + " </ul>";
+      if (email != "None") {
+          msg = msg + "<div>Email: <i>" + email + "</i></div>";
+      }
+      msg = msg + " <a href=\"" + link + "\">" +
+                  "<small>Info<\/small><\/a>"; 
+      marker.openInfoWindowHtml(msg);
+    });
+	
+    return marker;
+}
+
+function showDetail(uid) {
+	if (map.getZoom() < 9) {
+      map.setZoom(9);
+	}
+	map.panTo(markers[uid].getPoint())
+    GEvent.trigger(markers[uid], "click");
+}
+//-->
+</script>
+<style type="text/css">
+#map {
+	border: 1px solid #bbbbbb;
+	height: 400px;
+	width: 80%;
+}
+
+	#map { float:left; width:500px; height:500px; }
+	#people { float:left; width:300px; background:#eee; list-style:none; padding:0; }
+	#people tr { padding:5px; }
+	#people tr:hover { background:#FFF; color:#ff;}
+</style>
+
+{% block initmap %}
+{% endblock %}
+
+{% endblock %}

Modified: comdev/nearby_people/templates/map.html
URL: http://svn.apache.org/viewvc/comdev/nearby_people/templates/map.html?rev=1745916&r1=1745915&r2=1745916&view=diff
==============================================================================
--- comdev/nearby_people/templates/map.html (original)
+++ comdev/nearby_people/templates/map.html Sat May 28 18:29:53 2016
@@ -1,23 +1,13 @@
-{% extends "base.html" %}
+{% extends "base_map.html" %}
 {% load distances %}
 {% load emails %}
 
 {% block title %}- Public Committers Locations{% endblock %}
 {% block heading %}Apache Public Committers Map{% endblock %}
 {% block bodyclass %}people{% endblock %}
-{% block extrahead %}
-
-<script type="text/javascript" src="http://www.google.com/jsapi?key={{gmaps_key}}"></script>
-<script type="text/javascript" charset="utf-8">
-    google.load("maps", "2.x");
-    google.load("jquery", "1.3.1");
-</script>
-
+{% block initmap %}
 <script type="text/javascript" charset="utf-8">
 <!--
-var markers = [];
-var map;
-
 function global() {
     map.setZoom(1);
     map.panTo(new GLatLng(0, 0));
@@ -67,54 +57,8 @@ $(document).ready(function(){
       {% endfor %}
    }
 });
-
-function createMarker(name,lat,lng,link,projects,avatar,email) {
-	var point = new GLatLng(lat,lng);
-    var options = { title: name }; // appears when cursor hovers over marker
-    var marker = new GMarker(point,options);
-    GEvent.addListener(marker, "click", function() {
-      var msg = "<h3>" + name + "</h3>";
-      if (avatar != "None") {
-          msg = msg + "<img src='" + avatar + "' alt='Image of " + name + "'/>";
-      }
-      msg = msg + " <ul>";
-      for (var i = 0; i < projects.length; i++) {
-    	  msg = msg + "<li>" + projects[i] + "</li>";
-    	};
-      msg = msg + " </ul>";
-      if (email != "None") {
-          msg = msg + "<div>Email: <i>" + email + "</i></div>";
-      }
-      msg = msg + " <a href=\"" + link + "\">" +
-                  "<small>Info<\/small><\/a>"; 
-      marker.openInfoWindowHtml(msg);
-    });
-	
-    return marker;
-}
-
-function showDetail(uid) {
-	if (map.getZoom() < 9) {
-      map.setZoom(9);
-	}
-	map.panTo(markers[uid].getPoint())
-    GEvent.trigger(markers[uid], "click");
-}
 //-->
 </script>
-<style type="text/css">
-#map {
-	border: 1px solid #bbbbbb;
-	height: 400px;
-	width: 80%;
-}
-
-	#map { float:left; width:500px; height:500px; }
-	#people { float:left; width:300px; background:#eee; list-style:none; padding:0; }
-	#people tr { padding:5px; }
-	#people tr:hover { background:#FFF; color:#ff;}
-</style>
-
 {% endblock %}
 {% block content %}
 

Modified: comdev/nearby_people/templates/people.html
URL: http://svn.apache.org/viewvc/comdev/nearby_people/templates/people.html?rev=1745916&r1=1745915&r2=1745916&view=diff
==============================================================================
--- comdev/nearby_people/templates/people.html (original)
+++ comdev/nearby_people/templates/people.html Sat May 28 18:29:53 2016
@@ -1,23 +1,13 @@
-{% extends "base.html" %}
+{% extends "base_map.html" %}
 {% load distances %}
 {% load emails %}
 
 {% block title %}- {{people_type}} Near You{% endblock %}
 {% block heading %}Apache {{people_type}} Near You{% endblock %}
 {% block bodyclass %}people{% endblock %}
-{% block extrahead %}
-
-<script type="text/javascript" src="http://www.google.com/jsapi?key={{gmaps_key}}"></script>
-<script type="text/javascript" charset="utf-8">
-    google.load("maps", "2.x");
-    google.load("jquery", "1.3.1");
-</script>
-
+{% block initmap %}
 <script type="text/javascript" charset="utf-8">
 <!--
-var markers = [];
-var map;
-
 $(document).ready(function(){
 	if (GBrowserIsCompatible()) {
 		map = new GMap2(document.getElementById('map'));
@@ -57,55 +47,8 @@ $(document).ready(function(){
         map.addOverlay(search_point);
     }
 });
-
-function createMarker(name,lat,lng,link,projects,avatar,email) {
-	var point = new GLatLng(lat,lng);
-    var options = { title: name }; // appears when cursor hovers over marker
-    var marker = new GMarker(point,options);
-    GEvent.addListener(marker, "click", function() {
-      var msg = "<h3>" + name + "</h3>";
-      if (avatar != "None") {
-          msg = msg + "<img src='" + avatar + "' alt='Image of " + name + "'/>"; 
-      }
-      msg = msg + " <ul>";
-      for (var i = 0; i < projects.length; i++) {
-    	  msg = msg + "<li>" + projects[i] + "</li>";
-    	};
-      msg = msg + " </ul>";
-      if (email != "None") {
-          msg = msg + "<div>Email: <i>" + email + "</i></div>";
-      }
-      msg = msg + " <a href=\"" + link + "\">" +
-                  "<small>Info<\/small><\/a>"; 
-      marker.openInfoWindowHtml(msg);
-    });
-	
-    return marker;
-}
-
-function showDetail(uid) {
-	if (map.getZoom() < 9) {
-      map.setZoom(9);
-	}
-	map.panTo(markers[uid].getPoint())
-    GEvent.trigger(markers[uid], "click");
-}
-
 //-->
 </script>
-<style type="text/css">
-#map {
-	border: 1px solid #bbbbbb;
-	height: 400px;
-	width: 80%;
-}
-
-	#map { float:left; width:500px; height:500px; }
-	#people { float:left; width:300px; background:#eee; list-style:none; padding:0; }
-	#people tr { padding:5px; }
-	#people tr:hover { background:#FFF; color:#ff;}
-</style>
-
 {% endblock %}
 {% block content %}
 



Mime
View raw message