feat: add book metadata editor with Google Books and OpenLibrary integration

This commit is contained in:
2025-05-17 15:49:26 -04:00
parent f4f227b24d
commit d2b88f4e59
11 changed files with 981 additions and 30 deletions

View File

@@ -3,7 +3,13 @@ const axios = require('axios');
// Fetch book from the local database by ISBN
const fetchBookFromLocalDatabase = async (isbn) => {
return await Book.findOne({ where: { isbn } });
return await Book.findOne({
where: { isbn },
include: [{
model: Location,
as: 'Location'
}]
});
};
// Fetch book from Google Books API