extjs

Saving edited record in a cell editing grid

人走茶凉 提交于 2019-12-12 01:29:14
问题 How can I save the edited record on click of the save button? my code : // create the Data Store var store = Ext.create('Ext.data.Store', { //autoSync: true, autoLoad:true, autoDestroy: true, url: 'update_premise.php', model: 'Plant', proxy: { type: 'ajax', // load remote data using HTTP url: 'getLab.php', // specify a XmlReader (coincides with the XML format of the returned data) reader: { type: 'json' }, writer: { type: 'json' } }, sorters: [{ property: 'lab_name', direction:'ASC' }] });

Assigning Base 64 converted image from JSON

微笑、不失礼 提交于 2019-12-12 01:28:32
问题 Here the code which i have used to show the details from JSON , All detailsshowing properly except image.When i try to show the image its not showing in the image. JSON METHOD Ext.Ajax.request({ url: App.gvars.apiurl + 'ShowItemsByItemID/userID='+App.gvars.userid+'/itemID='+itemID, // url : this.getUrl(), method: "GET", useDefaultXhrHeader: false, withCredentials: true, success: function (response) { var respObj = Ext.JSON.decode(response.responseText); Ext.getCmp('myitemname').setValue

Sencha build error when viewed in browser

强颜欢笑 提交于 2019-12-12 01:28:10
问题 I have finally managed to create a production build of my sencha web app using Cmd 3.10.2.342 and touch 2.2.1 All my bespoke files are included and deltas are created as one would expect. However, when I run it in the browser, it stalls at the loading view. Console log says: TypeError: 'undefined' is not a function (evaluating 'h.call(w,w)') I have traced the error to Ext.application({... in app.js. I have tried the following changes, but still get errors: new Ext.application({... Ext

Firing events on a popup window (ExtJS)

前提是你 提交于 2019-12-12 01:18:42
问题 we're currently developing an application that makes extensive use of popup windows(*) and have run into an issue on IE (this has been reported before but I couldn't find any solution). The problem is this: our main window M opens a popup window P and keeps a reference to it. P then registers an event handler on an object in M . When the event fires, IE8 bombs out with the following error message: JScript object expected ext-all-debug.js (Line 1735, Char 17) Code: 0 which is the fire-function

Extjs Combobox set color to specific item

血红的双手。 提交于 2019-12-12 01:17:45
问题 Is there a way to set color of last item (or last two items) of combobox items, i tried to use TPL but didn't work. Here is the TPL defination with XTeplate which was defined before i updated. Thanks a lot. var resultTplHesap103Ekod = new Ext.XTemplate( '<tpl for="."><div class="x-combo-list-item">', '<h3><span> {val} </h3>', '<span style="color:blue"> {dsc} </span>', '</div></tpl>' ); From @MMT, I changed codes like this. var resultTplHesap360Ekod = new Ext.XTemplate( '<tpl for=".">', '<tpl

In ExtJS, Can I pass argument via vtype?

这一生的挚爱 提交于 2019-12-12 01:12:44
问题 I can't find the way to pass argument via vtype. So I do some onfly vtype function. var vtypeMaker = function(n){ Ext.apply(Ext.form.VTypes, { myTest : function(v, o){ console.debug(n); // <-- I can pass my custom value // do something // ... return myRegex.test(v); }, myTestText : 'some message' }); } And when I want to set vtype, I should call this function first. vtypeMaker(10); myTextfield.vtype = 'myTest'; It works but too long code. Anyone has better idea ? Thanks. 回答1: Use the

posting form to iframe with extjs without rendering to bidy

≯℡__Kan透↙ 提交于 2019-12-12 01:07:49
问题 I am trying to post a form to an iframe. my issue is that my form gets posted just fine when I render the iframe to body. But the issue with this is that the container displays at the bottom of the page instead of the place where I want it to show. If I don't use the renderTo property, my form never gets posted to iframe at all. It almost seems like that in the case when I do not use renderTo property, i think my form does not even see the iframe. here is my code thats working for the form

ExtJS 4.2.2 ComboBox fields show up behind Window

懵懂的女人 提交于 2019-12-12 01:05:14
问题 I'm having an issue where I pop up a window with a loaded comboBox, and when I click on it, the fields show up behind the window. Thinking I may be using some setting wrong, I created a small test based off the documentation of the ComboBox, and it does it here for me as well. (If you try it, may need to drag the bottom of the window up to see the options) showTestWindow = function() { var states = Ext.create('Ext.data.Store', { fields: ['abbr', 'name'], data : [ {"abbr":"AL", "name":"Alabama

How to override GroupTabPanel width in extjs 4

ぃ、小莉子 提交于 2019-12-12 01:04:25
问题 I want to override Ext.ux.GroupTabPanel width in extjs 4. Any Idea please? 回答1: The tab bar width is indeed hardcoded to 150, so you're right you must override or extend the class. The following override adds an option to GroupTabPanel to do what you want, without changing the default behaviour: /** * This override adds the {@link #tabBarWidth} config option. */ // The name of the class is only used by the loader to find the file Ext.define('MyApp.Ext.ux.GroupTabPanelWidthOption', { override:

How to use HTML tags in a Chart Legend?

寵の児 提交于 2019-12-12 01:04:02
问题 How can use HTML tags in a chart legend while using title to apply custom legend text? If we apply something like this title:['Your<b>New</b><br />Label'] the tags are just written as plain text. Ext.application({ name: 'Fiddle', launch: function () { var store = Ext.create('Ext.data.JsonStore', { fields: ['name', 'data', 'data2'], data: [{ 'name': 'metric one', 'data': 10, 'data2': 2 }, { 'name': 'metric two', 'data': 27, 'data2': 5 }] }); Ext.create('Ext.chart.Chart', { renderTo: Ext