diff --git a/app/urls.py b/app/urls.py index c8a92ac..8545679 100644 --- a/app/urls.py +++ b/app/urls.py @@ -42,6 +42,12 @@ urlpatterns = [ path("accounts/", include("django.contrib.auth.urls")), path("accounts/signup/", base.Signup.as_view(), name="signup"), path("hooks//", hooks.Hooks.as_view(), name="hooks"), - path("hooks/modal/add/", hooks.AddHook.as_view(), name="add-hook"), - path("hooks/modal/add//", hooks.AddHook.as_view(), name="add-hook"), + path("hooks/modal/add/", hooks.HookAction.as_view(), name="hook_action"), + path("hooks/modal/add//", hooks.HookAction.as_view(), name="hook_action"), + path( + "hooks/page/del//", hooks.HookAction.as_view(), name="hook_action" + ), + path( + "hooks/page/edit//", hooks.HookAction.as_view(), name="hook_action" + ), ] + static(settings.STATIC_URL, document_root=settings.STATIC_ROOT) diff --git a/core/migrations/0003_hook.py b/core/migrations/0003_hook.py index 7ae5ae3..b48ad7a 100644 --- a/core/migrations/0003_hook.py +++ b/core/migrations/0003_hook.py @@ -1,8 +1,8 @@ # Generated by Django 4.1.2 on 2022-10-14 23:15 +import django.db.models.deletion from django.conf import settings from django.db import migrations, models -import django.db.models.deletion class Migration(migrations.Migration): diff --git a/core/templates/modals/add-hook.html b/core/templates/modals/add-hook.html index bf1902d..ee86ad6 100644 --- a/core/templates/modals/add-hook.html +++ b/core/templates/modals/add-hook.html @@ -5,7 +5,11 @@ {% block modal_content %}
{% csrf_token %} diff --git a/core/templates/partials/hook-list.html b/core/templates/partials/hook-list.html index f389743..852d3a5 100644 --- a/core/templates/partials/hook-list.html +++ b/core/templates/partials/hook-list.html @@ -1,21 +1,26 @@ {% include 'partials/notify.html' %} - - - - - - - {% for item in hooks %} - - - - - + + + + + + + + {% for item in hooks %} + + + + + + + - - {% endfor %} + + + + + {% endfor %}
userhookreceived hooksactions
{{ item.user }}{{ item.hook }}{{ item.received }} +
idusernamehookreceived hooksactions
{{ item.id }}{{ item.user }}{{ item.name }}{{ item.hook }}{{ item.received }} +
-
diff --git a/core/templates/window-content/hooks.html b/core/templates/window-content/hooks.html index 5135775..f3332c0 100644 --- a/core/templates/window-content/hooks.html +++ b/core/templates/window-content/hooks.html @@ -1,7 +1,7 @@