1#!/usr/bin/env python3
2
3"""Standard Django file mapping url strings to view functions."""
4
5from django.urls import path
6from django.views.generic import TemplateView
7
8import chart.timeconv.views
9
10app_name = 'timeconv'
11
12urlpatterns = [
13 # Time conversion utility
14 path('',
15 chart.timeconv.views.index,
16 name='index'),
17
18 # JS support
19 path('js',
20 # disable "No value passed for parameter 'cls' in function call" warning
21 TemplateView.as_view(template_name='timeconv/timeconv.js',
22 content_type='text/javascript'), # pylint:disable=E1120
23 name='js'),
24
25 # Time converter function
26 path('ajax_convert',
27 chart.timeconv.views.ajax_convert,
28 name='convert'),
29]