- grid : {
- dataSource : {
- proxy : {
- '|xns' : 'Roo.data',
- method : 'GET',
- url : baseURL + '/Admin/Translations.php',
- xns : Roo.data,
- xtype : 'HttpProxy'
- },
- reader : {
- '|xns' : 'Roo.data',
- fields : [ 'id', 'tablename', 'tableid', 'colname', 'txt', 'lang', { name:'updated', type:'date', dateFormat: 'Y-m-d H:i:s' }, { name:'origupdated', type:'date', dateFormat: 'Y-m-d H:i:s' }, 'origtxt', 'msum', 'suggest' ],
- id : 'id',
- root : 'data',
- totalProperty : 'total',
- xns : Roo.data,
- xtype : 'JsonReader'
- },
- '|xns' : 'Roo.data',
- reader : Pman.Readers.Category,
- xns : Roo.data,
- xtype : 'Store',
- listeners : {
- beforeload : function (_self, opts)
- {
-
- if (!_this.langCombo || !_this.langCombo.getValue().length) {
- return false;
- }
- if (!_this.modCombo || !_this.modCombo.getValue().length) {
- return false;
- }
- opts.params = {
- lang : _this.langCombo.getValue(),
- module : _this.modCombo.getValue()
- };
- },
- loadexception : function (self, ret, load, jsonData)
- {
- Roo.MessageBox.alert("Error", jsonData);
- }
- },
- items : [
-
- ]
-
- },
- toolbar : {
- '|xns' : 'Roo',
- xns : Roo,
- xtype : 'Toolbar',
- items : [
- {
- store : {
- '|xns' : 'Roo.data',
- data : (function() {
- var modlist = [];
- AppModules = typeof(AppModules) == 'undefined' ? '' : AppModules;
- Roo.each( AppModules.split(','), function(mod) {
- modlist.push( [ mod ] );
- });
- return modlist;
- })(),
- fields : ['module'],
- xns : Roo.data,
- xtype : 'SimpleStore'
- },
- '|xns' : 'Roo.form',
- displayField : 'module',
- editable : false,
- emptyText : _this._strings['b51c3fa7e0ae26a1d88bf1279f265bb4'],
- mode : 'local',
- selectOnFocus : true,
- triggerAction : 'all',
- typeAhead : false,
- valueField : 'module',
- width : 200,
- xns : Roo.form,
- xtype : 'ComboBox',
- listeners : {
- render : function (_self)
- {
- _this.modCombo = _self;
- },
- select : function (combo, record, index)
- {
- _this.grid.getDataSource().reload();
- }
- },
- items : [
-
- ]
-
- },
- {
- store : {
- '|xns' : 'Roo.data',
- data : [ [ 'zh_HK' , '\u7E41\u4E2D - Trad. Chin. (HK)' ], [ 'zh_CN', '\u7C21\u4E2D - Simp. Chin.' ] ],
- fields : ['lang', 'ldisp'],
- xns : Roo.data,
- xtype : 'SimpleStore'
- },
- '|xns' : 'Roo.form',
- displayField : 'ldisp',
- editable : false,
- emptyText : _this._strings['83dad8107f9459efe2b4fabcf5b63108'],
- mode : 'local',
- selectOnFocus : true,
- triggerAction : 'all',
- typeAhead : false,
- valueField : 'lang',
- width : 200,
- xns : Roo.form,
- xtype : 'ComboBox',
- listeners : {
- render : function (_self)
- {
- _this.langCombo=_self;
- },
- select : function (combo, record, index)
- {
- _this.grid.getDataSource().reload();
- }
- },
- items : [
-
- ]
-
- },
- {
- '|xns' : 'Roo.Toolbar',
- xns : Roo.Toolbar,
- xtype : 'Fill'
- },
- {
- '|xns' : 'Roo.Toolbar',
- text : _this._strings['801ab24683a4a8c433c6eb40c48bcd9d'],
- xns : Roo.Toolbar,
- xtype : 'Button',
- listeners : {
- click : function (_self, e)
- {
- new Pman.Download({
- grid: _this.grid
-
- });