mirror of
https://github.com/pacnpal/thrillwiki_django_no_react.git
synced 2025-12-20 09:31:09 -05:00
fix commas
This commit is contained in:
20
history_tracking/apps.py
Normal file
20
history_tracking/apps.py
Normal file
@@ -0,0 +1,20 @@
|
||||
# history_tracking/apps.py
|
||||
from django.apps import AppConfig
|
||||
|
||||
|
||||
class HistoryTrackingConfig(AppConfig):
|
||||
default_auto_field = "django.db.models.BigAutoField"
|
||||
name = "history_tracking"
|
||||
|
||||
def ready(self):
|
||||
from .mixins import HistoricalChangeMixin
|
||||
from .models import Park
|
||||
|
||||
models_with_history = [Park]
|
||||
|
||||
for model in models_with_history:
|
||||
# Check if mixin is already applied
|
||||
if HistoricalChangeMixin not in model.history.model.__bases__:
|
||||
model.history.model.__bases__ = (
|
||||
HistoricalChangeMixin,
|
||||
) + model.history.model.__bases__
|
||||
Reference in New Issue
Block a user