urls.py 4.87 KB
Newer Older
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
# -*- coding:utf-8 -*
#
# Copyright 2016,2017
# - Skia <skia@libskia.so>
#
# Ce fichier fait partie du site de l'Association des Étudiants de l'UTBM,
# http://ae.utbm.fr.
#
# This program is free software; you can redistribute it and/or modify it under
# the terms of the GNU General Public License a published by the Free Software
# Foundation; either version 3 of the License, or (at your option) any later
# version.
#
# This program is distributed in the hope that it will be useful, but WITHOUT
# ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS
# FOR A PARTICULAR PURPOSE.  See the GNU General Public License for more
# details.
#
# You should have received a copy of the GNU General Public License along with
# this program; if not, write to the Free Sofware Foundation, Inc., 59 Temple
# Place - Suite 330, Boston, MA 02111-1307, USA.
#
#

Sli's avatar
Sli committed
25
from django.urls import re_path
Skia's avatar
Skia committed
26
27
28
29

from accounting.views import *

urlpatterns = [
Skia's avatar
Skia committed
30
    # Accounting types
Sli's avatar
Sli committed
31
    re_path(
Sli's avatar
Sli committed
32
33
34
35
        r"^simple_type$",
        SimplifiedAccountingTypeListView.as_view(),
        name="simple_type_list",
    ),
Sli's avatar
Sli committed
36
    re_path(
Sli's avatar
Sli committed
37
38
39
40
        r"^simple_type/create$",
        SimplifiedAccountingTypeCreateView.as_view(),
        name="simple_type_new",
    ),
Sli's avatar
Sli committed
41
    re_path(
Sli's avatar
Sli committed
42
43
44
45
        r"^simple_type/(?P<type_id>[0-9]+)/edit$",
        SimplifiedAccountingTypeEditView.as_view(),
        name="simple_type_edit",
    ),
Skia's avatar
Skia committed
46
    # Accounting types
Sli's avatar
Sli committed
47
48
49
    re_path(r"^type$", AccountingTypeListView.as_view(), name="type_list"),
    re_path(r"^type/create$", AccountingTypeCreateView.as_view(), name="type_new"),
    re_path(
Sli's avatar
Sli committed
50
51
52
53
        r"^type/(?P<type_id>[0-9]+)/edit$",
        AccountingTypeEditView.as_view(),
        name="type_edit",
    ),
Skia's avatar
Skia committed
54
    # Bank accounts
Sli's avatar
Sli committed
55
56
57
    re_path(r"^$", BankAccountListView.as_view(), name="bank_list"),
    re_path(r"^bank/create$", BankAccountCreateView.as_view(), name="bank_new"),
    re_path(
Sli's avatar
Sli committed
58
59
60
61
        r"^bank/(?P<b_account_id>[0-9]+)$",
        BankAccountDetailView.as_view(),
        name="bank_details",
    ),
Sli's avatar
Sli committed
62
    re_path(
Sli's avatar
Sli committed
63
64
65
66
        r"^bank/(?P<b_account_id>[0-9]+)/edit$",
        BankAccountEditView.as_view(),
        name="bank_edit",
    ),
Sli's avatar
Sli committed
67
    re_path(
Sli's avatar
Sli committed
68
69
70
71
        r"^bank/(?P<b_account_id>[0-9]+)/delete$",
        BankAccountDeleteView.as_view(),
        name="bank_delete",
    ),
Skia's avatar
Skia committed
72
    # Club accounts
Sli's avatar
Sli committed
73
74
    re_path(r"^club/create$", ClubAccountCreateView.as_view(), name="club_new"),
    re_path(
Sli's avatar
Sli committed
75
76
77
78
        r"^club/(?P<c_account_id>[0-9]+)$",
        ClubAccountDetailView.as_view(),
        name="club_details",
    ),
Sli's avatar
Sli committed
79
    re_path(
Sli's avatar
Sli committed
80
81
82
83
        r"^club/(?P<c_account_id>[0-9]+)/edit$",
        ClubAccountEditView.as_view(),
        name="club_edit",
    ),
Sli's avatar
Sli committed
84
    re_path(
Sli's avatar
Sli committed
85
86
87
88
        r"^club/(?P<c_account_id>[0-9]+)/delete$",
        ClubAccountDeleteView.as_view(),
        name="club_delete",
    ),
Skia's avatar
Skia committed
89
    # Journals
Sli's avatar
Sli committed
90
91
    re_path(r"^journal/create$", JournalCreateView.as_view(), name="journal_new"),
    re_path(
Sli's avatar
Sli committed
92
93
94
95
        r"^journal/(?P<j_id>[0-9]+)$",
        JournalDetailView.as_view(),
        name="journal_details",
    ),
Sli's avatar
Sli committed
96
    re_path(
Sli's avatar
Sli committed
97
98
99
100
        r"^journal/(?P<j_id>[0-9]+)/edit$",
        JournalEditView.as_view(),
        name="journal_edit",
    ),
Sli's avatar
Sli committed
101
    re_path(
Sli's avatar
Sli committed
102
103
104
105
        r"^journal/(?P<j_id>[0-9]+)/delete$",
        JournalDeleteView.as_view(),
        name="journal_delete",
    ),
Sli's avatar
Sli committed
106
    re_path(
Sli's avatar
Sli committed
107
108
109
110
        r"^journal/(?P<j_id>[0-9]+)/statement/nature$",
        JournalNatureStatementView.as_view(),
        name="journal_nature_statement",
    ),
Sli's avatar
Sli committed
111
    re_path(
Sli's avatar
Sli committed
112
113
114
115
        r"^journal/(?P<j_id>[0-9]+)/statement/person$",
        JournalPersonStatementView.as_view(),
        name="journal_person_statement",
    ),
Sli's avatar
Sli committed
116
    re_path(
Sli's avatar
Sli committed
117
118
119
120
        r"^journal/(?P<j_id>[0-9]+)/statement/accounting$",
        JournalAccountingStatementView.as_view(),
        name="journal_accounting_statement",
    ),
Skia's avatar
Skia committed
121
    # Operations
Sli's avatar
Sli committed
122
    re_path(
Sli's avatar
Sli committed
123
124
125
126
        r"^operation/create/(?P<j_id>[0-9]+)$",
        OperationCreateView.as_view(),
        name="op_new",
    ),
Sli's avatar
Sli committed
127
128
129
130
    re_path(
        r"^operation/(?P<op_id>[0-9]+)$", OperationEditView.as_view(), name="op_edit"
    ),
    re_path(
Sli's avatar
Sli committed
131
132
        r"^operation/(?P<op_id>[0-9]+)/pdf$", OperationPDFView.as_view(), name="op_pdf"
    ),
Skia's avatar
Skia committed
133
    # Companies
Sli's avatar
Sli committed
134
135
136
    re_path(r"^company/list$", CompanyListView.as_view(), name="co_list"),
    re_path(r"^company/create$", CompanyCreateView.as_view(), name="co_new"),
    re_path(r"^company/(?P<co_id>[0-9]+)$", CompanyEditView.as_view(), name="co_edit"),
Skia's avatar
Skia committed
137
    # Labels
Sli's avatar
Sli committed
138
139
    re_path(r"^label/new$", LabelCreateView.as_view(), name="label_new"),
    re_path(
Sli's avatar
Sli committed
140
141
142
143
        r"^label/(?P<clubaccount_id>[0-9]+)$",
        LabelListView.as_view(),
        name="label_list",
    ),
Sli's avatar
Sli committed
144
    re_path(
Sli's avatar
Sli committed
145
146
        r"^label/(?P<label_id>[0-9]+)/edit$", LabelEditView.as_view(), name="label_edit"
    ),
Sli's avatar
Sli committed
147
    re_path(
Sli's avatar
Sli committed
148
149
150
151
        r"^label/(?P<label_id>[0-9]+)/delete$",
        LabelDeleteView.as_view(),
        name="label_delete",
    ),
Sli's avatar
Sli committed
152
    # User account
Sli's avatar
Sli committed
153
    re_path(r"^refound/account$", RefoundAccountView.as_view(), name="refound_account"),
Skia's avatar
Skia committed
154
]