Sha256: 82a0b38ab795efdaf897ee2a624036b79a2f88c458438df7da3ffca3c39df81c

Contents?: true

Size: 529 Bytes

Versions: 5

Compression:

Stored size: 529 Bytes

Contents

require 'rails/generators/rails/scaffold/scaffold_generator'

module Goma
  module Generators
    module Scaffold
      class SessionGenerator < Rails::Generators::ScaffoldGenerator
        class_option :resource_name

        def initialize(args, *options)
          options[0] << '--controller-type=session'
          super
        end

        remove_hook_for :orm

        hook_for :resource_route,      required: true, in: 'goma'
        hook_for :scaffold_controller, required: true, in: 'goma'
      end
    end
  end
end

Version data entries

5 entries across 5 versions & 1 rubygems

Version Path
goma-0.0.1.rc3 lib/generators/goma/scaffold/session_generator.rb
goma-0.0.1.rc2 lib/generators/goma/scaffold/session_generator.rb
goma-0.0.1.rc1 lib/generators/goma/scaffold/session_generator.rb
goma-0.0.1.gamma lib/generators/goma/scaffold/session_generator.rb
goma-0.0.1.beta lib/generators/goma/scaffold/session_generator.rb