Delete & Row ID

10 views
Skip to first unread message

infringer

unread,
Sep 30, 2010, 11:59:44 AM9/30/10
to MyTableGrid
2 Questions...

1) How do you delete a row? More specifically how does the delete
button know which row to delete? I tried clicking on a row to
highlight it and that did nothing?
2) How is my update script supposed to know what the "id" of the row
is, I don't want to display the "id" in the first column. Typically I
do something like <tr id='$id'> and then just always grab the row id
on update. But I don't see a way to supply a row id.

Thanks,
-David

Pablo Aravena

unread,
Sep 30, 2010, 12:19:34 PM9/30/10
to mytab...@googlegroups.com
Hi David

You have to define a selectable checkbox column in case you need a mechanism for selecting rows, for example:

            {
                id : 'carId',
                title : 'Id',
                width : 30,
                editable: true,
                sortable: false,
                editor: new MyTableGrid.CellCheckbox({
                    selectable : true
                })
            }

Then you will be able to call the following method:

tableGrid.getSelectedRowsByColumn('id')



Good Luck





--
You received this message because you are subscribed to the Google Groups "MyTableGrid" group.
To post to this group, send email to mytab...@googlegroups.com.
To unsubscribe from this group, send email to mytablegrid...@googlegroups.com.
For more options, visit this group at http://groups.google.com/group/mytablegrid?hl=en.


Pablo Aravena

unread,
Sep 30, 2010, 12:20:14 PM9/30/10
to mytab...@googlegroups.com
A little mistake

tableGrid.getSelectedRowsByColumn('carId');
Reply all
Reply to author
Forward
0 new messages