<!--
    AngularJS template. Created by fran lopez on 14/12/15.

    This is the view to show a list of book reviews as a result of a
    search using one route parameter:

        -> bookId: Is a book identifier, used to book all book reviews
        associated to a book identified by this identifier.
-->

    <section data-ng-controller="BookReviewsController"
             data-ng-init="find()">
        <h1>Listado de críticas de un libro</h1><hr>
        <ul>
            <li data-ng-repeat="bookReview in bookReviews">
                <label class="labelWithReviewRating">
                    Valoración: </label>
                <label class="labelWithReviewRating labelWithRating"
                       data-ng-bind="bookReview.rating"></label><br><br>
                <label class="labelWithReview"
                       data-ng-bind="bookReview.review"></label>
                <br><br><br>
            </li>
        </ul>
        <label id="errorLabel" data-ng-hide="!bookReviews
        || bookReviews.length">No existen críticas para este libro</label>
        <hr><br>
        <a data-ng-href="#!/books/{{bookId}}">
            Volver a los detalles del libro</a>
    </section>