from django.conf.urls import patterns,url
from datapoints import views
from datapoints.models import *
from django.views.generic import TemplateView

urlpatterns = [

        ################
        ## DATAPOINTS ##
        ################

    ## INDEX ##
    url(r'^$', views.DataPointIndexView.as_view(),name='datapoint_index'),

     ## DASHBOARD ##
    url(r'^dashboard/$', views.DashBoardView.as_view(),name='dashboard'),

    ## CREATE ##
    url(r'^create/$', views.DataPointCreateView.as_view(),name='create_datapoint'),

    ## UPDATE ##
    url(r'^update/(?P<pk>[0-9]+)/$', views.DataPointUpdateView.as_view(),
        name='update_datapoint'),

    ## DELETE ##
    url(r'^delete/(?P<pk>[0-9]+)/$', views.DataPointDeleteView.as_view(),
        name='delete_datapoint'),

    ## SEARCH ##
    url(r'^search/$', views.search,name='search_datapoint'),

    ## META DATA ##
    url(r'^metadata/$', TemplateView.as_view(
        template_name = 'datapoints/metadata.html'),
        name='metadata_index'),

    ## PERMISSIONS NEEDED ##
    url(r'^permissions_needed/$', TemplateView.as_view(
        template_name='datapoints/permissions_needed.html'),
        name='permissions_needed'),

        ###############
        ## CAMPAIGNS ##
        ###############

    ## INDEX ##
    url(r'^campaigns$', views.CampaignIndexView.as_view(),
        name='campaign_index'),

    ## CREATE ##
    url(r'^campaign/create/$',
        views.CampaignCreateView.as_view(),
        name='create_campaign'),

    ## UPDATE ##
    url(r'^campaign/update/(?P<pk>[0-9]+)/$', views.CampaignUpdateView.as_view(),
        name='update_campaign'),


]

@@ -235,37 +235,41 @@
 #######%0A%0A    ## 
-INDEX
+DASHBOARD
  ##%0A    url(r'%5E$
@@ -283,20 +283,15 @@
 s.Da
-taPointIndex
+shBoard
 View
@@ -313,21 +313,15 @@
 ='da
-tapoint_index
+shboard
 '),%0A
@@ -325,29 +325,29 @@
 ),%0A%0A    
- 
 ## D
-ASHBOARD
+ata Table
  ##%0A    
@@ -353,25 +353,21 @@
  url(r'%5E
-dashboard
+table
 /$', vie
@@ -363,39 +363,44 @@
 ble/$', views.Da
-shBoard
+taPointIndex
 View.as_view(),n
@@ -398,39 +398,45 @@
 _view(),name='da
-shboard
+tapoint_index
 '),%0A%0A    ## CREA

Make the dashboard the index page