mirror of
https://github.com/ae-utbm/sith.git
synced 2025-07-10 11:59:23 +00:00
reorganize imports with ruff
This commit is contained in:
@ -23,18 +23,15 @@
|
||||
#
|
||||
#
|
||||
|
||||
from django.conf import settings
|
||||
from ajax_select.fields import AutoCompleteSelectMultipleField
|
||||
from django import forms
|
||||
from django.conf import settings
|
||||
from django.utils.translation import gettext_lazy as _
|
||||
|
||||
from ajax_select.fields import AutoCompleteSelectField, AutoCompleteSelectMultipleField
|
||||
|
||||
from club.models import Mailing, MailingSubscription, Club, Membership
|
||||
|
||||
from club.models import Club, Mailing, MailingSubscription, Membership
|
||||
from core.models import User
|
||||
from core.views.forms import SelectDate, SelectDateTime
|
||||
from core.views.forms import SelectDate, TzAwareDateTimeField
|
||||
from counter.models import Counter
|
||||
from core.views.forms import TzAwareDateTimeField
|
||||
|
||||
|
||||
class ClubEditForm(forms.ModelForm):
|
||||
|
@ -1,9 +1,9 @@
|
||||
# -*- coding: utf-8 -*-
|
||||
from __future__ import unicode_literals
|
||||
|
||||
from django.db import migrations, models
|
||||
import django.core.validators
|
||||
import django.db.models.deletion
|
||||
from django.db import migrations, models
|
||||
|
||||
|
||||
class Migration(migrations.Migration):
|
||||
|
@ -1,9 +1,9 @@
|
||||
# -*- coding: utf-8 -*-
|
||||
from __future__ import unicode_literals
|
||||
|
||||
from django.db import migrations, models
|
||||
from django.conf import settings
|
||||
import django.db.models.deletion
|
||||
from django.conf import settings
|
||||
from django.db import migrations, models
|
||||
|
||||
|
||||
class Migration(migrations.Migration):
|
||||
|
@ -1,9 +1,9 @@
|
||||
# -*- coding: utf-8 -*-
|
||||
from __future__ import unicode_literals
|
||||
|
||||
from django.db import migrations, models
|
||||
from django.conf import settings
|
||||
import django.db.models.deletion
|
||||
from django.conf import settings
|
||||
from django.db import migrations, models
|
||||
|
||||
|
||||
class Migration(migrations.Migration):
|
||||
|
@ -1,8 +1,8 @@
|
||||
# -*- coding: utf-8 -*-
|
||||
from __future__ import unicode_literals
|
||||
|
||||
from django.db import migrations, models
|
||||
import django.db.models.deletion
|
||||
from django.db import migrations, models
|
||||
|
||||
|
||||
class Migration(migrations.Migration):
|
||||
|
@ -1,8 +1,8 @@
|
||||
# -*- coding: utf-8 -*-
|
||||
from __future__ import unicode_literals
|
||||
|
||||
from django.db import migrations, models
|
||||
import django.utils.timezone
|
||||
from django.db import migrations, models
|
||||
|
||||
|
||||
class Migration(migrations.Migration):
|
||||
|
@ -1,7 +1,7 @@
|
||||
# -*- coding: utf-8 -*-
|
||||
from __future__ import unicode_literals
|
||||
|
||||
from django.db import migrations, models
|
||||
from django.db import migrations
|
||||
|
||||
|
||||
class Migration(migrations.Migration):
|
||||
|
@ -1,11 +1,12 @@
|
||||
# -*- coding: utf-8 -*-
|
||||
from __future__ import unicode_literals
|
||||
|
||||
from django.db import migrations, models
|
||||
from django.conf import settings
|
||||
import re
|
||||
|
||||
import django.core.validators
|
||||
import django.db.models.deletion
|
||||
from django.conf import settings
|
||||
from django.db import migrations, models
|
||||
|
||||
|
||||
class Migration(migrations.Migration):
|
||||
|
@ -1,11 +1,11 @@
|
||||
# -*- coding: utf-8 -*-
|
||||
from __future__ import unicode_literals
|
||||
|
||||
import django.db.models.deletion
|
||||
from django.db import migrations, models
|
||||
|
||||
from club.models import Club
|
||||
from core.operations import PsqlRunOnly
|
||||
import django.db.models.deletion
|
||||
|
||||
|
||||
def generate_club_pages(apps, schema_editor):
|
||||
|
@ -1,9 +1,10 @@
|
||||
# -*- coding: utf-8 -*-
|
||||
from __future__ import unicode_literals
|
||||
|
||||
from django.db import migrations, models
|
||||
import club.models
|
||||
import django.db.models.deletion
|
||||
from django.db import migrations, models
|
||||
|
||||
import club.models
|
||||
|
||||
|
||||
class Migration(migrations.Migration):
|
||||
|
@ -24,21 +24,19 @@
|
||||
#
|
||||
from typing import Optional
|
||||
|
||||
from django.core.cache import cache
|
||||
from django.db import models
|
||||
from django.core import validators
|
||||
from django.conf import settings
|
||||
from django.core import validators
|
||||
from django.core.cache import cache
|
||||
from django.core.exceptions import ObjectDoesNotExist, ValidationError
|
||||
from django.core.validators import RegexValidator, validate_email
|
||||
from django.db import models, transaction
|
||||
from django.db.models import Q
|
||||
from django.utils.timezone import now
|
||||
from django.utils.translation import gettext_lazy as _
|
||||
from django.core.exceptions import ValidationError, ObjectDoesNotExist
|
||||
from django.db import transaction
|
||||
from django.urls import reverse
|
||||
from django.utils import timezone
|
||||
from django.core.validators import RegexValidator, validate_email
|
||||
from django.utils.functional import cached_property
|
||||
from django.utils.translation import gettext_lazy as _
|
||||
|
||||
from core.models import User, MetaGroup, Group, SithFile, RealGroup, Notification, Page
|
||||
from core.models import Group, MetaGroup, Notification, Page, RealGroup, SithFile, User
|
||||
|
||||
# Create your models here.
|
||||
|
||||
|
@ -18,15 +18,14 @@ from datetime import timedelta
|
||||
from django.conf import settings
|
||||
from django.core.cache import cache
|
||||
from django.test import TestCase
|
||||
from django.utils import timezone, html
|
||||
from django.utils.timezone import now, localtime
|
||||
from django.utils.translation import gettext as _
|
||||
from django.urls import reverse
|
||||
from django.core.management import call_command
|
||||
from django.utils import html, timezone
|
||||
from django.utils.timezone import localtime, now
|
||||
from django.utils.translation import gettext as _
|
||||
|
||||
from core.models import User, AnonymousUser
|
||||
from club.models import Club, Membership, Mailing
|
||||
from club.forms import MailingForm
|
||||
from club.models import Club, Mailing, Membership
|
||||
from core.models import AnonymousUser, User
|
||||
from sith.settings import SITH_BAR_MANAGER, SITH_MAIN_CLUB_ID
|
||||
|
||||
|
||||
|
@ -26,50 +26,42 @@
|
||||
import csv
|
||||
|
||||
from django.conf import settings
|
||||
from django import forms
|
||||
from django.views.generic import ListView, DetailView, TemplateView, View
|
||||
from django.views.generic.edit import DeleteView
|
||||
from django.views.generic.detail import SingleObjectMixin
|
||||
from django.views.generic.edit import UpdateView, CreateView
|
||||
from django.core.exceptions import NON_FIELD_ERRORS, PermissionDenied, ValidationError
|
||||
from django.core.paginator import InvalidPage, Paginator
|
||||
from django.db.models import Sum
|
||||
from django.http import (
|
||||
HttpResponseRedirect,
|
||||
HttpResponse,
|
||||
Http404,
|
||||
HttpResponseRedirect,
|
||||
StreamingHttpResponse,
|
||||
)
|
||||
from django.shortcuts import get_object_or_404, redirect
|
||||
from django.urls import reverse, reverse_lazy
|
||||
from django.utils import timezone
|
||||
from django.utils.translation import gettext_lazy as _
|
||||
from django.utils.translation import gettext as _t
|
||||
from django.core.exceptions import PermissionDenied, ValidationError, NON_FIELD_ERRORS
|
||||
from django.core.paginator import Paginator, InvalidPage
|
||||
from django.shortcuts import get_object_or_404, redirect
|
||||
from django.db.models import Sum
|
||||
from django.utils.translation import gettext_lazy as _
|
||||
from django.views.generic import DetailView, ListView, TemplateView, View
|
||||
from django.views.generic.edit import CreateView, DeleteView, UpdateView
|
||||
|
||||
|
||||
from core.views import (
|
||||
CanCreateMixin,
|
||||
CanViewMixin,
|
||||
CanEditMixin,
|
||||
CanEditPropMixin,
|
||||
UserIsRootMixin,
|
||||
TabedViewMixin,
|
||||
PageEditViewBase,
|
||||
DetailFormView,
|
||||
from club.forms import ClubEditForm, ClubMemberForm, MailingForm, SellingsForm
|
||||
from club.models import Club, Mailing, MailingSubscription, Membership
|
||||
from com.views import (
|
||||
PosterCreateBaseView,
|
||||
PosterDeleteBaseView,
|
||||
PosterEditBaseView,
|
||||
PosterListBaseView,
|
||||
)
|
||||
from core.models import PageRev
|
||||
|
||||
from counter.models import Selling
|
||||
|
||||
from com.views import (
|
||||
PosterListBaseView,
|
||||
PosterCreateBaseView,
|
||||
PosterEditBaseView,
|
||||
PosterDeleteBaseView,
|
||||
from core.views import (
|
||||
CanCreateMixin,
|
||||
CanEditMixin,
|
||||
CanEditPropMixin,
|
||||
CanViewMixin,
|
||||
DetailFormView,
|
||||
PageEditViewBase,
|
||||
TabedViewMixin,
|
||||
UserIsRootMixin,
|
||||
)
|
||||
|
||||
from club.models import Club, Membership, Mailing, MailingSubscription
|
||||
from club.forms import MailingForm, ClubEditForm, ClubMemberForm, SellingsForm
|
||||
from counter.models import Selling
|
||||
|
||||
|
||||
class ClubTabsMixin(TabedViewMixin):
|
||||
|
Reference in New Issue
Block a user