50 lines
1.5 KiB
HTML
50 lines
1.5 KiB
HTML
{% extends "users/base.html" %}
|
|
{% load crispy_forms_tags %}
|
|
{% load static %}
|
|
{% block content %}
|
|
{% if request.user.profile.agency.module_news %}
|
|
<div class="content-section col-6">
|
|
|
|
<h3>News anlegen</h3>
|
|
<hr>
|
|
<form method="POST">
|
|
{% csrf_token %}
|
|
{{normalForm.media}}
|
|
{{normalForm|crispy}}
|
|
<hr>
|
|
<button type="submit" class="btn btn-primary" href="{% url 'news-add' %} ">News anlegen</button>
|
|
<a class="btn" href="{% url 'news-management' %} ">Abbrechen</a>
|
|
</form>
|
|
</div>
|
|
<script type="text/javascript">
|
|
$(document).ready(function() {
|
|
$('#id_content').summernote({
|
|
height: 400,
|
|
lang: "de-DE",
|
|
disableDragAndDrop: true,
|
|
toolbar: [
|
|
['style', ['style']],
|
|
['fontname', ['fontname']],
|
|
['style', ['bold', 'italic', 'underline', 'clear']],
|
|
['fontsize', ['fontsize']],
|
|
['color', ['color']],
|
|
['para', ['ul', 'ol', 'paragraph']],
|
|
['height', ['height']],
|
|
['table', ['table']],
|
|
['insert', ['link', 'picture', 'video']],
|
|
['hr', ['hr']],
|
|
['view', ['fullscreen', 'codeview', 'help']],
|
|
]
|
|
});
|
|
|
|
//Set offline-Datei plus 2 weeks
|
|
//today = new Date();
|
|
//today = new Date(today.setDate(today.getDate() + 14));
|
|
//$("#id_go_offline_on").data("DateTimePicker").date(today);
|
|
|
|
});
|
|
</script>
|
|
{% else %}
|
|
<h3>Das Modul News wurde in ihrer Agentur deaktiviert.</h3>
|
|
{% endif %}
|
|
{% endblock content %} |