Sha256: dc92f22eef49d4f25166f759ccaed8b4654501398eefe3d761c839fdbdf70a95
Contents?: true
Size: 764 Bytes
Versions: 5
Compression:
Stored size: 764 Bytes
Contents
class MotionPrime::ScaffoldGenerator < MotionPrime::Generator def generate(name) @s_name = name.singularize.downcase @p_name = name.pluralize.downcase @s_title = @s_name.titleize @p_title = @p_name.titleize @s_class_name = @s_name.camelize @p_class_name = @p_name.camelize template 'scaffold/screen.rb', "app/screens/#{@p_name}.rb" template 'scaffold/model.rb', "app/models/#{@s_name}.rb" template 'scaffold/table.rb', "app/sections/#{@p_name}/table.rb" template 'scaffold/cell.rb', "app/sections/#{@p_name}/cell.rb" template 'scaffold/form.rb', "app/sections/#{@p_name}/form.rb" template 'scaffold/show.rb', "app/sections/#{@p_name}/show.rb" template 'scaffold/styles.rb', "app/styles/#{@p_name}.rb" end end
Version data entries
5 entries across 5 versions & 1 rubygems