Sha256: 83f688ae479d61e0651d2f0ed395c9b7d1707cb5e0f18ffaceb9aab42102d4b1
Contents?: true
Size: 863 Bytes
Versions: 3
Compression:
Stored size: 863 Bytes
Contents
module Rails::Assist artifacts.each do |name| class_eval %{ module #{name.to_s.camelize} include Rails::Assist::BaseHelper def create_#{name} name, options={}, &block create_artifact(name, set(options, :#{name}), &block) end def insert_into_#{name}(name, options={}, &block) insert_content(name, set(options, :#{name}), &block) end def read_#{name}(name, options={}, &block) read_artifact(name, set(options, :#{name}), &block) end def remove_#{name} name remove_artifact name, :#{name} end def remove_#{name}s *names remove_artifacts :#{name}, *names end aliases_for :#{name} end } end end
Version data entries
3 entries across 3 versions & 1 rubygems
Version | Path |
---|---|
rails3_assist-0.2.4 | lib/rails3_assist/app/methods/crud.rb |
rails3_assist-0.2.3 | lib/rails3_assist/app/methods/crud.rb |
rails3_assist-0.2.2 | lib/rails3_assist/app/methods/crud.rb |