mirror of
https://github.com/daniviga/django-ram.git
synced 2025-08-04 05:07:50 +02:00
Allow books with no authors
This commit is contained in:
18
ram/bookshelf/migrations/0015_alter_book_authors.py
Normal file
18
ram/bookshelf/migrations/0015_alter_book_authors.py
Normal file
@@ -0,0 +1,18 @@
|
||||
# Generated by Django 5.1.2 on 2024-11-26 22:21
|
||||
|
||||
from django.db import migrations, models
|
||||
|
||||
|
||||
class Migration(migrations.Migration):
|
||||
|
||||
dependencies = [
|
||||
("bookshelf", "0014_book_published"),
|
||||
]
|
||||
|
||||
operations = [
|
||||
migrations.AlterField(
|
||||
model_name="book",
|
||||
name="authors",
|
||||
field=models.ManyToManyField(blank=True, to="bookshelf.author"),
|
||||
),
|
||||
]
|
@@ -40,7 +40,7 @@ class Author(models.Model):
|
||||
|
||||
class Book(BaseModel):
|
||||
title = models.CharField(max_length=200)
|
||||
authors = models.ManyToManyField(Author)
|
||||
authors = models.ManyToManyField(Author, blank=True)
|
||||
publisher = models.ForeignKey(Publisher, on_delete=models.CASCADE)
|
||||
ISBN = models.CharField(max_length=17, blank=True) # 13 + dashes
|
||||
language = models.CharField(
|
||||
|
@@ -1,4 +1,4 @@
|
||||
from ram.utils import git_suffix
|
||||
|
||||
__version__ = "0.13.4"
|
||||
__version__ = "0.13.5"
|
||||
__version__ += git_suffix(__file__)
|
||||
|
Reference in New Issue
Block a user