From fe94efeb39aa9a75a0a78bec44d67c6eb3c9f17f Mon Sep 17 00:00:00 2001 From: lizanle <491823689@qq.com> Date: Thu, 16 Apr 2015 10:50:53 +0800 Subject: [PATCH 1/6] =?UTF-8?q?=E6=96=B0=E5=BB=BA=E7=89=88=E6=9C=AC?= =?UTF-8?q?=E6=9B=B4=E6=94=B9=E9=A1=B5=E9=9D=A2?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../projects/settings/_new_versions.html.erb | 44 ++++++++++++++++++- 1 file changed, 42 insertions(+), 2 deletions(-) diff --git a/app/views/projects/settings/_new_versions.html.erb b/app/views/projects/settings/_new_versions.html.erb index 06e704495..75216ebb3 100644 --- a/app/views/projects/settings/_new_versions.html.erb +++ b/app/views/projects/settings/_new_versions.html.erb @@ -1,3 +1,10 @@ + <% if @project.shared_versions.any? %> @@ -44,12 +51,45 @@ <%= link_to l(:label_close_versions), close_completed_project_versions_path(@project), :method => :put, :class =>"c_orange fr" %> <% end %> - <%= link_to l(:label_version_new), new_project_version_path(@project, :back_url => ''), :class => 'c_blue fl' if User.current.allowed_to?(:manage_versions, @project) %> + <%= link_to l(:label_version_new),"#", :class => 'c_blue fl',:onclick=>"pro_st_show_ban();" if User.current.allowed_to?(:manage_versions, @project) %>
+<%= form_for :version, :url => project_versions_path(@project),:html=>{:id=>"new_project_version_form"} do |f| %>
- +
+<% end %> From dc81db1d8b22ad7e2edb89d5cd97161c3b819042 Mon Sep 17 00:00:00 2001 From: huang Date: Thu, 16 Apr 2015 11:07:37 +0800 Subject: [PATCH 2/6] =?UTF-8?q?=E5=A4=84=E7=90=86=E8=AE=A8=E8=AE=BA?= =?UTF-8?q?=E5=8C=BA=E3=80=81=E7=BC=BA=E9=99=B7=E5=88=97=E8=A1=A8=E6=A0=B7?= =?UTF-8?q?=E5=BC=8F=E6=98=BE=E7=A4=BA=E5=BC=82=E5=B8=B8?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- app/views/boards/_project_show.html.erb | 38 ++++++++++--------------- public/stylesheets/public.css | 8 +++--- 2 files changed, 19 insertions(+), 27 deletions(-) diff --git a/app/views/boards/_project_show.html.erb b/app/views/boards/_project_show.html.erb index 69866aa2c..7af313188 100644 --- a/app/views/boards/_project_show.html.erb +++ b/app/views/boards/_project_show.html.erb @@ -8,13 +8,16 @@ }
-

<%= h @board.name %>

+

+ <% if User.current.language == "zh"%> + <%= h @board.name %> + <% else %> + <%= l(:project_module_boards) %> + <% end %> +

<% if User.current.logged? %> -
-

<%= l(:project_module_boards_post) %>

-
<%= form_for @message, :url => new_board_message_path(@board), :html => {:multipart => true, :id => 'message-form'} do |f| %> <%= render :partial => 'messages/form_project', :locals => {:f => f} %>

@@ -42,18 +45,10 @@

-
-

- <% if User.current.language == "zh"%> - <%= h @board.name %> - <% else %> - <%= l(:project_module_boards) %> - <% end %> -

-
+
-
<%= l(:label_project_board_count , :count => @topic_count)%>
- <% if @project.enabled_modules.where("name = 'boards'").count > 0 && User.current.member_of?(@project) %> +
<%= l(:label_project_board_count , :count => @topic_count)%>
+ <% if @project.enabled_modules.where("name = 'boards'").count > 0 && User.current.member_of?(@project) %> <%= link_to l(:project_module_boards_post), new_board_message_path(@board), :class => 'problem_new_btn fl c_dorange', :onclick => 'showAndScrollTo("add-message", "message_subject"); return false;' if User.current.logged? %> @@ -66,16 +61,13 @@
<%= link_to image_tag(url_to_avatar(topic.author), :width=>"32",:height=>"32"), user_path(topic.author),:class => 'problem_pic talk_pic fl' %>
-
- <%= link_to h(topic.subject), board_message_path(@board, topic), title:topic.subject.to_s, :class =>"problem_tit fl" %> + <%= link_to h(topic.subject), board_message_path(@board, topic), title:topic.subject.to_s, :class =>"problem_tit fl" %> <% if topic.sticky? %> - <%= l(:label_board_sticky)%> + <%= l(:label_board_sticky)%> <% end %> -
-
- <%= l(:label_post_by)%><%= link_to topic.author, user_path(topic.author), :class =>"problem_name" %> -  <%= l(:label_post_by_time)%><%= format_time topic.created_on %> -
+
+ <%= l(:label_post_by)%><%= link_to topic.author, user_path(topic.author), :class =>"problem_name" %> +  <%= l(:label_post_by_time)%><%= format_time topic.created_on %>
<%= link_to (l(:label_short_reply) + " "+topic.replies_count.to_s), board_message_path(@board, topic), :style =>"color:#fff;line-height: 18px;" %>
diff --git a/public/stylesheets/public.css b/public/stylesheets/public.css index d9261c10e..16d5ccd13 100644 --- a/public/stylesheets/public.css +++ b/public/stylesheets/public.css @@ -159,10 +159,10 @@ a:hover.blue_u_btn{background:#64bdd9; color:#fff;} .nolink_btn{ background:#BCBCBC; color: #fff; padding:2px 5px;} .more_btn{-moz-border-radius:3px; -webkit-border-radius:3px; border:1px solid #9DCEFF; color:#9DCEFF; border-radius:3px; padding:0px 3px;} /*.upbtn{ margin:42px 0 0 10px; border:none; color:#999; }*/ -.red_btn_cir{ background:#e74c3c; padding:1px 10px; -moz-border-radius:2px; -webkit-border-radius:2px; border-radius:2px; color:#fff; font-weight:normal;font-size:12px;} -.green_btn_cir{ background:#28be6c; padding:1px 10px; -moz-border-radius:2px; -webkit-border-radius:2px; border-radius:2px; color:#fff; font-weight:normal;font-size:12px;} -.blue_btn_cir{ background:#3498db; padding:1px 10px; -moz-border-radius:2px; -webkit-border-radius:2px; border-radius:2px; color:#fff; font-weight:normal;font-size:12px;} -.orange_btn_cir{ background:#e67e22; padding:1px 10px; -moz-border-radius:2px; -webkit-border-radius:2px; border-radius:2px; color:#fff; font-weight:normal; font-size:12px;} +.red_btn_cir{ background:#e74c3c; padding:1px 10px; -moz-border-radius:2px; -webkit-border-radius:2px; border-radius:2px; color:#fff; font-weight:normal;font-size:12px;white-space:nowrap;} +.green_btn_cir{ background:#28be6c; padding:1px 10px; -moz-border-radius:2px; -webkit-border-radius:2px; border-radius:2px; color:#fff; font-weight:normal;font-size:12px;white-space:nowrap;} +.blue_btn_cir{ background:#3498db; padding:1px 10px; -moz-border-radius:2px; -webkit-border-radius:2px; border-radius:2px; color:#fff; font-weight:normal;font-size:12px;white-space:nowrap;} +.orange_btn_cir{ background:#e67e22; padding:1px 10px; -moz-border-radius:2px; -webkit-border-radius:2px; border-radius:2px; color:#fff; font-weight:normal; font-size:12px;white-space:nowrap;} /* commonpic */ .pic_date{ display:block; background:url(../images/new_project/public_icon.png) -31px 0 no-repeat; width:16px; height:15px; float:left;} .pic_add{ display:block; background:url(../images/new_project/public_icon.png) -31px -273px no-repeat; width:16px; height:15px; float:left;} From 38672458b04f5521363d8a3935ea98fb902a3cb7 Mon Sep 17 00:00:00 2001 From: lizanle <491823689@qq.com> Date: Thu, 16 Apr 2015 11:07:38 +0800 Subject: [PATCH 3/6] =?UTF-8?q?=E6=96=B0=E5=BB=BA=E7=89=88=E6=9C=AC=20=20?= =?UTF-8?q?=E6=9B=B4=E6=94=B9=E9=A1=B5=E9=9D=A2?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- app/views/projects/settings/_new_versions.html.erb | 7 ++----- 1 file changed, 2 insertions(+), 5 deletions(-) diff --git a/app/views/projects/settings/_new_versions.html.erb b/app/views/projects/settings/_new_versions.html.erb index 1d16a21e1..7d513f192 100644 --- a/app/views/projects/settings/_new_versions.html.erb +++ b/app/views/projects/settings/_new_versions.html.erb @@ -74,16 +74,13 @@
  • - <%= f.text_field :effective_date, :size => 10, :readonly => true %> + <%= f.text_field :effective_date, :size => 10, :readonly => true,:class=>" fl" %> <%= calendar_for('version_effective_date') %>
  • - + <%= f.select :sharing, @project.versions.build.allowed_sharings.collect {|v| [format_version_sharing(v), v]} %>
  • 保存 From a4d6eaa46c35b0d9995e4826d024747b0d0b08cc Mon Sep 17 00:00:00 2001 From: lizanle <491823689@qq.com> Date: Thu, 16 Apr 2015 11:08:00 +0800 Subject: [PATCH 4/6] =?UTF-8?q?=E8=B7=B3=E8=BD=AC=E5=9B=9E=E6=9D=A5?= =?UTF-8?q?=E8=87=AA=E5=8A=A8=E9=80=89=E6=8B=A9tab=E9=A1=B5?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- app/views/projects/settings.html.erb | 2 ++ 1 file changed, 2 insertions(+) diff --git a/app/views/projects/settings.html.erb b/app/views/projects/settings.html.erb index 247656350..7775c9c3c 100644 --- a/app/views/projects/settings.html.erb +++ b/app/views/projects/settings.html.erb @@ -3,6 +3,8 @@ $(function(){ <%if @select_tab == "modules"%> project_setting(2); + <% else @select_tab == "versions"%> + project_setting(4); <% end%> }); <% end%> From e34a00f66e1d3cceeac8b099a352e20c742bee36 Mon Sep 17 00:00:00 2001 From: huang Date: Thu, 16 Apr 2015 11:17:44 +0800 Subject: [PATCH 5/6] =?UTF-8?q?=E8=AE=A8=E8=AE=BA=E5=8C=BA=E5=88=97?= =?UTF-8?q?=E8=A1=A8=E6=A0=B7=E5=BC=8F=E5=86=B2=E7=AA=81?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- app/views/boards/_form.html.erb | 15 +++++++++++++++ app/views/boards/_project_show.html.erb | 16 +++++++--------- 2 files changed, 22 insertions(+), 9 deletions(-) diff --git a/app/views/boards/_form.html.erb b/app/views/boards/_form.html.erb index c1ab085cf..47ae0672d 100644 --- a/app/views/boards/_form.html.erb +++ b/app/views/boards/_form.html.erb @@ -13,3 +13,18 @@

    <% end %>
    + + + +
    + <%= link_to h(topic.subject), board_message_path(@board, topic), title:topic.subject.to_s, :class =>"problem_tit fl" %> + <% if topic.sticky? %> + <%= l(:label_board_sticky)%> + <% end %> +
    + <%= l(:label_post_by)%><%= link_to topic.author, user_path(topic.author), :class =>"problem_name" %> +  <%= l(:label_post_by_time)%><%= format_time topic.created_on %> +
    +<%= link_to (l(:label_short_reply) + " "+topic.replies_count.to_s), board_message_path(@board, topic), :style =>"color:#fff;line-height: 18px;" %> +
    +
    \ No newline at end of file diff --git a/app/views/boards/_project_show.html.erb b/app/views/boards/_project_show.html.erb index 7af313188..fa16fcb51 100644 --- a/app/views/boards/_project_show.html.erb +++ b/app/views/boards/_project_show.html.erb @@ -44,19 +44,17 @@ <% end %> -
    - -
    -
    <%= l(:label_project_board_count , :count => @topic_count)%>
    - <% if @project.enabled_modules.where("name = 'boards'").count > 0 && User.current.member_of?(@project) %> +
    +
    <%= l(:label_project_board_count , :count => @topic_count)%>
    +<% if @project.enabled_modules.where("name = 'boards'").count > 0 && User.current.member_of?(@project) %> <%= link_to l(:project_module_boards_post), new_board_message_path(@board), :class => 'problem_new_btn fl c_dorange', :onclick => 'showAndScrollTo("add-message", "message_subject"); return false;' if User.current.logged? %> <% end %> -
    -
    +
    +
    - <% if @topics.any? %> +<% if @topics.any? %> <% @topics.each do |topic| %>
    <%= link_to image_tag(url_to_avatar(topic.author), :width=>"32",:height=>"32"), user_path(topic.author),:class => 'problem_pic talk_pic fl' %> @@ -76,7 +74,7 @@ <% else %>

    <%= l(:label_no_data) %>

    <% end %> -
      +
        <%= pagination_links_full @topic_pages, @topic_count, :per_page_links => false, :remote => false, :flag => true %>
      From 8803942a0291b1f9b079035b43dc6cade7bd768e Mon Sep 17 00:00:00 2001 From: huang Date: Thu, 16 Apr 2015 11:35:38 +0800 Subject: [PATCH 6/6] =?UTF-8?q?=E9=A1=B9=E7=9B=AE=E8=AE=A8=E8=AE=BA?= =?UTF-8?q?=E5=8C=BA=EF=BC=8C=E5=BC=95=E7=94=A8=E6=A0=B7=E5=BC=8F=E8=B0=83?= =?UTF-8?q?=E6=95=B4?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- app/views/messages/_project_show.html.erb | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/app/views/messages/_project_show.html.erb b/app/views/messages/_project_show.html.erb index 33f55cfac..3dbfe3a8d 100644 --- a/app/views/messages/_project_show.html.erb +++ b/app/views/messages/_project_show.html.erb @@ -50,12 +50,12 @@
      ">
      <%= link_to image_tag(url_to_avatar(message.author), :width => '46',:height => '46'), user_path(message.author) %>
      -
      +
      <%= link_to_user_header message.author,false,:class => 'c_blue fb fl mb10 ' %> <%= format_time(message.created_on) %>
      -

      <%= textilizable message,:content,:attachments => message.attachments %>

      - <%= link_to_attachment_project message, :author => false %> +

      <%= textAreailizable message,:content,:attachments => message.attachments %>

      + <%= link_to_attachments_course message, :author => false %>
      <%= link_to(