magic_locales 0.0.20 → 0.0.21

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA1:
3
- metadata.gz: 98ddbbbd16bad9c9239a196acf1990197e1b4787
4
- data.tar.gz: ffedc01e75bc0726f6e996178fd8a0503b1a6230
3
+ metadata.gz: 89fff227a4b3b7aadc8952547e26bb5a75537894
4
+ data.tar.gz: 5c41f74a5953e2b7c4b378a617fdc45d85719e46
5
5
  SHA512:
6
- metadata.gz: 111f032b466528acdec1fbb1fe103c5a16bae26e246c157e9ae07e5f57fb402ce4aa3bcac26c89258e34cb044221d811e39dd8afbf21aab1583af14b5a17eb15
7
- data.tar.gz: 25c8d0edf093820b7dd64f83c4d87584cf2e092f5cf2008cb1a44ec85235058511e821f54ad3017dae3b602e7a43eb0bc0d0d8df4ae09b0dcac9b478b7b4f7f3
6
+ metadata.gz: 46737baf2fbcd8fee5e090efe2784638a19c73435e3d101dc0768cb62e465f80e0af81d5193199bcf9084ea0e9c3d33b8422b57c9378b6d63ec1400185b38982
7
+ data.tar.gz: c98dc0dfb328b5405d877c965c3a5eb55eb01dd9d28d9c940076bf291ecdfad813fe249eef6853cf9c569684e1e781ed7d110aa9f98b40b1f33aa4ce7f80d6ce
@@ -6,6 +6,12 @@ class MagicLocales::BaseController < ApplicationController
6
6
  before_action :authenticate_visitor, except: [:change_locale]
7
7
 
8
8
 
9
+ protected
10
+
11
+ def default_url_options( options = {} )
12
+ { locale: I18n.locale, only_path: true }
13
+ end
14
+
9
15
  private
10
16
 
11
17
  # overwrite for authentication
@@ -1 +1 @@
1
- <%= link_to raw("<i class='icomoon-pencil'></i>"), url_for( controller: "magic_locales/locales", action: :edit, id: locale), class: "btn btn-default btn-sm", data: { toggle: "modal", target: "#appModal" }, title: t("magic_locales.edit") %>
1
+ <%= link_to raw("<i class='icomoon-pencil'></i>"), url_for( controller: "/magic_locales/locales", action: :edit, id: locale), class: "btn btn-default btn-sm", data: { toggle: "modal", target: "#appModal" }, title: t("magic_locales.edit") %>
@@ -4,6 +4,6 @@
4
4
 
5
5
  <% %w(activate release deactivate).each do |state| %>
6
6
  <% if locale.state.trigger?(state.to_sym) %>
7
- <%= link_to raw("<i class='icomoon-#{clss[state]}'></i>"), url_for( controller: "magic_locales/locales", action: :trigger, id: locale, state: state), class: "btn btn-#{clss[state]} btn-sm", title: t("magic_locales.triggers.#{state}") %>
7
+ <%= link_to raw("<i class='icomoon-#{clss[state]}'></i>"), url_for( controller: "/magic_locales/locales", action: :trigger, id: locale, state: state), class: "btn btn-#{clss[state]} btn-sm", title: t("magic_locales.triggers.#{state}") %>
8
8
  <% end %>
9
9
  <% end %>
@@ -1,5 +1,5 @@
1
1
  <%# path = @locale.id.present? ? mgclang_locale_path(@locale) : mgclang_locales_path %>
2
- <% path = @locale.id.present? ? url_for( controller: "magic_locales/locales", action: :update, id: @locale) : url_for( controller: "magic_locales/locales", action: :create ) %>
2
+ <% path = @locale.id.present? ? url_for( controller: "/magic_locales/locales", action: :update, id: @locale) : url_for( controller: "/magic_locales/locales", action: :create ) %>
3
3
 
4
4
  <%= form_for @locale, url: path do |f| %>
5
5
 
@@ -2,7 +2,7 @@
2
2
 
3
3
  <%= content_for :headline do %>
4
4
 
5
- <%= link_to "+ #{t("activerecord.attributes.magic_locales_locale.one")}", url_for( controller: "magic_locales/locales", action: :new), class: "btn btn-success pull-right btn-sm", data: { toggle: "modal", target: "#appModal" } %>
5
+ <%= link_to "+ #{t("activerecord.attributes.magic_locales_locale.one")}", url_for( controller: "/magic_locales/locales", action: :new), class: "btn btn-success pull-right btn-sm", data: { toggle: "modal", target: "#appModal" } %>
6
6
  <i class="icon-bubbles"></i> <%= t("activerecord.attributes.magic_locales_locale.other") %>
7
7
 
8
8
  <% end %>
@@ -32,7 +32,7 @@ module MagicLocales
32
32
 
33
33
  desc "add magic_logales initialitzer"
34
34
  def copy_mgca_initialitzer
35
- copy_file( "magic_initializer.rb", "config/initializers/magic_logales.rb" )
35
+ copy_file( "magic_initializer.rb", "config/initializers/magic_locales.rb" )
36
36
  end
37
37
 
38
38
  desc "add magic_locales routes"
@@ -1,3 +1,3 @@
1
1
  module MagicLocales
2
- VERSION = "0.0.20"
2
+ VERSION = "0.0.21"
3
3
  end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: magic_locales
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.0.20
4
+ version: 0.0.21
5
5
  platform: ruby
6
6
  authors:
7
7
  - Torsten Wetzel
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2016-01-04 00:00:00.000000000 Z
11
+ date: 2017-07-24 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: rails