datatables

jQuery DataTables - Cannot reinitialise DataTable

走远了吗. 提交于 2019-12-31 02:59:19
问题 I'm making a statements page in a spring 4.x application using jQuery DataTables to render the statements. I have the following object returned by the server after parsing thru the Jackson message converter. { "data":[ { "desc":"SUBWAY 00501197 BRONX NYUS", "amount":"-", "date":"5.72" }, { "desc":"MIDTOWN COMICS NEW YORK NYUS", "amount":"-", "date":"73.32" }, { "desc":"GOOGLE *PlayDog Soft GOOGLE.COM/CHCAUS", "amount":"-", "date":"1.99" }, { "desc":"BIMG PRIMARY CARE NEW YORK NYUS", "amount":

DataTables change checkboxes over all pages

↘锁芯ラ 提交于 2019-12-31 01:33:28
问题 I'm using DataTables to list which "events" are shown on each page of my web application. For each page I have a column and each event is a row with checkboxes per page. (To give you an idea of what it looks like: http://i.stack.imgur.com/6QhsJ.png) When I click on a page it should check all checkboxes, however the checkboxes are only checked on the current page of the DataTable. Any help is appreciated! Edit: here is a JSFiddle for my problem (https://jsfiddle.net/2n3dyLhh/2/) HTML <table id

DataTables - Dynamic Columns From Ajax Data Source?

隐身守侯 提交于 2019-12-30 18:29:14
问题 I am trying to get DataTables to read the column names from an AJAX data source but it seems that there must be something that I must be missing here. I made a fiddle fiddle in which I can manually define the data and columns that are being used by the table. The table is declared in the HTML and there is no no need to define the column names ( <thead>..</thead> ): <table id="example" class="display table table-striped table-bordered" cellspacing="0" width="100%"></table> In the JS we

R shiny: update select input values in data.table

徘徊边缘 提交于 2019-12-30 14:48:07
问题 I have renderDataTable with select Inputs and buttons inside. I want to update selectInput inside datatable after click on 'Save' button in appropriate row. How can I do that? During searching for a solution I found that "if you rerender the table, the inputs won't work unless you add some extra code to unbind". However I am new in shiny and using js options, so I would be grateful for any hints/solutions. library(shiny) library(DT) runApp(list( ui = basicPage( h2('The mtcars data'), DT:

Datatables - How do I change background and text color of a cell changed dynamically?

ぐ巨炮叔叔 提交于 2019-12-30 10:19:22
问题 I use the following code to update a cell dynamically and works perfect, the only thing is how to change the color of the background and the text of that cell data. If it´s possible an example of how to change the entire row as well. Thanks in advance. $(document).ready(function (){ var table = $('#example').DataTable(); table.rows().every( function ( rowIdx, tableLoop, rowLoop ) { var data = this.data(); console.log(data); data[0] = '* ' + data[0]; this.data(data); }); }); 回答1: SOLUTION You

Why can't jQuery dataTables parse my JSON?

∥☆過路亽.° 提交于 2019-12-30 09:29:15
问题 I am trying to populate a dataTable as follows: $("#my-datatable").dataTable( { "sAjaxSource" : "/someURLOnMyServer", "bDestroy" : true, "fnServerParams" : function(serverParams) { serverParams.push( { "name" : "widget", "value" : token } ); } }); And the HTML table it is populating: <table id="my-datatable"> <thead> <tr> <th>Type</th> <th>Value</th> <th>ID</th> <th>Fizz</th> <th>Buzz</th> </tr> </thead> <tbody></tbody> </table> According to Firebug, the JSON coming back from the server is: [

jQuery Datatable DOM positioning for Buttons

我只是一个虾纸丫 提交于 2019-12-30 08:14:17
问题 I just upgraded my jQuery Datatable version to 1.10. And then i tried to remove its retired plugin such as "Colvis" and "Tabletools" with the "Button" extension. Everything works fine here. But the problem for me is, I could not able to separate "Colvis" button from the "Tabletool" buttons. "sDom": "B<'row'><'row'<'col-md-6'l><'col-md-6'f>r>t<'row'<'col-md-4'i>><'row'p>B", "buttons": [ 'copyHtml5', 'excelHtml5', 'csvHtml5', { extend: 'colvis', postfixButtons: [ 'colvisRestore' ], columns: '0

JQuery Datatable with parent child relationship in same dataset. How to display it as parent child rows in the table?

☆樱花仙子☆ 提交于 2019-12-30 07:31:40
问题 I have a nested dataset. Few records in the dataset are child to other records in the same dataset. The records that have parent as null do not have any child elements, but ones that has value associated with is will indicate its parent in same dataset. How do I represent this in jQuery Datatable with Parent Child relationship. I have just manipulated the common dataset to explain my requirements. As in the dataset example below, Record with Name - Tiger Nixon have two child records, which

JQuery Datatable with parent child relationship in same dataset. How to display it as parent child rows in the table?

喜你入骨 提交于 2019-12-30 07:31:05
问题 I have a nested dataset. Few records in the dataset are child to other records in the same dataset. The records that have parent as null do not have any child elements, but ones that has value associated with is will indicate its parent in same dataset. How do I represent this in jQuery Datatable with Parent Child relationship. I have just manipulated the common dataset to explain my requirements. As in the dataset example below, Record with Name - Tiger Nixon have two child records, which

jquery datatables sorting neglect null value

倖福魔咒の 提交于 2019-12-30 07:18:39
问题 I'm using datatables and jQuery for making nice sortable tables. I now want to sort the rows an a value. This value is a numeric value. But it can also be not available, so at that point I will echo a dash. When I now sort this column, all rows with the dash are on top. And than the rows with value 1, 3, 6, 8, 10 are shown. How do I change this so that the dash (-) are always on bottom of the table? At the moment I put in a maximum number, what puts them on the bottom. However I don't want