Add open library API call when search has no result

This commit is contained in:
2025-12-27 01:23:40 +01:00
parent 746f6312b1
commit 167e711649
7 changed files with 1261 additions and 20 deletions

View File

@@ -7,6 +7,7 @@
const props = defineProps({
id: Number,
openlibraryid: String,
title: String,
author: String,
rating: Number,
@@ -27,7 +28,11 @@ async function onUserBookRead() {
}
function openBook() {
router.push(`/book/${props.id}`)
if (props.id != 0) {
router.push(`/book/${props.id}`);
} else {
console.log("Open Library Id : " + props.openlibraryid);
}
}
</script>