diff --git a/smash/web/templates/_base.html b/smash/web/templates/_base.html index 8779d279c12492c247e55b19c3e5223cc6803d8c..4f4b59bf72f636625948a85cbd018358e2857a39 100644 --- a/smash/web/templates/_base.html +++ b/smash/web/templates/_base.html @@ -186,8 +186,8 @@ desired effect </div> </div> <!-- /.row --> - {% endcomment %} </li> + {% endcomment %} <!-- Menu Footer--> <li class="user-footer"> <!--<div class="pull-left"> diff --git a/smash/web/templates/mail_templates/index.html b/smash/web/templates/mail_templates/index.html deleted file mode 100644 index 137ade1b2b90f7773f205a2a6d81981db5212e75..0000000000000000000000000000000000000000 --- a/smash/web/templates/mail_templates/index.html +++ /dev/null @@ -1,134 +0,0 @@ -{% extends "_base.html" %} -{% load static %} - -{% block styles %} - {{ block.super }} - <!-- DataTables --> - <link rel="stylesheet" href="{% static 'AdminLTE/plugins/datatables/dataTables.bootstrap.css' %}"> -{% endblock styles %} - -{% block ui_active_tab %}'mail_templates'{% endblock ui_active_tab %} -{% block page_header %}Mail templates{% endblock page_header %} -{% block page_description %}{% endblock page_description %} - -{% block breadcrumb %} - {% include "mail_templates/breadcrumb.html" %} -{% endblock breadcrumb %} - -{% block maincontent %} - <div class="box box-danger box-solid"> - <div class="box-header with-border"> - <h3 class="box-title">Not yet implemented</h3> - - <div class="box-tools pull-right"> - <button type="button" class="btn btn-box-tool" data-widget="remove"><i class="fa fa-times"></i></button> - </div> - <!-- /.box-tools --> - </div> - <!-- /.box-header --> - <div class="box-body"> - This is only a static page to show, how the system would look like. - A comprehensive system for template editing and generation has to be developed. - </div> - <!-- /.box-body --> - </div> - - <div> - <a class="btn btn-app"> - <i class="fa fa-plus"></i> Add new letter - </a> - </div> - - <div class="box-body"> - <table id="table" class="table table-bordered table-striped"> - <thead> - <tr> - <th>No.</th> - <th>Destination</th> - <th>Language</th> - <th>Title</th> - <th>Details</th> - <th>Edit</th> - <th>Delete</th> - <th>Generate</th> - </tr> - </thead> - <tbody> - <tr> - <td>1</td> - <td>Patients</td> - <td>english</td> - <td>"Thank you" letter</td> - <td> - <button type="button" class="btn btn-block btn-default">Details</button> - </td> - <td> - <button type="button" class="btn btn-block btn-warning">Edit</button> - </td> - <td> - <button type="button" class="btn btn-block btn-danger">Delete</button> - </td> - <td> - <button type="button" class="btn btn-block btn-default">Generate</button> - </td> - </tr> - <tr> - <td>2</td> - <td>Patients</td> - <td>english</td> - <td>"Dankescreiben" letter</td> - <td> - <button type="button" class="btn btn-block btn-default">Details</button> - </td> - <td> - <button type="button" class="btn btn-block btn-warning">Edit</button> - </td> - <td> - <button type="button" class="btn btn-block btn-danger">Delete</button> - </td> - <td> - <button type="button" class="btn btn-block btn-default">Generate</button> - </td> - </tr> - <tr> - <td>3</td> - <td>Doctors</td> - <td>english</td> - <td>"New Scheduling system"</td> - <td> - <button type="button" class="btn btn-block btn-default">Details</button> - </td> - <td> - <button type="button" class="btn btn-block btn-warning">Edit</button> - </td> - <td> - <button type="button" class="btn btn-block btn-danger">Delete</button> - </td> - <td> - <button type="button" class="btn btn-block btn-default">Generate</button> - </td> - </tr> - </tbody> - </table> - </div> -{% endblock maincontent %} - -{% block scripts %} - {{ block.super }} - - <script src="{% static 'AdminLTE/plugins/datatables/jquery.dataTables.min.js' %}"></script> - <script src="{% static 'AdminLTE/plugins/datatables/dataTables.bootstrap.min.js' %}"></script> - - <script> - $(function () { - $('#table').DataTable({ - "paging": true, - "lengthChange": false, - "searching": true, - "ordering": true, - "info": true, - "autoWidth": false - }); - }); - </script> -{% endblock scripts %} diff --git a/smash/web/urls.py b/smash/web/urls.py index 6376c8d2a6300e3a9beaea96528ec2e919ec5d5d..1e97079064f8895f1a7b55dc7651153fe2ba7b72 100644 --- a/smash/web/urls.py +++ b/smash/web/urls.py @@ -133,7 +133,6 @@ urlpatterns = [ # MAIL # #################### - url(r'^mail_templates_old$', views.mails.mail_templates, name='web.views.mail_templates_old'), url(r'^mail_templates$', views.mails.MailTemplatesListView.as_view(), name='web.views.mail_templates'), url(r'^mail_templates/add$', views.mails.MailTemplatesCreateView.as_view(), name='web.views.mail_template_add'), url(r'^mail_templates/(?P<pk>\d+)/delete$', views.mails.MailTemplatesDeleteView.as_view(), diff --git a/smash/web/views/mails.py b/smash/web/views/mails.py index 8ca773008e269e26c2c9a03010ff25ad5f8df05a..78d33d4189374f9776058715650dec560b13d0d9 100644 --- a/smash/web/views/mails.py +++ b/smash/web/views/mails.py @@ -12,7 +12,7 @@ from django.views.generic import DeleteView from django.views.generic import ListView from django.views.generic import UpdateView -from . import wrap_response, WrappedView +from . import WrappedView from ..models import StudySubject, Visit, Appointment, MailTemplate from ..models.constants import MAIL_TEMPLATE_CONTEXT_SUBJECT, MAIL_TEMPLATE_CONTEXT_VISIT, \ MAIL_TEMPLATE_CONTEXT_APPOINTMENT @@ -26,10 +26,6 @@ CONTEXT_TYPES_MAPPING = { } -def mail_templates(request): - return wrap_response(request, "mail_templates/index.html", {}) - - class MailTemplatesListView(ListView, WrappedView): model = MailTemplate context_object_name = "mail_templates"