tradePosTable =
$('#trading_positions_table').dataTable({
"sDom": '<"top"i>rt<"pos_links"><"bottom"p><"clear">',
"aoColumns":[
{"sType": "string"},
{"sType": "numeric-comma"},
{"sType": "numeric-comma"},
{"sType": "numeric-comma"},
{"sType": "numeric-comma"},
{"sType": "numeric-comma"},
{"sType": "numeric-comma"},
{"sType": "numeric-comma"},
{"sType": "numeric-comma"},
{"sType": "string"},
{"sType": "numeric-comma"},
{"sType": "string"},
{"sType": "numeric-comma"}
],
"sPaginationType": "full_numbers",
"bPaginate": true,
"aLengthMenu": [[10, 25, 50,100, -1], [10, 25, 50,100, "Alla"]],
"aaSorting":[],
"bFilter": false,
"bInfo":true,
"bAutoWidth": true,
"bSortClasses": false,
"iDisplayLength": 250,
"sScrollY":275,
"sScrollX":"100%",
"bProcessing":true,
"oLanguage":{
"sZeroRecords": "No positions"
},
"fnRowCallback": function( nRow, aData, iDisplayIndex ) {
decorateTradingPosRow(nRow);
return nRow;
}
});
//create buttons within the table
$('div.pos_links').html(
"<input id='filter_all_positions' type='button' value='All' " +
"style='width:20%;'>" +
"<input type='button' id='filter_non_flat_positions' " +
"value='Non-Flat' style='margin-left:20%; width:20%;'/>" +
"<span style='margin-left:20%;' id='more_trading_positions'></span>" +
"<input type='button' id='more_trading_positions_button' " +
"value='More' style='width:19.5%;'/>"
);
It looks like you're new here. If you want to get involved, click one of these buttons!
Get useful and friendly help straight from the source.