2014-06-10 17:03:02 +08:00
|
|
|
<div class="project-block">
|
2013-11-05 20:46:38 +08:00
|
|
|
<div class="img-tag-2">
|
2014-06-10 15:44:37 +08:00
|
|
|
<% if get_avatar?(course)%>
|
|
|
|
<%= image_tag(url_to_avatar(course), :class => "avatar2") %>
|
2013-11-05 20:46:38 +08:00
|
|
|
<% else %>
|
2014-06-10 15:44:37 +08:00
|
|
|
<%= image_tag('../images/avatars/course/course.jpg', :class => "avatar2") %>
|
2013-11-05 20:46:38 +08:00
|
|
|
<% end %>
|
|
|
|
</div>
|
|
|
|
|
|
|
|
<div class="wiki-description">
|
|
|
|
<p >
|
|
|
|
<%= content_tag('span',"#{l(:label_bid_show_course_name)}:", :class => "course-font")%>
|
2014-09-01 14:41:11 +08:00
|
|
|
<% unless @course.is_public == 1 %>
|
2014-10-21 14:21:33 +08:00
|
|
|
<span class='private_project'>
|
|
|
|
<%= l(:label_private) %>
|
|
|
|
</span>
|
2014-09-01 14:41:11 +08:00
|
|
|
<% end %>
|
2014-10-25 16:19:19 +08:00
|
|
|
<%= content_tag('span', link_to("#{@course.name}", course_path(@course), :class => "info #{User.current.member_of_course?(@course) ? 'my-project' : nil}"))%>
|
2013-11-05 20:46:38 +08:00
|
|
|
</p>
|
|
|
|
<p >
|
|
|
|
<%= content_tag('span', "#{l(:label_institution_name)}:", :class => "course-font")%>
|
2014-06-10 15:44:37 +08:00
|
|
|
<% @admin = @course.course_infos%>
|
2014-06-03 09:56:54 +08:00
|
|
|
<%if @admin&&@admin.first&&@admin.first.user&&@admin.first.user.user_extensions%>
|
2014-07-05 11:00:01 +08:00
|
|
|
<% unless @course.teacher.user_extensions.school.nil? %>
|
2014-10-21 14:21:33 +08:00
|
|
|
<%= link_to(@course.school.try(:name), school_course_list_path(@course.school)) if @course.school %>
|
2014-07-05 11:00:01 +08:00
|
|
|
<% end %>
|
2013-11-05 20:46:38 +08:00
|
|
|
<% end %>
|
|
|
|
</p>
|
|
|
|
<p >
|
|
|
|
<%= content_tag('div', "#{l(:field_teacher_name)}:", :class => "info course-font teacher") %>
|
|
|
|
<% if @admin.size > 0 %>
|
|
|
|
<%= content_tag('a', @admin.collect{|u| link_to(u.user.lastname+u.user.firstname, user_path(u.user_id))}.join(", ").html_safe) %>
|
|
|
|
<% end %>
|
|
|
|
</p>
|
2014-07-10 16:35:53 +08:00
|
|
|
|
2015-04-16 16:39:52 +08:00
|
|
|
<p>
|
|
|
|
<%= content_tag "span","#{l(:label_duration_time)}:", :class => "course-font"%>
|
|
|
|
<%= get_course_term @course %>
|
|
|
|
</p>
|
|
|
|
<p>
|
|
|
|
<%= content_tag "span", "#{l(:label_course_brief_introduction)}:", :class => "course-font" %>
|
|
|
|
</p>
|
2015-05-22 09:50:20 +08:00
|
|
|
<%= content_tag "div", course.short_description, :class => "brief_introduction",:style=>'float:left;', :title => course.short_description %>
|
2015-04-16 16:39:52 +08:00
|
|
|
|
2013-11-05 20:46:38 +08:00
|
|
|
</div>
|
|
|
|
|
|
|
|
<div class="information_for_course" >
|
|
|
|
<p class="stats">
|
2015-06-02 17:17:34 +08:00
|
|
|
<%= content_tag('span', link_to("#{@course.homework_commons.count}", homework_common_index_path(:course => @course.id)), :class => "info") %>
|
|
|
|
<%= content_tag('span', l(:label_x_task, :count => @course.homework_commons.count)) %>
|
2013-11-05 20:46:38 +08:00
|
|
|
</p>
|
|
|
|
<p class="stats">
|
2014-06-10 15:44:37 +08:00
|
|
|
<% files_count = @course.attachments.count %>
|
|
|
|
<%= content_tag('span', link_to(files_count, course_files_path(@course)), :class => "info") %>
|
2013-11-05 20:46:38 +08:00
|
|
|
<%= content_tag('span', l(:label_x_data,:count => files_count)) %>
|
|
|
|
</p>
|
|
|
|
<p class="stats">
|
2014-06-10 15:44:37 +08:00
|
|
|
<%= content_tag('span', "#{garble @course.members.count}", :class => "info") %>
|
2015-05-13 14:58:11 +08:00
|
|
|
<%= content_tag('span', l(:label_x_member, :count => @course.members.count)) %>
|
2013-11-05 20:46:38 +08:00
|
|
|
</p>
|
2015-05-06 16:37:18 +08:00
|
|
|
|
2014-04-24 09:13:06 +08:00
|
|
|
<!--gcm-->
|
|
|
|
<p class="stats">
|
2015-07-30 11:10:49 +08:00
|
|
|
<%= content_tag('span', link_to("#{course_activity_count @course}", course_path(@course)), :class => "info") %>
|
2014-06-10 15:44:37 +08:00
|
|
|
<%= content_tag('span', l(:label_x_activity, :count => @course_activity_count[@course.id])) %>
|
2014-04-24 09:13:06 +08:00
|
|
|
</p>
|
|
|
|
<!--gcm-->
|
2015-05-06 16:37:18 +08:00
|
|
|
|
2013-11-06 10:28:18 +08:00
|
|
|
<div class="buttons_for_course" style="margin-top:30px;margin-left:144px">
|
2013-11-05 20:46:38 +08:00
|
|
|
<span class="info"></span>
|
2014-06-10 17:03:02 +08:00
|
|
|
<% if(course_endTime_timeout? @course) %>
|
2014-03-07 11:28:52 +08:00
|
|
|
<span class="font_lighter">
|
2014-10-21 14:21:33 +08:00
|
|
|
<%= l(:lable_course_end) %>
|
2014-03-07 11:28:52 +08:00
|
|
|
</span>
|
2014-06-10 15:44:37 +08:00
|
|
|
<% else %>
|
2014-06-10 17:03:02 +08:00
|
|
|
<%= join_in_course_for_list(@course, User.current,['regular'])%>
|
2014-06-10 15:44:37 +08:00
|
|
|
<% end -%>
|
2013-11-05 20:46:38 +08:00
|
|
|
</div>
|
|
|
|
</div>
|
|
|
|
</div>
|
|
|
|
|
|
|
|
<div class="tags">
|
|
|
|
<div id="tags">
|
|
|
|
<%= image_tag( "/images/sidebar/tags.png") %>
|
2014-06-10 15:44:37 +08:00
|
|
|
<%= render :partial => 'tags/tag_name', :locals => {:obj => @course,:object_flag => "9",:non_list_all => true }%>
|
2013-11-05 20:46:38 +08:00
|
|
|
</div>
|
|
|
|
</div>
|