Moving api requests to another controller.
This commit is contained in:
1 parent
314f4f2a14
commit
f715f401e1
5 files changed
+36
-24
No files matched your search
@@ -53,13 +53,13 @@ export default {
|
||||
},
|
||||
methods: {
|
||||
search: function () {
|
||||
axios.get('/book/search/' + this.searchTerm).then(response => {
|
||||
axios.get('/online/search/' + this.searchTerm).then(response => {
|
||||
this.books = response.data;
|
||||
});
|
||||
},
|
||||
getBookDetails: function (url) {
|
||||
this.manualMode = true;
|
||||
axios.get('/book/info/' + btoa(url)).then(response => {
|
||||
axios.get('/online/info/' + btoa(url)).then(response => {
|
||||
const book = this.selectedBook = response.data;
|
||||
this.$el.querySelector('#book_title').value = book.title;
|
||||
this.$el.querySelector('#book_author').value = book.author;
|
||||
|
||||
Reference in new issue
Block a user