Import translations by each locale, not at once (document size issue).
This commit is contained in:
parent
01298449cc
commit
3491dcf043
1 changed files with 32 additions and 30 deletions
|
@ -15,7 +15,8 @@ load translations from online
|
||||||
=end
|
=end
|
||||||
|
|
||||||
def self.load
|
def self.load
|
||||||
url = 'https://i18n.zammad.com/api/v1/translations'
|
Locale.where(active: true).each {|locale|
|
||||||
|
url = "https://i18n.zammad.com/api/v1/translations/#{locale.locale}"
|
||||||
if !UserInfo.current_user_id
|
if !UserInfo.current_user_id
|
||||||
UserInfo.current_user_id = 1
|
UserInfo.current_user_id = 1
|
||||||
end
|
end
|
||||||
|
@ -49,6 +50,7 @@ load translations from online
|
||||||
end
|
end
|
||||||
}
|
}
|
||||||
end
|
end
|
||||||
|
}
|
||||||
true
|
true
|
||||||
end
|
end
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue