diff --git a/app/helpers/welcome_helper.rb b/app/helpers/welcome_helper.rb
index 034bf7fe1..57e4825ea 100644
--- a/app/helpers/welcome_helper.rb
+++ b/app/helpers/welcome_helper.rb
@@ -22,6 +22,28 @@ module WelcomeHelper
include CoursesHelper
include ProjectsHelper
+ def get_course_term project
+ str = ( project.try(:course_extra).try(:time).to_s << '.' << project.try(:course_extra).try(:term).to_s )
+ str[0..-4]
+ end
+
+ def welcome_join_in_course(project, user)
+ if(user.logged? &&
+ !(course_timeout? project) &&
+ (project.course_extra.teacher.id != user.id)
+ )
+ join_in_course(project, user)
+ end
+ end
+
+ def get_course_avatar project
+ if get_avatar?(project)
+ url_to_avatar(project)
+ else
+ '../images/avatars/Project/course.jpg'
+ end
+ end
+
# 前略·天国の首页君/Earth has been unable stop to welcomePage's.
# sum - 要搜索的项目数量
# max_rate - 新项目所占所有项目的比重,10分制
diff --git a/app/views/files/index.html.erb b/app/views/files/index.html.erb
index 31625fc33..a0ee754f9 100644
--- a/app/views/files/index.html.erb
+++ b/app/views/files/index.html.erb
@@ -106,8 +106,14 @@ div.pagination{
margin: 0px 25px;
}
.relation_file_div fieldset{
- margin: 0px 25px;
+ margin: 0px 0px;
+ padding: 10px;
border-radius: 5px;
+ transition: all 2s linear 1s;
+}
+.relation_file_div input:focus{
+ border: 1px solid #1B95C6;
+ box-shadow: 0px 0px 4px #1B95C6;
}
diff --git a/app/views/welcome/course.html.erb b/app/views/welcome/course.html.erb
index 61c6ceb9e..f6774b499 100644
--- a/app/views/welcome/course.html.erb
+++ b/app/views/welcome/course.html.erb
@@ -111,34 +111,25 @@
<% find_miracle_course(10, 7).map do |project| %>
- -
+
-
- <% if get_avatar?(project)%>
- <%= image_tag(url_to_avatar(project), :class => "avatar-4") %>
- <% else %>
- <%= image_tag('../images/avatars/Project/course.jpg', :class => "avatar-4") %>
- <% end %>
-
-
-
- <%= link_to( project.name, project_path(project.id), :class => "d-g-blue d-p-project-name",:title => "#{project.name}", :target => "_blank" )%>
- 学生人数:<%= link_to "#{studentCount(project)}", project_member_path(project, :role => 2) ,:course =>'1', :target => "_blank" %>
-
-
- <%if User.current.logged? && !(course_timeout? project)%>
- <%= join_in_course(project, User.current) unless project.course_extra.teacher.id == User.current.id %>
- <% end %>
-
-
-
- <%= content_tag "div", " ".html_safe< "d-p-project-intro", :style => 'display:inline-block; position:relative;float:right;color:#ff4800;' %>
-
-
- <%= content_tag "span", " ".html_safe+project.description.truncate(50, omission: '...'), :class => "d-p-project-intro" , :title => project.description.to_s %>
-
-
+ <%= image_tag(get_course_avatar(project), :class => "avatar-4") %>
+
+
+
+ [<%= get_course_term project %>]
+ <%#= join_in_course(project, User.current) %>
+ <%= link_to( project.name, project_path(project.id), :class => "d-g-blue d-p-project-name",:title => "#{project.name}" )%>
+ (<%= link_to "#{studentCount(project)}人", project_member_path(project, :role => 2) ,:course =>'1' %>)
+
+
+ ><%=project.description.truncate(25, omission: '...')%>
+
+
+ <%= join_in_course(project, User.current)%>
+
- <% end %>
+ <% end; reset_cycle %>
diff --git a/public/stylesheets/application.css b/public/stylesheets/application.css
index 96cfaeab2..0661235d0 100644
--- a/public/stylesheets/application.css
+++ b/public/stylesheets/application.css
@@ -2060,7 +2060,7 @@ button.tab-right {
/***** Settings Tabs *****/
/*modified by huang*/
#content .tabs_new {height: 2.6em; margin-bottom:1.2em; margin-top: 0.8em; position:relative; overflow:hidden;}
-#content .tabs_new ul {margin:0; position:absolute; bottom:0; padding-left: 0.5em; width: 2000px; border-bottom: 1px solid #15BCCF;font-size:14px;}
+#content .tabs_new ul {margin:0; position:absolute; bottom:0; padding-left: 0.5em; width: 100%; border-bottom: 1px solid #15BCCF;font-size:14px;}
#content .tabs_new ul li {
width:80px; /*modified by linchun*/
float:left;
diff --git a/public/stylesheets/welcome.css b/public/stylesheets/welcome.css
index 76e302530..7ff39fef6 100644
--- a/public/stylesheets/welcome.css
+++ b/public/stylesheets/welcome.css
@@ -176,7 +176,7 @@ li {
}
.d-p-index-newsource li,.d-p-index-hotproject ul.d-p-projectlist li{
color: rgb(102, 102, 102);
- background: center -1px no-repeat;
+ /*background: center -1px no-repeat;*/
line-height: 20px;
padding: 5px 5px 0px 9px;
width: 440px;
@@ -188,6 +188,12 @@ li {
margin-top: 0px;
border-bottom: 1px solid rgb(245,245,245);
}
+ul.odd{
+ background-color: #F5F5F5;
+}
+ul.even{
+ background-color: #F6F7F8;
+}
.d-g-blue{
color: rgb(17, 102, 173) !important;
@@ -198,6 +204,7 @@ ul.d-p-projectlist{
margin-top: 0px;
}
+
/*
p.layout-1 {
margin-top: -8px;