Re: Is Pear RADy ?
| From: | Olivier Guilyardi | Date: | Thu, 22 Jul 2004 08:50:42 +0000 |
| Subject: | Re: Is Pear RADy ? | ||
| References: | 1 2 3 4 | Groups: | php.pear.general |
| Request: | Send a blank email to pear-general+get-13797@lists.php.net to get a copy of this message | ||
Justin Patrin wrote:
On Tue, 20 Jul 2004 09:03:17 +0200, Olivier Guilyardi <ml@xung.org> wrote:I'm interested ; I'm gonna use that for the prototype I'm about to code. We shall make it better ; what about calling it DB_DataObject_Pager, or some other shorter name ?
Well, I called it what I did because it's built on FormBuilder. Part of the "niceness" of it is that it also uses the link display functionality in the outputted table. I'm sure I could make it better to use, possibly even use Structures_DataGrid for the output.Definitely. Structures_Datagrid seems powerful (thanks Klaus).
You can also affect how the table is displayed and how the form is displayed / works through the config options of FormBuilder. Such as defining the fields to render or the use editable fields *per-table*. You just add it to the DataObject and it magically appears in the form.What about using HTML_Menu to improve the tables menu you've set up ? Possibly with some nested levels (a tree like thingy). In addition, the formbuilder lacks support for sql enumerations (ex : status ENUM ('customer', 'prospect')) ; it should generate a drop down list (<select>) in those cases. There also could be some interesting feature making use of foreign keys. It may be somewhat tricky, though. Say you want to create a new Bill object, the form could present you with the list of all Contacts, since the 'bill' table contains a field like : contact_no integer REFERENCES contact (contact_no). Analysing the table structure may not be sufficient for this though (AFAIK MySQL does not support foreign keys anyway) Then what ? Xml database schema ? Or adding a little method (after ###END_AUTOCODE) to the DataOjects that want to make use of such foreign keys ? -- og