mirror of
https://github.com/EGroupware/egroupware.git
synced 2024-11-23 08:23:12 +01:00
WIP EGroupware tutorial:
- Make sure to not create etemplate2 object for an empty container - Fix fallback lang not working
This commit is contained in:
parent
9fce06e650
commit
1d43c74ea6
@ -1018,6 +1018,8 @@ var AppJS = Class.extend(
|
|||||||
{
|
{
|
||||||
//DOM container
|
//DOM container
|
||||||
var div = document.getElementById('egw_tutorial_'+egw.app_name()+'_sidebox');
|
var div = document.getElementById('egw_tutorial_'+egw.app_name()+'_sidebox');
|
||||||
|
if (!div) return;
|
||||||
|
|
||||||
// et2 object
|
// et2 object
|
||||||
var etemplate = new etemplate2 (div, false);
|
var etemplate = new etemplate2 (div, false);
|
||||||
var template = egw.webserverUrl+'/etemplate/templates/default/egw_tutorial.xet';
|
var template = egw.webserverUrl+'/etemplate/templates/default/egw_tutorial.xet';
|
||||||
@ -1027,7 +1029,7 @@ var AppJS = Class.extend(
|
|||||||
var content = {content:{list:[]}};
|
var content = {content:{list:[]}};
|
||||||
if (_data && _data[egw.app_name()])
|
if (_data && _data[egw.app_name()])
|
||||||
{
|
{
|
||||||
if (_data[egw.app_name()][lang] == 'undefined' || _data[egw.app_name()][lang].length == 0 ) lang = 'en';
|
if (!_data[egw.app_name()][lang]) lang = 'en';
|
||||||
if (typeof _data[egw.app_name()][lang] !='undefined'
|
if (typeof _data[egw.app_name()][lang] !='undefined'
|
||||||
&& _data[egw.app_name()][lang].length > 0)
|
&& _data[egw.app_name()][lang].length > 0)
|
||||||
{
|
{
|
||||||
|
Loading…
Reference in New Issue
Block a user