Requests form updated
This commit is contained in:
parent
85dfd065e6
commit
61ca8968ae
|
@ -83,7 +83,7 @@ class RssFeed(Feed):
|
|||
|
||||
|
||||
class BlogFeed(Feed):
|
||||
title = "Mss.xmlaidstone Hackspace Blog"
|
||||
title = "Maidstone Hackspace Blog"
|
||||
link = "/blog/"
|
||||
feed_type = MediaRssFeed
|
||||
description = "The latest blog posts and news from the Maidstone Hackspace site"
|
||||
|
|
|
@ -47,7 +47,7 @@ class RequestsDetail(LoginRequiredMixin, DetailView):
|
|||
def get_context_data(self, *args, **kwargs):
|
||||
context = super(RequestsDetail, self).get_context_data(*args, **kwargs)
|
||||
context['requests_comments'] = UserRequestsComment.objects.all()
|
||||
context['requests_form'] = UserRequestFormComment
|
||||
context['form'] = UserRequestFormComment
|
||||
return context
|
||||
|
||||
|
||||
|
|
|
@ -30,7 +30,8 @@
|
|||
|
||||
<link href="{% sass_src 'sass/project.scss' %}" rel="stylesheet">
|
||||
<link href="https://maxcdn.bootstrapcdn.com/font-awesome/4.7.0/css/font-awesome.min.css" rel="stylesheet" integrity="sha384-wvfXpqpZZVQGK6TAh5PVlGOfQNHSoD2xbE+QkPxCAFlNEevoEH3Sl0sibVcOQVnN" crossorigin="anonymous">
|
||||
|
||||
{% render_block "css" %}
|
||||
{% block css %}{% endblock %}
|
||||
|
||||
{% block head-open-graph %}
|
||||
<meta property="og:title" content="Maidstone Hackspace" />
|
||||
|
@ -39,8 +40,6 @@
|
|||
<meta property="og:image" content="https://maidstone-hackspace.org.uk/static/images/android-chrome-192x192.png" />
|
||||
{% endblock head-open-graph %}
|
||||
|
||||
{% render_block "css" %}
|
||||
{% block css %}{% endblock %}
|
||||
|
||||
{% block head-extra %}
|
||||
{% endblock head-extra %}
|
||||
|
|
|
@ -1,7 +1,6 @@
|
|||
{% extends "base.html" %}
|
||||
{% load i18n %}
|
||||
{% load crispy_forms_tags %}
|
||||
{% load recapture %}
|
||||
|
||||
|
||||
{% block head-open-graph %}
|
||||
|
@ -25,20 +24,12 @@
|
|||
<p>{{ comment.comment }}</p>
|
||||
{% endfor %}
|
||||
|
||||
{% if requests_form %}
|
||||
{% if form %}
|
||||
<form method="POST" action="{% url 'requests_detail_form' request_detail.id %}" class="requests_detail_form">
|
||||
{% csrf_token %}
|
||||
{{ requests_form|crispy }}
|
||||
{{ google_capture }}
|
||||
<button class="btn btn-primary " type="submit" name="action">
|
||||
<span class="fa fa-submit" ></span>
|
||||
{% trans "Add Comment" %}</button>
|
||||
{% include "partials/form.html" %}
|
||||
</form>
|
||||
{% endif %}
|
||||
|
||||
{% endblock content %}
|
||||
|
||||
{% block javascript %}
|
||||
{{ block.super }}
|
||||
<script src='https://www.google.com/recaptcha/api.js'></script>
|
||||
{% endblock %}
|
||||
|
|
|
@ -2,6 +2,7 @@
|
|||
{% load i18n %}
|
||||
{% load crispy_forms_tags %}
|
||||
{% load recapture %}
|
||||
{% load sekizai_tags i18n wiki_tags static %}
|
||||
|
||||
|
||||
{% block head-open-graph %}
|
||||
|
@ -22,13 +23,9 @@
|
|||
|
||||
|
||||
{% if form %}
|
||||
<form method="POST" action="{% url 'requests_form' %}" class="requests_form">
|
||||
<form method="POST" action="{% url 'requests_form' %}" class="ui form">
|
||||
{% csrf_token %}
|
||||
{{ form|crispy }}
|
||||
{{ google_capture }}
|
||||
<button class="btn btn-primary " type="submit" name="action">
|
||||
<span class="fa fa-submit" ></span>
|
||||
{% trans "Send" %}</button>
|
||||
{% include "partials/form.html" %}
|
||||
</form>
|
||||
{% else %}
|
||||
<div class="row">
|
||||
|
@ -111,7 +108,3 @@
|
|||
{% endif %}
|
||||
{% endblock content %}
|
||||
|
||||
{% block javascript %}
|
||||
{{ block.super }}
|
||||
<script src='https://www.google.com/recaptcha/api.js'></script>
|
||||
{% endblock %}
|
||||
|
|
|
@ -0,0 +1,31 @@
|
|||
{% load crispy_forms_tags %}
|
||||
{% load recapture %}
|
||||
{% load sekizai_tags i18n wiki_tags static %}
|
||||
|
||||
<form method="POST" action="{% url 'requests_form' %}" class="ui form">
|
||||
{% csrf_token %}
|
||||
{{ form|crispy }}
|
||||
{{ google_capture }}
|
||||
<button class="btn btn-primary " type="submit" name="action">
|
||||
<span class="fa fa-submit" ></span>
|
||||
{% trans "Send" %}</button>
|
||||
</form>
|
||||
|
||||
{% addtoblock "css" %}
|
||||
<link href="{% static 'plugins/css/ace.min.css' %}" type="text/css" media="all" rel="stylesheet" />
|
||||
<link href="{% static 'plugins/css/semantic.min.css' %}" type="text/css" media="all" rel="stylesheet" />
|
||||
<link href="{% static 'martor/css/martor.css' %}" type="text/css" media="all" rel="stylesheet" />
|
||||
{% endaddtoblock css %}
|
||||
|
||||
{% addtoblock "js" %}
|
||||
<script src='https://www.google.com/recaptcha/api.js'></script>
|
||||
<script type="text/javascript" src="{% static 'plugins/js/ace.js' %}"></script>
|
||||
<script type="text/javascript" src="{% static 'plugins/js/semantic.min.js' %}"></script>
|
||||
<script type="text/javascript" src="{% static 'plugins/js/mode-markdown.js' %}"></script>
|
||||
<script type="text/javascript" src="{% static 'plugins/js/ext-language_tools.js' %}"></script>
|
||||
<script type="text/javascript" src="{% static 'plugins/js/theme-github.js' %}"></script>
|
||||
<script type="text/javascript" src="{% static 'plugins/js/highlight.min.js' %}"></script>
|
||||
<script type="text/javascript" src="{% static 'plugins/js/resizable.min.js' %}"></script>
|
||||
<script type="text/javascript" src="{% static 'plugins/js/emojis.min.js' %}"></script>
|
||||
<script type="text/javascript" src="{% static 'martor/js/martor.min.js' %}"></script>
|
||||
{% endaddtoblock %}
|
Loading…
Reference in New Issue