Improved code layout.
This commit is contained in:
parent
b026113a34
commit
00cc1ff6ce
1 changed files with 1 additions and 1 deletions
|
@ -15,7 +15,7 @@ class ApplicationModel < ActiveRecord::Base
|
||||||
def self.cache_set(data_id, data)
|
def self.cache_set(data_id, data)
|
||||||
# puts 'cache_set', data_id
|
# puts 'cache_set', data_id
|
||||||
key = self.to_s + '::' + data_id.to_s
|
key = self.to_s + '::' + data_id.to_s
|
||||||
Rails.cache.write( key.to_s, data)
|
Rails.cache.write( key.to_s, data )
|
||||||
end
|
end
|
||||||
def self.cache_get(data_id)
|
def self.cache_get(data_id)
|
||||||
# puts 'cache_get', data_id
|
# puts 'cache_get', data_id
|
||||||
|
|
Loading…
Reference in a new issue