зеркало из https://github.com/mozilla/kitsune.git
PEP8 cleanup.
This commit is contained in:
Родитель
2546841c42
Коммит
f65c9fd527
|
@ -2,6 +2,7 @@ from django import forms
|
|||
|
||||
from .models import Post, Thread
|
||||
|
||||
|
||||
class ReplyForm(forms.ModelForm):
|
||||
"""Reply form for forum threads."""
|
||||
|
||||
|
|
|
@ -42,7 +42,7 @@ class Post(ModelBase):
|
|||
author = models.ForeignKey(User)
|
||||
created = models.DateTimeField(auto_now_add=True, db_index=True)
|
||||
updated = models.DateTimeField(auto_now=True, db_index=True)
|
||||
|
||||
|
||||
class Meta:
|
||||
ordering = ['created']
|
||||
|
||||
|
|
|
@ -1,4 +1,3 @@
|
|||
|
||||
def test_new_post_updates_thread():
|
||||
"""Saving a new post in a thread should update the last_post key in
|
||||
that thread to point to the new post."""
|
||||
|
|
|
@ -5,6 +5,7 @@ urlpatterns = patterns('forums.views',
|
|||
url(r'^/reply$', 'reply', name='forums.reply'),
|
||||
url(r'^/(?P<forum_slug>[\w\-]+)/(?P<thread_id>\d+)$',
|
||||
'posts', name='forums.posts'),
|
||||
url(r'^/(?P<forum_slug>[\w\-]+)/new$', 'new_thread', name='forums.new_thread'),
|
||||
url(r'^/(?P<forum_slug>[\w\-]+)/new$', 'new_thread',
|
||||
name='forums.new_thread'),
|
||||
url(r'^/(?P<forum_slug>[\w\-]+)$', 'threads', name='forums.threads'),
|
||||
)
|
||||
|
|
Загрузка…
Ссылка в новой задаче