Sha256: eb0d1e4457a33d2a78a48246586da0ac34dbe8f8c30de2b87d806f6c1cb5fe21

Contents?: true

Size: 371 Bytes

Versions: 10

Compression:

Stored size: 371 Bytes

Contents

class ServiceGenerator < Rails::Generators::NamedBase
  source_root File.expand_path('../templates', __FILE__)

  def create_service_file
    template("service.rb", File.join("app/services", class_path, "#{file_name}.rb"))
  end

  def generate_locale_file
    invoke("locale:service", [name]) if ActiveGenerator.configuration.autoload_service_generator_locale
  end

end

Version data entries

10 entries across 10 versions & 1 rubygems

Version Path
active_generator-2.2.8 lib/generators/service/service_generator.rb
active_generator-2.2.7 lib/generators/service/service_generator.rb
active_generator-2.2.6 lib/generators/service/service_generator.rb
active_generator-2.2.5 lib/generators/service/service_generator.rb
active_generator-2.2.4 lib/generators/service/service_generator.rb
active_generator-2.2.3 lib/generators/service/service_generator.rb
active_generator-2.2.2 lib/generators/service/service_generator.rb
active_generator-2.2.1 lib/generators/service/service_generator.rb
active_generator-2.2.0 lib/generators/service/service_generator.rb
active_generator-2.1.0 lib/generators/service/service_generator.rb