Re: DB_DataObject and Structures_DataGrid integration
| From: | Justin Patrin | Date: | Thu, 12 Aug 2004 22:07:00 +0000 |
| Subject: | Re: DB_DataObject and Structures_DataGrid integration | ||
| References: | 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 | Groups: | php.pear.dev |
| Request: | Send a blank email to pear-dev+get-32603@lists.php.net to get a copy of this message | ||
On Thu, 12 Aug 2004 17:53:45 -0400, Andrew Nagy <asnagy@webitecture.org> wrote:
> Justin Patrin wrote:
>
> >>>>Take a look at phpMyAdmin, that's where my ideas for the editable column
> >>>>came from.
> >>>
> >>>
> >>>After looking, I don't see anywhere to edit columns. Where exactly is this?
> >>
> >>Any of the data editing pages (insert, update) have the function column
> >>with a drop down for every record (in this case the "records" are table
> >>fields) and the value column has a text field. Notice how not every
> >>column is editable.
> >>
> >
> > That's a different kind of thing. That's showing and editing *one*
> > record. DataGrid shows multiple records at once. It makes sense to be
> > editing a record, not a column. I can think of reason for editing one
> > column, but not many. The DataGrid use would be link when you click
> > Browse on the table. You could then edit the records *on that screen*.
> >
>
> I am referring to the record edit pages. The fact that it is editing
> one record is not what I am talking about, it is the table layout not
> the content i am referring to.
>
> | Address | Phone | Edit
> --+---------+-------+------
> 1 | | |
> --+---------+-------+------
> 2 | | |
> --+---------+-------+------
> 3 | | |
>
> For example, let's say I want to edit the address for every record, I
> would use the editable column for the address column. Now let's say I
> wanted to have a link for every record in the edit column. I could use
> a hyper link column as the column class.
Ok, it makes some sense, but it makes more sense to me to edit
per-record, not per-column. In fact, part of the idea was to be able
to edit multiple records at once (possibly all displayed).
>
> The same argument could be made for making an editable record. For
> example if I want to edit every column for record number 2.
>
> However, the reason I feel the way this should be done via a column
> class, is due to the data types. Let's say addresses are dropdowns and
> phone numbers are text boxes, I would need to define this per column.
It's already defined per-column in the db.ini file and the links.ini
file for DB_DataObject. In addition, FormBuilder already creates
select boxes for the links. This is all done, tested, and working code
in DB_DataObject_FormBuilder.
>
> Now the trick is, using my paradigm, how do you limit the editing on a
> per record basis.
>
Using your paradigm, I don't see how you can. If only columns are
editable, then only columns are editable.
BTW, looking at the latest phpMyAdmin, I still don't see editable columns.
http://www.phpmyadmin.net/phpMyAdmin/
IMHO, DataGrid should focus on editable records, not columns.
--
DB_DataObject_FormBuilder - The database at your fingertips
http://pear.php.net/package/DB_DataObject_FormBuilder
paperCrane --Justin Patrin--