added basic structure for urls and views
This commit is contained in:
parent
5b43299967
commit
f2dbce73ad
|
@ -1 +1,20 @@
|
|||
# Create your views here.
|
||||
from django.shortcuts import render_to_response
|
||||
from ox.django.shortcuts import render_to_json_response
|
||||
from django.template import RequestContext
|
||||
|
||||
def search(request):
|
||||
d = RequestContext(request, {})
|
||||
return render_to_response("search.html", d)
|
||||
|
||||
def search_json(request):
|
||||
d = {}
|
||||
return render_to_json_response(d)
|
||||
|
||||
def search_related(request):
|
||||
d = RequestContext(request, {})
|
||||
return render_to_response("search_related.html")
|
||||
|
||||
def search_related_json(request):
|
||||
d = {}
|
||||
return render_to_json_response(d)
|
||||
|
|
|
@ -4,7 +4,7 @@ from os.path import join
|
|||
|
||||
DEBUG = True
|
||||
TEMPLATE_DEBUG = DEBUG
|
||||
DATA_DIR = '/home/sanj/c/gazetteer/data'
|
||||
# DATA_DIR = '/home/sanj/c/gazetteer/data'
|
||||
ADMINS = (
|
||||
# ('Your Name', 'your_email@domain.com'),
|
||||
)
|
||||
|
|
|
@ -0,0 +1,5 @@
|
|||
$(function() {
|
||||
var map = new OpenLayers.Map('map', {});
|
||||
|
||||
|
||||
});
|
|
@ -7,7 +7,10 @@ admin.autodiscover()
|
|||
urlpatterns = patterns('',
|
||||
# Example:
|
||||
# (r'^gazetteer/', include('gazetteer.foo.urls')),
|
||||
|
||||
('^search$', 'places.views.search'),
|
||||
('^search_json$', 'places.views.search_json'),
|
||||
('^search_related$', 'places.views.search_related'),
|
||||
('^search_related_json$', 'places.views.search_related.json'),
|
||||
# Uncomment the admin/doc line below to enable admin documentation:
|
||||
(r'^admin/doc/', include('django.contrib.admindocs.urls')),
|
||||
|
||||
|
|
Loading…
Reference in New Issue
Block a user