Merge branch 'develop' of https://bdgit.trustie.net/hushasha/bigdata into develop

This commit is contained in:
daiao 2017-06-02 10:45:14 +08:00
commit 439f1bcb2a
12 changed files with 19 additions and 24 deletions

View File

@ -53,7 +53,7 @@ class ShixunsController < ApplicationController
@current_user_had_passed = Myshixun.find_by_sql("select count(*) as had_passed from myshixuns where status =1 and user_id=#{User.current.id}
and shixun_id in (SELECT id FROM `shixuns` where authentication=1)").first.try(:had_passed).to_i
@shixuns_count = @shixuns.count
@limit = 8
@limit = 20
@is_remote = true
@shixun_pages = Paginator.new @shixuns_count, @limit, params['page'] || 1
@offset ||= @shixun_pages.offset

View File

@ -1,11 +1,15 @@
<% @syllabuses.each do | sy | %>
<div class="sub-con fl" style="cursor: default;">
<div class="top pt20">
<a href="<%= syllabus_path(sy) %>" title="<%= sy.title %>" target="_blank" >
<p class="font-14 title">
<div class="task-index-list-box-top ">
<a href="<%= syllabus_path(sy) %>" title="<%= sy.title %>" target="_blank" >
<p class="font-14 task-index-list-title two_lines_show">
<%= sy.title %>
</p>
</a>
<div class=" clearfix task-index-list-user">
<img src="images/user/female.jpg" width="60" height="60" alt="用户" class="panel-warp-img mr10 fl">
<a href="#" class="task-index-name task-hide fl">Cillian</a>
</div>
<p class="color-grey">
<% sy_author = User.find(sy.user_id) %>
<% if !sy_author.user_extensions.school_id.blank? && sy_author.user_extensions.school %>

View File

@ -4,17 +4,12 @@
<a href="<%= user_path(User.current) %>"><%= User.current.show_name %></a> &gt;
<a href="<%= courses_path %>">智能课堂</a>
</p>
<div class="task-index-head mt20 mb20">
<div class="task-index-head-top">
<div class="task-index-head mb20">
<div class="task-index-head-top-course">
<h2 class="fl task-inde-head-title">智能课堂</h2>
<%= link_to "创建", new_course_path, :class => "task-btn task-btn-green fr mt6" %>
<div class="cl"></div>
</div>
<ul class="task-index-head-info clearfix">
<li><span class="color-orange font-bd"><%= @shixuns_count %></span><br/><span >全部实训</span></li>
<li><span class="color-orange font-bd"><%= @current_user_had_passed %></span><br/><span>你已通过</span></li>
<li><span class="color-orange font-bd"><%= @shixun_my_score %></span><br/><span>取得成绩</span></li>
</ul>
</div>
<div class=" clearfix mb15 fl">
<select class="task task-height-40 panel-box-sizing fl color-grey " style="width:160px; border: none;" id="syllabuses" onchange="submit_select_syllabuses(this.value)">

View File

@ -1,6 +1,5 @@
<% @shixuns.each do |shixun| %>
<div class="task-index-list-box fl ">
<div class="task-mg8 task-mg8-hover">
<div class="task-index-list-box-top">
<p class="task-index-list-title two_lines_show">
<%= shixun.name %>
@ -11,17 +10,13 @@
</div>
<div class="cl"></div>
<span class="mt10 mb10"><%= shixun.language == "JDBC" ? "Java/SQL" : shixun.language %></span>
<a href="<%= shixun_path(shixun) %>" target="_blank">
<div class="task-index-list-hover">
</div>
</a>
</div>
<ul class="task-index-list-box-bottom clearfix">
<li><i class="fa fa-gamepad mr5 color-light-green" title="实训任务"></i><span><%= shixun.challenges.count %></span></li>
<!--<li><i class="fa fa-comments-o mr5 color-light-green"></i><span>1255</span></li>-->
<li><i class="fa fa-users mr5 color-light-green" title="已开启实训"></i><span><%= shixun.myshixuns.count %></span></li>
</ul>
</div>
</div>
<% end %>

View File

@ -66,7 +66,7 @@
</p>
</div>
<div class="task-index-list clearfix mb20" id="shixun_list_content" style="width:1215px;">
<div class="task-index-list clearfix mb20" id="shixun_list_content" >
<%= render "shixun_list" %>
</div>
</div>

Binary file not shown.

Before

Width:  |  Height:  |  Size: 27 KiB

After

Width:  |  Height:  |  Size: 10 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 101 KiB

After

Width:  |  Height:  |  Size: 132 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 141 KiB

View File

@ -29,7 +29,7 @@ textarea{resize: none;}
.break-word{word-break: break-all;word-wrap: break-word;}
.break-word-firefox{white-space: pre-wrap !important;word-break: break-all;}
/*超过隐藏*/
.task-hide{overflow:hidden; white-space: nowrap; text-overflow:ellipsis;}
.task-hide{overflow:-moz-hidden-unscrollable; white-space: nowrap; text-overflow:ellipsis;}
.hide{overflow:hidden; white-space: nowrap; text-overflow:ellipsis;}
.hide-text {overflow:hidden; white-space:nowrap;}
/*隐藏*/

View File

@ -1,8 +1,7 @@
/* 头部 */
.header{ width:100%; height:51px;min-width:1200px;background:#46484c; }
.header_con{ width:1200px; min-width:1200px; height:50px; margin:0 auto; }
.new-logo{ border:1px solid #fff;border-radius:3px;margin-top:10px;}
.new-logo img{ width: 27px; height:27px; border-radius:3px; }
.new-logo img{ width:30px; height:30px;margin-top:10px; }
.new-logo p{ font-size: 18px; color:#fff; line-height: 50px; }
a.new-nav-a{ display: block; font-size: 14px; line-height: 50px; color:#fff;}
a:hover.new-nav-a{ color:#3b94d6; text-decoration: none;}

View File

@ -4,7 +4,7 @@
.active-class .search .open{padding-top:6px;}
.active-class .search b{cursor:pointer;}
.active-class .search span input{border:none;outline:none;padding-right:80px;display:none;}
.active-class .content .sub-con{width:23.5%;border:1px solid #eee;background:#fff;margin: 0 1.5% 1.5% 0px;box-shadow: 0 1px 2px 0 rgba(0, 0, 0, 0.15);}
.active-class .content .sub-con{width:23.7%;border:1px solid #eee;background:#fff;margin: 0 1.5% 1.5% 0px;box-shadow: 0 1px 2px 0 rgba(0, 0, 0, 0.15);}
.active-class .content .sub-con:nth-child(4n+0){margin:0 0 1.5% 0;}
.active-class .content .sub-con:hover{box-shadow: 0 5px 15px 0 rgba(0, 0, 0, 0.15);cursor: pointer;-webkit-animation: bounce-down 1s linear 1;animation: bounce-down 1s linear 1;}
.active-class .content .sub-con .top{height:154px;}

View File

@ -209,15 +209,17 @@ input.knowledge_frame{height:30px;line-height:30px;border:none;background:#f3f5f
.task-index{ width: 1200px; margin:0 auto;}
.task-index-head{ box-shadow: 0 1px 2px 0 rgba(0, 0, 0, 0.15); }
.task-index-head-top{background-image: linear-gradient(to right, rgb(106, 177, 216) 0%, rgb(1, 74, 78) 100%);background-color: rgb(1, 70, 74); padding:30px;}
.task-index-head-top-course{background-image: linear-gradient(to right, rgb(68,191, 163) 0%, rgb(165, 175, 247) 100%);background-color:rgb(160, 175, 247); padding:30px;}
.task-inde-head-title{ color:#fff; }
.task-index-head-info{ background:#fff; padding:10px 30px;}
.task-index-head-info li{ width:100px; float: left; text-align: center; color:#666;}
.task-index-list{ width: 1200px;}
.task-index-list-box{ width:25%; }
.task-index-list-box{ width:23.7%;margin: 0 1.5% 1.5% 0px; border-radius:2px; border:1px solid #eee; box-shadow: 0 1px 2px 0 rgba(0, 0, 0, 0.15); color:#666; position:relative; }
.task-index-list-box:hover{-webkit-animation: bounce-down 1s linear 1;animation: bounce-down 1s linear 1; }
.task-index-list-box:nth-child(4n+0) {margin: 0 0 1.5% 0;}
.task-mg8{ margin:0 15px 15px 0px; border-radius:2px; border:1px solid #eee; box-shadow: 0 1px 2px 0 rgba(0, 0, 0, 0.15); color:#666; position:relative; }
.task-index-list-box-top{padding:16px; padding-top:30px; background:#fff; text-align: center; position:relative;}
.task-index-list-box-top{padding:16px; padding-top:30px; background:#fff; text-align: center; position:relative; height: 160px;}
.task-index-list-title{ max-width:80%; display: block; margin:10px auto 0px; font-size:14px; font-weight: bold;}
.task-index-list-user{padding:5px 10px; border-radius:25px;background: #F5F6F7; margin:0px auto 20px; display: inline-block;}
.task-index-list-box-bottom{ background: #F5F6F7; color:#666; padding:10px 10%;}