mirror of
https://github.com/daniviga/django-ram.git
synced 2025-08-04 05:07:50 +02:00
* Add support for generic documents * Add publish / unpublish actions * Minor improvements to models properties
41 lines
1.2 KiB
Python
41 lines
1.2 KiB
Python
# Generated by Django 5.1.4 on 2025-01-17 09:31
|
|
|
|
import ram.utils
|
|
from django.db import migrations, models
|
|
|
|
|
|
class Migration(migrations.Migration):
|
|
|
|
dependencies = [
|
|
("metadata", "0020_alter_decoderdocument_unique_together_and_more"),
|
|
]
|
|
|
|
operations = [
|
|
migrations.CreateModel(
|
|
name="GenericDocument",
|
|
fields=[
|
|
(
|
|
"id",
|
|
models.BigAutoField(
|
|
auto_created=True,
|
|
primary_key=True,
|
|
serialize=False,
|
|
verbose_name="ID",
|
|
),
|
|
),
|
|
("description", models.CharField(blank=True, max_length=128)),
|
|
(
|
|
"file",
|
|
models.FileField(
|
|
storage=ram.utils.DeduplicatedStorage(), upload_to="files/"
|
|
),
|
|
),
|
|
("private", models.BooleanField(default=False)),
|
|
("tags", models.ManyToManyField(blank=True, to="metadata.tag")),
|
|
],
|
|
options={
|
|
"verbose_name_plural": "Generic Documents",
|
|
},
|
|
),
|
|
]
|