1 //<script type="text/javascript">
3 // Auto generated file - created by app.Builder.js- do not edit directly (at present!)
5 Roo.namespace('Pman.Tab');
7 Pman.Tab.BAdminIPAccess = new Roo.XComponent({
10 'ce8ae9da5b7cd6c3df2929543a9af92d' :"Email",
11 '86f16ddf147752b95ffe69e2dfa769a1' :"Authorized By",
12 'ec53a8c4f07baed5d8825072c89799be' :"Status",
13 '7dce122004969d56ae2e0245cb754d35' :"Edit",
14 'fc6f97505d89fe9277965c126744647a' :"No Companies found",
15 '11e8622b4aa4b1924aee81a9ec54c555' :"Create Date",
16 'a12a3079e14ced46e69ba52b8a90b21a' :"IP",
17 'cfcd208495d565ef66e7dff9f98764da' :"0",
18 '155ca6a755e25c15ad7ce45e2f638f10' :"Displaying Companies{0} - {1} of {2}",
19 '5a787141d53b573ec9b86e900bfe0d79' :"Expire Date",
20 'f2a6c498fb90ee345d997f888fce3b18' :"Delete",
21 'e3030abfa75de4573fb37032affa11e7' :"IP Access"
24 part : ["BAdmin", "IPAccess" ],
25 order : '006-Pman.Tab.BAdminIPAccess',
27 parent : 'Pman.Tab.BAdmin',
28 name : "unnamed module",
31 _tree : function(_data)
38 title : _this._strings['e3030abfa75de4573fb37032affa11e7'] /* IP Access */,
39 xns : Roo.bootstrap.panel,
40 '|xns' : 'Roo.bootstrap.panel',
43 xns : Roo.bootstrap.layout,
44 '|xns' : 'Roo.bootstrap.layout',
49 xns : Roo.bootstrap.layout,
50 '|xns' : 'Roo.bootstrap.layout'
58 title : _this._strings['e3030abfa75de4573fb37032affa11e7'] /* IP Access */,
60 activate : function (_self)
62 _this.edit_btn.hide();
63 _this.delete_btn.hide();
66 _this.table.footer.onClick('first');
69 render : function (_self)
74 xns : Roo.bootstrap.panel,
75 '|xns' : 'Roo.bootstrap.panel',
77 xtype : 'NavSimplebar',
79 '|xns' : 'Roo.bootstrap',
84 '|xns' : 'Roo.bootstrap',
89 '|xns' : 'Roo.bootstrap',
94 '|xns' : 'Roo.bootstrap',
100 '|xns' : 'Roo.bootstrap',
106 '|xns' : 'Roo.bootstrap',
110 displayField : 'value',
112 hiddenName : 'status',
114 name : 'status_name',
115 tpl : '<div class=\"roo-select2-result\"><b>{value}</b></div>',
116 triggerAction : 'all',
120 render : function (_self)
124 select : function (combo, record, index)
126 _this.table.footer.onClick('first');
130 '|xns' : 'Roo.bootstrap',
132 xtype : 'SimpleStore',
139 fields : [ 'code', 'value' ],
150 '|xns' : 'Roo.bootstrap',
154 cls : 'roo-toolbar-button',
156 html : _this._strings['7dce122004969d56ae2e0245cb754d35'] /* Edit */,
159 click : function (_self, e)
161 var sel = _this.table.getSelectionModel().getSelected();
163 if(!sel || sel.data.id * 1 < 1){
164 Roo.bootstrap.MessageBox.alert('Error', 'Please select a row');
168 Pman.Dialog.BAdminIPAccess.show({
171 _this.table.store.load({});
175 render : function (_self)
177 _this.edit_btn = this;
183 '|xns' : 'Roo.bootstrap'
187 cls : 'roo-toolbar-button',
189 html : _this._strings['f2a6c498fb90ee345d997f888fce3b18'] /* Delete */,
192 click : function (_self, e)
194 Pman.genericDelete(_this.grid, 'core_ip_access');
197 render : function (_self)
199 _this.delete_btn = this;
205 '|xns' : 'Roo.bootstrap'
228 render : function (_self)
232 rowdblclick : function (_self, el, rowIndex, e)
234 var s = _this.table.store.getAt(rowIndex);
236 if(!s || s.data.id * 1 < 1){
240 Pman.Dialog.BAdminIPAccess.show({
243 _this.table.footer.onClick('first');
248 '|xns' : 'Roo.bootstrap',
250 xtype : 'PagingToolbar',
252 displayMsg : _this._strings['155ca6a755e25c15ad7ce45e2f638f10'] /* Displaying Companies{0} - {1} of {2} */,
253 emptyMsg : _this._strings['fc6f97505d89fe9277965c126744647a'] /* No Companies found */,
257 '|xns' : 'Roo.bootstrap'
262 sortinfo : { field : 'display_name', direction: 'ASC' },
264 beforeload : function (_self, o)
266 o.params = o.params || {};
268 var status = _this.status.getValue() * 1;
270 o.params.status = status;
273 load : function (_self, records, options)
275 _this.edit_btn.hide();
276 _this.delete_btn.hide();
284 url : baseURL + '/Roo/Core_ip_access.php',
289 xtype : 'JsonReader',
296 'name': 'created_dt',
298 'formatDate' : 'Y-m-d'
305 'name': 'authorized_by',
309 'name': 'authorized_by_name',
313 'name': 'authorized_by_email',
317 'name': 'authorized_key',
327 'formatDate' : 'Y-m-d'
330 'name': 'user_agent',
334 'name': 'updated_by',
338 'name': 'updated_by_name',
342 'name': 'updated_by_email',
349 totalProperty : 'total',
355 xtype : 'RowSelectionModel',
358 selectionchange : function (_self)
360 _this.edit_btn.hide();
361 _this.delete_btn.hide();
363 if (!this.getSelected()) {
367 _this.edit_btn.show();
368 _this.delete_btn.show();
372 xns : Roo.bootstrap.Table,
373 '|xns' : 'Roo.bootstrap.Table'
377 xtype : 'ColumnModel',
379 dataIndex : 'created_dt',
380 header : _this._strings['11e8622b4aa4b1924aee81a9ec54c555'] /* Create Date */,
381 renderer : function(v,x,r) {
382 return String.format('{0}', v ? v.format('Y-m-d') : '');
390 xtype : 'ColumnModel',
393 header : _this._strings['a12a3079e14ced46e69ba52b8a90b21a'] /* IP */,
394 renderer : function(v,x,r) {
395 return String.format('{0}', v ? v : '');
403 xtype : 'ColumnModel',
406 header : _this._strings['ce8ae9da5b7cd6c3df2929543a9af92d'] /* Email */,
407 renderer : function(v,x,r)
409 return String.format('<a href="mailto:{0}">{0}</a>', v ? v : '')
417 xtype : 'ColumnModel',
419 dataIndex : 'authorized_by',
420 header : _this._strings['86f16ddf147752b95ffe69e2dfa769a1'] /* Authorized By */,
421 renderer : function(v,x,r)
427 return String.format('{0}', r.data.authorized_by_name);
435 xtype : 'ColumnModel',
437 dataIndex : 'status',
438 header : _this._strings['ec53a8c4f07baed5d8825072c89799be'] /* Status */,
439 renderer : function(v,x,r)
443 var status = 'Pending';
453 status = 'Temporary';
459 return String.format('{0}', status);
468 xtype : 'ColumnModel',
470 dataIndex : 'expire_dt',
471 header : _this._strings['5a787141d53b573ec9b86e900bfe0d79'] /* Expire Date */,
472 renderer : function(v,x,r) {
474 if(r.data.status * 1 != -2){
478 return String.format('{0}', v ? v.format('Y-m-d') : '');