diff --git a/app/assets/stylesheets/custom.css.scss b/app/assets/stylesheets/custom.css.scss index 53f7491..7182061 100644 --- a/app/assets/stylesheets/custom.css.scss +++ b/app/assets/stylesheets/custom.css.scss @@ -34,15 +34,11 @@ h1 { font-size: 3em; letter-spacing: -2px; margin-bottom: 30px; - text-align: center; } h2 { - font-size: 1.2em; letter-spacing: -1px; margin-bottom: 30px; - text-align: center; - font-weight: normal; color: #777; } diff --git a/app/views/books/show.html.erb b/app/views/books/show.html.erb index f5a10cd..3eecd0f 100644 --- a/app/views/books/show.html.erb +++ b/app/views/books/show.html.erb @@ -1,19 +1,54 @@ -

<%= @book.title %>

- - - -

Serie: <%= @book.serie.name %>

-

Publisher: <%= @book.publisher.name %>

-

Publishing date: <%= @book.pubdate.to_formatted_s(:date) %>

+

+ + <%= "Language".pluralize(@book.languages.count) %> +

+
+ <% @book.languages.each do |language| %> + <%= language.lang_code %> + <% end %> +
+

+ + <%= "Tag".pluralize(@book.tags.count) %> +

+
+ <% @book.tags.each do |tag| %> + <%= tag.name %> + <% end %> +
+

Details

+ + diff --git a/app/views/series/show.html.erb b/app/views/series/show.html.erb index 2cbc211..e07316b 100644 --- a/app/views/series/show.html.erb +++ b/app/views/series/show.html.erb @@ -1,6 +1,32 @@ -

<%= @serie.name %>

+ +

+ + <%= "Book".pluralize(@serie.books.count) %> +

+<% +authors = Array.new +@serie.books.each do |book| + authors.concat book.authors +end +authors.uniq!.sort! { |x,y| x.sort <=> y.sort } +if authors %> +

+ + <%= "Author".pluralize(authors.count) %> +

+ +<% end %>