# from django.conf.urls import path from django.urls import path, re_path from .views import ( year_listing, transaction_details, comptability_export, generate_pdf_for_spf, export_year_spf_finance, transaction_by_year_listing, transaction_listing_for_year_and_type, transaction_create_or_update ) app_name = "annualcomptability" urlpatterns = [ path(r"", year_listing, name="year_listing"), re_path( r"^listing/(?P[0-9]{4})/(?P[A-Za-z]+)/$", transaction_by_year_listing, name="by_year_bank", ), re_path( r"^listing/(?P[0-9]{4})/(?P[A-Za-z]+)/$", transaction_by_year_listing, name="by_year_box", ), path( r"listing///", transaction_listing_for_year_and_type, name="transaction_listing_for_year_and_type", ), # http://127.0.0.1:8000/comptability/annual/listing/2017/3 path( r"listing//", transaction_by_year_listing, name="by_year", ), path( r"details//", transaction_details, name="transaction_details", ), path( r"export/simple//", export_year_spf_finance, name="export_simple", ), re_path( r"^export/(?P[0-9]{4})/(?P\w+)/$", comptability_export, name="export", ), path( r"export/pdf//", generate_pdf_for_spf, name="pdf_export", ), path(r"create/", transaction_create_or_update, name="transaction_create"), path(r"update//", transaction_create_or_update, name="transaction_update"), ]