seblucas/cops-html-ui

View on GitHub
app/book/book-detail.html

Summary

Maintainability
Test Coverage
<div class="row">
  <div class="col-md-offset-2 col-md-2 col-sm-12">
          <div class="cover-image">
              <a ng-href="{{ coverUrl }}" ng-show="book.hasCover == 1">
                  <img ng-src="{{ coverUrl }}" />
              </a>
          </div>
  </div>
  <div class="col-md-4 text-center">
      <h1><a rel="bookmark" ui-sref="base.book.detail()">
          <span class="glyphicon glyphicon-link"></span></a>{{ ::book.title }}
      </h1>
      <h4 ng-if="ratings"><uib-rating ng-model="ratings" readonly="true"></uib-rating></h4>
      <h4>{{ 'authors.title' | translate }}:
        <span ng-repeat="author in ::authors">
        <span ng-if="!$first">, </span><a ui-sref="base.category.books({cat: 'authors', id: author.id})">{{ ::author.name }}</a>
        </span>
      </h4>
      <h4>{{ 'tags.title' | translate }}:
        <span ng-repeat="tag in ::tags">
        <span ng-if="!$first">, </span><a ui-sref="base.category.books({cat: 'tags', id: tag.id})">{{ ::tag.name }}</a>
        </span>
      </h4>
      <h4 ng-if="series.length" ng-repeat="serie in ::series">
        {{ 'series.title' | translate }}: <a ui-sref="base.category.books({cat: 'series', id: serie.id})"
                                             translate-value-number="{{ ::book.seriesIndex }}"
                                             translate-value-name="{{ ::serie.name }}"
                                             translate>content.series.data</a>
      </h4>
  </div>
  <div class="col-md-2 col-sm-12">
      <div class="btn-group pull-right">
          <a href="#" class="btn btn-primary" role="button" ng-repeat="datum in ::data">{{ ::datum.format }}</a>
      </div>
  </div>
</div>
<div class="row">
  <div class="col-md-offset-2 col-md-8 col-sm-12">
      <div ng-if="::isPublicationDateOk">
          <h4 translate>pubdate.title</h4>{{ publicationYear }}
      </div>
      <div ng-if="::book.comment">
        <br />
        <h4 translate>content.summary</h4>
        <div ng-bind-html="::trustedComment"></div>
      </div>
  </div>
</div>