name : "Pman.Tab.CmsTranslateTemplates",
disabled : false,
permname : '',
- _tree : function()
+ _tree : function(_data)
{
var _this = this;
var MODULE = this;
return {
+ xtype : 'NestedLayoutPanel',
region : 'center',
title : _this._strings['dc00a593c8be0a664ba934335b093154'] /* Translate Templates */,
xns : Roo,
'|xns' : 'Roo',
- xtype : 'NestedLayoutPanel',
layout : {
+ xtype : 'BorderLayout',
xns : Roo,
'|xns' : 'Roo',
- xtype : 'BorderLayout',
center : {
+ xtype : 'LayoutRegion',
xns : Roo,
- '|xns' : 'Roo',
- xtype : 'LayoutRegion'
+ '|xns' : 'Roo'
},
west : {
+ xtype : 'LayoutRegion',
split : true,
width : 300,
xns : Roo,
- '|xns' : 'Roo',
- xtype : 'LayoutRegion'
+ '|xns' : 'Roo'
},
items : [
{
- region : 'west',
- xns : Roo,
- '|xns' : 'Roo',
xtype : 'TreePanel',
+ region : 'west',
listeners : {
render : function (_self)
{
_this.treepanel = _self;
}
},
+ xns : Roo,
+ '|xns' : 'Roo',
toolbar : {
+ xtype : 'Toolbar',
xns : Roo,
'|xns' : 'Roo',
- xtype : 'Toolbar',
items : [
{
- text : _this._strings['03c2e7e41ffc181a4e84080b4710e81e'] /* New */,
- xns : Roo.Toolbar,
- '|xns' : 'Roo.Toolbar',
xtype : 'Button',
+ text : _this._strings['03c2e7e41ffc181a4e84080b4710e81e'] /* New */,
listeners : {
click : function (_self, e)
{
});
}
- }
+ },
+ xns : Roo.Toolbar,
+ '|xns' : 'Roo.Toolbar'
},
{
+ xtype : 'Separator',
xns : Roo.Toolbar,
- '|xns' : 'Roo.Toolbar',
- xtype : 'Separator'
+ '|xns' : 'Roo.Toolbar'
},
{
- text : _this._strings['f2a6c498fb90ee345d997f888fce3b18'] /* Delete */,
- xns : Roo.Toolbar,
- '|xns' : 'Roo.Toolbar',
xtype : 'Button',
+ text : _this._strings['f2a6c498fb90ee345d997f888fce3b18'] /* Delete */,
listeners : {
click : function (_self, e)
{
});
}
- }
+ },
+ xns : Roo.Toolbar,
+ '|xns' : 'Roo.Toolbar'
},
{
+ xtype : 'Separator',
xns : Roo.Toolbar,
- '|xns' : 'Roo.Toolbar',
- xtype : 'Separator'
+ '|xns' : 'Roo.Toolbar'
},
{
- text : _this._strings['cd6ae20e52d83f601c5fa12b66f0f6d0'] /* Rescan */,
- xns : Roo.Toolbar,
- '|xns' : 'Roo.Toolbar',
xtype : 'Button',
+ text : _this._strings['cd6ae20e52d83f601c5fa12b66f0f6d0'] /* Rescan */,
listeners : {
click : function (_self, e)
{
}
- }
+ },
+ xns : Roo.Toolbar,
+ '|xns' : 'Roo.Toolbar'
},
{
+ xtype : 'Fill',
xns : Roo.Toolbar,
- '|xns' : 'Roo.Toolbar',
- xtype : 'Fill'
+ '|xns' : 'Roo.Toolbar'
},
{
- text : _this._strings['4d1c8263ba1036754f8db14a98f9f006'] /* Reload */,
- xns : Roo.Toolbar,
- '|xns' : 'Roo.Toolbar',
xtype : 'Button',
+ text : _this._strings['4d1c8263ba1036754f8db14a98f9f006'] /* Reload */,
listeners : {
click : function (_self, e)
{
_this.treepanel.tree.getRootNode().reload();
}
- }
+ },
+ xns : Roo.Toolbar,
+ '|xns' : 'Roo.Toolbar'
}
]
},
tree : {
+ xtype : 'TreePanel',
containerScroll : false,
rootVisible : true,
xns : Roo.tree,
'|xns' : 'Roo.tree',
- xtype : 'TreePanel',
root : {
+ xtype : 'AsyncTreeNode',
id : 'transtree',
text : _this._strings['0b8d92bc19b720bb1065649535463409'] /* Translations */,
xns : Roo.tree,
- '|xns' : 'Roo.tree',
- xtype : 'AsyncTreeNode'
+ '|xns' : 'Roo.tree'
},
selModel : {
- xns : Roo.tree,
- '|xns' : 'Roo.tree',
xtype : 'DefaultSelectionModel',
listeners : {
selectionchange : function (_self, node)
}).defer(100);
}
- }
+ },
+ xns : Roo.tree,
+ '|xns' : 'Roo.tree'
},
loader : {
+ xtype : 'TreeLoader',
baseParams : { _tree : 1 },
dataUrl : baseURL + '/Roo/cms_templatestr',
requestMethod : 'GET',
- xns : Roo.tree,
- '|xns' : 'Roo.tree',
- xtype : 'TreeLoader',
listeners : {
beforeload : function (This, node, callback)
{
{
Roo.MessageBox.alert("Error", "Problem loading tree");
}
- }
+ },
+ xns : Roo.tree,
+ '|xns' : 'Roo.tree'
}
}
},
{
+ xtype : 'GridPanel',
background : false,
fitContainer : true,
fitToframe : true,
region : 'center',
tableName : 'Page',
title : _this._strings['193cfc9be3b995831c6af2fea6650e60'] /* Page */,
- xns : Roo,
- '|xns' : 'Roo',
- xtype : 'GridPanel',
listeners : {
activate : function() {
_this.panel = this;
}
}
},
+ xns : Roo,
+ '|xns' : 'Roo',
grid : {
+ xtype : 'EditorGrid',
autoExpandColumn : 'txt',
clicksToEdit : 1,
loadMask : true,
- xns : Roo.grid,
- '|xns' : 'Roo.grid',
- xtype : 'EditorGrid',
listeners : {
afteredit : function (e)
{
});
}
},
+ xns : Roo.grid,
+ '|xns' : 'Roo.grid',
footer : {
+ xtype : 'PagingToolbar',
displayInfo : true,
displayMsg : _this._strings['e2f9d206562d8f5ea421ad51100f7151'] /* Displaying petition_entry{0} - {1} of {2} */,
emptyMsg : _this._strings['9d1ead73e678fa2f51a70a933b0bf017'] /* Not Found */,
pageSize : 100,
xns : Roo,
- '|xns' : 'Roo',
- xtype : 'PagingToolbar'
+ '|xns' : 'Roo'
},
toolbar : {
+ xtype : 'Toolbar',
xns : Roo,
'|xns' : 'Roo',
- xtype : 'Toolbar',
items : [
{
- emptyText : _this._strings['e3d388b2c43e5ba0905702620ae2abc1'] /* Search for */,
- xns : Roo.form,
- '|xns' : 'Roo.form',
xtype : 'TextField',
+ emptyText : _this._strings['e3d388b2c43e5ba0905702620ae2abc1'] /* Search for */,
listeners : {
render : function (_self)
{
{
_this.grid.footer.onClick('first');
}
- }
+ },
+ xns : Roo.form,
+ '|xns' : 'Roo.form'
},
{
+ xtype : 'Button',
cls : 'x-btn-icon',
icon : rootURL + '/Pman/templates/images/search.gif',
- xns : Roo.Toolbar,
- '|xns' : 'Roo.Toolbar',
- xtype : 'Button',
listeners : {
click : function (_self, e)
{
_this.grid.footer.onClick('first');
}
- }
+ },
+ xns : Roo.Toolbar,
+ '|xns' : 'Roo.Toolbar'
},
{
+ xtype : 'Button',
cls : 'x-btn-icon',
icon : rootURL + '/Pman/templates/images/edit-clear.gif',
- xns : Roo.Toolbar,
- '|xns' : 'Roo.Toolbar',
- xtype : 'Button',
listeners : {
click : function (_self, e)
{
_this.grid.footer.onClick('first');
}
- }
+ },
+ xns : Roo.Toolbar,
+ '|xns' : 'Roo.Toolbar'
}
]
},
dataSource : {
+ xtype : 'Store',
remoteSort : true,
sortInfo : { field : 'src_id_txt', direction: 'ASC' },
- xns : Roo.data,
- '|xns' : 'Roo.data',
- xtype : 'Store',
listeners : {
beforeload : function (_self, o)
{
}
o.params = o.params || {};
- o.params.lang = sn.parentNode.attributes.id ;
+
+ //var pn = sn.parentNode.attributes.id.split(':')[1]; // should be view:en:{module}
+
+
+ o.params.lang = sn.parentNode.attributes.id;
o.params.template_id = sn.attributes.id * 1;
o.params.active = 1;
o.params['!src_id'] = 0;
}
},
+ xns : Roo.data,
+ '|xns' : 'Roo.data',
proxy : {
+ xtype : 'HttpProxy',
method : 'GET',
url : baseURL + '/Roo/cms_templatestr.php',
xns : Roo.data,
- '|xns' : 'Roo.data',
- xtype : 'HttpProxy'
+ '|xns' : 'Roo.data'
},
reader : {
+ xtype : 'JsonReader',
fields : [
{
'name': 'id',
root : 'data',
totalProperty : 'total',
xns : Roo.data,
- '|xns' : 'Roo.data',
- xtype : 'JsonReader'
+ '|xns' : 'Roo.data'
}
},
cm : [
{
+ xtype : 'ColumnModel',
dataIndex : 'src_id_txt',
header : _this._strings['0a52da7a03a6de3beefe54f8c03ad80d'] /* Original */,
renderer : function(v,x,r)
},
width : 200,
xns : Roo.grid,
- '|xns' : 'Roo.grid',
- xtype : 'ColumnModel'
+ '|xns' : 'Roo.grid'
},
{
+ xtype : 'ColumnModel',
dataIndex : 'txt',
header : _this._strings['6dd08874f83507e9c7b23f1a46b7fa7c'] /* Translation */,
renderer : function(v,x,r)
width : 200,
xns : Roo.grid,
'|xns' : 'Roo.grid',
- xtype : 'ColumnModel',
editor : {
+ xtype : 'GridEditor',
xns : Roo.grid,
'|xns' : 'Roo.grid',
- xtype : 'GridEditor',
field : {
+ xtype : 'TextField',
allowBlank : false,
xns : Roo.form,
- '|xns' : 'Roo.form',
- xtype : 'TextField'
+ '|xns' : 'Roo.form'
}
}
},
{
+ xtype : 'ColumnModel',
dataIndex : 'src_id_mdsum',
header : _this._strings['1bc29b36f623ba82aaf6724fd3b16718'] /* md5 */,
hidden : true,
},
width : 250,
xns : Roo.grid,
- '|xns' : 'Roo.grid',
- xtype : 'ColumnModel'
+ '|xns' : 'Roo.grid'
}
]
}