from django.conf.urls import patterns, url

from .views import *
from .models import Measurement, MeasurementRound

urlpatterns = patterns('',
                       url(regex=r'^$',
                           view=MeasurementsListView.as_view(),
                           name=Measurement.overview_url),

                       url(regex=r'^(?P<pk>\d+)/$',
                           view=MeasurementDetailView.as_view(),
                           name=Measurement.detail_url),

                       url(regex=r'^round/(?P<pk>\d+)/$',
                           view=ThresholdRoundDetailView.as_view(),
                           name=MeasurementRound.detail_url),

                       url(regex=r'^report/(?P<pk>\d+)$',
                           view=SampleReportGeneratorView.as_view(),
                           name='sample_reporter'),
)