PDA

View Full Version : Add content to TabPanelItem



rancourtk
8 Oct 2007, 5:46 PM
Hi All,

I'm very new to Ext (I started about 10 hours ago). I'm moving right along and am loving it, but I'm now pulling my hair out trying to do a seemingly simple thing in the PoC I am creating.

I've created an EmployeeForm which is an extension of Ext.form.Form that contains various form fields for editing employee information. I've tested it on its owna nd it works very well. I created the form as a class because I anticipate instantiating multiple instances of the form so users can edit multiple employees at once (essentially a multiple document interface). I'd like to present these multiple instances of the form in a TabPanel, but I'm having trouble adding a new instance of my class to a TabPanelItem.

I've looked at the API and as far as I can see my options are loading tab content via an Ajax request or I can pass the content in directly. Obviously, neither of these two options helps me. I'm sure I can't be the first to be attempting something like this. Can anyone offer some advice?

I'm open to other possibilities as well, of course. If it turns out I'm approaching this in the completely wrong manner.

Thanks in advance to anyone who can help.

fangzhouxing
8 Oct 2007, 6:06 PM
You can use iframe in tabpanel to load instances of your form(the advantage is no conflict of form field ids), or you can see link below to reuse formPanel field:
http://extjs.com/forum/showthread.php?p=70027