diff --git a/app/controllers/courses_controller.rb b/app/controllers/courses_controller.rb index 524bde9d7..210ac8f3d 100644 --- a/app/controllers/courses_controller.rb +++ b/app/controllers/courses_controller.rb @@ -695,12 +695,13 @@ class CoursesController < ApplicationController # 显示老师和助教的活动 # @authors = searchTeacherAndAssistant(@course) @authors = course_all_member(@course) - Dir.glob("#{Rails.root}/app/models/*.rb").sort.each { |file| require file } + #TODO 貌似删除操作不会更新缓存 还是先不用缓存吧 + # Dir.glob("#{Rails.root}/app/models/*.rb").sort.each { |file| require file } events = [] - key = "course_events_#{@course.id}".to_sym - if Rails.env.production? && Setting.course_cahce_enabled? - events = Rails.cache.read(key) || [] - end + # key = "course_events_#{@course.id}".to_sym + # if Rails.env.production? && Setting.course_cahce_enabled? + # events = Rails.cache.read(key) || [] + # end if events.empty? @authors.each do |author| @activity = Redmine::Activity::Fetcher.new(User.current, :course => @course, @@ -716,7 +717,7 @@ class CoursesController < ApplicationController events += @activity.events(@days, @course.created_at, :is_public => 1) end end - Rails.cache.write(key, events) if Rails.env.production? && Setting.course_cahce_enabled? + # Rails.cache.write(key, events) if Rails.env.production? && Setting.course_cahce_enabled? end else # @author = @course.teacher diff --git a/app/controllers/memos_controller.rb b/app/controllers/memos_controller.rb index 54bcc0496..68f6f6473 100644 --- a/app/controllers/memos_controller.rb +++ b/app/controllers/memos_controller.rb @@ -157,7 +157,7 @@ class MemosController < ApplicationController def update respond_to do |format| - if( @memo.update_column(:subject, params[:memo][:subject]) && + if( #@memo.update_column(:subject, params[:memo][:subject]) && @memo.update_column(:content, params[:memo][:content]) && @memo.update_column(:sticky, params[:memo][:sticky]) && @memo.update_column(:lock, params[:memo][:lock])) diff --git a/app/controllers/repositories_controller.rb b/app/controllers/repositories_controller.rb index d0af82c8c..607c9b5db 100644 --- a/app/controllers/repositories_controller.rb +++ b/app/controllers/repositories_controller.rb @@ -227,7 +227,7 @@ update elsif request.get? respond_to do |format| format.html{ - render :layout => "project_base" + render :layout => "base_projects" } end @@ -376,7 +376,7 @@ update def revision respond_to do |format| - format.html{render :layout => 'project_base'} + format.html{render :layout => 'base_projects'} format.js {render :layout => false} end end diff --git a/app/views/memos/edit.html.erb b/app/views/memos/edit.html.erb index 6fc361d27..487d923b5 100644 --- a/app/views/memos/edit.html.erb +++ b/app/views/memos/edit.html.erb @@ -21,9 +21,9 @@
<% if @memo.parent.nil? && @memo.children.first.nil? %> - <%= f.text_field :subject, :required => true, :size => 96 ,:readonly => false, :maxlength => 50%> + <%#= f.text_field :subject, :required => true, :size => 96 ,:readonly => false, :maxlength => 50%> <% else %> - <%= f.text_field :subject, :required => true, :size => 96 ,:readonly => true, :style => "border: 1px solid gray", :maxlength => 50%> + <%#= f.text_field :subject, :required => true, :size => 96 ,:readonly => true, :style => "border: 1px solid gray", :maxlength => 50%> <% end %>
<% if User.current.admin?%> diff --git a/app/views/projects/settings/_new_repositories.html.erb b/app/views/projects/settings/_new_repositories.html.erb index 6e0d74849..ca771a487 100644 --- a/app/views/projects/settings/_new_repositories.html.erb +++ b/app/views/projects/settings/_new_repositories.html.erb @@ -33,8 +33,7 @@