-
24 Aug 2010 7:16 AM #1
Direct Form: API Submit
Direct Form: API Submit
setting an api.submit value does not seem to work. I keep getting an error.
my container panel has this...Code:uncaught exception: [Exception... "Component returned failure code: 0x80070057 (NS_ERROR_ILLEGAL_VALUE) [nsIXMLHttpRequest.open]" nsresult: "0x80070057 (NS_ERROR_ILLEGAL_VALUE)" location: "JS frame :: http://extadmin2.zenddev.net/js/ext-3.2.1/adapter/ext/ext-base.js :: i :: line 7" data: no]
notice i commented out the override of the baseparams.Code:saveNote: function(){ try{ var x_form = this.form.getForm(); var tab = this.tabs.getActiveTab(); //x_form.baseParams = tab.store.baseParams; console.log(x_form); x_form.submit({waitMsg:'Saving Data...'}); } catch(e) { console.log(e,this); } },
when I inspect the logged form the baseparams, api, and paramOrder are NOT set and I have no idea what is up.
where is the code generated by designer.
Code:/* * File: BenAdmin.formpanel.companynotes.ui.js * Date: Tue Aug 24 2010 10:11:24 GMT-0500 (Central Daylight Time) * * This file was generated by Ext Designer version xds-1.0.2.11. * http://www.extjs.com/products/designer/ * * This file will be auto-generated each and everytime you export. * * Do NOT hand edit this file. */ Ext.ns('BenAdmin.formpanel'); BenAdmin.formpanel.companynotesUi = Ext.extend(Ext.form.FormPanel, { title: 'Create Note', width: 310, collapsible: true, defaultType: 'textfield', autoScroll: true, padding: 10, frame: true, waitTitle: 'Processing Request...', initComponent: function() { this.defaults = { "width": 166 }; this.paramOrder = [ 't_ticket_type', 'compid', 'sitename' ]; this.baseParams = { t_ticket_type: "1", compid: "2", sitename: "3" }; this.api = { submit: BenAdmin.DirectAPI.mod_Support_Notes.update }; this.items = [ { xtype: 'textfield', fieldLabel: 'Call Back', name: 'callback' }, { xtype: 'textarea', anchor: '100%', fieldLabel: 'Notes', name: 'tn_note' }, { xtype: 'textfield', fieldLabel: 'Minutes', name: 'tn_work_minutes', inputType: 'numeric', value: 5 } ]; this.fbar = { xtype: 'toolbar', items: [ { xtype: 'button', text: 'Save', iconCls: 'icn-save', ref: '../save' } ] }; BenAdmin.formpanel.companynotesUi.superclass.initComponent.call(this); } });
-
24 Aug 2010 9:28 AM #2
Tried this with same result.
Help would be appreciated.
Code:/* * File: BenAdmin.formpanel.companynotes.ui.js * Date: Tue Aug 24 2010 10:11:24 GMT-0500 (Central Daylight Time) * * This file was generated by Ext Designer version xds-1.0.2.11. * http://www.extjs.com/products/designer/ * * This file will be auto-generated each and everytime you export. * * Do NOT hand edit this file. */ Ext.ns('BenAdmin.formpanel'); BenAdmin.formpanel.companynotesUi = Ext.extend(Ext.form.FormPanel, { title: 'Create Note', width: 310, collapsible: true, defaultType: 'textfield', autoScroll: true, padding: 10, frame: true, waitTitle: 'Processing Request...', defaults: { "width": 166 }, api: { submit: BenAdmin.DirectAPI.mod_Support_Notes.update }, paramOrder: [ 't_ticket_type', 'compid', 'sitename' ], baseParams: { t_ticket_type: "1", compid: "2", sitename: "3" }, initComponent: function() { this.items = [ { xtype: 'textfield', fieldLabel: 'Call Back', name: 'callback' }, { name: 'tn_employee', fieldLabel: 'Employee', xtype: 'benadmin_combo_supportemployee' }, { name: 'tn_priority', fieldLabel: 'Priority', xtype: 'benadmin_combo_supportpriority' }, { xtype: 'textarea', anchor: '100%', fieldLabel: 'Notes', name: 'tn_note' }, { xtype: 'textfield', fieldLabel: 'Minutes', name: 'tn_work_minutes', inputType: 'numeric', } ]; this.fbar = { xtype: 'toolbar', items: [ { xtype: 'button', text: 'Save', iconCls: 'icn-save', ref: '../save' } ] }; BenAdmin.formpanel.companynotesUi.superclass.initComponent.call(this); } });
-
30 Aug 2010 6:45 AM #3Sencha - Desktop Packager Dev Team
- Join Date
- Mar 2007
- Location
- Baltimore, MD.
- Posts
- 1,745
- Vote Rating
- 5
Hi Artisan,
This is an open ticket #197 for components that are configured via initialConfig, such as FormPanel & BasicForm. It will be corrected with the next maintenance release. Thanks.
Similar Threads
-
Direct+Grid+FORM API ok now?
By khebs@live.com in forum Ext.DirectReplies: 0Last Post: 9 Feb 2010, 10:21 AM -
api submit form
By maren in forum Ext 3.x: Help & DiscussionReplies: 0Last Post: 2 Nov 2009, 12:22 AM -
Ext.Direct form submit without formHandler
By scottpenrose in forum Ext.DirectReplies: 2Last Post: 10 Sep 2009, 12:16 AM -
API after form submit in com.extjs.gxt.ui.client.widget.form.FormPanel
By sample007 in forum Ext GWT: DiscussionReplies: 0Last Post: 22 Aug 2009, 1:35 AM -
Server API for form submit? (and info on actions)
By j1m in forum Ext 1.x: Help & DiscussionReplies: 3Last Post: 28 Aug 2007, 1:24 PM



Reply With Quote