extjs4.2

ExtJS 4.2.1 - add textfield to an XTemplate

回眸只為那壹抹淺笑 提交于 2019-12-05 21:49:16
I got a custom component in which i set the html with an xtemplate something like this Ext.apply(me, { html: mainTpl.apply() }); I want to add some textfields to my XTemplate too and i cant figure out how to do this. new Ext.XTemplate('<div Class="TopHeaderUserInfo"><div id="TopHeaderLanguageDiv" ><div Class="ActiveLanguageFlag" lang="{[ this.getLanguage() ]}" ></div>' + '<ul Class="LangSelectDropDown HeaderDropDown" style="position:absolute;"><li class="ListHeader">' + MR.locale.SelectLanguage + '</li>{[ this.renderLanguageItems() ]}</ul>' + '</div>{[this.renderUserInfo()]}</div>', { ... ...

ext-all-debug.js vs ext-all-dev.js

百般思念 提交于 2019-12-05 11:26:00
What is the main difference between ext-all-debug.js and ext-all-dev.js? "ext-all-debug.js" is mainly used for development & debugging. Using "ext-all-dev.js" will have any advantage? Please clarify. matt ext-all.js: minified, no docs/comments ext-all-debug.js: non-minified, no docs/comments ext-all-debug-w-comments.js: non-minified, with docs/comments ext-all-dev.js: non-minified, with docs/comments, with console warnings, e.g. if you're using deprecated functions/configs or there are configuration problems. The additional console output in ext-all-dev.js can be really helpful, so I'd

Extjs grid column header, add dropdown menu item to specific columns

拟墨画扇 提交于 2019-12-05 10:02:56
I'm trying to add a button to the column header drop-down menus in my grid. However, I only want to add it to columns with certain itemId. So far I've got it working to add the button to all columns, see code below. I dont see where I could check each column's itemId though, it doesn't seem to iterate through the columns. Is there any workaround for this? Thank you! items:[{ region:'center', xtype:'grid', columns:{ items: COLUMNS, //defined in index.php }, store:'Items', selType: 'checkboxmodel', listeners: { afterrender: function() { var menu = Ext.ComponentQuery.query('grid')[0].headerCt

How to export extjs grid data to excel?

a 夏天 提交于 2019-12-05 04:47:24
I have a grid with large number of records. I use filters to filter the data as required. But i want to export the filtered data to a excel sheet for further usage. I went through some articles available but they seem different and not compatible with latest 4.2 version. Please help me in achieving this in simple manner. Thanks much! For extjs < 4 http://edspencer.net/2009/11/24/ext-ux-exporter-export-any-grid-to-excel-or-csv/ For extjs >= 4 http://www.sencha.com/forum/showthread.php?136598-Export-store-to-Excel As far as I know this isn't possible without a Serverside implementation in a

how to get array of objects from store in extjs 4.2 and send it to server side?

↘锁芯ラ 提交于 2019-12-05 03:43:01
问题 Hiii all, I am using Extjs 4.2 data grid and i have a requirement to convert my 'store' into json array and send that to server side(i.e java). This is my model. Ext.define('Writer.Document',{ extend: 'Ext.data.Model', fields: ['id', 'name', 'notes', 'Type', 'date'] }); and my store (which contains list of objects) is var store = Ext.create('Ext.data.Store', { model: 'Writer.Document', autoLoad: true, proxy: { type: 'ajax', url : 'findPatientRecordAction', reader: { type: 'json',

Grid grouping and sorting in ExtJS 4.2.1

半世苍凉 提交于 2019-12-04 18:33:45
I try to implement grid with grouping similar to this example: http://dev.sencha.com/deploy/ext-4.0.0/examples/grid/groupgrid.html Here data is grouped by column "Cuisine" and sorting by this column sort groups accordingly. When I paste code of this example into a project, which uses 4.2.1, or in code editor at ExtJS 4.2.1 docs site, the view is exactly the same, sorting works for column "Name", but it doesn't work by column "Cuisine". Did they remove sorting by grouping column in 4.2.1? If not, how to make it work? The same example is present in 4.2.1 SDK, and indeed sorting by the grouped

How to add filters in grid column headers in extjs?

纵饮孤独 提交于 2019-12-04 15:41:41
I have a grid with lots of records in it. so I want to add filters in each column header to filter the required data easily. I have seen the example given in the sencha docs. But How to implement it in the Extjs 4.2 version. How to use UX classes in it? Is there any plugin available? I am greatly thankful to you. Please help me. Anand This is an example: Ext.define('Webdesktop.view.admin.List', { extend: 'Ext.grid.Panel', alias: 'widget.admin_casoslist', initComponent: function() { var me = this, filters = { ftype: 'filters', encode: false, local: true }; Ext.apply(me, { title: 'gridTitle',

extjs - How to disable pagination on a store

て烟熏妆下的殇ゞ 提交于 2019-12-04 12:01:53
问题 Whenever a store ( Ext.data.Store ) reads data from the server, it sends paging parameters like &page=1&start=0&limit=25 in a json proxy or [page:1, start:0, limit:25] using a direct proxy. I'd like to disable paging in the store or proxy configuration. I found this workaround, but I'm sure there must be a better method. proxy: { pageParam: undefined, startParam: undefined, limitParam: undefined, ... } Does anyone know how to disable paging properly ? 回答1: store: { pageSize: 0, limit:0, ....

Is there a way to minify an ExtJS application without Sencha CMD?

走远了吗. 提交于 2019-12-04 11:56:54
I have an existing ExtJS app developed using ExtJS 4.2.1. I am using Closure minifier through Maven plugin minify-maven-plugin. The generated minified JS files (without merge) works fine. However, generated merged minified file throws undefined errors because the definition comes later in the merged file. My question is, is there a way I can figure out the order I have to provide the plugin? (I don't want to use Sencha Cmd) The app folder follows the structure app/common, app/controller, app/model, app/proxy, app/store, app/utils, app/view At the moment this is how I have defined the build

File upload in extjs 4.2 without form.submit()

余生长醉 提交于 2019-12-04 05:33:36
I'm trying to upload a file (as of now of any extension) in extjs. I have a model and store. the file upload happens from a window and I dont have a form in the window. All example I tried in the net are with form.submit(). I instead use and Ajax call as below to send the data to the server. Ext.Ajax.request({ url : 'qaf/saveSetupDetails.action', params : { 'data' : recordsToSend }, failure : function(response){ //console.log('error connecting controller'); }, success : function(response){ //console.log('successfully submitted'); } }); The records to send in the data is got as below. var store