From ebd81795a391ff7a32d86a9a449f11eec40a2909 Mon Sep 17 00:00:00 2001 From: Rohan Moniz Date: Thu, 2 Nov 2023 13:16:52 -0400 Subject: [PATCH] isort --- backend/announcements/admin.py | 3 ++- .../announcements/management/commands/populate_audiences.py | 3 +-- backend/announcements/serializers.py | 2 +- backend/announcements/urls.py | 1 + backend/announcements/views.py | 4 ++-- 5 files changed, 7 insertions(+), 6 deletions(-) diff --git a/backend/announcements/admin.py b/backend/announcements/admin.py index c45583a..0825ab7 100644 --- a/backend/announcements/admin.py +++ b/backend/announcements/admin.py @@ -1,5 +1,6 @@ +from announcements.models import Announcement, Audience from django.contrib import admin -from announcements.models import Audience, Announcement + admin.site.register(Audience) admin.site.register(Announcement) diff --git a/backend/announcements/management/commands/populate_audiences.py b/backend/announcements/management/commands/populate_audiences.py index 39785fc..1f71568 100644 --- a/backend/announcements/management/commands/populate_audiences.py +++ b/backend/announcements/management/commands/populate_audiences.py @@ -1,6 +1,5 @@ -from django.core.management import BaseCommand - from announcements.models import Audience +from django.core.management import BaseCommand class Command(BaseCommand): diff --git a/backend/announcements/serializers.py b/backend/announcements/serializers.py index 0c8924e..6dd56a1 100644 --- a/backend/announcements/serializers.py +++ b/backend/announcements/serializers.py @@ -1,5 +1,5 @@ -from rest_framework import serializers from announcements.models import Announcement, Audience +from rest_framework import serializers class AudienceSerializer(serializers.ModelSerializer): diff --git a/backend/announcements/urls.py b/backend/announcements/urls.py index 4dde8f7..f78968c 100644 --- a/backend/announcements/urls.py +++ b/backend/announcements/urls.py @@ -1,6 +1,7 @@ from announcements.views import AnnouncementsViewSet from rest_framework import routers + app_name = "announcements" router = routers.SimpleRouter() router.register("", AnnouncementsViewSet) diff --git a/backend/announcements/views.py b/backend/announcements/views.py index eeb41c2..9813e2d 100644 --- a/backend/announcements/views.py +++ b/backend/announcements/views.py @@ -1,7 +1,7 @@ -from announcements.serializers import AnnouncementSerializer -from rest_framework import viewsets from announcements.models import Announcement from announcements.permissions import IsSuperuser +from announcements.serializers import AnnouncementSerializer +from rest_framework import viewsets class AnnouncementsViewSet(viewsets.ModelViewSet):