I have a multicolumn grid that loads from a mySQL database. When I change cell data the update to the mySQL data base occurs. When I do a drag and drop move of row database elements, although it looks fine locally, no update takes place on the mySQL database, and reloading of the page results in original data order. Is there a way to fix this? Thanks
DataProcessor and connectors are saving only data change, not the order of items, you need to customize the saving logic if you want to save the order of rows.
Any thoughts as to how to do this, or is there a way on display using grid to always do it by alphanumeric sorting?
or is there a way on display using grid to always do it by alphanumeric sorting
If you are using connector, you can replace
$grid->render_sql(“SELECT * FROM some ORDER BY some_field”, …
>> Any thoughts as to how to do this
It possible to extend both client and server side code to send row indexes , but it can be pretty complicated ( changing single row position may require to update indexes for many rows )
Right now I use:
What I could do is render in ascending aphabetic order based on “item_id” although I am not sure how to do this.
Probably the following method will be correct:
$grid->render_sql(“SELECT * FROM pphone_rad ORDER BY item_id”, “item_id”,“rad_name,rad_pager,rad_office”);
Please, see deatils here:
dhtmlx.com/dhxdocs/doku.php? … iting_data
Thanks, except if the data is in ascending alphabetical order it seems to do the reverse. Is there a way to make it sort in ascending alphabetical only?
Try to correct the SQL query:
$grid->render_sql(“SELECT * FROM pphone_rad ORDER BY item_id ASC”, “item_id”,“rad_name,rad_pager,rad_office”);