require(['order!domReady','order!jquery','order!i18n','order!startup'], function (domReady) {
- domReady.withResources(function () {
+ domReady.withResources(
+ loadi18n(function () {
$.ajax({
url: "restServices/archivaUiServices/runtimeInfoService/archivaRuntimeInfo/"+usedLang(),
dataType: 'json',
}
- })
- })
+ })
+ })
+ );
});
}
})
cache: false,//!window.archivaDevMode
dataType: 'json'
});
- loadi18n();
+
});
\ No newline at end of file
define("utils",["jquery","i18n","jquery.tmpl"], function() {
- loadi18n=function(){
+ loadi18n=function(loadCallback){
var browserLang = usedLang();
$.log("use browserLang:"+browserLang);
var options = {
cache:false,
mode: 'map',
- encoding:'utf-8'
+ encoding:'utf-8',
+ callback: loadCallback
};
loadAndParseFile("restServices/archivaServices/commonServices/getAllI18nResources?locale="+browserLang,options );
}