-
Notifications
You must be signed in to change notification settings - Fork 30
/
urls.py
312 lines (310 loc) · 12.2 KB
/
urls.py
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
from django.urls import re_path, path
from core.collections.feeds import CollectionFeed
from core.common.constants import NAMESPACE_PATTERN
from core.concepts.views import ConceptCascadeView
from . import views
urlpatterns = [
re_path(r'^$', views.CollectionListView.as_view(), name='collection-list'),
re_path(
'references/old-to-new/',
views.CollectionReferencesOldToNewStructureMigrationView.as_view(),
name='collection-references-old-to-new'
),
re_path(
'references/link-resources/',
views.CollectionReferencesLinkResourcesView.as_view(),
name='collection-references-old-to-new'
),
re_path(
fr"^(?P<collection>{NAMESPACE_PATTERN})/$",
views.CollectionRetrieveUpdateDestroyView.as_view(),
name='collection-detail'
),
re_path(
r'^(?P<collection>' + NAMESPACE_PATTERN + ')/client-configs/$',
views.CollectionClientConfigsView.as_view(),
name='collection-client-configs'
),
re_path(
fr"^(?P<collection>{NAMESPACE_PATTERN})/summary/$",
views.CollectionSummaryView.as_view(),
name='collection-summary'
),
re_path(
fr"^(?P<collection>{NAMESPACE_PATTERN})/logo/$",
views.CollectionLogoView.as_view(),
name='collection-logo'
),
re_path(
fr'^(?P<collection>{NAMESPACE_PATTERN})/versions/$',
views.CollectionVersionListView.as_view(),
name='collection-version-list'
),
re_path(fr'^(?P<collection>{NAMESPACE_PATTERN})/concepts/atom/$', CollectionFeed()),
re_path(
fr'^(?P<collection>{NAMESPACE_PATTERN})/latest/$',
views.CollectionLatestVersionRetrieveUpdateView.as_view(),
name='collectionversion-latest-detail'
),
re_path(
fr'^(?P<collection>{NAMESPACE_PATTERN})/latest/summary/$',
views.CollectionLatestVersionSummaryView.as_view(),
name='collectionversion-latest-summary'
),
re_path(
fr'^(?P<collection>{NAMESPACE_PATTERN})/latest/export/$',
views.CollectionVersionExportView.as_view(),
name='collectionversion-latest-export-detail'
),
path(
"<str:collection>/concepts/<str:concept>/mappings/",
views.CollectionVersionConceptMappingsView.as_view(),
name='concept-mappings'
),
path(
"<str:collection>/concepts/<str:concept>/<str:concept_version>/mappings/",
views.CollectionVersionConceptMappingsView.as_view(),
name='concept-version-mappings'
),
path(
"<str:collection>/concepts/<str:concept>/$cascade/",
ConceptCascadeView.as_view(),
name='concept-cascade'
),
path(
"<str:collection>/concepts/<str:concept>/<str:concept_version>/",
views.CollectionVersionConceptRetrieveView.as_view(),
name='concept-version-detail'
),
path(
"<str:collection>/concepts/<str:concept>/",
views.CollectionVersionConceptRetrieveView.as_view(),
name='concept-detail'
),
re_path(
fr"^(?P<collection>{NAMESPACE_PATTERN})/concepts/",
views.CollectionVersionConceptsView.as_view(),
name='concept-list'
),
path(
"<str:collection>/mappings/<str:mapping>/<str:mapping_version>/",
views.CollectionVersionMappingRetrieveView.as_view(),
name='mapping-version-detail'
),
path(
"<str:collection>/mappings/<str:mapping>/",
views.CollectionVersionMappingRetrieveView.as_view(),
name='mapping-detail'
),
re_path(
fr"^(?P<collection>{NAMESPACE_PATTERN})/mappings/",
views.CollectionVersionMappingsView.as_view(),
name='mapping-list'
),
re_path(
fr'^(?P<collection>{NAMESPACE_PATTERN})/references/$',
views.CollectionReferencesView.as_view(),
name='collection-references'
),
re_path(
r'^(?P<collection>{pattern})/references/(?P<reference>{pattern})/$'.format(pattern=NAMESPACE_PATTERN),
views.CollectionReferenceView.as_view(),
name='collection-reference'
),
re_path(
r'^(?P<collection>{pattern})/references/(?P<reference>{pattern})/concepts/$'.format(pattern=NAMESPACE_PATTERN),
views.CollectionReferenceConceptsView.as_view(),
name='collection-reference-concepts-list'
),
re_path(
r'^(?P<collection>{pattern})/references/(?P<reference>{pattern})/mappings/$'.format(pattern=NAMESPACE_PATTERN),
views.CollectionReferenceMappingsView.as_view(),
name='collection-reference-mappings-list'
),
re_path(
fr"^(?P<collection>{NAMESPACE_PATTERN})/extras/$",
views.CollectionExtrasView.as_view(),
name='collection-extras'
),
re_path(
r'^(?P<collection>{pattern})/(?P<version>{pattern})/$'.format(pattern=NAMESPACE_PATTERN),
views.CollectionVersionRetrieveUpdateDestroyView.as_view(),
name='collection-version-detail'
),
re_path(
r'^(?P<collection>{pattern})/(?P<version>{pattern})/summary/$'.format(pattern=NAMESPACE_PATTERN),
views.CollectionVersionSummaryView.as_view(),
name='collection-version-summary'
),
re_path(
r'^(?P<collection>{pattern})/(?P<version>{pattern})/expansions/$'.format(pattern=NAMESPACE_PATTERN),
views.CollectionVersionExpansionsView.as_view(),
name='expansion-list'
),
re_path(
r'^(?P<collection>{pattern})/(?P<version>{pattern})/expansions/(?P<expansion>{pattern})/$'.format(
pattern=NAMESPACE_PATTERN),
views.CollectionVersionExpansionView.as_view(),
name='collection-version-expansion-detail'
),
path(
"<str:collection>/<str:version>/expansions/<str:expansion>/concepts/<str:concept>/mappings/",
views.CollectionVersionExpansionConceptMappingsView.as_view(),
name='concept-mappings'
),
path(
"<str:collection>/<str:version>/expansions/<str:expansion>/concepts/<str:concept>/<str:concept_version>/mappings/", # pylint: disable=line-too-long
views.CollectionVersionExpansionConceptMappingsView.as_view(),
name='concept-version-mappings'
),
path(
"<str:collection>/<str:version>/expansions/<str:expansion>/concepts/<str:concept>/$cascade/",
ConceptCascadeView.as_view(),
name='concept-cascade'
),
path(
"<str:collection>/<str:version>/expansions/<str:expansion>/concepts/index/",
views.ExpansionConceptsIndexView.as_view(),
name='expansion-concepts-index'
),
path(
"<str:collection>/<str:version>/expansions/<str:expansion>/concepts/<str:concept>/<str:concept_version>/",
views.CollectionVersionExpansionConceptRetrieveView.as_view(),
name='concept-version-detail'
),
path(
"<str:collection>/<str:version>/expansions/<str:expansion>/concepts/<str:concept>/",
views.CollectionVersionExpansionConceptRetrieveView.as_view(),
name='concept-detail'
),
path(
"<str:collection>/<str:version>/expansions/<str:expansion>/mappings/<str:mapping>/<str:mapping_version>/",
views.CollectionVersionExpansionMappingRetrieveView.as_view(),
name='mapping-version-detail'
),
path(
"<str:collection>/<str:version>/expansions/<str:expansion>/mappings/index/",
views.ExpansionMappingsIndexView.as_view(),
name='expansion-mappings-index'
),
path(
"<str:collection>/<str:version>/expansions/<str:expansion>/mappings/<str:mapping>/",
views.CollectionVersionExpansionMappingRetrieveView.as_view(),
name='mapping-detail'
),
re_path(
r'^(?P<collection>{pattern})/(?P<version>{pattern})/expansions/(?P<expansion>{pattern})/concepts/$'.format(
pattern=NAMESPACE_PATTERN),
views.CollectionVersionExpansionConceptsView.as_view(),
name='collection-version-expansion-concepts'
),
re_path(
r'^(?P<collection>{pattern})/(?P<version>{pattern})/expansions/(?P<expansion>{pattern})/mappings/$'.format(
pattern=NAMESPACE_PATTERN),
views.CollectionVersionExpansionMappingsView.as_view(),
name='collection-version-expansion-mappings'
),
re_path(
r"^(?P<collection>{pattern})/extras/(?P<extra>{pattern})/$".format(pattern=NAMESPACE_PATTERN),
views.CollectionExtraRetrieveUpdateDestroyView.as_view(),
name='collection-extra'
),
re_path(
r'^(?P<collection>{pattern})/(?P<version>{pattern})/export/$'.format(pattern=NAMESPACE_PATTERN),
views.CollectionVersionExportView.as_view(), name='collectionversion-export'
),
re_path(
r"^(?P<collection>{pattern})/(?P<version>{pattern})/extras/$".format(pattern=NAMESPACE_PATTERN),
views.CollectionExtrasView.as_view(),
name='collectionversion-extras'
),
re_path(
r"^(?P<collection>{pattern})/(?P<version>{pattern})/extras/(?P<extra>{pattern})/$".format(
pattern=NAMESPACE_PATTERN
),
views.CollectionExtraRetrieveUpdateDestroyView.as_view(),
name='collectionversion-extra'
),
path(
"<str:collection>/<str:version>/concepts/<str:concept>/$cascade/",
ConceptCascadeView.as_view(),
name='concept-$cascade'
),
path(
"<str:collection>/<str:version>/concepts/<str:concept>/<str:concept_version>/mappings/",
views.CollectionVersionConceptMappingsView.as_view(),
name='concept-version-mappings'
),
path(
"<str:collection>/<str:version>/concepts/<str:concept>/mappings/",
views.CollectionVersionConceptMappingsView.as_view(),
name='concept-mappings'
),
path(
"<str:collection>/<str:version>/concepts/<str:concept>/<str:concept_version>/",
views.CollectionVersionConceptRetrieveView.as_view(),
name='concept-version-detail'
),
path(
"<str:collection>/<str:version>/concepts/<str:concept>/",
views.CollectionVersionConceptRetrieveView.as_view(),
name='concept-detail'
),
re_path(
r"^(?P<collection>{pattern})/(?P<version>{pattern})/concepts/".format(
pattern=NAMESPACE_PATTERN
),
views.CollectionVersionConceptsView.as_view(),
name='concept-list'
),
path(
"<str:collection>/<str:version>/mappings/<str:mapping>/<str:mapping_version>/",
views.CollectionVersionMappingRetrieveView.as_view(),
name='mapping-version-detail'
),
path(
"<str:collection>/<str:version>/mappings/<str:mapping>/",
views.CollectionVersionMappingRetrieveView.as_view(),
name='mapping-detail'
),
re_path(
r"^(?P<collection>{pattern})/(?P<version>{pattern})/mappings/".format(
pattern=NAMESPACE_PATTERN
),
views.CollectionVersionMappingsView.as_view(),
name='mapping-list'
),
re_path(
r'^(?P<collection>{pattern})/(?P<version>{pattern})/references/link/$'.format(pattern=NAMESPACE_PATTERN),
views.CollectionVersionReferencesLinkView.as_view(),
name='collectionversion-references-link'
),
re_path(
r'^(?P<collection>{pattern})/(?P<version>{pattern})/references/(?P<reference>{pattern})/$'.format(
pattern=NAMESPACE_PATTERN),
views.CollectionReferenceView.as_view(),
name='collectionversion-reference'
),
re_path(
r'^(?P<collection>{pattern})/(?P<version>{pattern})/references/(?P<reference>{pattern})/concepts/$'.format(
pattern=NAMESPACE_PATTERN),
views.CollectionReferenceConceptsView.as_view(),
name='collectionversion-reference-concepts-list'
),
re_path(
r'^(?P<collection>{pattern})/(?P<version>{pattern})/references/(?P<reference>{pattern})/mappings/$'.format(
pattern=NAMESPACE_PATTERN),
views.CollectionReferenceMappingsView.as_view(),
name='collectionversion-reference-mappings-list'
),
re_path(
r'^(?P<collection>{pattern})/(?P<version>{pattern})/references/$'.format(pattern=NAMESPACE_PATTERN),
views.CollectionVersionReferencesView.as_view(),
name='collectionversion-references'
),
re_path(
r'^(?P<collection>{pattern})/(?P<version>{pattern})/processing/$'.format(pattern=NAMESPACE_PATTERN),
views.CollectionVersionProcessingView.as_view(),
name='collectionversion-processing'
),
]