From 2ae6b54a45338fd85fca0664152aa285972b5b39 Mon Sep 17 00:00:00 2001 From: "Matthew K. Fu JuYuan" Date: Fri, 13 Jul 2012 18:32:17 +0800 Subject: [PATCH] fix for not working cache --- app/controllers/admin/module_apps_new_interface_controller.rb | 2 +- app/views/layouts/_users_checkbox_ary.html.erb | 2 -- 2 files changed, 1 insertion(+), 3 deletions(-) diff --git a/app/controllers/admin/module_apps_new_interface_controller.rb b/app/controllers/admin/module_apps_new_interface_controller.rb index 2f1b0fe6..ab6dceee 100644 --- a/app/controllers/admin/module_apps_new_interface_controller.rb +++ b/app/controllers/admin/module_apps_new_interface_controller.rb @@ -6,7 +6,7 @@ class Admin::ModuleAppsNewInterfaceController < OrbitBackendController layout "new_admin" def setting - @sys_users = Rails.cache.read('user_setting') #User.all(conditions: {admin: false}).includes(:avatar) + @sys_users = User.all(conditions: {admin: false}).includes(:avatar) @module_app = ModuleApp.find(params[:module_app_id]) @options_from_collection_for_select_bulletin_categorys = [@module_app].collect{|ma| [ma.title,ma.id] } # if params.has_key? :category diff --git a/app/views/layouts/_users_checkbox_ary.html.erb b/app/views/layouts/_users_checkbox_ary.html.erb index aa2e1d45..e3baca27 100644 --- a/app/views/layouts/_users_checkbox_ary.html.erb +++ b/app/views/layouts/_users_checkbox_ary.html.erb @@ -1,5 +1,3 @@ <%= content_tag :div ,:id => "users_checkbox_ary",:class => 'clear' do %> - <% cache ["users_checkbox_ary"] do%> <%= render :partial => "shared/privilege_user",:collection =>@sys_users,:as=>:user ,:locals =>{ :chosen_users=> @users_array } %> - <%end -%> <%end -%> \ No newline at end of file