forked from External/greenlight
HOT-FIX: Issue with changes with the language file name (#466)
* HOT-FIX: Issue with changes with the language file name * Rubocop!
This commit is contained in:
parent
5ff41d0590
commit
c8a799bce8
|
@ -45,7 +45,7 @@ class ApplicationController < ActionController::Base
|
||||||
|
|
||||||
def update_locale(user)
|
def update_locale(user)
|
||||||
I18n.locale = if user && user.language != 'default'
|
I18n.locale = if user && user.language != 'default'
|
||||||
user.language
|
user.language.tr('-', '_')
|
||||||
else
|
else
|
||||||
http_accept_language.language_region_compatible_from(I18n.available_locales)
|
http_accept_language.language_region_compatible_from(I18n.available_locales)
|
||||||
end
|
end
|
||||||
|
|
|
@ -64,7 +64,7 @@ module SessionsHelper
|
||||||
end
|
end
|
||||||
|
|
||||||
def parse_user_domain(hostname)
|
def parse_user_domain(hostname)
|
||||||
return hostname.split('.').first unless Rails.configuration.url_host
|
return hostname.split('.').first if Rails.configuration.url_host.empty?
|
||||||
Rails.configuration.url_host.split(',').each do |url_host|
|
Rails.configuration.url_host.split(',').each do |url_host|
|
||||||
if hostname.include?(url_host)
|
if hostname.include?(url_host)
|
||||||
return hostname.chomp(url_host).chomp('.')
|
return hostname.chomp(url_host).chomp('.')
|
||||||
|
|
|
@ -93,7 +93,7 @@ es:
|
||||||
video: Ve nuestro tutorial de como utilizar Greenlight
|
video: Ve nuestro tutorial de como utilizar Greenlight
|
||||||
upgrade: Muestrame como actualizar a versión 2.0
|
upgrade: Muestrame como actualizar a versión 2.0
|
||||||
version: Hemos publicado una nueva version de Greenlight pero tu base de datos no es compatible.
|
version: Hemos publicado una nueva version de Greenlight pero tu base de datos no es compatible.
|
||||||
language_name: Español (México)
|
language_name: Español
|
||||||
language_default: Por omisión (idioma del navegador)
|
language_default: Por omisión (idioma del navegador)
|
||||||
ldap_error: No se puede conectar al servidor LDAP. Compruebe la configuración de LDAP en el archivo "env" y asegúrate de que tu servidor está ejecutándose.
|
ldap_error: No se puede conectar al servidor LDAP. Compruebe la configuración de LDAP en el archivo "env" y asegúrate de que tu servidor está ejecutándose.
|
||||||
login: Ingresar
|
login: Ingresar
|
||||||
|
|
Loading…
Reference in New Issue