mirror of
https://github.com/node-red/node-red.git
synced 2023-10-10 13:36:53 +02:00
parent
6b7e623d33
commit
617628b886
@ -51,7 +51,7 @@ RED.i18n = (function() {
|
|||||||
|
|
||||||
},
|
},
|
||||||
loadNodeCatalog: function(namespace,done) {
|
loadNodeCatalog: function(namespace,done) {
|
||||||
var languageList = i18n.functions.toLanguages(i18n.detectLanguage());
|
var languageList = i18n.functions.toLanguages(localStorage.getItem("editor-language")||i18n.detectLanguage());
|
||||||
var toLoad = languageList.length;
|
var toLoad = languageList.length;
|
||||||
languageList.forEach(function(lang) {
|
languageList.forEach(function(lang) {
|
||||||
$.ajax({
|
$.ajax({
|
||||||
@ -73,7 +73,7 @@ RED.i18n = (function() {
|
|||||||
},
|
},
|
||||||
|
|
||||||
loadNodeCatalogs: function(done) {
|
loadNodeCatalogs: function(done) {
|
||||||
var languageList = i18n.functions.toLanguages(i18n.detectLanguage());
|
var languageList = i18n.functions.toLanguages(localStorage.getItem("editor-language")||i18n.detectLanguage());
|
||||||
var toLoad = languageList.length;
|
var toLoad = languageList.length;
|
||||||
|
|
||||||
languageList.forEach(function(lang) {
|
languageList.forEach(function(lang) {
|
||||||
|
@ -107,9 +107,12 @@ var RED = (function() {
|
|||||||
}
|
}
|
||||||
|
|
||||||
function loadNodes() {
|
function loadNodes() {
|
||||||
|
var lang = localStorage.getItem("editor-language")||i18n.detectLanguage();
|
||||||
|
|
||||||
$.ajax({
|
$.ajax({
|
||||||
headers: {
|
headers: {
|
||||||
"Accept":"text/html"
|
"Accept":"text/html",
|
||||||
|
"Accept-Language": lang
|
||||||
},
|
},
|
||||||
cache: false,
|
cache: false,
|
||||||
url: 'nodes',
|
url: 'nodes',
|
||||||
|
Loading…
Reference in New Issue
Block a user