From 41568916b832d4f5ee8660cfe747788f6a51b24a Mon Sep 17 00:00:00 2001
From: Pierre-antoine Comby <comby@crans.org>
Date: Tue, 24 Mar 2020 22:13:15 +0100
Subject: [PATCH] error fixes

---
 apps/note/views.py                           | 2 +-
 apps/permission/permissions.py               | 1 +
 templates/note/transactiontemplate_list.html | 1 -
 3 files changed, 2 insertions(+), 2 deletions(-)

diff --git a/apps/note/views.py b/apps/note/views.py
index a8118cb2..8a7d24fd 100644
--- a/apps/note/views.py
+++ b/apps/note/views.py
@@ -109,7 +109,7 @@ class TransactionTemplateCreateView(LoginRequiredMixin, CreateView):
     """
     model = TransactionTemplate
     form_class = TransactionTemplateForm
-    success_url = reverse_lazy('template_list')
+    success_url = reverse_lazy('note:template_list')
 
 class TransactionTemplateListView(LoginRequiredMixin, SingleTableView):
     """
diff --git a/apps/permission/permissions.py b/apps/permission/permissions.py
index 7959065f..9f6d8cd2 100644
--- a/apps/permission/permissions.py
+++ b/apps/permission/permissions.py
@@ -2,6 +2,7 @@
 # SPDX-License-Identifier: GPL-3.0-or-later
 
 from rest_framework.permissions import DjangoObjectPermissions
+from .backends import PermissionBackend
 
 SAFE_METHODS = ('HEAD', 'OPTIONS', )
 
diff --git a/templates/note/transactiontemplate_list.html b/templates/note/transactiontemplate_list.html
index ca88010f..ea227ea8 100644
--- a/templates/note/transactiontemplate_list.html
+++ b/templates/note/transactiontemplate_list.html
@@ -60,7 +60,6 @@ function search_field_moved(secondfield) {
 }
 // on click of button "delete" , call the API 
  function delete_button(button_id){
-     console.log(button_id);
      $.ajax({
          url:"/api/note/transaction/template/"+button_id,
          method:"DELETE",
-- 
GitLab