Sha256: 106d70dd64620dc32d00bea5deeb987ac00f07c0bd09a8c8143d2fcb1f46d2c3

Contents?: true

Size: 861 Bytes

Versions: 18

Compression:

Stored size: 861 Bytes

Contents

class AwesomeTranslations::MovalsController < AwesomeTranslations::ApplicationController
  def index
    @movals = AwesomeTranslations::CacheDatabaseGenerator::TranslationValue
      .select("translation_values.*, handler_translations.id AS handler_translation_id")
      .joins("
        INNER JOIN handler_translations ON
          handler_translations.translation_key_id = translation_values.translation_key_id
      ")
      .where("translation_values.file_path NOT LIKE handler_translations.dir || '%'")
      .group("translation_values.id")
  end

  def create
    params[:m].each do |translation_value_id, _handler_translation_id|
      translation_value = AwesomeTranslations::CacheDatabaseGenerator::TranslationValue.find(translation_value_id)
      translation_value.migrate_to_awesome_translations_namespace!
    end

    redirect_to :back
  end
end

Version data entries

18 entries across 18 versions & 1 rubygems

Version Path
awesome_translations-0.0.50 app/controllers/awesome_translations/movals_controller.rb
awesome_translations-0.0.49 app/controllers/awesome_translations/movals_controller.rb
awesome_translations-0.0.48 app/controllers/awesome_translations/movals_controller.rb
awesome_translations-0.0.47 app/controllers/awesome_translations/movals_controller.rb
awesome_translations-0.0.46 app/controllers/awesome_translations/movals_controller.rb
awesome_translations-0.0.45 app/controllers/awesome_translations/movals_controller.rb
awesome_translations-0.0.44 app/controllers/awesome_translations/movals_controller.rb
awesome_translations-0.0.43 app/controllers/awesome_translations/movals_controller.rb
awesome_translations-0.0.42 app/controllers/awesome_translations/movals_controller.rb
awesome_translations-0.0.41 app/controllers/awesome_translations/movals_controller.rb
awesome_translations-0.0.40 app/controllers/awesome_translations/movals_controller.rb
awesome_translations-0.0.39 app/controllers/awesome_translations/movals_controller.rb
awesome_translations-0.0.38 app/controllers/awesome_translations/movals_controller.rb
awesome_translations-0.0.37 app/controllers/awesome_translations/movals_controller.rb
awesome_translations-0.0.36 app/controllers/awesome_translations/movals_controller.rb
awesome_translations-0.0.35 app/controllers/awesome_translations/movals_controller.rb
awesome_translations-0.0.34 app/controllers/awesome_translations/movals_controller.rb
awesome_translations-0.0.33 app/controllers/awesome_translations/movals_controller.rb