This topic contains 1 reply, has 2 voices, and was last updated by Hristo 8 years, 6 months ago.
Viewing 2 posts - 1 through 2 (of 2 total)
Viewing 2 posts - 1 through 2 (of 2 total)
You must be logged in to reply to this topic.
jQuery UI Widgets › Forums › DataTable › Advanced displaying / editing with associated models
Tagged: angular datatable, bootstrap datatable, javascript datatable, jquery datatable, jqwidgets datatable, jqxdatatable
This topic contains 1 reply, has 2 voices, and was last updated by Hristo 8 years, 6 months ago.
Hi all, i have a question about some more advanced usage of DataTable. I have a more complicated model to show which is not 1:1 to the display values in the datatable. Some fields i’ m showing are the id – foreign key of the associated child model which have a name attribute with the actual value to be shown in the dominant model shown as datatable. Furthermore i want do be able to edit the id / value combination for some cells perhaps with the combobox or dropdownlist. In short terms the dominant model should retain the child id’s as its attribute value, but display the actual string containing the data, wit the possibility to retain sorting on that column by that string not by id.
Is that possible with DataTables? Im using Knockout.js and tried that with computed observables, with read/write but somehow the computedobservable gets broken after the cell update, it looses the observable definition and becomes normal primitive.
Hello cybercow,
Please, take a look at those demos:
http://www.jqwidgets.com/jquery-widgets-demo/demos/jqxdatatable/javascript-datatable-custom-editors.htm?arctic
(in the example above could find out how to use ‘initEditor’ and ‘getEditorValue’)
http://www.jqwidgets.com/jquery-widgets-demo/demos/jqxdatatable/javascript-datatable-dialog-editing.htm?arctic
http://www.jqwidgets.com/jquery-widgets-demo/demos/jqxdatatable/javascript-datatable-validation.htm?arctic
(if you would like to set some validation)
http://www.jqwidgets.com/jquery-widgets-demo/demos/jqxknockout/datatable.htm?arctic
This topic could be helpful too:
http://www.jqwidgets.com/community/topic/hierarchical-data-as-source-issue/
Unfortunately, you cannot set custom sorting in the DataTable but you can do this in the Grid.
Best Regards,
Hristo Hristov
jQWidgets team
http://www.jqwidgets.com
You must be logged in to reply to this topic.