[Zope3-dev] Re: [Zope3-Users] z3c.form 1.0.0 released!
One form demo might be a simple form that relates the input from one field to another in the form. For example two dropdown lists where second dropdown is based on what choice in first dropdown. The need for something like this is fairly common for apps I believe. Regards David Stephan Richter wrote: On Wednesday 30 May 2007 12:27, David Pratt wrote: Another form related demo might show how to effectively use a data source with a large number of choices in a select list (like choosing a user in a select list from all users on the site) using an ajax widget where you can start typing and it will begin narrowing the choices - much like the way live search works (and without generating all options in the form). Yeah, there are some demos related to AJAX-features that could be done. Roger is already working on AJAX-related demos, including live search and input validation. Regards, Stephan ___ Zope3-dev mailing list Zope3-dev@zope.org Unsub: http://mail.zope.org/mailman/options/zope3-dev/archive%40mail-archive.com
Re: [Zope3-dev] Re: [Zope3-Users] z3c.form 1.0.0 released!
It works together with a mapper like SQLAlchemy (and z3c.zalchemy). IMHO, it is not formlib's task to do mappings like that. Not sure what mappings you're talking about. I just want to know how can I get some data from somewhere (it may be a file, RDBMS or other external source) and display it in a form, then edit this data etc. Formlib default forms (EditForm, AddForm) assume that it works with content objects and I just want to call SQLScript to get data for my form and to commit it back to RDBMS. Not so difficult but there are no docs and no demos for this with formlib. Thats why I'd like to know how to do such things with z3c.form. you should redefine getContent method on your form, inside getContent you can get data from anywhere and return it in dict. ___ Zope3-dev mailing list Zope3-dev@zope.org Unsub: http://mail.zope.org/mailman/options/zope3-dev/archive%40mail-archive.com
Re: [Zope3-dev] Re: [Zope3-Users] z3c.form 1.0.0 released!
On Thursday 31 May 2007 02:25, Nikolay Kim wrote: Not sure what mappings you're talking about. I just want to know how can I get some data from somewhere (it may be a file, RDBMS or other external source) and display it in a form, then edit this data etc. Formlib default forms (EditForm, AddForm) assume that it works with content objects and I just want to call SQLScript to get data for my form and to commit it back to RDBMS. Not so difficult but there are no docs and no demos for this with formlib. Thats why I'd like to know how to do such things with z3c.form. you should redefine getContent method on your form, inside getContent you can get data from anywhere and return it in dict. Yes, this is correct. You can also have other data structures. All you have to do is to develop and register a new data manager. By default there are two data managers registered: one for instances and one for dicts. Regards, Stephan -- Stephan Richter CBU Physics Chemistry (B.S.) / Tufts Physics (Ph.D. student) Web2k - Web Software Design, Development and Training ___ Zope3-dev mailing list Zope3-dev@zope.org Unsub: http://mail.zope.org/mailman/options/zope3-dev/archive%40mail-archive.com
Re: [Zope3-dev] Re: [Zope3-Users] z3c.form 1.0.0 released!
I also still struggle with this issue. In my case, I have the following scenarios: I currently try to solve these issues with a self-made Form class, which descends from form.Form. In case you are interested, here is my docstring which somehow explains the basic idea: Thanks for the code. I'm using old (?) way with SQLScripts not with ORM's so may case is a bit different. I've also created my own library that extends formlib: 'dbformlib' (available at google code) for such things. I'm not sure why do you have to clone fields, possibly because of ORM specifics? Idea of widget_template_files is very interesting. I need to see docs and code for z3c.form now :) -- Maciej Wisniowski ___ Zope3-dev mailing list Zope3-dev@zope.org Unsub: http://mail.zope.org/mailman/options/zope3-dev/archive%40mail-archive.com
Re: [Zope3-dev] Re: [Zope3-Users] z3c.form 1.0.0 released!
Am Mittwoch, den 30.05.2007, 18:12 +0200 schrieb Maciej Wisniowski: Thanks. BTW, I am still looking for 1-2 demos to write but I am out of ideas. Do have anything related to forms that you would like to see demoed? It would be very interesting to see RDBMS interaction. Formlib for example is not trivial to use with RDBMS especially because of a lack of documentation and because everything seems to be written with ZODB objects in mind. It works together with a mapper like SQLAlchemy (and z3c.zalchemy). IMHO, it is not formlib's task to do mappings like that. Christian -- gocept gmbh co. kg - forsterstraße 29 - 06112 halle/saale - germany www.gocept.com - [EMAIL PROTECTED] - phone +49 345 122 9889 7 - fax +49 345 122 9889 1 - zope and plone consulting and development signature.asc Description: Dies ist ein digital signierter Nachrichtenteil ___ Zope3-dev mailing list Zope3-dev@zope.org Unsub: http://mail.zope.org/mailman/options/zope3-dev/archive%40mail-archive.com
[Zope3-dev] Re: [Zope3-Users] z3c.form 1.0.0 released!
On Wednesday 30 May 2007 12:27, David Pratt wrote: Another form related demo might show how to effectively use a data source with a large number of choices in a select list (like choosing a user in a select list from all users on the site) using an ajax widget where you can start typing and it will begin narrowing the choices - much like the way live search works (and without generating all options in the form). Yeah, there are some demos related to AJAX-features that could be done. Roger is already working on AJAX-related demos, including live search and input validation. Regards, Stephan -- Stephan Richter CBU Physics Chemistry (B.S.) / Tufts Physics (Ph.D. student) Web2k - Web Software Design, Development and Training ___ Zope3-dev mailing list Zope3-dev@zope.org Unsub: http://mail.zope.org/mailman/options/zope3-dev/archive%40mail-archive.com