1 //<script type="text/javascript">
3 // Auto generated file - created by app.Builder.js- do not edit directly (at present!)
5 Pman.Tab.CoreOAuthClient = new Roo.XComponent({
6 part : ["Core","OAuthClient"],
7 order : '900-Pman.Tab.CoreOAuthClient',
9 parent : 'Pman.Tab.Admin',
10 name : "unnamed module",
18 xtype: 'NestedLayoutPanel',
21 title : "Oauth2 Clients",
23 xtype: 'BorderLayout',
30 activate : function() {
34 _this.grid.footer.onClick('first');
42 tableName : 'core_oauth_clients',
43 title : "Oauth2 Clients",
51 if (_this.panel.active) {
52 this.footer.onClick('first');
55 afteredit : function (e)
57 if(e.originalValue == e.value || !e.value.length){
65 autoExpandColumn : 'redirect_uri',
72 beforeload : function (_self, o){
73 o.params = o.params || {};
76 update : function (_self, record, operation)
78 if (operation != Roo.data.Record.COMMIT) {
82 if (!record.data.client_id.length || !record.data.client_secret.length) {
87 url : baseURL + '/Core/Core_oauth_clients.php',
90 success : function(res) {
91 _this.gird.footer.onClick('refresh');
98 sortInfo : { field : 'client_id', direction: 'ASC' },
103 url : baseURL + '/Roo/Core_oauth_clients'
110 totalProperty : 'total',
117 'name': 'client_secret',
121 'name': 'redirect_uri',
138 var nr = _this.grid.ds.reader.newRow({
144 _this.grid.stopEditing();
145 _this.grid.ds.insert(_this.grid.ds.getCount(), nr);
146 _this.grid.startEditing(_this.grid.ds.getCount()-1, 1);
149 cls : 'x-btn-text-icon',
151 icon : Roo.rootURL + 'images/default/dd/drop-add.gif'
159 var cs = _this.grid.getSelectionModel().getSelectedCell();
161 Roo.MessageBox.alert("Error", "Select a cell");
164 _this.grid.stopEditing();
166 var r = _this.grid.ds.getAt(cs[0]);
168 _this.grid.ds.remove(r);
172 cls : 'x-btn-text-icon',
174 icon : rootURL + '/Pman/templates/images/trash.gif'
179 xtype: 'PagingToolbar',
182 emptyMsg : "No Clients found",
187 xtype: 'ColumnModel',
189 dataIndex : 'client_id',
190 header : 'Client ID',
192 renderer : function(v) {
193 return String.format('{0}', v ? v : '');
206 xtype: 'ColumnModel',
208 dataIndex : 'client_secret',
209 header : 'Client Secret',
211 renderer : function(v) {
212 return String.format('{0}', v ? v : '');
225 xtype: 'ColumnModel',
227 dataIndex : 'redirect_uri',
228 header : 'Redirect URI',
230 renderer : function(v) {
231 return String.format('{0}', v ? v : '');
247 xtype: 'LayoutRegion',