From 85a95262fed4d7bb10618398c6e90219b9f83d0c Mon Sep 17 00:00:00 2001 From: z9hang Date: Thu, 21 Aug 2014 16:01:24 +0800 Subject: [PATCH 01/26] =?UTF-8?q?=E9=A1=B9=E7=9B=AE=E5=BE=97=E5=88=86?= =?UTF-8?q?=E7=BB=86=E8=8A=82=E4=B8=AD=E6=96=87=E6=A1=A3=E5=BE=97=E5=88=86?= =?UTF-8?q?=E7=82=B9=E5=87=BB=E6=97=A0=E5=8F=8D=E5=BA=94=E9=97=AE=E9=A2=98?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- app/views/projects/_file_score_index.html.erb | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/app/views/projects/_file_score_index.html.erb b/app/views/projects/_file_score_index.html.erb index ce80ddbd2..bfc87097e 100644 --- a/app/views/projects/_file_score_index.html.erb +++ b/app/views/projects/_file_score_index.html.erb @@ -1,4 +1,4 @@ -
<%= l(:label_file_number) %> * 4 = <%= document_num(@project) %> * 4 = <%= format("%.2f" , document_score(@project)).to_i %>
-
<%= l(:label_file_score) %> = <%= format("%.2f" , document_score(@project)).to_i %>
+
<%= l(:label_file_number) %> * 4 = <%= documents_num(@project) %> * 4 = <%= format("%.2f" , documents_score(@project)).to_i %>
+
<%= l(:label_file_score) %> = <%= format("%.2f" , documents_score(@project)).to_i %>
\ No newline at end of file From b30bfd073c9972205682cbcd48eda23f7a2ce222 Mon Sep 17 00:00:00 2001 From: linhk <304431313@.com> Date: Thu, 21 Aug 2014 16:55:46 +0800 Subject: [PATCH 02/26] 1 --- app/controllers/projects_controller.rb | 2 +- app/controllers/words_controller.rb | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/app/controllers/projects_controller.rb b/app/controllers/projects_controller.rb index 3fea454de..329159a05 100644 --- a/app/controllers/projects_controller.rb +++ b/app/controllers/projects_controller.rb @@ -407,7 +407,7 @@ class ProjectsController < ApplicationController @page = @page.to_i # Find the page of the requested reply @jours = @project.journals_for_messages.where('m_parent_id IS NULL').order('created_on DESC') - @limit = 3 + @limit = 10 offset = @jours.count(:conditions => ["#{JournalsForMessage.table_name}.id > ?", params[:r].to_i]) page = 1 + offset / @limit diff --git a/app/controllers/words_controller.rb b/app/controllers/words_controller.rb index e31bb2738..2d03b2112 100644 --- a/app/controllers/words_controller.rb +++ b/app/controllers/words_controller.rb @@ -99,7 +99,7 @@ class WordsController < ApplicationController @project = Project.find params[:project_id] # Find the page of the requested reply @jours = @project.journals_for_messages.where('m_parent_id IS NULL').order('created_on DESC') - @limit = 3 + @limit = 10 offset = @jours.count(:conditions => ["#{JournalsForMessage.table_name}.id > ?", params[:r].to_i]) page = 1 + offset / @limit From 9d23e6a8be9dc6c53b6a6ab68d3a1a1841c1bb82 Mon Sep 17 00:00:00 2001 From: z9hang Date: Thu, 21 Aug 2014 17:09:35 +0800 Subject: [PATCH 03/26] =?UTF-8?q?=E6=B7=BB=E5=8A=A0=E7=AB=9E=E8=B5=9B?= =?UTF-8?q?=E9=80=9A=E7=9F=A5=E6=A0=87=E9=A2=98=E9=95=BF=E5=BA=A6=E9=99=90?= =?UTF-8?q?=E5=88=B6?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- app/controllers/admin_controller.rb | 2 +- app/models/contest_notification.rb | 1 + app/views/welcome/contest.html.erb | 2 +- 3 files changed, 3 insertions(+), 2 deletions(-) diff --git a/app/controllers/admin_controller.rb b/app/controllers/admin_controller.rb index aac107cfb..c75b9f9bf 100644 --- a/app/controllers/admin_controller.rb +++ b/app/controllers/admin_controller.rb @@ -241,7 +241,7 @@ class AdminController < ApplicationController end else respond_to do |format| - flash.now[:error] = "#{l :label_first_page_create_fail}: #{@first_page.errors.full_messages[0]}\n\t#{@contest_page.errors.full_messages[0]}" + flash.now[:error] = "#{l :label_first_page_create_fail}: #{@first_page.errors.full_messages[0]}\n\t#{@contest_page.errors.full_messages[0]}\n\t#{@notification.errors.full_messages[0]}" format.html { render :action => 'contest_page_made' } diff --git a/app/models/contest_notification.rb b/app/models/contest_notification.rb index c1f2fde6f..d525b4b3a 100644 --- a/app/models/contest_notification.rb +++ b/app/models/contest_notification.rb @@ -1,3 +1,4 @@ class ContestNotification < ActiveRecord::Base attr_accessible :content, :title + validates_length_of :title, maximum: 30 end diff --git a/app/views/welcome/contest.html.erb b/app/views/welcome/contest.html.erb index 8df19a280..30395aa6f 100644 --- a/app/views/welcome/contest.html.erb +++ b/app/views/welcome/contest.html.erb @@ -197,7 +197,7 @@ <%#= link_to l(:label_more_information), forums_path %>
-
<%= @contestNotification.title %>
+
<%= @contestNotification.title %>
From 337ca5fb9339a4c11564d1923bb470d8b16e3e83 Mon Sep 17 00:00:00 2001 From: sw <939547590@qq.com> Date: Thu, 21 Aug 2014 17:14:30 +0800 Subject: [PATCH 04/26] =?UTF-8?q?=E4=BF=AE=E5=A4=8D=E7=94=A8=E6=88=B7?= =?UTF-8?q?=E7=95=99=E8=A8=80=E5=8F=96=E6=B6=88=E6=8C=89=E9=92=AE=E6=8F=8F?= =?UTF-8?q?=E8=BF=B0=E4=B8=8D=E6=AD=A3=E7=A1=AE=E7=9A=84=E9=97=AE=E9=A2=98?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- app/views/users/user_newfeedback.html.erb | 2 +- app/views/words/_new.html.erb | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/app/views/users/user_newfeedback.html.erb b/app/views/users/user_newfeedback.html.erb index 22ff5a280..d6337e1d0 100644 --- a/app/views/users/user_newfeedback.html.erb +++ b/app/views/users/user_newfeedback.html.erb @@ -2,7 +2,7 @@
<%= render :partial => 'words/new', :locals => {:user => @user, :sta => @state} %>
-
+
<%= l(:label_newfeedback_message) %>(<%= @feedback_count%>)
diff --git a/app/views/words/_new.html.erb b/app/views/words/_new.html.erb index aa2001028..bc4d19225 100644 --- a/app/views/words/_new.html.erb +++ b/app/views/words/_new.html.erb @@ -72,7 +72,7 @@ + <%= submit_tag l(:button_cancel), :name => nil, :class => "enterprise", :onclick => "clearMessage('new_form_user_message');", :onmouseout => "this.style.backgroundPosition = 'left top'", :onmouseover => "this.style.backgroundPosition = 'left -31px'" %>
<%= submit_tag l(:button_leave_meassge), :name => nil , :class => "enterprise", :onmouseout => "this.style.backgroundPosition = 'left top'", :onmouseover => "this.style.backgroundPosition = 'left -31px'"%> - <%= submit_tag l(:button_clear), :name => nil, :class => "enterprise", :onclick => "clearMessage('new_form_user_message');", :onmouseout => "this.style.backgroundPosition = 'left top'", :onmouseover => "this.style.backgroundPosition = 'left -31px'" %>
<% else %> From 063593218713bf51a660bd4f324b67d1fa85c8c8 Mon Sep 17 00:00:00 2001 From: linhk <304431313@.com> Date: Thu, 21 Aug 2014 17:31:36 +0800 Subject: [PATCH 05/26] =?UTF-8?q?=E7=94=A8=E6=88=B7=E4=B8=AA=E4=BA=BA?= =?UTF-8?q?=E4=B8=BB=E9=A1=B5=E9=A1=B9=E7=9B=AE=E9=93=BE=E6=8E=A5=E9=94=99?= =?UTF-8?q?=E8=AF=AF=E4=BF=AE=E6=94=B9?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- app/views/users/show.html.erb | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/app/views/users/show.html.erb b/app/views/users/show.html.erb index 20f64dc3f..b70d73eb6 100644 --- a/app/views/users/show.html.erb +++ b/app/views/users/show.html.erb @@ -129,7 +129,7 @@ <% if e.user == User.current %> - <%= link_to("#{l(:label_i)}", user_path(e.user_id)) %> <%= l(:label_i_new_activity) %> <%= link_to(l(:label_activity_project)+act.issue.project.name, project_path(act.issue.project.identifier)) %> <%= link_to format_activity_title("#{act.issue.tracker} ##{act.issue.id}: #{act.issue.subject}"), {:controller => 'issues', :action => 'show', :id => act.issue.id, :anchor => "change-#{act.id}"} %> + <%= link_to("#{l(:label_i)}", user_path(e.user_id)) %> <%= l(:label_i_new_activity) %> <%= link_to(l(:label_activity_project)+act.issue.project.name, project_path(act.issue.project.id)) %> <%= link_to format_activity_title("#{act.issue.tracker} ##{act.issue.id}: #{act.issue.subject}"), {:controller => 'issues', :action => 'show', :id => act.issue.id, :anchor => "change-#{act.id}"} %> <% else %> From c4fff8a8ac759a79bd8d498020c05f8662b4e3cf Mon Sep 17 00:00:00 2001 From: chenmin <19763783@qq.com> Date: Fri, 22 Aug 2014 08:41:06 +0800 Subject: [PATCH 06/26] =?UTF-8?q?=E9=A1=B9=E7=9B=AE=E8=AE=A8=E8=AE=BA?= =?UTF-8?q?=E5=8C=BA=E5=B8=96=E5=AD=90=E4=B8=BB=E9=A2=98=E8=BF=87=E9=95=BF?= =?UTF-8?q?=E6=98=BE=E7=A4=BA=E4=BC=98=E5=8C=96=EF=BC=9B=20=E8=AE=A8?= =?UTF-8?q?=E8=AE=BA=E5=8C=BA=E4=B8=BB=E9=A2=98=E4=B8=8B=E6=96=B9=E5=AD=98?= =?UTF-8?q?=E5=9C=A8=E8=99=9A=E7=BA=BFbug=E4=BF=AE=E5=A4=8D=EF=BC=9B?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- app/views/messages/_project_show.html.erb | 9 +++------ 1 file changed, 3 insertions(+), 6 deletions(-) diff --git a/app/views/messages/_project_show.html.erb b/app/views/messages/_project_show.html.erb index ad91c72f8..ec06e3e86 100644 --- a/app/views/messages/_project_show.html.erb +++ b/app/views/messages/_project_show.html.erb @@ -95,11 +95,11 @@

-
+
<% if @project %> - <%= label_tag l(:field_subject) %>: <%= link_to @topic.subject, project_boards_path(@topic.project) %> + <%= label_tag l(:field_subject) %>: <%= link_to @topic.subject.truncate(20, omission: '...'), project_boards_path(@topic.project),title: @topic.subject.to_s %> <% elsif @course %> - <%= label_tag l(:field_subject) %>: <%= link_to @topic.subject, course_boards_path(@topic.course) %> + <%= label_tag l(:field_subject) %>: <%= link_to @topic.subject.truncate(20,omission:'...'), course_boards_path(@topic.course),title: @topic.subject.to_s %> <% end %>
@@ -179,9 +179,6 @@
<% end %> - - - <% if !@topic.locked? && authorize_for('messages', 'reply') %> diff --git a/config/locales/zh.yml b/config/locales/zh.yml index a73f9db56..4f0744d86 100644 --- a/config/locales/zh.yml +++ b/config/locales/zh.yml @@ -1641,7 +1641,7 @@ zh: label_call_bonus: 奖金 label_bids_form_new_description: 企业可以在此发布一个软件开发任务或者一个技术方案需求:(1)获得价廉物美的解决方案;(2)发现对此项任务有贡献的大学生,获得可以招聘的人才。 label_bids_form_contest_new_description: 企业或者高校可以在此发布一个竞赛。 - label_homeworks_form_new_description: 发布一个作业,作业提交方式可以是附件或者项目形式,在作业类型里面设置。 + label_homeworks_form_new_description: 发布一个作业,作业提交方式可以是附件或者项目形式。 label_fork_form_new_description: 该需求将作为某课程的作业被发布,作业提交方式可以使附件或者项目形式,在作业类型里面设置。 label_bids_new_money: 输入奖励金额,如 500,2.5等 label_bids_new_credit: 输入该作业对应课程的学分,如 3,2.5等 From d2bd1cc26167dd04fa2c4f12029149d7552701cf Mon Sep 17 00:00:00 2001 From: chenmin <19763783@qq.com> Date: Fri, 22 Aug 2014 09:00:15 +0800 Subject: [PATCH 08/26] =?UTF-8?q?=E4=BF=AE=E5=A4=8D=E8=AF=BE=E7=A8=8B?= =?UTF-8?q?=E8=AE=A8=E8=AE=BA=E5=8C=BA=E5=B8=96=E5=AD=90=E4=B8=BB=E9=A2=98?= =?UTF-8?q?=E9=97=AE=E9=A2=98=EF=BC=8C=E4=BF=AE=E5=A4=8D=E4=B8=BB=E9=A2=98?= =?UTF-8?q?=E5=90=8E=E9=9D=A2=E7=A9=BA=E7=99=BD=E8=BF=87=E5=A4=9A=E7=9A=84?= =?UTF-8?q?=E9=97=AE=E9=A2=98=EF=BC=9B?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- app/views/messages/_course_show.html.erb | 10 ++-------- app/views/messages/_project_show.html.erb | 4 ++-- 2 files changed, 4 insertions(+), 10 deletions(-) diff --git a/app/views/messages/_course_show.html.erb b/app/views/messages/_course_show.html.erb index 5b8b629d4..55cf9d61c 100644 --- a/app/views/messages/_course_show.html.erb +++ b/app/views/messages/_course_show.html.erb @@ -96,9 +96,9 @@
<% if @project %> - <%= label_tag l(:field_subject) %>: <%= link_to @topic.subject, project_boards_path(@topic.project) %> + <%= label_tag l(:field_subject) %>: <%= link_to @topic.subject.truncate(24, omission: '...'), project_boards_path(@topic.project),title: @topic.subject.to_s %> <% elsif @course %> - <%= label_tag l(:field_subject) %>: <%= link_to @topic.subject, course_boards_path(@topic.course) %> + <%= label_tag l(:field_subject) %>: <%= link_to @topic.subject.truncate(24,omission:'...'), course_boards_path(@topic.course),title: @topic.subject.to_s %> <% end %>
@@ -109,14 +109,8 @@
<%= authoring @topic.created_on, @topic.author %>
- -
<%= toggle_link l(:button_reply), "reply", :focus => 'message_content' %>
- - - -

diff --git a/app/views/messages/_project_show.html.erb b/app/views/messages/_project_show.html.erb index ec06e3e86..7f88816f5 100644 --- a/app/views/messages/_project_show.html.erb +++ b/app/views/messages/_project_show.html.erb @@ -97,9 +97,9 @@
<% if @project %> - <%= label_tag l(:field_subject) %>: <%= link_to @topic.subject.truncate(20, omission: '...'), project_boards_path(@topic.project),title: @topic.subject.to_s %> + <%= label_tag l(:field_subject) %>: <%= link_to @topic.subject.truncate(24, omission: '...'), project_boards_path(@topic.project),title: @topic.subject.to_s %> <% elsif @course %> - <%= label_tag l(:field_subject) %>: <%= link_to @topic.subject.truncate(20,omission:'...'), course_boards_path(@topic.course),title: @topic.subject.to_s %> + <%= label_tag l(:field_subject) %>: <%= link_to @topic.subject.truncate(24,omission:'...'), course_boards_path(@topic.course),title: @topic.subject.to_s %> <% end %>
From 554d744929924ac37e1ca585906256ef3baad6c9 Mon Sep 17 00:00:00 2001 From: chenmin <19763783@qq.com> Date: Fri, 22 Aug 2014 09:18:45 +0800 Subject: [PATCH 09/26] =?UTF-8?q?=E4=BF=AE=E5=A4=8D=E9=A1=B9=E7=9B=AE?= =?UTF-8?q?=E5=92=8C=E8=AF=BE=E7=A8=8B=E8=AE=A8=E8=AE=BA=E5=8C=BA=E6=89=80?= =?UTF-8?q?=E6=9C=89=E5=B8=96=E5=AD=90=E6=98=BE=E7=A4=BA=E9=A1=B5=E9=9D=A2?= =?UTF-8?q?=E5=90=84=E5=B8=96=E5=AD=90=E5=86=85=E5=AE=B9=E6=B2=A1=E5=AF=B9?= =?UTF-8?q?=E9=BD=90=E7=9A=84bug=EF=BC=9B?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- app/views/boards/_course_show.html.erb | 4 +++- app/views/boards/_project_show.html.erb | 4 +++- 2 files changed, 6 insertions(+), 2 deletions(-) diff --git a/app/views/boards/_course_show.html.erb b/app/views/boards/_course_show.html.erb index 25d35d407..ca33b7516 100644 --- a/app/views/boards/_course_show.html.erb +++ b/app/views/boards/_course_show.html.erb @@ -63,7 +63,9 @@ - + diff --git a/app/views/boards/_project_show.html.erb b/app/views/boards/_project_show.html.erb index 1327f13e9..ef1afd27e 100644 --- a/app/views/boards/_project_show.html.erb +++ b/app/views/boards/_project_show.html.erb @@ -71,7 +71,9 @@
<%= link_to h(topic.subject), board_message_path(@board, topic) %><%= link_to h(topic.subject.truncate(40,ommision:'...')), board_message_path(@board, topic),title: topic.subject.to_s %> +
<%=link_to (topic.replies_count), board_message_path(@board, topic) %>
回答
- + diff --git a/app/views/messages/_form.html.erb b/app/views/messages/_form.html.erb index 1e74cbf48..44d6dfbe4 100644 --- a/app/views/messages/_form.html.erb +++ b/app/views/messages/_form.html.erb @@ -42,7 +42,7 @@

<%= l(:label_attachment_plural) %>
-<%= render :partial => 'attachments/form', :locals => {:container => @message,:isReply => @isReply} %>

+<%= render :partial => 'attachments/form_course', :locals => {:container => @message,:isReply => @isReply} %>

From d1d2dd0e4bf334df2ec66b98f58c1fb703698778 Mon Sep 17 00:00:00 2001 From: z9hang Date: Fri, 22 Aug 2014 11:58:12 +0800 Subject: [PATCH 20/26] =?UTF-8?q?undefined=20m=5Fcoumt=E9=97=AE=E9=A2=98?= =?UTF-8?q?=E4=BF=AE=E6=AD=A3?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- app/helpers/user_score_helper.rb | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/app/helpers/user_score_helper.rb b/app/helpers/user_score_helper.rb index 376f676b7..c94763e31 100644 --- a/app/helpers/user_score_helper.rb +++ b/app/helpers/user_score_helper.rb @@ -864,7 +864,7 @@ FROM `users` where id = #{user.id}") users = Attachment.find_by_sql("SELECT COUNT(*) as m_count FROM #{Attachment.table_name} WHERE author_id = '#{user.id}' and container_type = 'Project' and container_id = #{project.id}") result = 0 if users.count > 0 - result = users.first.m_coumt + result = users.first.m_count end result end From c6a19209f48a65b971ec1aa666068324610732dd Mon Sep 17 00:00:00 2001 From: sw <939547590@qq.com> Date: Fri, 22 Aug 2014 12:32:16 +0800 Subject: [PATCH 21/26] =?UTF-8?q?=E4=BF=AE=E5=A4=8D=E8=AF=BE=E7=A8=8B?= =?UTF-8?q?=E3=80=81=E9=A1=B9=E7=9B=AE=E6=97=A0=E6=B3=95=E4=B8=8A=E4=BC=A0?= =?UTF-8?q?=E8=B5=84=E6=BA=90=E7=9A=84=E9=97=AE=E9=A2=98?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- app/controllers/files_controller.rb | 37 ++++++++++++++--------------- db/schema.rb | 16 ++++++------- 2 files changed, 26 insertions(+), 27 deletions(-) diff --git a/app/controllers/files_controller.rb b/app/controllers/files_controller.rb index 666c39d30..3d541fd61 100644 --- a/app/controllers/files_controller.rb +++ b/app/controllers/files_controller.rb @@ -26,6 +26,18 @@ class FilesController < ApplicationController include SortHelper helper :project_score + def show_attachments obj + all_attachments = [] + obj.each do |container| + all_attachments += container.attachments + end + @limit = 10 + @feedback_count = all_attachments.count + @feedback_pages = Paginator.new @feedback_count, @limit, params['page'] + @offset ||= @feedback_pages.offset + @curse_attachments = all_attachments[@offset, @limit] + end + def index #sort_init 'filename', 'asc' sort_init 'created_on', 'desc' @@ -39,15 +51,7 @@ class FilesController < ApplicationController @containers = [ Project.includes(:attachments).reorder("#{Attachment.table_name}.created_on DESC").find(@project.id)] @containers += @project.versions.includes(:attachments).reorder("#{Attachment.table_name}.created_on DESC").all.sort - all_attachments = [] - @containers.each do |container| - all_attachments += container.attachments - end - @limit = 10 - @feedback_count = all_attachments.count - @feedback_pages = Paginator.new @feedback_count, @limit, params['page'] - @offset ||= @feedback_pages.offset - @curse_attachments = all_attachments[@offset, @limit] + show_attachments @containers render :layout => !request.xhr? elsif params[:course_id] @@ -79,16 +83,7 @@ class FilesController < ApplicationController @containers = [ Course.includes(:attachments).reorder("#{Attachment.table_name}.created_on desc").find(@course.id)] end - all_attachments = [] - @containers.each do |container| - all_attachments += container.attachments - end - - @limit = 10 - @feedback_count = all_attachments.count - @feedback_pages = Paginator.new @feedback_count, @limit, params['page'] - @offset ||= @feedback_pages.offset - @curse_attachments = all_attachments[@offset, @limit] + show_attachments @containers render :layout => 'base_courses' end @@ -133,6 +128,8 @@ class FilesController < ApplicationController @containers = [Project.includes(:attachments).reorder("#{Attachment.table_name}.created_on DESC").find(@project.id)] #modify by Long Jun @containers += @project.versions.includes(:attachments).reorder("#{Attachment.table_name}.created_on DESC").all.sort + show_attachments @containers + @attachtype = 0 @contenttype = 0 @@ -159,6 +156,8 @@ class FilesController < ApplicationController @containers = [Course.includes(:attachments).reorder("#{Attachment.table_name}.created_on DESC").find(@course.id)] + show_attachments @containers + @attachtype = 0 @contenttype = 0 diff --git a/db/schema.rb b/db/schema.rb index cdedc6a2c..525cfb745 100644 --- a/db/schema.rb +++ b/db/schema.rb @@ -11,7 +11,7 @@ # # It's strongly recommended to check this file into your version control system. -ActiveRecord::Schema.define(:version => 20140812065417) do +ActiveRecord::Schema.define(:version => 20140814062455) do create_table "activities", :force => true do |t| t.integer "act_id", :null => false @@ -441,21 +441,21 @@ ActiveRecord::Schema.define(:version => 20140812065417) do t.datetime "created_at", :null => false t.datetime "updated_at", :null => false t.integer "sort_type" - t.integer "image_width", :default => 107 - t.integer "image_height", :default => 63 t.integer "show_course", :default => 1 t.integer "show_contest", :default => 1 + t.integer "image_width", :default => 107 + t.integer "image_height", :default => 63 end create_table "forums", :force => true do |t| - t.string "name", :null => false - t.string "description", :default => "" + t.string "name", :null => false + t.text "description" t.integer "topic_count", :default => 0 t.integer "memo_count", :default => 0 t.integer "last_memo_id", :default => 0 - t.integer "creator_id", :null => false - t.datetime "created_at", :null => false - t.datetime "updated_at", :null => false + t.integer "creator_id", :null => false + t.datetime "created_at", :null => false + t.datetime "updated_at", :null => false end create_table "groups_users", :id => false, :force => true do |t| From 08a6e9af1a38b3dca0fa22be80de838e2c22e80a Mon Sep 17 00:00:00 2001 From: zhanghaitao <562681745@qq.com> Date: Fri, 22 Aug 2014 13:43:48 +0800 Subject: [PATCH 22/26] =?UTF-8?q?=E8=BE=B9=E6=A1=86=E6=98=BE=E7=A4=BA?= =?UTF-8?q?=E9=97=AE=E9=A2=98=E4=BF=AE=E6=94=B9?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../files/_course_show_all_attachment.html.erb | 16 ++++++++-------- app/views/files/_show_all_attachment.html.erb | 2 +- 2 files changed, 9 insertions(+), 9 deletions(-) diff --git a/app/views/files/_course_show_all_attachment.html.erb b/app/views/files/_course_show_all_attachment.html.erb index f70142a05..fbf398c36 100644 --- a/app/views/files/_course_show_all_attachment.html.erb +++ b/app/views/files/_course_show_all_attachment.html.erb @@ -3,7 +3,7 @@ <% attachmenttypes = @course.attachmenttypes %> <% delete_allowed = User.current.allowed_to?(:manage_files, @course) %> <% edit_allowed = User.current.allowed_to?(:manage_files, @course) %> -
<%= link_to h(topic.subject), board_message_path(@board, topic) %><%= link_to h(topic.subject.truncate(40,ommision:'...')), board_message_path(@board, topic),title:topic.subject.to_s %> + From 589c6d37db19d7caef7796de1d799353d11e35bb Mon Sep 17 00:00:00 2001 From: sw <939547590@qq.com> Date: Fri, 22 Aug 2014 09:20:03 +0800 Subject: [PATCH 10/26] =?UTF-8?q?=E5=8F=96=E6=B6=88=E6=97=A5=E6=9C=9F?= =?UTF-8?q?=E7=BC=96=E8=BE=91=E6=A1=86=E5=8F=AF=E6=89=8B=E5=8A=A8=E8=BE=93?= =?UTF-8?q?=E5=85=A5=E7=9A=84=E9=97=AE=E9=A2=98=20#1045?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- app/views/bids/_homework_form.html.erb | 4 ++-- app/views/courses/_homework_form.html.erb | 2 +- app/views/memos/_form.html.erb | 14 +++++++------- 3 files changed, 10 insertions(+), 10 deletions(-) diff --git a/app/views/bids/_homework_form.html.erb b/app/views/bids/_homework_form.html.erb index f7c753b45..463b2b621 100644 --- a/app/views/bids/_homework_form.html.erb +++ b/app/views/bids/_homework_form.html.erb @@ -26,9 +26,9 @@

<%= f.text_field :name, :required => true, :size => 60, :style => "width:490px;", :maxlength => Bid::NAME_LENGTH_LIMIT %>

<%= f.text_area :description, :rows => 8, :class => 'wiki-edit', :style => "font-size:small;width:490px;margin-left:10px;", :maxlength => Bid::DESCRIPTION_LENGTH_LIMIT %>

-

<%= f.text_field :deadline, :required => true, :size => 60, :style => "width:150px;" %><%= calendar_for('bid_deadline')%>

diff --git a/app/views/courses/_homework_form.html.erb b/app/views/courses/_homework_form.html.erb index 41c059603..bfecb5304 100644 --- a/app/views/courses/_homework_form.html.erb +++ b/app/views/courses/_homework_form.html.erb @@ -30,7 +30,7 @@ <%#= f.text_field :budget, :required => true, :size => 60, :style => "width:350px;", :placeholder => l(:label_bids_reward_what) %>

--> <% time = (Time.now + 3600 * 24).strftime('%Y-%m-%d') %> -

<%= f.text_field(:deadline, :required => true, :size => 60, :style => "width:150px;",:value => "#{time}") %><%= calendar_for('bid_deadline')%> +

<%= f.text_field(:deadline, :required => true, :size => 60, :style => "width:150px;",:value => "#{time}",:readonly => "readonly") %><%= calendar_for('bid_deadline')%>

<%= f.select :is_evaluation, is_evaluation_option %>

diff --git a/app/views/memos/_form.html.erb b/app/views/memos/_form.html.erb index d4b517048..116f97149 100644 --- a/app/views/memos/_form.html.erb +++ b/app/views/memos/_form.html.erb @@ -2,12 +2,12 @@

<%= l(:label_homeworks_form_new_description) %>

+ <%# if @memo.safe_attribute? 'sticky' %> + <%#= f.check_box :sticky %> <%= l(:label_board_sticky) %> + <%# end %> + <%# if @memo.safe_attribute? 'locked' %> + <%#= f.check_box :locked %> <%#= label_tag 'memo_locked', l(:label_board_locked) %> + <%# end %> + <%# end %> -->

<%= f.text_field :content, :required => true, :size => 60, :style => "width:150px;" %>

<%= hidden_field_tag 'subject', ||=@memo.subject %> \ No newline at end of file From b635a6b3c5492476b35225f839872a12637b3360 Mon Sep 17 00:00:00 2001 From: zhanghaitao <562681745@qq.com> Date: Fri, 22 Aug 2014 09:38:07 +0800 Subject: [PATCH 11/26] =?UTF-8?q?1.=E6=B7=BB=E5=8A=A0=E5=B7=A5=E4=BD=9C?= =?UTF-8?q?=E5=8F=B0=E5=88=86=E9=A1=B5=E5=A4=84=E7=90=86=E6=93=8D=E4=BD=9C?= =?UTF-8?q?=202.=E5=88=86=E9=A1=B5=E5=A4=84=E7=90=86=E8=B7=AF=E7=94=B1?= =?UTF-8?q?=E5=87=BD=E6=95=B0=E6=B7=BB=E5=8A=A0?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- app/controllers/issues_controller.rb | 4 +++ app/controllers/my_controller.rb | 27 ++++++++++++++++++- app/views/my/blocks/_assiagn_issue.html.erb | 26 ++++++++++++++++++ .../my/blocks/_issuesassignedtome.html.erb | 20 +++----------- app/views/my/page.js.erb | 1 + app/views/my/page2.js.erb | 1 + config/routes.rb | 2 ++ 7 files changed, 63 insertions(+), 18 deletions(-) create mode 100644 app/views/my/blocks/_assiagn_issue.html.erb create mode 100644 app/views/my/page.js.erb create mode 100644 app/views/my/page2.js.erb diff --git a/app/controllers/issues_controller.rb b/app/controllers/issues_controller.rb index 9d734db37..b522a09d6 100644 --- a/app/controllers/issues_controller.rb +++ b/app/controllers/issues_controller.rb @@ -83,6 +83,10 @@ class IssuesController < ApplicationController :limit => @limit) @issue_count_by_group = @query.issue_count_by_group + + + + respond_to do |format| format.html { render :template => 'issues/index', :layout => @project_base_tag }#by young format.api { diff --git a/app/controllers/my_controller.rb b/app/controllers/my_controller.rb index 91da700a1..14814ed32 100644 --- a/app/controllers/my_controller.rb +++ b/app/controllers/my_controller.rb @@ -37,14 +37,39 @@ class MyController < ApplicationController }.freeze def index + page render :action => 'page' - end + end # Show user's page def page @user = User.current + @Issues= Issue.visible.open. + where(:assigned_to_id => ([User.current.id] + User.current.group_ids)) + @limit = 10 + @feedback_count = @Issues.count + @feedback_pages = Paginator.new @feedback_count, @limit, params['page'] + @offset ||= @feedback_pages.offset + @curse_attachments = @Issues[@offset, @limit] + + @blocks = @user.pref[:my_page_layout] || DEFAULT_LAYOUT + end + + def page2 + @limit = 10 + @user = User.current + @Issues= Issue.visible.open. + where(:assigned_to_id => ([User.current.id] + User.current.group_ids)) + @feedback_count = @Issues.count + @feedback_pages = Paginator.new @feedback_count, @limit, params['page'] + @offset ||= @feedback_pages.offset + @curse_attachments = @Issues[@offset, @limit] + @state = false @blocks = @user.pref[:my_page_layout] || DEFAULT_LAYOUT + respond_to do |format| + format.js + end end # Edit user's account diff --git a/app/views/my/blocks/_assiagn_issue.html.erb b/app/views/my/blocks/_assiagn_issue.html.erb new file mode 100644 index 000000000..6e7df84fd --- /dev/null +++ b/app/views/my/blocks/_assiagn_issue.html.erb @@ -0,0 +1,26 @@ +<% assigned_issues = issuesassignedtome_items %> +<%= render :partial => 'issues/list_simple', :locals => { :issues => assigned_issues } %> +<% if assigned_issues.length > 0 %> + + +

<%= link_to l(:label_issue_view_all), :controller => 'issues', + :action => 'index', + :set_filter => 1, + :assigned_to_id => 'me', + :sort => 'priority:desc,updated_on:desc' %>

+<% end %> +<% content_for :header_tags do %> +<%= auto_discovery_link_tag(:atom, + {:controller => 'issues', :action => 'index', :set_filter => 1, + :assigned_to_id => 'me', :format => 'atom', :key => User.current.rss_key}, + {:title => l(:label_assigned_to_me_issues)}) %> + +<% end %> \ No newline at end of file diff --git a/app/views/my/blocks/_issuesassignedtome.html.erb b/app/views/my/blocks/_issuesassignedtome.html.erb index 02d8c9aa6..0b20dd4e5 100644 --- a/app/views/my/blocks/_issuesassignedtome.html.erb +++ b/app/views/my/blocks/_issuesassignedtome.html.erb @@ -1,18 +1,4 @@

<%=l(:label_assigned_to_me_issues)%> (<%= Issue.visible.open.count(:conditions => {:assigned_to_id => ([User.current.id] + User.current.group_ids)})%>)

- -<% assigned_issues = issuesassignedtome_items %> -<%= render :partial => 'issues/list_simple', :locals => { :issues => assigned_issues } %> -<% if assigned_issues.length > 0 %> -

<%= link_to l(:label_issue_view_all), :controller => 'issues', - :action => 'index', - :set_filter => 1, - :assigned_to_id => 'me', - :sort => 'priority:desc,updated_on:desc' %>

-<% end %> - -<% content_for :header_tags do %> -<%= auto_discovery_link_tag(:atom, - {:controller => 'issues', :action => 'index', :set_filter => 1, - :assigned_to_id => 'me', :format => 'atom', :key => User.current.rss_key}, - {:title => l(:label_assigned_to_me_issues)}) %> -<% end %> +
+ <%= render :partial => "my/blocks/assiagn_issue" %> +
\ No newline at end of file diff --git a/app/views/my/page.js.erb b/app/views/my/page.js.erb new file mode 100644 index 000000000..d3f47a8e1 --- /dev/null +++ b/app/views/my/page.js.erb @@ -0,0 +1 @@ +$("#asdsadwsc").html("<%= escape_javascript(render :partial => 'my/blocks/assiagn_issue') %>"); \ No newline at end of file diff --git a/app/views/my/page2.js.erb b/app/views/my/page2.js.erb new file mode 100644 index 000000000..d3f47a8e1 --- /dev/null +++ b/app/views/my/page2.js.erb @@ -0,0 +1 @@ +$("#asdsadwsc").html("<%= escape_javascript(render :partial => 'my/blocks/assiagn_issue') %>"); \ No newline at end of file diff --git a/config/routes.rb b/config/routes.rb index f93318c7d..ed9001ee2 100644 --- a/config/routes.rb +++ b/config/routes.rb @@ -275,6 +275,8 @@ RedmineApp::Application.routes.draw do match 'my/remove_block', :controller => 'my', :action => 'remove_block', :via => :post match 'my/order_blocks', :controller => 'my', :action => 'order_blocks', :via => :post + get 'my/page2', :to => 'my#page2', :as => "my_page2" + resources :users match 'users/:id/memberships/:membership_id', :to => 'users#edit_membership', :via => :put, :as => 'user_membership' match 'users/:id/memberships/:membership_id', :to => 'users#destroy_membership', :via => :delete From 6253f281bc4d482c45de17f7179a4e5b81789e81 Mon Sep 17 00:00:00 2001 From: linhk <304431313@.com> Date: Fri, 22 Aug 2014 09:56:03 +0800 Subject: [PATCH 12/26] =?UTF-8?q?=E6=96=B0=E5=A2=9E=E8=AF=84=E5=AE=A1?= =?UTF-8?q?=E4=BB=BB=E5=8A=A1=E4=BD=8D=E7=BD=AE=E6=9B=B4=E6=94=B9?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- app/views/attachments/file.html.erb | 8 +++++++- 1 file changed, 7 insertions(+), 1 deletion(-) diff --git a/app/views/attachments/file.html.erb b/app/views/attachments/file.html.erb index 57393b81e..c85cbe32a 100644 --- a/app/views/attachments/file.html.erb +++ b/app/views/attachments/file.html.erb @@ -4,7 +4,13 @@

<%= h("#{@attachment.description} - ") unless @attachment.description.blank? %> <%= link_to_user(@attachment.author) %>, <%= format_time(@attachment.created_on) %>

<%= link_to_attachment @attachment, :text => l(:button_download), :download => true -%> - (<%= number_to_human_size @attachment.filesize %>)

+ (<%= number_to_human_size @attachment.filesize %>)    + <%= link = link_to(l(:button_add), {:controller => 'code_review', + :action => 'assign', :action_type => 'attachment', + :id=>@attachment.project, + :change_id => '', :attachment_id => @attachment.id, + }, :class => 'icon icon-add') %> +

  From 0d93783764f5892c5af273c1700cfe71ead20eed Mon Sep 17 00:00:00 2001 From: zhanghaitao <562681745@qq.com> Date: Fri, 22 Aug 2014 10:20:30 +0800 Subject: [PATCH 13/26] =?UTF-8?q?#1047=20=E4=BF=AE=E5=A4=8D=E4=BD=9C?= =?UTF-8?q?=E5=93=81=E4=B8=8B=E8=BD=BD--=E5=86=85=E5=AE=B9=E8=B6=85?= =?UTF-8?q?=E5=87=BA=E5=8F=B3=E8=BE=B9=E6=A1=86?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- app/views/files/_show_all_attachment.html.erb | 19 ++++++++++--------- 1 file changed, 10 insertions(+), 9 deletions(-) diff --git a/app/views/files/_show_all_attachment.html.erb b/app/views/files/_show_all_attachment.html.erb index 043fe1183..f865235ae 100644 --- a/app/views/files/_show_all_attachment.html.erb +++ b/app/views/files/_show_all_attachment.html.erb @@ -3,7 +3,8 @@ <% attachmenttypes = @project.attachmenttypes %> <% delete_allowed = User.current.allowed_to?(:manage_files, @project) %> <% edit_allowed = User.current.allowed_to?(:manage_files, @project) %> -
+
+
@@ -40,17 +41,17 @@ <%next%> <%end%> "> - + - - + - - + - + - @@ -83,7 +84,7 @@
<%= link_to_attachment file, :download => true, :title => file.filename+"\n"+file.description.to_s, :style => "width: 230px; overflow: hidden; white-space: nowrap;text-overflow: ellipsis;" %><%= link_to_attachment file, :download => true, :title => file.filename+"\n"+file.description.to_s, :style => "width: 230px; overflow: hidden; white-space: nowrap;text-overflow: ellipsis;" %> <%= number_to_human_size(file.filesize) %> + <%= number_to_human_size(file.filesize) %> <%= file.attachmentstype.typeName %> <%= render :partial => 'attachments/type_edit', :locals => {:attachmenttypes => attachmenttypes, :attachment => file, :contentype => selContentType} %> <%= file.show_suffix_type %> + <%= file.show_suffix_type %> <%= file.file_dense_str %>   @@ -58,9 +59,9 @@ :attachment => file} %> <%= file.downloads %><%= file.downloads %> + <%= link_to(image_tag('delete.png'), attachment_path(file), :data => {:confirm => l(:text_are_you_sure)}, :method => :delete) if delete_allowed %>
- +
-
- <%= textilizable message, :content, :attachments => message.attachments %> +
+ <%= textAreailizable message,:content,:attachments => message.attachments %> + <%#= message.content.html_safe %>
<%= link_to_attachments message, :author => false %>
+
@@ -40,17 +40,17 @@ <%next%> <%end%> "> - + - - + - - + - + - diff --git a/app/views/files/_show_all_attachment.html.erb b/app/views/files/_show_all_attachment.html.erb index f865235ae..e4af62cad 100644 --- a/app/views/files/_show_all_attachment.html.erb +++ b/app/views/files/_show_all_attachment.html.erb @@ -4,7 +4,7 @@ <% delete_allowed = User.current.allowed_to?(:manage_files, @project) %> <% edit_allowed = User.current.allowed_to?(:manage_files, @project) %>
-
<%= link_to_attachment file, :download => true, :title => file.filename+"\n"+file.description.to_s, :style => "width: 230px; overflow: hidden; white-space: nowrap;text-overflow: ellipsis;" %><%= link_to_attachment file, :download => true, :title => file.filename+"\n"+file.description.to_s, :style => "width: 230px; overflow: hidden; white-space: nowrap;text-overflow: ellipsis;" %> <%= number_to_human_size(file.filesize) %> + <%= number_to_human_size(file.filesize) %> <%= file.attachmentstype.typeName unless file.attachmentstype.nil? %> <%= render :partial => 'attachments/course_type_edit', :locals => {:attachmenttypes => attachmenttypes, :attachment => file, :contentype => selContentType} %> <%= file.show_suffix_type %> + <%= file.show_suffix_type %> <%= file.file_dense_str %>   @@ -58,9 +58,9 @@ :attachment => file} %> <%= file.downloads %><%= file.downloads %> + <%= link_to(image_tag('delete.png'), attachment_path(file), :data => {:confirm => l(:text_are_you_sure)}, :method => :delete) if delete_allowed %>
+
From c046ad011cab643fedd7626f83d370c3935f2e19 Mon Sep 17 00:00:00 2001 From: zhanghaitao <562681745@qq.com> Date: Fri, 22 Aug 2014 14:17:20 +0800 Subject: [PATCH 23/26] =?UTF-8?q?=E9=A1=B5=E9=9D=A2=E6=98=BE=E7=A4=BA?= =?UTF-8?q?=E4=BF=AE=E6=94=B9?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- app/views/files/_show_all_attachment.html.erb | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/app/views/files/_show_all_attachment.html.erb b/app/views/files/_show_all_attachment.html.erb index e4af62cad..aeabcfa9c 100644 --- a/app/views/files/_show_all_attachment.html.erb +++ b/app/views/files/_show_all_attachment.html.erb @@ -4,7 +4,7 @@ <% delete_allowed = User.current.allowed_to?(:manage_files, @project) %> <% edit_allowed = User.current.allowed_to?(:manage_files, @project) %>
-
+
From 00b38dc7926f8f973a17f2d8362368427aacdc59 Mon Sep 17 00:00:00 2001 From: zhanghaitao <562681745@qq.com> Date: Fri, 22 Aug 2014 14:20:45 +0800 Subject: [PATCH 24/26] =?UTF-8?q?=E9=A1=B5=E9=9D=A2=E6=98=BE=E7=A4=BA?= =?UTF-8?q?=E9=BB=98=E8=AE=A4=E8=BE=B9=E6=A1=86=E5=8F=96=E6=B6=88?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- app/views/files/_show_all_attachment.html.erb | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/app/views/files/_show_all_attachment.html.erb b/app/views/files/_show_all_attachment.html.erb index aeabcfa9c..0dbd735c4 100644 --- a/app/views/files/_show_all_attachment.html.erb +++ b/app/views/files/_show_all_attachment.html.erb @@ -4,7 +4,7 @@ <% delete_allowed = User.current.allowed_to?(:manage_files, @project) %> <% edit_allowed = User.current.allowed_to?(:manage_files, @project) %>
-
+
From 25affe30b0eac5d1767f42a7aa2e708ea72e8fd9 Mon Sep 17 00:00:00 2001 From: zhanghaitao <562681745@qq.com> Date: Fri, 22 Aug 2014 14:38:16 +0800 Subject: [PATCH 25/26] =?UTF-8?q?#1059=20=E8=BD=AF=E4=BB=B6=E5=88=9B?= =?UTF-8?q?=E5=AE=A2=E2=80=9D=20=E4=BF=AE=E6=94=B9=E7=94=A8=E6=88=B7?= =?UTF-8?q?=E8=B5=84=E6=96=99=E4=B8=AD=E7=9A=84=E7=94=A8=E6=88=B7=E5=8D=95?= =?UTF-8?q?=E4=BD=8D=E9=A1=B5=E9=9D=A2=E7=9A=84=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/my/account.html.erb | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/app/views/my/account.html.erb b/app/views/my/account.html.erb index 6a937b376..a57e35e65 100644 --- a/app/views/my/account.html.erb +++ b/app/views/my/account.html.erb @@ -128,7 +128,7 @@

学校列表

- +   
    <% @ss = School.find_by_sql("select distinct province from schools") %> @@ -140,7 +140,7 @@ <% end %>
-
+
    From 2a7b9025b6dfbac016f82b8551dffc0d727c27f2 Mon Sep 17 00:00:00 2001 From: sw <939547590@qq.com> Date: Fri, 22 Aug 2014 14:47:11 +0800 Subject: [PATCH 26/26] =?UTF-8?q?=E4=BF=AE=E5=A4=8D=E8=AF=BE=E7=A8=8B?= =?UTF-8?q?=E3=80=81=E9=A1=B9=E7=9B=AE=E4=B8=8A=E4=BC=A0=E8=B5=84=E6=BA=90?= =?UTF-8?q?=E5=85=B3=E8=81=94=E8=B5=84=E6=BA=90=E6=97=B6=EF=BC=8C=E6=9F=A5?= =?UTF-8?q?=E8=AF=A2=E5=87=BA=E7=BB=93=E6=9E=9C=E8=B6=85=E5=87=BA=E6=B5=8F?= =?UTF-8?q?=E8=A7=88=E5=99=A8=E8=BE=B9=E7=95=8C=E7=9A=84=E9=97=AE=E9=A2=98?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- app/views/attachments/autocomplete.js.erb | 1 + 1 file changed, 1 insertion(+) diff --git a/app/views/attachments/autocomplete.js.erb b/app/views/attachments/autocomplete.js.erb index 404ad9a61..abe2c3757 100644 --- a/app/views/attachments/autocomplete.js.erb +++ b/app/views/attachments/autocomplete.js.erb @@ -4,4 +4,5 @@ $('#relation_file').html('<%=render_attachments_for_new_project(@project, nil)%> <% elsif @course%> $('#relation_file').html('<%=render_attachments_for_new_course(@course, nil)%>'); <% end%> +$('#attachments').children().css("width","100%").css("word-break","break-all");