mirror of
https://github.com/flibusta-apps/book_library_server.git
synced 2025-12-06 15:15:36 +01:00
Fix
This commit is contained in:
@@ -148,7 +148,7 @@ async fn get_author_books(
|
|||||||
let author = db
|
let author = db
|
||||||
.author()
|
.author()
|
||||||
.find_unique(
|
.find_unique(
|
||||||
author::id::equals(author_id)
|
author::id::equals(author_id),
|
||||||
)
|
)
|
||||||
.with(
|
.with(
|
||||||
author::author_annotation::fetch()
|
author::author_annotation::fetch()
|
||||||
@@ -165,6 +165,7 @@ async fn get_author_books(
|
|||||||
let books_count = db
|
let books_count = db
|
||||||
.book()
|
.book()
|
||||||
.count(vec![
|
.count(vec![
|
||||||
|
book::is_deleted::equals(false),
|
||||||
book::book_authors::some(vec![
|
book::book_authors::some(vec![
|
||||||
book_author::author_id::equals(author_id)
|
book_author::author_id::equals(author_id)
|
||||||
]),
|
]),
|
||||||
@@ -177,6 +178,7 @@ async fn get_author_books(
|
|||||||
let books = db
|
let books = db
|
||||||
.book()
|
.book()
|
||||||
.find_many(vec![
|
.find_many(vec![
|
||||||
|
book::is_deleted::equals(false),
|
||||||
book::book_authors::some(vec![
|
book::book_authors::some(vec![
|
||||||
book_author::author_id::equals(author_id)
|
book_author::author_id::equals(author_id)
|
||||||
]),
|
]),
|
||||||
@@ -229,6 +231,7 @@ async fn get_author_books_available_types(
|
|||||||
let books = db
|
let books = db
|
||||||
.book()
|
.book()
|
||||||
.find_many(vec![
|
.find_many(vec![
|
||||||
|
book::is_deleted::equals(false),
|
||||||
book::book_authors::some(vec![
|
book::book_authors::some(vec![
|
||||||
book_author::author_id::equals(author_id)
|
book_author::author_id::equals(author_id)
|
||||||
]),
|
]),
|
||||||
|
|||||||
@@ -137,6 +137,7 @@ async fn get_sequence_available_types(
|
|||||||
let books = db
|
let books = db
|
||||||
.book()
|
.book()
|
||||||
.find_many(vec![
|
.find_many(vec![
|
||||||
|
book::is_deleted::equals(false),
|
||||||
book::book_sequences::some(vec![
|
book::book_sequences::some(vec![
|
||||||
book_sequence::sequence_id::equals(sequence_id)
|
book_sequence::sequence_id::equals(sequence_id)
|
||||||
]),
|
]),
|
||||||
@@ -184,6 +185,7 @@ async fn get_sequence_books(
|
|||||||
let books_count = db
|
let books_count = db
|
||||||
.book()
|
.book()
|
||||||
.count(vec![
|
.count(vec![
|
||||||
|
book::is_deleted::equals(false),
|
||||||
book::book_sequences::some(vec![
|
book::book_sequences::some(vec![
|
||||||
book_sequence::sequence_id::equals(sequence_id)
|
book_sequence::sequence_id::equals(sequence_id)
|
||||||
]),
|
]),
|
||||||
@@ -196,6 +198,7 @@ async fn get_sequence_books(
|
|||||||
let books = db
|
let books = db
|
||||||
.book()
|
.book()
|
||||||
.find_many(vec![
|
.find_many(vec![
|
||||||
|
book::is_deleted::equals(false),
|
||||||
book::book_sequences::some(vec![
|
book::book_sequences::some(vec![
|
||||||
book_sequence::sequence_id::equals(sequence_id)
|
book_sequence::sequence_id::equals(sequence_id)
|
||||||
]),
|
]),
|
||||||
|
|||||||
@@ -33,6 +33,7 @@ async fn get_translated_books(
|
|||||||
let books_count = db
|
let books_count = db
|
||||||
.book()
|
.book()
|
||||||
.count(vec![
|
.count(vec![
|
||||||
|
book::is_deleted::equals(false),
|
||||||
book::translations::some(vec![
|
book::translations::some(vec![
|
||||||
translator::author_id::equals(translator_id)
|
translator::author_id::equals(translator_id)
|
||||||
]),
|
]),
|
||||||
@@ -45,6 +46,7 @@ async fn get_translated_books(
|
|||||||
let books = db
|
let books = db
|
||||||
.book()
|
.book()
|
||||||
.find_many(vec![
|
.find_many(vec![
|
||||||
|
book::is_deleted::equals(false),
|
||||||
book::translations::some(vec![
|
book::translations::some(vec![
|
||||||
translator::author_id::equals(translator_id)
|
translator::author_id::equals(translator_id)
|
||||||
]),
|
]),
|
||||||
@@ -97,6 +99,7 @@ async fn get_translated_books_available_types(
|
|||||||
let books = db
|
let books = db
|
||||||
.book()
|
.book()
|
||||||
.find_many(vec![
|
.find_many(vec![
|
||||||
|
book::is_deleted::equals(false),
|
||||||
book::translations::some(vec![
|
book::translations::some(vec![
|
||||||
translator::author_id::equals(translator_id)
|
translator::author_id::equals(translator_id)
|
||||||
]),
|
]),
|
||||||
|
|||||||
Reference in New Issue
Block a user