All pastes #634689 Raw Edit

Mine

public ruby v1 · immutable
#634689 ·published 2007-07-26 16:27 UTC
rendered paste body
    class NewReport<R('/new/report')      def get        h1 "Not Implemented Yet"      end            def post        mod = Object.const_get(input[:module])        x = mod.const_get(input[:klass]) rescue nil        raise if x        klass = Class.new(Ruport::Report) {          renders_as_table          define_method(:renderable_data) { query(input[:sql]) }        }        mod = Object.const_get(input[:module])        mod.const_set(input[:klass],klass)        mod.const_get(input[:klass]).instance_eval {acts_as_managed_report }      end    end