lib/scaffolding_extensions/controller/ramaze.rb
# Sets request.params['id'] if it was given as part of the request path.
# Checks nonidempotent requests require POST.
Sets request.params['id'] if it was given as part of the request path.
Checks nonidempotent requests require POST.
Sets request . params [ ' id ' ] if it was given as part of the request path . Checks nonidempotent requests require POST .
def scaffold_define_method(name, &block)
      scaffolded_methods.add(name)
      define_method(name) do |*args|
        scaffold_check_nonidempotent_requests
        request.params['id'] = args.shift if args.length > 0
        instance_eval(&block)
      end
    end
def scaffold_define_method ( name , & block ) scaffolded_methods . add ( name ) define_method ( name ) do | * args | scaffold_check_nonidempotent_requests request . params [ 'id' ] = args . shift if args . length > 0 instance_eval ( & block ) end end
Sets request.params['id'] if it was given as part of the request path.
Sets request . params [ ' id ' ] if it was given as part of the request path .
name
<not_specific>
block
<not_specific>