Displaying 1 result from an estimated 1 matches for "simple_obj".
Did you mean:
simple_objs
2006 Jan 13
6
rails bug ? metadata lost between page invocation ?
...ation, so that''s why the class variable has to be in a separate
class, one that won''t be reloaded between invocation)
Let me simply give a code example to show what I mean:
Here is the SimpleObj model (notice the new method ''extra_attr''):
# file app/models/simple_obj
class SimpleObj < ActiveRecord::Base
def extra_attr
"hello"
end
end
Here is the controller
# file app/controllers/my_test_controller.rb
class MyTestController < ApplicationController
def put
MyCache.put
end
def get...