extjs3

ExtJS 3.x: How to disable the red mark indicating a dirty record in ExtJS EditorGridPanel

前提是你 提交于 2019-12-11 03:17:21
问题 EditorGridPanel shows a small red triangular corner on the column that is edited to indicate an unsaved record. Since I am using autoSave, I don't need to indicate the record as dirty/unsaved. Is there an easy way to disable this ? 回答1: See this : http://www.sencha.com/learn/Ext_FAQ_Grid#Dirty_Record_.2F_Red_Flag_.28modifying.2C_etc..29 回答2: view: Ext.grid.GridView({markDirty: false}) or viewConfig: { markDirty: false } 回答3: .x-grid3-dirty-cell { background-image: none; } 来源: https:/

extjs button scope

大憨熊 提交于 2019-12-11 02:28:50
问题 I am trying to understand scope in the below scenario. When calling searchTerms , this under the scope:this refers to the searchTerms function rather than the panel itself. It seems to be different from what I observe from other examples. May I know what mistakes did i make? function searchTerms(){ var searchGrid = new Ext.grid.GridPanel({ }); var searchPanel = new Ext.form.FormPanel({ region: 'south', height:150, items:[ { xtype: 'textfield', fieldLabel: 'Keywords', },{ xtype: 'textfield',

extjs: how to use ajax call in column renderer?

喜欢而已 提交于 2019-12-10 23:51:37
问题 What i've got now is this: renderer : function(value) { var ret; var conn = new Ext.data.Connection(); conn.request({ method : 'POST', url : rsdBackend, params : { get_object_by_id : 'true', rsd_type : record.data.references_table, object_id : value, uid : logged_user_id }, success : function(responseObject) { var data = Ext.decode(responseObject.responseText); ret = data[0].object_name; } }); return ret; } If a column contains a link to another data (foreign key in database terms) i need to

ExtJS AJAX save as dialog box

前提是你 提交于 2019-12-10 23:09:54
问题 I make an ExtJS AJAX request and I want the standard browser 'save as' dialog box to be displayed to the user. The file to download can be a pdf, jpg or png file. At the moment the AJAX request is successfully submitted but as it's asynchronous no dialog box comes up. I could simply not use AJAX but there is a lot of javascript code that I need to use prior to making the request and I don't really feel rewriting it to java. My code looks like this: var params = getPrintInfo(form); Ext.Ajax

Extjs Restful Store, Sending request in Batch?

邮差的信 提交于 2019-12-10 20:06:57
问题 I created a Grid component with the store configuration like this: //Create the store config.store = new Ext.data.Store({ restful: true, autoSave: false, batch: true, writer: new Ext.data.JsonWriter({ encode: false }), reader: new Ext.data.JsonReader({ totalProperty: 'total', root: 'data', fields: cfg.fields }), proxy: new Ext.data.HttpProxy({ url:cfg.rest, listeners:{ exception: { fn: function(proxy, type, action, options, response, arg) { this.fireEvent('exception', proxy, type, action,

Checkbox for group header of extjs grouping grid

左心房为你撑大大i 提交于 2019-12-10 15:23:42
问题 I am having a ExtJs EditorGridPanel configured with a GroupingStore , GroupingView and a CheckboxSelectionModel . The Checkbox appears in the grid's header and in all the rows. I want to bring the checkbox on the group header also. My intention is to let the user select all records under a group by selecting the group header's checkbox. Is there a way to do this? I'm using ExtJs 3.1.1 and RowActions plugin from saki. 回答1: I found a way to acheive this using groupTextTpl config option in

After loading store, select and show specific row in grid works in Chrome, not in IE

强颜欢笑 提交于 2019-12-10 11:40:48
问题 I suppose I must be doing something wrong here. I have a GridPanel which gets its data from a Store. The store has a listener on the load event, which selects row 8 of the grid's selection model and tries to bring it into focus. In Chrome (currently version 33) this works and the specified record is visible. In IE (version 11) this does not work. At the time of the alert('pause'); statement, the grid is visible with the specified row visible. But after clicking away the alert message, the

Error: 'this.proxy' is null or not an object in EXTJS

戏子无情 提交于 2019-12-10 11:37:07
问题 When i ran this EXTJS code,i got an error 'this.proxy' is null or not an object . Can you help me out regarding this,plzz ? var myData = [ ['J', 'MD'], ['A', 'VA'], ['S', 'DC'], ['M', 'DE'], ['B', 'NJ'], ['N', 'CA'], ['S', 'RT'], ['S', 'CG'] ]; var store = new Ext.data.ArrayStore({ totalProperty : 8, autoLoad : { params : { start : 0, limit : 4 } }, fields : [ { name : 'fullName' }, { name : 'state' } ] }); store.loadData(myData); var grid = new Ext.grid.GridPanel({ store : store, columns : [

Extjs panel. Keyboard events

我怕爱的太早我们不能终老 提交于 2019-12-08 07:33:58
问题 I have a panel which I am rendering using following code. new Ext.Panel({ id: 'textPanel', height: 1000, width: 1200, renderTo: Ext.getBody(), html:"An HTML fragment, or a DomHelper specification to use as the layout element content. The HTML content is added after the component is rendered, so the document will not contain this HTML at the time the render event is fired. This content is inserted into the body before any configured contentEl is appended." }); And then I want to listen to

How to remove item from Panel

独自空忆成欢 提交于 2019-12-08 06:36:03
问题 I have container, which have box , textfield and button . I am adding that container in one panel. When I am clicking on button I want to remove that container. Problem is, Container is removed but it not showing on UI. My Code where I am removing container from panel. var panel = Ext.getCmp("ABC"); var record = panel.items.items; var recordlength = record.length; for (var j = 0; j < recordlength - 1; j++) { if (record[j].Label == me.Label) { record.remove(me); panel.remove(); } } 回答1: As you