I am encountering an issue when attempting to pass a parameter from the HTML page to delete a row from the database. The http.get() method retrieves data for all books, and I am passing the ID for a specific book for deletion. However, I am facing a syntax error upon return.
Below is the HTML page featuring a delete button with a function call triggered by ng-click:
<div class="container">
<table class="table">
<thead>
<tr>
<th>Id</th>
<th>Name of Book</th>
<th>Author</th>
<th>Description</th>
<th>No of books available</th>
</tr>
</thead>
<tbody>
<tr ng-repeat = "book in libraryBooks | filter:keyword">
<td>{{book.id}}</td>
<td>{{book.name}}</td>
<td>{{book.author}}</td>
<td>{{book.description}}</td>
<td>{{book.count}}</td>
<td><button ng-click = "removeItem({{book.id}})">remove</button></td>
</tr>
</tbody>
</table>
</div>
The browser console is displaying a syntax error. I am passing this parameter to fetch in the controller to execute a Hibernate function for deleting the book with that specific ID.