camping.txt

doc/camping.txt
Last Update: Wed Dec 17 10:17:53 -0800 2008

Camping doesn’t have a defined folder structure for models, so scaffold_all_models shouldn’t be used unless you pass the :only option, which gives a list of models to scaffold.

To use this plugin after installing the gem:

  require 'scaffolding_extensions'

If you want to use it without installing the gem, add this before requiring it:

  $:.unshift('scaffolding_extensions/lib')

To use the plugin, inside your app’s Controllers module, you need to define a subclass of scaffold_R, and call one of the scaffold methods inside of it. For example:

  Camping.goes :Cse
  module Cse::Controllers
    class Admin < scaffold_R("/admin")
      scaffold_all_models :only=>[Model1, Model2, Model3]
    end
  end

The path given to scaffold_R will be the root of the plugin.

Camping is not fully supported in that you can’t override the scaffolded layout or scaffold templates without changing the scaffold_template_dir.