diff --git a/application/forms.py b/application/forms.py index 7fffe59..38e6cf0 100644 --- a/application/forms.py +++ b/application/forms.py @@ -1,9 +1,8 @@ from django import forms from .models import Post, CustomUser -from django.contrib.auth.forms import UserCreationForm, UserChangeForm class PostForm(forms.ModelForm): - + published_date = forms.DateField(widget=forms.widgets.DateInput(format="%d. %h %Y, %M:%S")) class Meta: model = Post - fields = ('title', 'text') \ No newline at end of file + fields = ('title', 'text', 'published_date', 'tags') \ No newline at end of file diff --git a/application/static/js/app.js b/application/static/js/app.js new file mode 100644 index 0000000..e69de29 diff --git a/application/templates/base.html b/application/templates/base.html index 003ca2d..c6294f7 100644 --- a/application/templates/base.html +++ b/application/templates/base.html @@ -8,8 +8,6 @@ {% block title %}Seitenname{% endblock %} - {% include "taggit_templatetags2/tagcanvas_include_js_static.html" %} - {% include_tagcanvas 'tag-cloud' 'width px' 'height px' 'post_list.html' 'application' %} @@ -62,7 +60,8 @@
  • {% csrf_token %} {% if next %} - {% endif %} + + {% endif %}
    @@ -93,6 +92,7 @@ + diff --git a/application/templates/blog_search_list_view.html b/application/templates/blog_search_list_view.html index 3713239..f8adebd 100644 --- a/application/templates/blog_search_list_view.html +++ b/application/templates/blog_search_list_view.html @@ -1,4 +1,10 @@ {% extends "base.html" %} {% block content %} -hi +
    +
      + {% for tag in tags %} +
    • {{tag}} ({{tag.num_times}})
    • + {% endfor %} +
    +
    {% endblock %} \ No newline at end of file diff --git a/application/templates/post_edit.html b/application/templates/post_edit.html index 28d8471..cdc7477 100644 --- a/application/templates/post_edit.html +++ b/application/templates/post_edit.html @@ -3,7 +3,7 @@ {% block content %}

    New post

    {% csrf_token %} - {{ form.as_p }} + {{ form.as_p }} {% endblock %} \ No newline at end of file diff --git a/application/templates/post_list.html b/application/templates/post_list.html index ec323db..32fee5c 100644 --- a/application/templates/post_list.html +++ b/application/templates/post_list.html @@ -18,7 +18,8 @@
    {% endfor %} -{% get_tagcloud as tags for 'application' %} +{% include "taggit_templatetags2/tagcanvas_include_js_static.html" %} +