from django.conf.urls import url
from django.views.generic import TemplateView

from . import views

urlpatterns = [
    url(r'^$', views.home, name='home'),
    url(r'^children$', views.show_children, name='show_children'),
    url(r'^child-information/(?P<child_id>\d+)/', views.child_information, name='child_information'),
    url(r'^(?P<user_class>\w+)/add/', views.add_user, name='add_user'),
    url(r'^edit/(?P<user_id>\d+)/', views.edit_user, name='edit_user'),
    url(r'^child/letter/', views.letter, name='child_letter'),
    url(r'^child/request/', views.send_request, name='child_request'),
    url(r'^child/change-volunteer/', views.change_volunteer, name='change_volunteer'),
    url(r'^child/purchases/', views.child_purchases, name='child_purchases'),
    url(r'^login/', views.login, name='login'),
    url(r'^forget/$', views.forget, name='forget'),
    url(r'^forget/(?P<uidb36>[0-9A-Za-z]+)/(?P<token>[0-9A-Za-z]{1,13}-[0-9A-Za-z]{1,20})/$', views.reset_password,
        name='reset_password'),
    url(r'^logout/', views.logout, name='logout'),
    url(r'^profile/(?P<user_id>\d+)/', views.profile, name='profile'),
    url(r'^volunteer/letter-verification/$', views.volunteer_letter_verification, name='volunteer_letter_verification'),
    url(r'^volunteer/letter-verification/accept/(?P<letter_id>\d+)/', views.accept_letter,
        name='decline_letter'),
    url(r'^volunteer/letter-verification/decline/(?P<letter_id>\d+)/', views.decline_letter,
        name='accept_letter'),
    url(r'^donor/purchase/', views.purchase, name='donor_purchase'),
    url(r'^donor/purchases/', views.donor_purchases, name='donor_purchases'),
    url(r'^admin/activities/', views.activities, name='admin_activities'),
    url(r'^admin/approval/', views.approval, name='admin_approvals'),
    url(r'^admin/purchases/', views.admin_purchases, name='admin_purchases'),
    url(r'^admin/unresolveds/', views.admin_unresolveds, name='admin_unresolveds'),
    url(r'^admin/volunteers/', views.admin_volunteers, name='admin_volunteers'),
    url(r'^history/', TemplateView.as_view(template_name='main/static/history.html'), name='static_history'),
    url(r'^vision/', TemplateView.as_view(template_name='main/static/vision.html'), name='static_vision'),
    url(r'^chart/', TemplateView.as_view(template_name='main/static/chart.html'), name='static_chart'),
    url(r'^sponsorship/', TemplateView.as_view(template_name='main/static/sponsorship.html'),
        name='static_sponsorship'),
    url(r'^faq/', TemplateView.as_view(template_name='main/static/faq.html'), name='static_faq'),
    url(r'^bank/', views.bank, name='bank'),
    url(r'^commit-info/(?P<action>\w+)/(?P<user_id>\d+)/', views.commit_info, name='commit_info'),
]
