fnp
/
redakcja.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
ptrad
[redakcja.git]
/
src
/
sources
/
models.py
diff --git
a/src/sources/models.py
b/src/sources/models.py
index
dd521da
..
ed2775e
100644
(file)
--- a/
src/sources/models.py
+++ b/
src/sources/models.py
@@
-130,7
+130,7
@@
class BookSource(models.Model):
return f'{self.source} -> {self.book}'
def get_absolute_url(self):
return f'{self.source} -> {self.book}'
def get_absolute_url(self):
- return reverse('source_book_prepare', args=[self.pk])
+ return reverse('source_book_prepare', args=[self.
book.
pk])
def get_view_files(self):
# TODO: won't work for PDFs.
def get_view_files(self):
# TODO: won't work for PDFs.
@@
-162,6
+162,7
@@
class BookSource(models.Model):
if dbook is None:
dbook = DBook.create(
user, texts[0],
if dbook is None:
dbook = DBook.create(
user, texts[0],
+ catalogue_book=book,
title=book.title,
slug=str(uuid.uuid4()),
)
title=book.title,
slug=str(uuid.uuid4()),
)