From a58cebdf5c2b64aa2cf332c04f2c680ae20b9f18 Mon Sep 17 00:00:00 2001 From: Tim Date: Tue, 18 Oct 2016 17:30:07 +0800 Subject: [PATCH 1/7] =?UTF-8?q?=E6=8F=90=E4=BA=A4=E6=94=B9=E5=8A=A8?= =?UTF-8?q?=E9=A1=B5=E9=9D=A2=E5=AE=BD=E5=BA=A6=E6=89=A9=E5=B1=95?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- app/views/repositories/changes.html.erb | 41 ++- app/views/repositories/stats.html.erb | 352 ++++++++++++------------ public/stylesheets/css/public.css | 2 +- 3 files changed, 195 insertions(+), 200 deletions(-) diff --git a/app/views/repositories/changes.html.erb b/app/views/repositories/changes.html.erb index b7e744288..94abb04e5 100644 --- a/app/views/repositories/changes.html.erb +++ b/app/views/repositories/changes.html.erb @@ -1,29 +1,26 @@ <%= call_hook(:view_repositories_show_contextual, { :repository => @repository, :project => @project }) %> +
+
+

<%= render :partial => 'breadcrumbs', :locals => {:path => @path, :kind => 'dir', :revision => @rev} %>

+
-
-

<%= render :partial => 'breadcrumbs', :locals => {:path => @path, :kind => 'dir', :revision => @rev} %>

-
+
+ <%= render :partial => 'navigation' %> +
+
-
- <%= render :partial => 'navigation' %> -
-
+ <%= render :partial => 'link_to_functions' %> -<%= render :partial => 'link_to_functions' %> + <%= render_properties(@properties) %> -<%= render_properties(@properties) %> +
+ <%= render(:partial => 'revisions', :locals => {:project => @project, :path => @path , :revisions => @commits, :entry => @entry , :commits_pages => @commits_pages , :commits_count => @commits_count}) unless @commits.empty? %> +
+
-
+ <% content_for :header_tags do %> + <%= stylesheet_link_tag "scm" %> + <% end %> - <%= render(:partial => 'revisions', :locals => {:project => @project, :path => @path , :revisions => @commits, :entry => @entry , :commits_pages => @commits_pages , :commits_count => @commits_count}) unless @commits.empty? %> - -
-<% content_for :header_tags do %> -<%= stylesheet_link_tag "scm" %> -<% end %> - -<% html_title(l(:label_change_plural)) -%> - - + <% html_title(l(:label_change_plural)) -%> +
\ No newline at end of file diff --git a/app/views/repositories/stats.html.erb b/app/views/repositories/stats.html.erb index f14022810..f7a875a33 100644 --- a/app/views/repositories/stats.html.erb +++ b/app/views/repositories/stats.html.erb @@ -1,74 +1,174 @@ <%= javascript_include_tag 'highcharts','highcharts-more' %> -
-

<%= l(:label_statistics) %>

-
-<% if false %> -
请在版本库中提交代码,统计信息将更准确
-<% else %> -
- <%= render :partial => 'navigation' %> -
+
+
+

<%= l(:label_statistics) %>

+ <% if false %> +
请在版本库中提交代码,统计信息将更准确
+ <% else %> +
+ <%= render :partial => 'navigation' %> +
+
-
-
-
-
+
+
+
+
- -// 代码提交次数统计 - $('#container').highcharts({ - chart: { - type: 'line' - }, - credits:{ - enabled: false - }, - title: { - text: '版本库代码提交次数', - style:{ - fontSize: '14px' - } - - }, - subtitle: { -// text: 'Source: WorldClimate.com' - }, - xAxis: { -// categories: ["Jan", "Jan", "Jan", 'Apr', 'May', 'Jun', 'Jul', 'Aug', 'Sep', 'Oct', 'Nov', 'Dec'] - categories: <%= raw(@static_total_per_user.map{|c| c.uname}) %> - }, - yAxis: { - title: { - text: '次' - } - }, - tooltip: { - enabled: false, - formatter: function() { - return ''+ this.series.name +'
'+this.x +': '+ this.y +'°C'; - } - }, - plotOptions: { - series: { - marker: { - radius: 3, //曲线点半径,默认是4 - symbol: 'circle' //曲线点类型:"circle", "square", "diamond", "triangle","triangle-down",默认是"circle" - } - }, - line: { - dataLabels: { - enabled: true - }, - enableMouseTracking: false - } - }, - series: [{ - name: '提交次数', - fontWeight: 'normal', - color: '#d05d5a', -// data: [7.0, 6.9, 9.5, 14.5, 18.4, 21.5, 25.2, 26.5, 23.3, 18.3, 13.9, 9.6] - data: <%= @static_total_per_user.map{|c| c.commits_num.to_i} %>, - dataLabels: { - enabled: true, - style: { - fontSize: '13px', - color: '#aaa', - fontFamily: 'Arial', - textShadow: '0px 0px 6px rgb(0, 0, 0), 0px 0px 3px rgb(f, f, f)', - fontWeight: 'normal' - } - }, - lineWidth: 1.5 - - } -// { -// name: 'London', -// data: [3.9, 4.2, 5.7, 8.5, 11.9, 15.2, 17.0, 16.6, 14.2, 10.3, 6.6, 4.8] -// } - ] - }); - }); - - -

<%= link_to l(:button_back), :action => 'show', :id => @project %>

- <% html_title(l(:label_repository), l(:label_statistics)) -%> -<% end %> - - \ No newline at end of file +

<%= link_to l(:button_back), :action => 'show', :id => @project %>

+ <% html_title(l(:label_repository), l(:label_statistics)) -%> + <% end %> +
\ No newline at end of file diff --git a/public/stylesheets/css/public.css b/public/stylesheets/css/public.css index b8538ab90..04f2bae89 100644 --- a/public/stylesheets/css/public.css +++ b/public/stylesheets/css/public.css @@ -8,7 +8,7 @@ #LSide{ width:240px;} #RSide{ width:670px; background:#fff; padding:10px; margin-left: 10px; margin-bottom:10px;} .courseRSide{ width:730px; background:#fff; padding:10px; margin-left: 10px; margin-bottom:10px;} -.wrap-big {background:#fff; padding:10px; margin-bottom:10px;} +.wrap-big {width:980px; background:#fff; padding:10px; margin-bottom:10px;} /*资源库*/ .resources {width:718px; background-color:#ffffff; padding:15px; border:1px solid #dddddd;float: right} .resourcesBanner {width:730px; height:40px; background-color:#eaeaea; margin-bottom:10px;} From 03056768965881518780e360a11c350c42d26e76 Mon Sep 17 00:00:00 2001 From: huang Date: Wed, 19 Oct 2016 09:30:22 +0800 Subject: [PATCH 2/7] =?UTF-8?q?=E9=A1=B9=E7=9B=AE=E5=8A=A8=E6=80=81?= =?UTF-8?q?=E9=99=84=E4=BB=B6=E4=BF=A1=E6=81=AF=E5=88=86=E7=A6=BB?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../projects/_project_attachment.html.erb | 46 +++++++++++++++++++ 1 file changed, 46 insertions(+) create mode 100644 app/views/projects/_project_attachment.html.erb diff --git a/app/views/projects/_project_attachment.html.erb b/app/views/projects/_project_attachment.html.erb new file mode 100644 index 000000000..ee116b788 --- /dev/null +++ b/app/views/projects/_project_attachment.html.erb @@ -0,0 +1,46 @@ +
+
+
+ <%= link_to image_tag(url_to_avatar(activity.author), :width => "50", :height => "50"), user_path(activity.author_id), :alt => "用户头像" %> + <%#= render :partial => 'users/show_detail_info', :locals => {:user => activity.author} %> +
+
+
+ <% if activity.try(:author).try(:realname) == ' ' %> + <%= link_to activity.try(:author), user_path(activity.author_id), :class => "newsBlue mr15" %> + <% else %> + <%= link_to activity.try(:author).try(:realname), user_path(activity.author_id), :class => "newsBlue mr15" %> + <% end %> + TO + <%= link_to activity.project.name.to_s+" | 项目资源", project_files_path(activity.course), :class => "newsBlue ml15" %> +
+
+ <%= link_to activity.filename, project_files_path(activity.course), :class => "postGrey" %> +
+
+
+ 文件大小: + <%= number_to_human_size activity.filesize%> +
+
上传时间:<%= format_time(activity.created_on) %>
+
+ +
+
+
+
+ From 3750252f396eedd6f168ff3d72b90fa9a7cc6212 Mon Sep 17 00:00:00 2001 From: huang Date: Wed, 19 Oct 2016 09:35:53 +0800 Subject: [PATCH 3/7] =?UTF-8?q?=E9=A1=B9=E7=9B=AE=E5=88=9B=E5=BB=BA?= =?UTF-8?q?=E4=BF=A1=E6=81=AF=E4=B8=8E=E7=94=A8=E6=88=B7=E5=8A=A8=E6=80=81?= =?UTF-8?q?=E4=B8=AD=E5=88=86=E6=94=AF?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../projects/_project_activities.html.erb | 2 +- app/views/projects/_project_create.html.erb | 25 ++----------------- 2 files changed, 3 insertions(+), 24 deletions(-) diff --git a/app/views/projects/_project_activities.html.erb b/app/views/projects/_project_activities.html.erb index 7ba1d7acc..07363a0a5 100644 --- a/app/views/projects/_project_activities.html.erb +++ b/app/views/projects/_project_activities.html.erb @@ -45,7 +45,7 @@ <%= render :partial => 'projects/act_messages', :locals => {:activity => activity.forge_act, :user_activity_id => activity.id, :is_course => 1, :is_board => 0} %> <% when "Attachment" %> - <%= render :partial => 'users/project_attachment', :locals => {:activity => activity.forge_act, :user_activity_id => activity.id } %> + <%= render :partial => 'projects/project_attachment', :locals => {:activity => activity.forge_act, :user_activity_id => activity.id } %> <% when "Commit" %> <%= render :partial => 'projects/project_commit', :locals => {:activity => activity.forge_act, :user_activity_id => activity.id, :identifier => get_rep_identifier_by_project(@project) } %> <% end %> diff --git a/app/views/projects/_project_create.html.erb b/app/views/projects/_project_create.html.erb index 0d24c4f6b..a62276542 100644 --- a/app/views/projects/_project_create.html.erb +++ b/app/views/projects/_project_create.html.erb @@ -4,15 +4,10 @@
<%= link_to image_tag(url_to_avatar(user), :width => "50", :height => "50"), user_path(user), :alt => "用户头像" %> - <%= render :partial => 'users/show_detail_info', :locals => {:user => user} %>
- <% if user.try(:realname) == ' ' %> - <%= link_to user, user_path(user), :class => "newsBlue mr15" %> - <% else %> - <%= link_to user.try(:realname), user_path(user), :class => "newsBlue mr15" %> - <% end %> + <%= link_to user.show_name, user_path(user), :class => "newsBlue mr15" %> TO <%= link_to project.to_s+" | 项目", project_path(project.id,:host=>Setting.host_course), :class => "newsBlue ml15" %>
@@ -22,23 +17,7 @@
创建时间:<%= format_time(project.created_on) %>
-
-
- + \ No newline at end of file From 89292054c88bc18a190946f5ea71c658d58fccc0 Mon Sep 17 00:00:00 2001 From: huang Date: Wed, 19 Oct 2016 09:57:17 +0800 Subject: [PATCH 4/7] =?UTF-8?q?=E9=A1=B9=E7=9B=AE=E5=8A=A8=E6=80=81?= =?UTF-8?q?=E8=AE=A8=E8=AE=BA=E5=8C=BA=E6=A8=A1=E5=9D=97=E7=8B=AC=E7=AB=8B?= =?UTF-8?q?=E5=87=BA=E6=9D=A5?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- app/views/projects/_act_messages.html.erb | 10 +-- .../projects/_project_attachment.html.erb | 22 +------ .../_project_comment_reply_detail.html.erb | 20 ++++++ .../projects/_project_intro_content.html.erb | 19 ++++++ .../_project_journal_comment_reply.html.erb | 8 +++ .../_project_message_contents.html.erb | 29 +++++++++ .../_project_message_replies.html.erb | 62 +++++++++++++++++++ app/views/users/_message_contents.html.erb | 8 +-- 8 files changed, 148 insertions(+), 30 deletions(-) create mode 100644 app/views/projects/_project_comment_reply_detail.html.erb create mode 100644 app/views/projects/_project_intro_content.html.erb create mode 100644 app/views/projects/_project_journal_comment_reply.html.erb create mode 100644 app/views/projects/_project_message_contents.html.erb create mode 100644 app/views/projects/_project_message_replies.html.erb diff --git a/app/views/projects/_act_messages.html.erb b/app/views/projects/_act_messages.html.erb index 786b56087..2faa08f8a 100644 --- a/app/views/projects/_act_messages.html.erb +++ b/app/views/projects/_act_messages.html.erb @@ -2,7 +2,7 @@
<%= link_to image_tag(url_to_avatar(activity.author), :width => "50", :height => "50"), user_path(activity.author_id), :alt => "用户头像" %> - <%= render :partial => 'users/show_detail_info', :locals => {:user => activity.author} %> + <%#= render :partial => 'users/show_detail_info', :locals => {:user => activity.author} %>
@@ -37,7 +37,7 @@ <% else %> <% content = activity.parent.content%> <% end %> - <%=render :partial =>"users/intro_content", :locals=>{:user_activity_id =>user_activity_id, :content=>content} %> + <%=render :partial =>"projects/project_intro_content", :locals=>{:user_activity_id =>user_activity_id, :content=>content} %>
@@ -87,12 +87,12 @@ <%# allow_delete = (activity.user == User.current || User.current.admin? || User.current.allowed_to?(:as_teacher,activity.course)) %> <%# count = fetch_user_leaveWord_reply(activity).count %>
- <%= render :partial => 'users/reply_banner', :locals => {:count => count, :activity => activity, :user_activity_id => user_activity_id,:is_course => is_course,:is_board =>is_board} %> + <%= render :partial => 'projects/project_reply_banner', :locals => {:count => count, :activity => activity, :user_activity_id => user_activity_id,:is_course => is_course,:is_board =>is_board} %> <% comments = all_replies[0..2] %> <% if count > 0 %>
- <%= render :partial => 'users/message_replies', :locals => {:comments => comments, :user_activity_id => user_activity_id, :type => 'Message', :activity_id =>activity.id, :is_course => is_course, :is_board =>is_board}%> + <%= render :partial => 'projects/project_message_replies', :locals => {:comments => comments, :user_activity_id => user_activity_id, :type => 'Message', :activity_id =>activity.id, :is_course => is_course, :is_board =>is_board}%>
<% end %> @@ -113,7 +113,7 @@ <% end%>
<% else %> - <%= render :partial => "users/show_unlogged" %> + <%= render :partial => "projects/show_unlogged" %> <% end %>
diff --git a/app/views/projects/_project_attachment.html.erb b/app/views/projects/_project_attachment.html.erb index ee116b788..4cbedee4b 100644 --- a/app/views/projects/_project_attachment.html.erb +++ b/app/views/projects/_project_attachment.html.erb @@ -6,11 +6,7 @@
- <% if activity.try(:author).try(:realname) == ' ' %> - <%= link_to activity.try(:author), user_path(activity.author_id), :class => "newsBlue mr15" %> - <% else %> - <%= link_to activity.try(:author).try(:realname), user_path(activity.author_id), :class => "newsBlue mr15" %> - <% end %> + <%= link_to activity.try(:author).show_name, user_path(activity.author_id), :class => "newsBlue mr15" %> TO <%= link_to activity.project.name.to_s+" | 项目资源", project_files_path(activity.course), :class => "newsBlue ml15" %>
@@ -24,23 +20,7 @@
上传时间:<%= format_time(activity.created_on) %>
-
- diff --git a/app/views/projects/_project_comment_reply_detail.html.erb b/app/views/projects/_project_comment_reply_detail.html.erb new file mode 100644 index 000000000..70082dae4 --- /dev/null +++ b/app/views/projects/_project_comment_reply_detail.html.erb @@ -0,0 +1,20 @@ +
+ <%= link_to image_tag(url_to_avatar(comment.creator_user), :width => "33", :height => "33"), user_path(comment.creator_user.id), :alt => "用户头像" %> +
+
+ <%= link_to comment.creator_user.show_name, user_path(comment.creator_user.id), :class => "content-username" %> + <%= time_from_now(comment.respond_to?(:created_on) ? comment.created_on : comment.created_at) %> +
+ <% if comment.class == Journal %> + <% if comment.details.any? %> + <% details_to_strings(comment.details).each do |string| %> +

<%= string %>

+ <% end %> + <% end %> +

<%= comment.content_detail.html_safe %>

+ <% else %> + <%= comment.content_detail.html_safe %> + <% end %> +
+
+
\ No newline at end of file diff --git a/app/views/projects/_project_intro_content.html.erb b/app/views/projects/_project_intro_content.html.erb new file mode 100644 index 000000000..d00f5aea5 --- /dev/null +++ b/app/views/projects/_project_intro_content.html.erb @@ -0,0 +1,19 @@ +
+
+ <%= content.to_s.html_safe %> +
+
+ \ No newline at end of file diff --git a/app/views/projects/_project_journal_comment_reply.html.erb b/app/views/projects/_project_journal_comment_reply.html.erb new file mode 100644 index 000000000..b4f80773f --- /dev/null +++ b/app/views/projects/_project_journal_comment_reply.html.erb @@ -0,0 +1,8 @@ +
+ <% if !comment.parent.nil? && !comment.parent.parent.nil? %> +
+ <%=render :partial => 'projects/project_journal_comment_reply', :locals => {:comment => comment.parent} %> +
+ <% end %> + <%=render :partial => 'projects/project_comment_reply_detail', :locals => {:comment => comment} %> +
\ No newline at end of file diff --git a/app/views/projects/_project_message_contents.html.erb b/app/views/projects/_project_message_contents.html.erb new file mode 100644 index 000000000..365914908 --- /dev/null +++ b/app/views/projects/_project_message_contents.html.erb @@ -0,0 +1,29 @@ +
+ <%= link_to comment.creator_user.show_name, user_url_in_org(comment.creator_user.id), :class => "newsBlue mr10 f14" %> + <%= time_from_now(comment.respond_to?(:created_on) ? comment.created_on : comment.created_at) %> +
+<% if !comment.parent.nil? && !comment.parent.parent.nil? %> + <% parents_rely = [] %> + <% parents_rely = get_reply_parents_no_root parents_rely, comment %> + <% length = parents_rely.length %> +
+ <% if length <= 3 %> + <%=render :partial => 'users/journal_comment_reply', :locals => {:comment => comment.parent} %> + <% else %> +
+
+
+ <%=render :partial => 'users/journal_comment_reply', :locals => {:comment => parents_rely[length - 1]} %> +
+ <%=render :partial => 'users/comment_reply_detail', :locals => {:comment => parents_rely[length - 2]} %> +
+
+ + + <%= link_to '点击展开隐藏楼层', show_all_replies_users_path(:comment => comment, :type => comment.class),:remote=>true %> +
+ <%=render :partial => 'users/comment_reply_detail', :locals => {:comment => parents_rely[0]} %> +
+ <% end %> +
+<% end %> \ No newline at end of file diff --git a/app/views/projects/_project_message_replies.html.erb b/app/views/projects/_project_message_replies.html.erb new file mode 100644 index 000000000..0a35e9811 --- /dev/null +++ b/app/views/projects/_project_message_replies.html.erb @@ -0,0 +1,62 @@ + \ No newline at end of file diff --git a/app/views/users/_message_contents.html.erb b/app/views/users/_message_contents.html.erb index 365914908..a4584f825 100644 --- a/app/views/users/_message_contents.html.erb +++ b/app/views/users/_message_contents.html.erb @@ -8,21 +8,21 @@ <% length = parents_rely.length %>
<% if length <= 3 %> - <%=render :partial => 'users/journal_comment_reply', :locals => {:comment => comment.parent} %> + <%=render :partial => 'projects/project_journal_comment_reply', :locals => {:comment => comment.parent} %> <% else %>
- <%=render :partial => 'users/journal_comment_reply', :locals => {:comment => parents_rely[length - 1]} %> + <%=render :partial => 'projects/project_journal_comment_reply', :locals => {:comment => parents_rely[length - 1]} %>
- <%=render :partial => 'users/comment_reply_detail', :locals => {:comment => parents_rely[length - 2]} %> + <%=render :partial => 'projects/project_comment_reply_detail', :locals => {:comment => parents_rely[length - 2]} %>
<%= link_to '点击展开隐藏楼层', show_all_replies_users_path(:comment => comment, :type => comment.class),:remote=>true %>
- <%=render :partial => 'users/comment_reply_detail', :locals => {:comment => parents_rely[0]} %> + <%=render :partial => 'projects/project_comment_reply_detail', :locals => {:comment => parents_rely[0]} %>
<% end %>
From 6fbb6629d78db5af01b4e4e6ea93ee8c97968200 Mon Sep 17 00:00:00 2001 From: Tim Date: Wed, 19 Oct 2016 10:17:56 +0800 Subject: [PATCH 5/7] =?UTF-8?q?=E5=8A=A8=E6=80=81issue=E5=9B=9E=E5=A4=8D?= =?UTF-8?q?=E5=AE=BD=E5=BA=A6=E6=89=A9=E5=B1=95?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- app/views/projects/_project_issue_reply.html.erb | 10 +++++----- app/views/projects/_project_reply_banner.html.erb | 2 +- 2 files changed, 6 insertions(+), 6 deletions(-) diff --git a/app/views/projects/_project_issue_reply.html.erb b/app/views/projects/_project_issue_reply.html.erb index 019e435b8..3e21d49c8 100644 --- a/app/views/projects/_project_issue_reply.html.erb +++ b/app/views/projects/_project_issue_reply.html.erb @@ -1,5 +1,5 @@ <% count = activity.journals.count %> -
+
<%= render :partial => 'projects/project_reply_banner', :locals => {:count => count, :activity => activity, :user_activity_id => user_activity_id} %> <% comments = activity.journals.includes(:user, :details).reorder("created_on desc").limit(3) %> @@ -13,11 +13,11 @@ autoUrl('reply_content_<%= comment.id %>'); }); -
  • +
  • <%= link_to image_tag(url_to_avatar(comment.creator_user), :width => 33, :height => 33, :alt => "用户头像"), user_url_in_org(comment.creator_user.id) %>
    -
    +
    <%= render :partial => 'projects/project_issue_contents', :locals => {:comment => comment}%> <% if !comment.content_detail.blank? || comment.class == Journal %> @@ -76,9 +76,9 @@
    <% end %> -
    +
    <%= link_to image_tag(url_to_avatar(User.current), :width => "33", :height => "33"), user_path(activity.author_id), :alt => "用户头像" %>
    -
    +
    <% if User.current.logged? %>
    <%= form_for('new_form',:url => add_journal_issue_path(activity.id, :user_activity_id => user_activity_id),:method => "post", :remote => true) do |f| %> diff --git a/app/views/projects/_project_reply_banner.html.erb b/app/views/projects/_project_reply_banner.html.erb index 58c0688ee..6efbf9fda 100644 --- a/app/views/projects/_project_reply_banner.html.erb +++ b/app/views/projects/_project_reply_banner.html.erb @@ -1,4 +1,4 @@ -
    +
    回复 ︿ From e4a6a5f58dfdf929be6c689e337e3263054bd8e5 Mon Sep 17 00:00:00 2001 From: Tim Date: Wed, 19 Oct 2016 11:17:34 +0800 Subject: [PATCH 6/7] =?UTF-8?q?=E9=A1=B9=E7=9B=AEissue=E7=8A=B6=E6=80=81?= =?UTF-8?q?=E5=AE=BD=E5=BA=A6=E8=B0=83=E6=95=B4?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../projects/_project_issue_detail.html.erb | 28 +++++++++---------- public/stylesheets/css/project.css | 4 +-- 2 files changed, 16 insertions(+), 16 deletions(-) diff --git a/app/views/projects/_project_issue_detail.html.erb b/app/views/projects/_project_issue_detail.html.erb index f0431bc26..ff70849e1 100644 --- a/app/views/projects/_project_issue_detail.html.erb +++ b/app/views/projects/_project_issue_detail.html.erb @@ -44,7 +44,7 @@ <%# end %> <%= form_tag({:controller => 'issues', :action => 'update', :id => activity.id, :issue_detail => true, :type => "status"},:remote=>'true', :method => :put, :id=>"issue_query_form_#{activity.id}", :class => 'query_form') do %>
  • -

     状态  : 

    +

     状态  : 

    <%= activity.status.name %>

    <%= select( :issue,:status, [["新增",1],["正在解决",2],["已解决",3],["反馈",4],["关闭",5],["拒绝",6]].unshift(["状态",0]), {:include_blank => false, :selected => @status_id ? @status_id : 0 }, @@ -56,7 +56,7 @@
    <%= form_tag({:controller => 'issues', :action => 'update', :id => activity.id, :issue_detail => true, :type => "assigned"},:remote=>'true', :method => :put, :id=>"issue_query_assign_form_#{activity.id}", :class => 'query_form') do %>
  • -

     指派  : 

    +

     指派  : 

    <%= link_to activity.try(:assigned_to).show_name, user_path(activity.assigned_to_id), :class => "linkBlue hidden", :style => "max-width:100px; display:inline-block;" %> @@ -71,8 +71,8 @@
      <%= form_tag({:controller => 'issues', :action => 'update', :id => activity.id, :issue_detail => true, :type => "prior"},:remote=>'true', :method => :put, :id=>"issue_query_prior_form_#{activity.id}", :class => 'query_form') do %>
    • -

       优先级  : 

      - <%= activity.priority.name %> +

       优先级  : 

      + <%= activity.priority.name %> <%= select( :issue,:prior, [["低",1],["正常",2],["高",3],["紧急",4],["立刻",5]].unshift(["优先级",0]), {:include_blank => false,:selected=>@priority_id ? @priority_id : 0}, {:onchange=>"remote_function('#issue_query_prior_form_#{activity.id}');",:id=>"priority_id",:name=>"priority_id",:class=>"w70 undis issueEdit"}) %> @@ -81,8 +81,8 @@
      <%= form_tag({:controller => 'issues', :action => 'update', :id => activity.id, :issue_detail => true, :type => "ratio"},:remote=>'true', :method => :put, :id=>"issue_query_done_form_#{activity.id}", :class => 'query_form') do %>
    • -

       完成度  : 

      - <%= activity.done_ratio %>% +

       完成度  : 

      + <%= activity.done_ratio %>% <%= select( :issue,:done_ratio, ((0..10).to_a.collect { |r| ["#{r*10} %", r*10] }), {:include_blank => false, :selected => @done_ratio ? @done_ratio : 0}, {:onchange=>"remote_function('#issue_query_done_form_#{activity.id}');",:id=>"done_ratio",:name=>"done_ratio",:class=>"w70 undis issueEdit"}) %> @@ -93,23 +93,23 @@
    • -

       开始  : 

      -

      <%= format_date(activity.start_date) %>

      +

       开始  : 

      +

      <%= format_date(activity.start_date) %>

    • -

       周期  : 

      - <%= l_hours(activity.estimated_hours) %>
    • +

       周期  : 

      + <%= l_hours(activity.estimated_hours) %>
    • -

       计划完成  : 

      - <%= format_date(activity.due_date)? format_date(activity.due_date) : "--" %>
    • +

       计划完成  : 

      + <%= format_date(activity.due_date)? format_date(activity.due_date) : "--" %>
    • -

       <%=l(:milestone)%>  : 

      - <%= (activity.fixed_version ? link_to_user_version(activity.fixed_version) : "--") %>
    • +

       <%=l(:milestone)%>  : 

      + <%= (activity.fixed_version ? link_to_user_version(activity.fixed_version) : "--") %>
    diff --git a/public/stylesheets/css/project.css b/public/stylesheets/css/project.css index d2ec83c2e..4e492e9b9 100644 --- a/public/stylesheets/css/project.css +++ b/public/stylesheets/css/project.css @@ -256,8 +256,8 @@ p.percent { .newpro_box input{ height:26px; float:left; margin-bottom:10px;} .newpro_box textarea{ height:150px; float:left; margin-bottom:10px;} .newpro_box select{ height:29px; float:left; margin-bottom:10px;} -.label{ width:80px; text-align:right; font-size:14px; display:block; float:left;} -.label02{ width:110px; text-align:right; font-size:14px; display:block; float:left;} +.label{ width:80px; text-align:right; display:block; float:left; white-space: nowrap;} +.label02{ width:110px; text-align:right; display:block; float:left; white-space: nowrap;} .label03{ width:70px; text-align:right; display:block; float:left; white-space: nowrap;} .collapsible{ border-left:none;border-right:none;border-bottom:none; border-top:1px solid #e4e4e4; padding-top:10px; } .icon-reload { background-image: url(/images/reload.png); } From af5db3713c4f425079a0b517bd8f696782fd7c36 Mon Sep 17 00:00:00 2001 From: Tim Date: Wed, 19 Oct 2016 14:57:31 +0800 Subject: [PATCH 7/7] =?UTF-8?q?issue=E8=AF=A6=E6=83=85=E9=A1=B5=E9=9D=A2?= =?UTF-8?q?=EF=BC=8C=E5=B1=9E=E6=80=A7=E9=A1=B5=E9=9D=A2=EF=BC=8C=E5=9B=9E?= =?UTF-8?q?=E5=A4=8D=E9=A1=B5=E9=9D=A2=EF=BC=8C=E4=BA=8C=E7=BA=A7=E5=9B=9E?= =?UTF-8?q?=E5=A4=8D=E9=A1=B5=E9=9D=A2=E5=AE=BD=E5=BA=A6=E8=B0=83=E6=95=B4?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- app/views/issues/_attributes_show.html.erb | 16 ++++++++-------- app/views/issues/_detail.html.erb | 4 ++-- app/views/issues/_issue_replies.html.erb | 8 ++++---- app/views/issues/_issue_reply_ke_form.html.erb | 4 ++-- app/views/issues/show.html.erb | 12 ++++++------ public/stylesheets/css/project.css | 1 - 6 files changed, 22 insertions(+), 23 deletions(-) diff --git a/app/views/issues/_attributes_show.html.erb b/app/views/issues/_attributes_show.html.erb index 7ff59fd9d..a968281b2 100644 --- a/app/views/issues/_attributes_show.html.erb +++ b/app/views/issues/_attributes_show.html.erb @@ -2,45 +2,45 @@
    <%= issue_fields_rows do |rows| %>
      -
    •  状态  : 

      <%= @issue.status.name %>

      +
    •  状态  : 

      <%= @issue.status.name %>

    • <% unless @issue.disabled_core_fields.include?('assigned_to_id') %> -
    •  指派给  : 

      <%= @issue.assigned_to ? link_to_isuue_user(@issue.assigned_to) : "--" %> +
    •  指派给  : 

      <%= @issue.assigned_to ? link_to_isuue_user(@issue.assigned_to) : "--" %>
    • <% end %>
      -
    •  优先级  : 

      <%= @issue.priority.name %> +
    •  优先级  : 

      <%= @issue.priority.name %>
    • <% unless @issue.disabled_core_fields.include?('done_ratio') %> -
    •  % 完成  : 

      <%= @issue.done_ratio %>% +
    •  % 完成  : 

      <%= @issue.done_ratio %>%
    • <% end %>
      <% unless @issue.disabled_core_fields.include?('start_date') %> -
    •  开始  : 

      <%= format_date(@issue.start_date) %>

      +
    •  开始  : 

      <%= format_date(@issue.start_date) %>

    • <% end %>
      <% unless @issue.disabled_core_fields.include?('estimated_hours') %> -
    •  周期  : 

      <%= l_hours(@issue.estimated_hours) %> +
    •  周期  : 

      <%= l_hours(@issue.estimated_hours) %>
    • <% end %>
      <% unless @issue.disabled_core_fields.include?('due_date') %> -
    •  计划完成  : 

      <%= format_date(@issue.due_date)? format_date(@issue.due_date) : "--" %> +
    •  计划完成  : 

      <%= format_date(@issue.due_date)? format_date(@issue.due_date) : "--" %>
    • <% end %>
      <% unless @issue.disabled_core_fields.include?('fixed_version_id') %> -
    •  <%=l(:milestone)%>  : 

      <%= (@issue.fixed_version ? link_to_version(@issue.fixed_version, :class => "pro_info_p") : "--") %> +
    •  <%=l(:milestone)%>  : 

      <%= (@issue.fixed_version ? link_to_version(@issue.fixed_version, :class => "pro_info_p") : "--") %>
    • <% end %>
      diff --git a/app/views/issues/_detail.html.erb b/app/views/issues/_detail.html.erb index 9ae3dfc43..8f0eaabe6 100644 --- a/app/views/issues/_detail.html.erb +++ b/app/views/issues/_detail.html.erb @@ -2,8 +2,8 @@
      <%= link_to image_tag(url_to_avatar(@issue.author), :width => 46, :height => 46), user_path(@issue.author), :class => "ping_dispic" %>
      -
      -

      +

      +

      <% case @issue.tracker_id %> <% when 1%> 【缺陷】 diff --git a/app/views/issues/_issue_replies.html.erb b/app/views/issues/_issue_replies.html.erb index 1bc8dc132..d80f4a3e8 100644 --- a/app/views/issues/_issue_replies.html.erb +++ b/app/views/issues/_issue_replies.html.erb @@ -6,11 +6,11 @@ autoUrl('reply_content_<%= comment.id %>'); }); -

    • +
    • <%= link_to image_tag(url_to_avatar(comment.user), :width => "33", :height => "33"), user_path(comment.user_id), :alt => "用户头像" %>
      -
      +
      <%= render :partial => 'users/news_contents', :locals => {:comment => comment}%>
      @@ -55,13 +55,13 @@
    • <% end %>
    -
    +
    <%= link_to image_tag(url_to_avatar(User.current), :width => "33", :height => "33"), user_path(@issue.author_id), :alt => "用户头像" %>
    -
    +
    <% if User.current.logged? %>
    <%= form_for('new_form',:url => add_journal_issue_path(@issue.id),:method => "post", :remote => true) do |f| %> diff --git a/app/views/issues/_issue_reply_ke_form.html.erb b/app/views/issues/_issue_reply_ke_form.html.erb index cf4c3e504..1393cb948 100644 --- a/app/views/issues/_issue_reply_ke_form.html.erb +++ b/app/views/issues/_issue_reply_ke_form.html.erb @@ -1,10 +1,10 @@ -
    +
    <%= link_to image_tag(url_to_avatar(User.current), :width => "33", :height => "33"), user_path(@issue.author_id), :alt => "用户头像" %>
    -
    +
    <% if User.current.logged? %>
    <%= form_for('new_form',:url => add_reply_issue_path(@issue.id),:method => "post", :remote => true) do |f|%> diff --git a/app/views/issues/show.html.erb b/app/views/issues/show.html.erb index 40728d451..4f8af8656 100644 --- a/app/views/issues/show.html.erb +++ b/app/views/issues/show.html.erb @@ -15,12 +15,12 @@ } }); -
    -
    -
    问题跟踪
    +
    + -
    +
    @@ -33,9 +33,9 @@
    -
    +
    -
    +
    <%=render :partial => 'issue_reply_banner' %>
    diff --git a/public/stylesheets/css/project.css b/public/stylesheets/css/project.css index 4e492e9b9..f2ab58883 100644 --- a/public/stylesheets/css/project.css +++ b/public/stylesheets/css/project.css @@ -476,7 +476,6 @@ a.upload_btn_grey{background:#a3a3a3;} a:hover.upload_btn_grey{background:#8a8a8a;} .upload_btn{width:80px; height:26px;} .upload_check{ margin-top:4px;} -.orig_reply_box2{border-top:1px solid #e3e3e3; width:95%; padding:10px 25px 10px 0;} .talk_info a{ color:#15bccf; } .ping_disfoot span a span{ color: #6883b6;}