Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Update imports from django.conf.urls and avoid import *.
- Loading branch information
Showing
9 changed files
with
41 additions
and
36 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Original file line | Diff line number | Diff line change |
---|---|---|---|
@@ -1,36 +1,37 @@ | |||
from __future__ import absolute_import | from __future__ import absolute_import | ||
|
|
||
from django.conf.urls.defaults import * | from django.conf.urls import patterns, url | ||
|
|||
from . import views | from . import views | ||
|
|
||
urlpatterns = patterns('', | urlpatterns = patterns('', | ||
url(r'^$', | url(r'^$', | ||
views.index, | views.index, | ||
name = 'community-index' | name='community-index' | ||
), | ), | ||
url(r'^mine/$', | url(r'^mine/$', | ||
views.my_feeds, | views.my_feeds, | ||
name = 'community-my-feeds' | name='community-my-feeds' | ||
), | ), | ||
url( | url( | ||
r'^(?P<feed_type_slug>[-\w]+)/$', | r'^(?P<feed_type_slug>[-\w]+)/$', | ||
views.feed_list, | views.feed_list, | ||
name = "community-feed-list" | name='community-feed-list' | ||
), | ), | ||
url( | url( | ||
r'^add/(?P<feed_type_slug>[-\w]+)/$', | r'^add/(?P<feed_type_slug>[-\w]+)/$', | ||
views.add_feed, | views.add_feed, | ||
name = 'community-add-feed' | name='community-add-feed' | ||
), | ), | ||
url( | url( | ||
r'^edit/(?P<feed_id>\d+)/$', | r'^edit/(?P<feed_id>\d+)/$', | ||
views.edit_feed, | views.edit_feed, | ||
name = 'community-edit-feed' | name='community-edit-feed' | ||
), | ), | ||
url( | url( | ||
r'^delete/(?P<feed_id>\d+)/$', | r'^delete/(?P<feed_id>\d+)/$', | ||
views.delete_feed, | views.delete_feed, | ||
name = 'community-delete-feed' | name='community-delete-feed' | ||
), | ), | ||
) | ) | ||
|
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Original file line | Diff line number | Diff line change |
---|---|---|---|
@@ -1,26 +1,28 @@ | |||
from __future__ import absolute_import | from __future__ import absolute_import | ||
|
|
||
from django.conf.urls.defaults import * | from django.conf.urls import patterns, url | ||
from django.views.generic.simple import direct_to_template | from django.views.generic.simple import direct_to_template | ||
|
|||
from contact_form.views import contact_form | from contact_form.views import contact_form | ||
|
|||
from .forms import FoundationContactForm | from .forms import FoundationContactForm | ||
|
|
||
urlpatterns = patterns('', | urlpatterns = patterns('', | ||
url( | url( | ||
regex = r'^foundation/$', | regex=r'^foundation/$', | ||
view = contact_form, | view=contact_form, | ||
kwargs = dict( | kwargs=dict( | ||
form_class = FoundationContactForm, | form_class=FoundationContactForm, | ||
template_name = 'contact/foundation.html', | template_name='contact/foundation.html', | ||
), | ), | ||
name = 'contact_foundation', | name='contact_foundation', | ||
), | ), | ||
url( | url( | ||
regex = r'^sent/', | regex=r'^sent/', | ||
view = direct_to_template, | view=direct_to_template, | ||
kwargs = dict( | kwargs=dict( | ||
template = 'contact/sent.html', | template='contact/sent.html', | ||
), | ), | ||
name = 'contact_form_sent', | name='contact_form_sent', | ||
) | ) | ||
) | ) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters