extjs4

Sencha CMD: 404 errors when running built production version

有些话、适合烂在心里 提交于 2019-12-06 14:40:47
问题 I have converted my existing ExtJS 4.1.3 application to use the Sencha CMD recommended structure and tools. I created the structure first, then put my existing app JS files at the place where the single-page JS app should be located. I currently access the development version of my application at: {my-server-side-app-url}/sws/dt/index.jsp where sws is the Sencha workspace and dt is the Sencha single-page app. So far, no problems I believe. Then I run the command: sencha app build within my

Ext.ComponentLoader lazy loading html+js within component

生来就可爱ヽ(ⅴ<●) 提交于 2019-12-06 14:40:07
I have four files: layout.html //contains ext resources layout.js //contains my panel partial.html //contains <script src="partial.js"> partial.js //contains a component I have this panel configured in my layout.js: var myPanel = Ext.widget('panel',{ title: 'Load HTML into panel', html: 'initial', width: 300, height: 300, loader: { url: 'partial.html', renderer: 'html', scripts: true, autoLoad: true }, renderTo: Ext.getBody() }); And this code in my partial.js Ext.onReady(function(){ var myDynPanel = Ext.widget('panel',{ title: 'Is this working', html: 'Dynamic test', //renderTo: 'myDynPnl' })

how to make a “MVC Application” with extjs 4.0 beta 3?

拈花ヽ惹草 提交于 2019-12-06 14:29:20
Is there someone here who made a MVC application using EXTJS 4 BETA 3? and works fine?? please help me how?, .. I have followed step by step here .. and @Abdel Olakara help but there is still an error ... here my firebug [Ext.Loader] Synchronously loading 'AM.controller.Users'; consider adding Ext.require('AM.controller.Users') above Ext.onReady [Ext.Loader] Synchronously loading 'AM.store.Users'; consider adding Ext.require('AM.store.Users') above Ext.onReady this.getView('Viewport') is null When i read this at the forum ... there are still some bug with MVC guide ... so, if you ever make it

Trouble loading JSON data into a ExtJS datastore

删除回忆录丶 提交于 2019-12-06 13:28:55
I've tried every combination I can think of in terms of how to configure my ExtJS datastore to read my incoming JSON data. I'm getting this JSON data in: [{ "data_type": {"attribute1" : "value1", "attribute2" : "value2", "attribute3" : "value3" } }, { "data_type": {"attribute1": "value4", "attribute2" : "value5", "attribute3" : "value6" } } ] I don't want to parse the JSON and reformat it in order to make ExtJS happy because it seems redundant. What I want to end up with is a datastore which would allow me to do: Ext.create('Ext.container.Container', { id: 'junk', renderTo: 'slider', width:

ExtJS 4 recaptcha form

China☆狼群 提交于 2019-12-06 11:18:50
I have set up a key and can get the recaptcha to show on the page it self but I don't know how to get it into a form. Actually I don't want to use an id since I'll be reusing this later inside the app too so to use itemId would be preferred.I'm assuming that the element hasn't been created yet. My include: HTML Code: <script type="text/javascript" src="http://www.google.com/recaptcha/api/js/recaptcha_ajax.js"></script> Error (generated from recaptcha_ajax.js. Can't get the control with id 'recaptcha'): Uncaught TypeError: Cannot set property 'innerHTML' of null Here's the code: Ext.define(

path of view is incorrect in extjs 4 mvc application

99封情书 提交于 2019-12-06 11:12:01
I'm trying to deploy my mvc app into my large web application. I have defined the app folder and can see in fire bug that it is calling the correct files with the exception of the initial view. So "App.view.Jobs" is calling https://www.estore.localhost/Jobs/Edit/ext/jobs/App/view/Jobs.js?_dc=1328471746967 when i would like it to call https://www.estore.localhost/ext/jobs/App/view/Jobs.js?_dc=1328471746967 Ext.Loader.setConfig({ enabled: true }); Ext.application({ name: 'MyApp', appFolder: '/ext/jobs/app', models: ['Part', 'Material', 'Job', 'Process'], stores: ['SalesContact', 'Parts',

In ExtJs, how do I get an id after syncing a record to the store?

你说的曾经没有我的故事 提交于 2019-12-06 10:53:08
If I have a store under ExtJs 4, how do I get an id from a newly added record after a sync occurs? For example, if I have a PersonStore set to autosync and I add a new person based on a form filled out by the users, I can add the new record to the store by doing the following; var values = button.up('form').getForm().getValues(), store = Ext.StoreMgr.lookup('PersonStore'), result; result = store.add(values); Since autosync is set to true, this sends over the new value to the backend where it is assigned an id. The backend then responds to the client with the id of the newly created record. How

ExtJs4 load panel from URL

核能气质少年 提交于 2019-12-06 10:36:03
In ExtJs 3x this code Ext.getCmp('specific_panel_id').load({ url:'url_containing_scripts.htm', scripts:true, params:{ something:else } }); works for loading content from URL into a specific panel... However it does not work in ExtJs 4.x. This also work: Ext.define('EI.view.Viewport',{ extend: 'Ext.container.Viewport', alias: 'widget.principal', layout: { type: 'vbox', align: 'center', pack: 'center' }, items:[ { xtype: 'panel', title: 'Mi Documentacion', width: 800, height: 600, border: false, autoScroll: true, loader: { autoLoad:true, url :'http://localhost/docs/' } } ] }); The load method is

How to skip over particular cells when tabbing through an Ext grid?

吃可爱长大的小学妹 提交于 2019-12-06 09:31:51
I have a grid panel where some cells are editable, and others aren't. I'd like to make it so that when you tab through the grid with your keyboard, the non-editable cells are skipped over i.e. never get selected. Here's my simple grid so far: var store = Ext.create('Ext.data.Store', { fields:['name', 'age', 'country'], data:[ {name:'Lisa', age:13, country: 'USA'}, {name:'Bart', age:75, country: 'France'}, {name:'Homer', age:32, country: 'Germany'}, {name:'Marge', age:56, country: 'Australia'} ] }); var grid = Ext.create('Ext.grid.Panel', { title: 'People', store: store, columns: [ {header:

Save nested form data back to server in ExtJS

久未见 提交于 2019-12-06 09:03:55
问题 I have a Model that contains an association to another Model. I am able to display the nested data into a form by using the mapping attribute on the field. Example: Ext.define('Example.model.Request', { extend: 'Ext.data.Model', fields: [ { name: 'id', type: Ext.data.Types.NUMBER, useNull: false } { name: 'plan_surveyor', mapping: 'plan.surveyor', type: Ext.data.Types.STRING } ], associations: [ {type: 'hasOne', associationKey: 'plan', getterName:'getPlan', model: 'Specs.model.Plan'} ], proxy