extjs

Putting javascript charts inside an extjs window

十年热恋 提交于 2019-12-11 07:24:15
问题 How would I put an external javascript chart, like one from flot or jqplot, inside an extjs window? I know that I could use the charts that extjs provides, but i want to put a flot or jqplot chart inside the window instead. 回答1: Just do as Chris said (why didn't you post it as an answer, dude?). Here's a complete example: Live on jsFiddle (be sure to check the "External Resource" tab; Flot code is from their basic example). Ext.onReady(function() { Ext.widget('window', { autoShow: true

Downside to extjs “iframe architecture” (should I refactor to MVC pattern?)

不羁岁月 提交于 2019-12-11 07:15:39
问题 I have an existing intranet webapp (solely internal) built with ExtJS using an "iframe architecture", i.e. it has a top menu and a tabpanel on an index page and about 30 other separate webpages that open as iframes "tabs" inside the main tabpanel. There is not any particular reason to use iframes, everything is on the same domain and most of these other seperate pages are written using the ExtJS library almost solely in javascript. The html on almost all of them consists of empty HTML, HEAD

JSONP not working on ExtJS 4 - Uncaught TypeError: Cannot call method 'substring' of undefined

做~自己de王妃 提交于 2019-12-11 07:13:59
问题 I'm stuck with this code, I'm getting this json formated data from the Youtube API, if I use type:'json' it will fail, because of that cross domain thing but the other elements loads anyway; then, if I change type: to 'jsonp' (which is the syntax described on the ExtJS API) it would give me this error:"Uncaught TypeError: Cannot call method 'substring' of undefined" I tried setting type:'anyotherstupidthing' and the same happens, so what could be happening? Here are my current data model and

extjs nested json store rails

一曲冷凌霜 提交于 2019-12-11 07:12:03
问题 i am working with Ext JS & Rails as backend..i am having myysql database that has parent-child relationship i.e. 1-to-many relationship...I want a "single" JSON store that can be used to load "GRID" data with parent & child records.. Also is there any way to bind both - the form as well as the grid to the same store but having different jsonreaders? i.e. form's datareader would read the string with root: 'customers' and grid will read the string with root :'products' ? The JSON looks like

Sencha Touch XML Reader Problem

ぃ、小莉子 提交于 2019-12-11 07:06:52
问题 I am student and cannot afford the premium support, so my question here: I have quite a simple XML and it gives me the following Error: http://img33.imageshack.us/i/screenprn.png/ Ext.regModel('User', { fields: ['id', 'name', 'email'] }); var store = new Ext.data.Store({ model: 'User', autoLoad:true, proxy: { type: 'ajax', url : 'ajax/user.xml', reader: { type : 'xml', model: 'User', record: 'user' } } }); 回答1: To begin with, your XML sould be like this : <?xml version="1.0" encoding="UTF-8"?

ExtJS grid Panel Paging toolbar not showing required number of records per page

泪湿孤枕 提交于 2019-12-11 06:58:58
问题 I am new to extJS and I am trying to show 8[a random number] records in a grid panel and am also using paging toolbar to show 4 records per page but it shows 8 records in one page only. var myData = [ ['3m Co', 71.72, 0.02, 0.03, '9/1 12:00am'], ['Alcoa Inc', 29.01, 0.42, 1.47, '9/1 12:00am'], ['American International Group, Inc.', 64.13, 0.31, 0.49, '9/1 12:00am'], ['AT&T Inc.', 31.61, -0.48, -1.54, '9/1 12:00am'], ['Boeing Co.', 75.43, 0.53, 0.71, '9/1 12:00am'], ['Caterpillar Inc.', 67.27,

Load usercontrol from client side

落花浮王杯 提交于 2019-12-11 06:46:34
问题 I am loading my user control like below.How I can achive that from client side. same code but client side request what I need private void LoadUserControlTab(string num, string title = "") { Ext.Net.Panel pn = new Ext.Net.Panel(); pn.Title = title; pn.ID = num; string pnid = num; pn.Closable = true; pn.Flex = 1; pn.Height = 500; currentUC = (UserControl)this.LoadControl(string.Format("Controls/UserControl{0}.ascx", num)); currentUC.ID = "UC" + num; pn.ContentControls.Add(currentUC); pn.AddTo

Add a chart to <div id=“whatever”>

不打扰是莪最后的温柔 提交于 2019-12-11 06:34:14
问题 After an RPC I want to get a specific non-gwt-generated div via DOM to place a chart there. final VerticalPanel contentHome = new VerticalPanel(); // ... public void onSuccess(String result) { if(result == null) { contentHome.add(new HTML("Could not load content from server.")); return; } contentHome.getElement().setId("inner"); contentHome.add(new HTML(result)); Element el = DOM.getElementById("whatever"); LineChart lc = new LineChart(); el.appendChild(lc.asWidget().getElement()); // <--

Special characters in Extjs4?

China☆狼群 提交于 2019-12-11 06:23:23
问题 How to get special characters like ČĆŠĐŽ working in Extjs4. I have tried adding meta utf-8..., also tried with !DOCTYPE html5, and XHTML 1.0 Transitional. Prefered index.html on sencha web page is : <html> <head> <meta http-equiv="Content-Type" content="text/html; charset=utf-8" /> <title id='title'>HTML Page setup Tutorial</title> <link rel="stylesheet" type="text/css" href="../../resources/css/ext-all.css" /> <script type="text/javascript" src="../../adapter/ext/ext-base.js"></script>

Pagination with remote data for the Combobox

回眸只為那壹抹淺笑 提交于 2019-12-11 06:08:45
问题 I'm trying to load a combobox with remote data from a SQL database, Here is the Combobox Code, { xtype: 'fieldset', title: 'Busname', items: [ { xtype: 'myCombobox', name: 'busname', forceNewStore: true, pageSize:10, queryMode: 'local', displayField: "description", valueField: "description", mapperId: 'busnamefetch', maskRe: /[A-Za-z0-9]/, forceSelection: true, emptyText: 'Select Bus', margin: '15px', triggers: { clear: { cls: 'x-form-clear-trigger', handler: function () { this.reset(); } } }