Hybrid View
-
22 Feb 2009 2:00 PM #1
Ext.ux.data.BindMgr - Databind Manager
Ext.ux.data.BindMgr - Databind Manager
Hi there,
as some of you may have noticed, I've been into data binding technology recently. I've run from failed concept of "binding-record-to-component", through "binding-components-to-record" implemented in Ext.data.Record, to Bind Manager that finally looks pretty usable and universal, yet simple enough.
BindMgr is a singleton that manages records (as many of them as you need, from as many stores as you need - or standalone records) and components bound to them. The idea is that after you bind a component to a record, the component will be informed about data changes in that record. If component has afterEdit, afterReject, afterCommit, onBind and onUnbind methods they will be called with the record causing the change as argument.
You can see the demo at http://examples.extjs.eu/?ex=databind and documentation of BindMgr at http://extjs.eu/docs/?class=Ext.ux.data.BindMgr
Enjoy,
SakiJozef Sakalos, aka Saki
A lot of valuable info at:
Saki's Extensions and Plugins
Saki's Extensions and Plugins Docs
Saki's Examples, Latest: Grid in Card Layout
Saki's Blog, Featured: Writing a Big Application in Ext, Latest: Grid MultiSearch Plugin Video
-
23 Feb 2009 5:39 PM #2
post deleted by MJ
MJ
API Search || Ext 3: docs-demo-upgrade guide || User Extension Repository
Frequently Asked Questions: FAQs
Tutorial: Grid (php/mysql/json) , Application Design and Structure || Extensions: MetaGrid, MessageWindow
-
24 Feb 2009 1:40 AM #3
Re id: Bound components are internally stored in an object and keyed by their id for easy reference. Ext assign ids anyway.
Re Record (last version): It is fully functional but I started to doubt that it will find its way to to the core. I also started to realize that data binding functionality should be separated from the record itself. I will update the Feature Request thread.Jozef Sakalos, aka Saki
A lot of valuable info at:
Saki's Extensions and Plugins
Saki's Extensions and Plugins Docs
Saki's Examples, Latest: Grid in Card Layout
Saki's Blog, Featured: Writing a Big Application in Ext, Latest: Grid MultiSearch Plugin Video
-
24 Feb 2009 4:46 AM #4
post deleted by MJ
MJ
API Search || Ext 3: docs-demo-upgrade guide || User Extension Repository
Frequently Asked Questions: FAQs
Tutorial: Grid (php/mysql/json) , Application Design and Structure || Extensions: MetaGrid, MessageWindow
-
24 Feb 2009 4:48 AM #5
Because I use c.id as key to internal object that stores bound components:
this.bounds[internal_id].components[c.id] = c;Jozef Sakalos, aka Saki
A lot of valuable info at:
Saki's Extensions and Plugins
Saki's Extensions and Plugins Docs
Saki's Examples, Latest: Grid in Card Layout
Saki's Blog, Featured: Writing a Big Application in Ext, Latest: Grid MultiSearch Plugin Video
-
24 Feb 2009 4:55 AM #6
post deleted by MJ
MJ
API Search || Ext 3: docs-demo-upgrade guide || User Extension Repository
Frequently Asked Questions: FAQs
Tutorial: Grid (php/mysql/json) , Application Design and Structure || Extensions: MetaGrid, MessageWindow
-
25 Feb 2009 5:56 AM #7
We where thinking about implementing much the same idea. Is there any specific reason you didn't choose to use the plugin structure?
-
25 Feb 2009 6:12 AM #8
Plugin to components? I dropped the idea for more reasons:
1) concept of binding record to component failed. Good concept is: bind components to record
2) it is too much overhead of add plugin to all components you want to bind
3) you can have many records from many stores and many components bound to them at the same time
So the concept of sigleton BindMgr is best I can see at present.Jozef Sakalos, aka Saki
A lot of valuable info at:
Saki's Extensions and Plugins
Saki's Extensions and Plugins Docs
Saki's Examples, Latest: Grid in Card Layout
Saki's Blog, Featured: Writing a Big Application in Ext, Latest: Grid MultiSearch Plugin Video
-
25 Feb 2009 12:16 PM #9
post deleted by MJ
MJ
API Search || Ext 3: docs-demo-upgrade guide || User Extension Repository
Frequently Asked Questions: FAQs
Tutorial: Grid (php/mysql/json) , Application Design and Structure || Extensions: MetaGrid, MessageWindow
-
25 Feb 2009 12:27 PM #10
MJ, if you can put it to form needed for my examples (html + js + css, if any) I can host it at my server. Looks nice and useful.
Jozef Sakalos, aka Saki
A lot of valuable info at:
Saki's Extensions and Plugins
Saki's Extensions and Plugins Docs
Saki's Examples, Latest: Grid in Card Layout
Saki's Blog, Featured: Writing a Big Application in Ext, Latest: Grid MultiSearch Plugin Video


Reply With Quote