extjs4.2

extjs 4 how to wrap children components of container in custom html?

北慕城南 提交于 2019-12-13 04:33:10
问题 I need to create Twitter Bootstrap basic NavBar component in my ExtJS 4.2 application. All I want to make my component generate the following html: <div class="navbar navbar-inverse navbar-fixed-top"> <div class="navbar-inner"> <ul class="nav"> <li class="active"><a href="#"><i class="icon1"></i> Item #1</a></li> <li><a href="#"><i class="icon2"></i> Item #3</a></li> <li><a href="#"><i class="icon3"></i> Item #3</a></li> </ul> </div> </div> I've created two views (NavBar and NavBarItem

how to override Extjs Timefield to show custom max value

本小妞迷上赌 提交于 2019-12-12 17:28:17
问题 I want to display 11:59 as the maxValue for ExtJs timefield with increment=30. I set maxValue as "23:59" but it did not work, and shows 23:30 as the maximum value. Can anyone specify which function/code to override to display 11:59 as the maximum value? Thanks in advance. 回答1: Try overriding 'createStore' function of 'Ext.picker.Time' to include 23:59 in the list, so that if the maxValue is set to 23:59 it will get displayed. 来源: https://stackoverflow.com/questions/25379403/how-to-override

How to scroll to a specified record in a grid

梦想与她 提交于 2019-12-12 16:24:44
问题 How can we scroll to a defined record (record or index) in a grid? Using a buffered renderer this is quite easy by calling: grid.view.bufferedRenderer.scrollTo(0, false, callback, scope); but how can this be done with a default renderer? 回答1: Try grid.getView().scrollRowIntoView(rowIndex) 来源: https://stackoverflow.com/questions/23421508/how-to-scroll-to-a-specified-record-in-a-grid

Downloading multiple files into a Zip file Javascript using data URI

拥有回忆 提交于 2019-12-12 11:34:42
问题 I am using EXT JS 4.2 which has a panel which contains a export to CSV button. On clicking on it multiple (total six) files are downloaded. I want these files to be downloaded in a single ZIP file. 回答1: There is a perfect plugin to create zip files inside browser. JSZip: https://stuk.github.io/jszip/ Install the plugin by adding js files manually: download JSZip and include the file dist/jszip.js or dist/jszip.min.js JSFiddle - JSZip 3.0: https://jsfiddle.net/andrebonna/u8zsbzau/ var zip =

extjs - Store with autoload true should not load on application launch

我与影子孤独终老i 提交于 2019-12-12 07:56:43
问题 I have a grid linked to a store with autoLoad: true . The problem is that the store gets loaded on application launch, even if the view is created only later when accessed through a menu. I have referenced the store in Application.js and in the view, but I'm not instatiating explicitly neither the store nor the view. I don't know how to achieve that the store is loaded only when needed by the view. If I set autoLoad: true , the store gets loaded on application launch. If I set autoLoad: false

ExtJS Grid SelectionChange is fired in other controller

最后都变了- 提交于 2019-12-12 06:26:33
问题 I have a main application with a left navigation menu. My Main.js controller handles the treepanelselect event where a Tab is added: onTreepanelSelect: function (selModel, record, index, options) { var mainPanel = Ext.ComponentQuery.query('mainpanel')[0]; var newTab = mainPanel.items.findBy( function (tab) { return tab.title === record.raw.text; }); if (!newTab) { newTab = mainPanel.add({ xtype: record.raw.class_name, // this is my View widget name closable: true, iconCls: "key", title:

Sencha CMD - Build Error: Mixed-Mode x-compile and microload markup is currently unsupported

无人久伴 提交于 2019-12-12 04:54:45
问题 Good day, I am trying to build my ExtJS 4.2 application and I am using Sencha Architect 3.1 and Sencha CMD 5.1.1.39 for the OSX. I was following this tutorial on how to build from the Terminal, and as expected, I got this error: com.sencha.exceptions.ExBuild: Mixed-Mode x-compile and microload markup is currently unsupported Upon googling, I came upon this thread from Sencha discussing how to get around this error. What I did next was to remove lines from my app.json file which originally

Ext JS: Saving DOM manipulation of a grid row

浪尽此生 提交于 2019-12-12 04:37:44
问题 I'm having a little difficulty with Ext JS's ActionColumn, but that's really a separate issue. What I'm trying to do right now is save off whatever DOM manipulation I do with Ext JS, so that when I refresh my grid, the changes stay. var grid = Ext.create('Ext.grid.Panel', { columns: [{ xtype: 'actioncolumn', width: 50, items: [{ icon: 'http://cdn.sencha.com/ext/gpl/4.2.1/examples/personel-review/images/edit.png', tooltip: 'Edit', iconCls: 'hideable', handler: function(grid, rowIndex, colIndex

To destroy card when inactive and instantiate when active in ExtJs

こ雲淡風輕ζ 提交于 2019-12-12 04:28:02
问题 Goal : To improve performance of the app and reduce the loading time.When card is active I am instantiating it and its DOM is created, as deferredRender:true .Now I want to destroy the card as it gets inactive so as to reduce DOM.But I am somewhat facing some issue during removal and again instantiation of the card. Here is the simple fiddle , i have created based on my layout structure i am following: Card Layout Fiddle I went through this link,but failed to understand the implemetation.

How to modify fields before rendering it to the grid in Extjs

隐身守侯 提交于 2019-12-12 04:07:26
问题 I have to append a value to the data fetched from the store before rendering it to the grid in ExtJs. Please guide me on achieving the above mentioned functionality. Currently the grid is populated in the following manner: Ext.define("MyApp.view.ShowDetails",{ extend: 'Ext.grid.Panel', requires:['MyApp.store.MyStore'], store:'MyStore', stateId: 'stateGrid', selType : 'checkboxmodel', selModel : { mode : 'MULTI' }, plugins : [Ext.create('Ext.grid.plugin.RowEditing', { clicksToEdit : 2 })],