Return-Path: X-Original-To: archive-asf-public-internal@cust-asf2.ponee.io Delivered-To: archive-asf-public-internal@cust-asf2.ponee.io Received: from cust-asf.ponee.io (cust-asf.ponee.io [163.172.22.183]) by cust-asf2.ponee.io (Postfix) with ESMTP id 91F6B200AEF for ; Sat, 28 May 2016 16:13:21 +0200 (CEST) Received: by cust-asf.ponee.io (Postfix) id 90D19160A1A; Sat, 28 May 2016 14:13:21 +0000 (UTC) Delivered-To: archive-asf-public@cust-asf.ponee.io Received: from mail.apache.org (hermes.apache.org [140.211.11.3]) by cust-asf.ponee.io (Postfix) with SMTP id B08B3160939 for ; Sat, 28 May 2016 16:13:20 +0200 (CEST) Received: (qmail 15621 invoked by uid 500); 28 May 2016 14:13:19 -0000 Mailing-List: contact commits-help@community.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: dev@community.apache.org Delivered-To: mailing list commits@community.apache.org Received: (qmail 15612 invoked by uid 99); 28 May 2016 14:13:19 -0000 Received: from pnap-us-west-generic-nat.apache.org (HELO spamd4-us-west.apache.org) (209.188.14.142) by apache.org (qpsmtpd/0.29) with ESMTP; Sat, 28 May 2016 14:13:19 +0000 Received: from localhost (localhost [127.0.0.1]) by spamd4-us-west.apache.org (ASF Mail Server at spamd4-us-west.apache.org) with ESMTP id 81018C0856 for ; Sat, 28 May 2016 14:13:19 +0000 (UTC) X-Virus-Scanned: Debian amavisd-new at spamd4-us-west.apache.org X-Spam-Flag: NO X-Spam-Score: 0.374 X-Spam-Level: X-Spam-Status: No, score=0.374 tagged_above=-999 required=6.31 tests=[KAM_ASCII_DIVIDERS=0.8, KAM_LAZY_DOMAIN_SECURITY=1, RP_MATCHES_RCVD=-1.426] autolearn=disabled Received: from mx2-lw-eu.apache.org ([10.40.0.8]) by localhost (spamd4-us-west.apache.org [10.40.0.11]) (amavisd-new, port 10024) with ESMTP id n0jf-qjfLGUT for ; Sat, 28 May 2016 14:13:17 +0000 (UTC) Received: from mailrelay1-us-west.apache.org (mailrelay1-us-west.apache.org [209.188.14.139]) by mx2-lw-eu.apache.org (ASF Mail Server at mx2-lw-eu.apache.org) with ESMTP id AF5EB5F263 for ; Sat, 28 May 2016 14:13:16 +0000 (UTC) Received: from svn01-us-west.apache.org (svn.apache.org [10.41.0.6]) by mailrelay1-us-west.apache.org (ASF Mail Server at mailrelay1-us-west.apache.org) with ESMTP id 95800E048C for ; Sat, 28 May 2016 14:13:15 +0000 (UTC) Received: from svn01-us-west.apache.org (localhost [127.0.0.1]) by svn01-us-west.apache.org (ASF Mail Server at svn01-us-west.apache.org) with ESMTP id 41CE63A0046 for ; Sat, 28 May 2016 14:13:15 +0000 (UTC) Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit Subject: svn commit: r1745876 - in /comdev/nearby_people: nearby/forms.py nearby/shortcuts.py nearby/views.py templates/map.html templates/welcome.html urls.py Date: Sat, 28 May 2016 14:13:14 -0000 To: commits@community.apache.org From: nick@apache.org X-Mailer: svnmailer-1.0.9 Message-Id: <20160528141315.41CE63A0046@svn01-us-west.apache.org> archived-at: Sat, 28 May 2016 14:13:21 -0000 Author: nick Date: Sat May 28 14:13:14 2016 New Revision: 1745876 URL: http://svn.apache.org/viewvc?rev=1745876&view=rev Log: Start to provide a "all public committers" map too Added: comdev/nearby_people/templates/map.html Modified: comdev/nearby_people/nearby/forms.py comdev/nearby_people/nearby/shortcuts.py comdev/nearby_people/nearby/views.py comdev/nearby_people/templates/welcome.html comdev/nearby_people/urls.py Modified: comdev/nearby_people/nearby/forms.py URL: http://svn.apache.org/viewvc/comdev/nearby_people/nearby/forms.py?rev=1745876&r1=1745875&r2=1745876&view=diff ============================================================================== --- comdev/nearby_people/nearby/forms.py (original) +++ comdev/nearby_people/nearby/forms.py Sat May 28 14:13:14 2016 @@ -19,7 +19,7 @@ from django import forms types_field = forms.TypedChoiceField(choices=( ('','Default (Local Mentors)'), ('lm','Local Mentors'), - ('sp','Speakers'), + ('sp','Speakers'), ('all','All Public Committers') ), required=False, widget=forms.HiddenInput, Modified: comdev/nearby_people/nearby/shortcuts.py URL: http://svn.apache.org/viewvc/comdev/nearby_people/nearby/shortcuts.py?rev=1745876&r1=1745875&r2=1745876&view=diff ============================================================================== --- comdev/nearby_people/nearby/shortcuts.py (original) +++ comdev/nearby_people/nearby/shortcuts.py Sat May 28 14:13:14 2016 @@ -23,7 +23,8 @@ from django.template import RequestConte mimetypes = { "json": "application/json", - "rdf": "application/rdf+xml" + "rdf": "application/rdf+xml", + "text": "text/plain" } def render(request, template_name, data_dict=None, content_type=None): Modified: comdev/nearby_people/nearby/views.py URL: http://svn.apache.org/viewvc/comdev/nearby_people/nearby/views.py?rev=1745876&r1=1745875&r2=1745876&view=diff ============================================================================== --- comdev/nearby_people/nearby/views.py (original) +++ comdev/nearby_people/nearby/views.py Sat May 28 14:13:14 2016 @@ -92,6 +92,9 @@ def retrieve_people_data(form): if form.data.get("type",None) == "sp": foaf = speakers_foaf people_type = "Speakers" + if form.data.get("type",None) == "all": + foaf = speakers_foaf # TODO All public + people_type = "Public Committers" search_data = form.data search_latitude = float(search_data["latitude"]) @@ -143,3 +146,7 @@ def find_people_json(request): "Old style JSON API, using a simple JSON dump" data = retrieve_people_data(LocationForm(request.GET)) return HttpResponse(json_dump(data), mimetype=mimetypes["json"]) + +def all_people(request): + "Map of all committers with public locations" + return HttpResponse("TODO", mimetype=mimetypes["text"]) Added: comdev/nearby_people/templates/map.html URL: http://svn.apache.org/viewvc/comdev/nearby_people/templates/map.html?rev=1745876&view=auto ============================================================================== --- comdev/nearby_people/templates/map.html (added) +++ comdev/nearby_people/templates/map.html Sat May 28 14:13:14 2016 @@ -0,0 +1,139 @@ +{% extends "base.html" %} +{% load distances %} +{% load emails %} + +{% block title %}- Public Committers{% endblock %} +{% block heading %}Apache Public Committers{% endblock %} +{% block bodyclass %}people{% endblock %} +{% block extrahead %} + + + + + + + +{% endblock %} +{% block content %} + +

TODO - Update this to match the old https://people.apache.org/map.html

+ +{% if people %} + {% if large_distance %} +

Sorry, there isn't anyone all that near to you. Below is a + list of people you may wish to visit when travelling futher + afield.

+ {% endif %} + + + {% for dist, person in people %} + + + + + {% endfor %} +
{{person.name}}{{dist|distanceformat}}
+ +
+ +{% else %} +

Sorry, there's no-one near you :(

+

Maybe try somewhere else?

+

Why not try searching for people near where you may be visiting + when on holiday, or next time you're travelling for work?

+{% endif %} + +{% endblock %} Modified: comdev/nearby_people/templates/welcome.html URL: http://svn.apache.org/viewvc/comdev/nearby_people/templates/welcome.html?rev=1745876&r1=1745875&r2=1745876&view=diff ============================================================================== --- comdev/nearby_people/templates/welcome.html (original) +++ comdev/nearby_people/templates/welcome.html Sat May 28 14:13:14 2016 @@ -10,6 +10,8 @@
  • Local Mentors will return people willing to help understand the ASF
  • Speakers will return people willing to speak at events
  • +
  • All Public Committers will find any Apache Committer with + a public location. See also the all committers map
  • @@ -21,11 +23,14 @@

    -

    If you are an existing Apache committer, and you are willing to act as +

    If you are an existing Apache Committer, and you are willing to act as as a Local Mentor or Speaker, then please see http://community.apache.org/localmentors.html and http://community.apache.org/speakers/index.html for more information on what it would entail, and how to sign up.

    +

    Any Apache Committers with good ideas on making it easier to sign up as a + Local Mentor or Speaker is strongly encouraged to share them on + dev@community!

    {% endblock %} Modified: comdev/nearby_people/urls.py URL: http://svn.apache.org/viewvc/comdev/nearby_people/urls.py?rev=1745876&r1=1745875&r2=1745876&view=diff ============================================================================== --- comdev/nearby_people/urls.py (original) +++ comdev/nearby_people/urls.py Sat May 28 14:13:14 2016 @@ -33,6 +33,10 @@ urlpatterns = patterns('', # Old style JSON support, not template based (r'^find_people_json/$', 'nearby_people.nearby.views.find_people_json'), + # Replacement for https://people.apache.org/map.html + (r'^map/$', 'nearby_people.nearby.views.all_people'), + (r'^map.html$', 'nearby_people.nearby.views.all_people'), + # Uncomment the admin/doc line below and add 'django.contrib.admindocs' # to INSTALLED_APPS to enable admin documentation: # (r'^admin/doc/', include('django.contrib.admindocs.urls')),