diff --git a/src/documents/migrations/1056_customfieldinstance_deleted_at_and_more.py b/src/documents/migrations/1056_customfieldinstance_deleted_at_and_more.py index 2b29620db..eba1e4281 100644 --- a/src/documents/migrations/1056_customfieldinstance_deleted_at_and_more.py +++ b/src/documents/migrations/1056_customfieldinstance_deleted_at_and_more.py @@ -1,4 +1,4 @@ -# Generated by Django 5.1.2 on 2024-10-28 01:46 +# Generated by Django 5.1.2 on 2024-10-28 01:55 from django.db import migrations from django.db import models @@ -25,4 +25,34 @@ class Migration(migrations.Migration): name="transaction_id", field=models.UUIDField(blank=True, null=True), ), + migrations.AddField( + model_name="note", + name="deleted_at", + field=models.DateTimeField(blank=True, null=True), + ), + migrations.AddField( + model_name="note", + name="restored_at", + field=models.DateTimeField(blank=True, null=True), + ), + migrations.AddField( + model_name="note", + name="transaction_id", + field=models.UUIDField(blank=True, null=True), + ), + migrations.AddField( + model_name="sharelink", + name="deleted_at", + field=models.DateTimeField(blank=True, null=True), + ), + migrations.AddField( + model_name="sharelink", + name="restored_at", + field=models.DateTimeField(blank=True, null=True), + ), + migrations.AddField( + model_name="sharelink", + name="transaction_id", + field=models.UUIDField(blank=True, null=True), + ), ] diff --git a/src/documents/models.py b/src/documents/models.py index e74ff318c..4528d5127 100644 --- a/src/documents/models.py +++ b/src/documents/models.py @@ -710,7 +710,7 @@ class PaperlessTask(models.Model): return f"Task {self.task_id}" -class Note(models.Model): +class Note(SoftDeleteModel): note = models.TextField( _("content"), blank=True, @@ -750,7 +750,7 @@ class Note(models.Model): return self.note -class ShareLink(models.Model): +class ShareLink(SoftDeleteModel): class FileVersion(models.TextChoices): ARCHIVE = ("archive", _("Archive")) ORIGINAL = ("original", _("Original"))