From 4bdac4922abce512d8a1a87cfd2c4c8b55a767e5 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E6=9D=A8=E6=A0=91=E6=98=8E?= <775174143@qq.com> Date: Wed, 17 Jul 2019 10:39:31 +0800 Subject: [PATCH] =?UTF-8?q?=E6=95=99=E5=AD=A6=E6=A1=88=E4=BE=8B=E9=A6=96?= =?UTF-8?q?=E9=A1=B5=E8=B0=83=E6=95=B4?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- app/helpers/libraries_helper.rb | 2 +- app/views/libraries/_library_list.html.erb | 18 +++++++++++------- public/stylesheets/educoder/edu-all.css | 2 +- 3 files changed, 13 insertions(+), 9 deletions(-) diff --git a/app/helpers/libraries_helper.rb b/app/helpers/libraries_helper.rb index e2e74324..60beab53 100644 --- a/app/helpers/libraries_helper.rb +++ b/app/helpers/libraries_helper.rb @@ -2,7 +2,7 @@ module LibrariesHelper def show_library_tags(library) html = '' library.library_tags.each do |tag| - html += content_tag(:span, tag.name, class: "edu-filter-btn fl cdefault mt3 ml10 #{library_tag_class(tag)}") + html += content_tag(:span, tag.name, class: "edu-filter-btn fl cdefault mt10 ml10 #{library_tag_class(tag)}") end raw html diff --git a/app/views/libraries/_library_list.html.erb b/app/views/libraries/_library_list.html.erb index 7ae5031c..21e96536 100644 --- a/app/views/libraries/_library_list.html.erb +++ b/app/views/libraries/_library_list.html.erb @@ -2,21 +2,25 @@ <% if @libraries.present? %> <% @libraries.each do |library| %>
  • - <%= link_to image_tag(url_to_avatar(library.user), width: 50, height: 50, class: 'radius mr15 mt3'), user_path(library.user) %> + <%= link_to image_tag(url_to_avatar(library.user), width: 120, height: 90, class: ' mr15 mt3'), user_path(library.user) %>
    -

    - <%= link_to library.title, library_path(library),:class => "task-hide font-16 library_l_name" %> +

    + <%= link_to library.title, library_path(library),:class => "task-hide font-22 library_l_name" %> <%= show_library_tags(library) %> -

    -

    - <%= link_to library.user.show_real_name, user_path(library.user) %> - <%= library.visited_count || 0 %> 浏览 <% if params[:type] == 'mine' %> 上传时间:<%= library.created_at.strftime('%Y-%m-%d %H:%M') %> <% else %> 发布时间:<%= library.published_at.try(:strftime, '%Y-%m-%d %H:%M') %> <% end %>

    +

    + 作者: + <%= link_to library.user.show_real_name, user_path(library.user) %> + 学校 + <%= library.visited_count || 0 %> 浏览 + <%= library.visited_count || 0 %> 下载 + <%= library.visited_count || 0 %> 赞 +

  • <% end %> diff --git a/public/stylesheets/educoder/edu-all.css b/public/stylesheets/educoder/edu-all.css index 2822c384..9ea717ba 100644 --- a/public/stylesheets/educoder/edu-all.css +++ b/public/stylesheets/educoder/edu-all.css @@ -3466,7 +3466,7 @@ line-height: 16px;display: inline-block;color: rgba(65, 140, 205, 1) !important; margin-bottom: 30px; } .library_list_item{ - background: #fff;padding:30px;margin-bottom: 15px;display: flex; + background: #fff;padding:30px;margin-bottom: 30px;display: flex; } .library_list_item .library_l_name{max-width: 900px;float: left;} .upload_Title{