Skip to content

Commit

Permalink
Format code
Browse files Browse the repository at this point in the history
  • Loading branch information
oliver-ni committed Sep 16, 2023
1 parent e054e29 commit 7c7ef2f
Show file tree
Hide file tree
Showing 8 changed files with 2 additions and 7 deletions.
2 changes: 1 addition & 1 deletion hknweb/admin.py
Original file line number Diff line number Diff line change
Expand Up @@ -21,6 +21,7 @@
# Unregister the provided model admin
admin.site.unregister(User)


# Register out own model admin, based on the default UserAdmin
@admin.register(User)
class CustomUserAdmin(UserAdmin):
Expand Down Expand Up @@ -124,7 +125,6 @@ def provision_candidate_accounts(self, request):


class AnnouncementAdmin(admin.ModelAdmin):

# NOTE: release_date is not readonly because we can reuse announcements from past semesters
# The VP can just change the date and release it again
fields = ["title", "text", "visible", "release_date"]
Expand Down
1 change: 0 additions & 1 deletion hknweb/candidate/admin/announcement.py
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,6 @@

@admin.register(Announcement)
class AnnouncementAdmin(admin.ModelAdmin):

# NOTE: release_date is not readonly because we can reuse announcements from past semesters
# The VP can just change the date and release it again
fields = ["title", "text", "visible", "release_date"]
Expand Down
1 change: 0 additions & 1 deletion hknweb/candidate/admin/bitbyteactivity.py
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,6 @@

@admin.register(BitByteActivity)
class BitByteActivityAdmin(admin.ModelAdmin):

fields = ["participants", "confirmed", "proof", "notes", "request_date"]
readonly_fields = ["request_date"]
list_display = (
Expand Down
1 change: 0 additions & 1 deletion hknweb/candidate/admin/officer_challenge.py
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,6 @@

@admin.register(OffChallenge)
class OffChallengeAdmin(admin.ModelAdmin):

fields = [
"requester",
"officer",
Expand Down
1 change: 1 addition & 0 deletions hknweb/coursesemester/models.py
Original file line number Diff line number Diff line change
@@ -1,5 +1,6 @@
from django.db import models


# Create your models here.
class Department(models.Model):
abbreviated_name = models.CharField(
Expand Down
1 change: 0 additions & 1 deletion hknweb/events/admin/event.py
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,6 @@

@admin.register(Event)
class EventAdmin(admin.ModelAdmin):

fields = [
"name",
"start_time",
Expand Down
1 change: 0 additions & 1 deletion hknweb/events/admin/rsvp.py
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,6 @@

@admin.register(Rsvp)
class RsvpAdmin(admin.ModelAdmin):

fields = ["event", "user", "confirmed", "comment", "created_at"]
readonly_fields = ["created_at"]
list_display = ("event", "user", "full_name", "confirmed", "created_at")
Expand Down
1 change: 0 additions & 1 deletion hknweb/utils.py
Original file line number Diff line number Diff line change
Expand Up @@ -210,7 +210,6 @@ def markdownify(text):

# Sanitize html if wanted
if getattr(settings, "MARKDOWNIFY_BLEACH", True):

cleaner = bleach.Cleaner(
tags=whitelist_tags,
attributes=whitelist_attrs,
Expand Down

0 comments on commit 7c7ef2f

Please sign in to comment.