From 0c849c321648df30ae99eb225e5a6da3e3ce009f Mon Sep 17 00:00:00 2001 From: nieguanghui Date: Wed, 6 Nov 2013 10:28:18 +0800 Subject: [PATCH] =?UTF-8?q?=E8=A7=A3=E5=86=B3=E6=8C=89=E9=92=AE=E5=86=B2?= =?UTF-8?q?=E7=AA=81?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- app/views/projects/_course.html.erb | 10 +-- .../stylesheets/application.css | 67 +++---------------- 2 files changed, 17 insertions(+), 60 deletions(-) diff --git a/app/views/projects/_course.html.erb b/app/views/projects/_course.html.erb index 22ec78fa3..73e3a455b 100644 --- a/app/views/projects/_course.html.erb +++ b/app/views/projects/_course.html.erb @@ -45,7 +45,7 @@ <%= content_tag('span', link_to("#{@project.members.count}", member_project_path(@project)), :class => "info") %> <%= content_tag('span', l(:label_x_member, :count => @project.members.count)) %>

-
+
<%= join_in_course_for_list(@project, User.current,['regular'])%>
@@ -55,9 +55,11 @@
<%= content_tag "span","#{l(:label_duration_time)}:", :class => "course-font"%> - <%= DateTime.parse(Course.find_by_extra(@project.identifier).setup_time.to_s).strftime("%Y年%m月%d日").to_s unless Course.find_by_extra(@project.identifier).setup_time.nil? %> - <%= '-' unless Course.find_by_extra(@project.identifier).setup_time.nil? %> - <%= DateTime.parse(Course.find_by_extra(@project.identifier).endup_time.to_s).strftime("%Y年%m月%d日").to_s unless Course.find_by_extra(@project.identifier).endup_time.nil? %> + <% unless Course.find_by_extra(@project.identifier).nil? %> + <%= DateTime.parse(Course.find_by_extra(@project.identifier).setup_time.to_s).strftime("%Y年%m月%d日").to_s unless Course.find_by_extra(@project.identifier).setup_time.nil? %> + <%= '-' unless Course.find_by_extra(@project.identifier).setup_time.nil? %> + <%= DateTime.parse(Course.find_by_extra(@project.identifier).endup_time.to_s).strftime("%Y年%m月%d日").to_s unless Course.find_by_extra(@project.identifier).endup_time.nil? %> + <% end %>
diff --git a/public/themes/redpenny-master/stylesheets/application.css b/public/themes/redpenny-master/stylesheets/application.css index 8e34a62e4..261b8d4ab 100644 --- a/public/themes/redpenny-master/stylesheets/application.css +++ b/public/themes/redpenny-master/stylesheets/application.css @@ -1908,16 +1908,17 @@ div.avatar_user{ margin-bottom: 5px; } -.buttons a, .buttons button{ +/*#added by nie*/ +.buttons_for_course a { display:block; float:left; margin:0 7px 0 0; - background-color:#ec6300; + background-color: #ec6300; border:1px solid #dedede; border-top:1px solid #eee; border-left:1px solid #eee; - font-family:"Lucida Grande", Tahoma, Arial, Verdana, sans-serif; + font-family:"微软雅黑", sans-serif; font-size:12px; line-height:130%; text-decoration:none; @@ -1926,87 +1927,41 @@ div.avatar_user{ cursor:pointer; padding:5px 10px 6px 7px; /* Links */ } -.buttons button{ - width:auto; - overflow:visible; - padding:4px 10px 3px 7px; /* IE6 */ -} -.buttons button[type]{ - padding:5px 10px 5px 7px; /* Firefox */ - line-height:17px; /* Safari */ -} -*:first-child+html button[type]{ - padding:4px 10px 3px 7px; /* IE7 */ -} -.buttons button img, .buttons a img{ - margin:0 3px -3px 0 !important; - padding:0; - border:none; - width:16px; - height:16px; -} + /* STANDARD */ -button:hover, .buttons a:hover{ +.buttons_for_course a:hover{ background-color:#dff4ff; border:1px solid #c2e1ef; color:#336699; } -.buttons a:active{ +.buttons_for_course a:active{ background-color:#6299c5; border:1px solid #6299c5; color:#fff; } -/* POSITIVE */ -button.positive, .buttons a.positive{ - color:#529214; -} -.buttons a.positive:hover, button.positive:hover{ - background-color:#E6EFC2; - border:1px solid #C6D880; - color:#529214; -} -.buttons a.positive:active{ - background-color:#529214; - border:1px solid #529214; - color:#fff; -} -/* NEGATIVE */ - -.buttons a.negative, button.negative{ - color:#d12f19; -} -.buttons a.negative:hover, button.negative:hover{ - background:#fbe3e4; - border:1px solid #fbc2c4; - color:#d12f19; -} -.buttons a.negative:active{ - background-color:#d12f19; - border:1px solid #d12f19; - color:#fff; -} /* REGULAR */ -button.regular, .buttons a.regular{ +.buttons_for_course a.regular{ color:#ffffff; } -.buttons a.regular:hover, button.regular:hover{ +.buttons_for_course a.regular:hover { background-color:#dff4ff; border:1px solid #c2e1ef; color:#336699; } -.buttons a.regular:active{ +.buttons_for_course a.regular:active{ background-color:#6299c5; border:1px solid #6299c5; color:#fff; } +/* end */ .course-font { color:#8c8a8a;