Newbie ruby question.
I have a class
class ReportPage < Page
def badge_item(item_int)
case item_int
when 1..50 then @item= 1
when 50..100 then @item= 50
end
def check_completed_items_badge
badge_item(50)
puts @item
end
end
Sure enough, it puts nil. And here comes my question - how can I use @item variable inside of the other method of the class?
Thank you a lot!