Goodafternoon,
I started since a while to play with TW5 and I love it. I created a
personal planning tool with weekly logs, journal items and stakeholder
pages. My next step is to create an activity overview. Each activity is a
tiddler and in the overview I show title, category, assignee and quarter
(in which the activity should be done e.g. 2021Q2).
Now i would like to use the JavaScript framework datatables
(https://datatables.net/) to enhance this table with sorting and grouping.
For instance I want to group on category or quarter to get better insight.
I made a tiddler which I tagged as $:/tags/RawMarkup and set the type
to: text/vnd.tiddlywiki the content of the tidder is:
<link rel="stylesheet" type="text/css"
href="https://cdn.datatables.net/1.10.24/css/jquery.dataTables.css">
<link rel="stylesheet" type="text/css"
href="https://cdn.datatables.net/rowgroup/1.1.2/css/rowGroup.dataTables.min.css">
<script
src="https://ajax.googleapis.com/ajax/libs/jquery/3.5.1/jquery.min.js"></script>
<script type="text/javascript" charset="utf8"
src="https://cdn.datatables.net/1.10.24/js/jquery.dataTables.js"></script>
<script type="text/javascript" charset="utf8"
src="https://cdn.datatables.net/rowgroup/1.1.2/js/dataTables.rowGroup.min.js"></script>
<script type="text/javascript">
$(document).ready( function () {
debugger;
$(table).DataTable( {
paging: false,
order: [[2, 'asc']],
rowGroup: {
dataSrc: 2
}
} );
} );
</script>
this is the logic I tested first in a standalone html page to test the
datatable. Running this I get an uncaught exception. When I look in the
develop console of my Chrome browser I see that table is not defined. Also
when I try other jQuery commands on table it fails. Although jQuery on the
document works.
Anyone an idea how to include this great library to enhance my tables?
Kind regards, Joost
--
You received this message because you are subscribed to the Google Groups
"TiddlyWiki" group.
To unsubscribe from this group and stop receiving emails from it, send an email
to [email protected].
To view this discussion on the web visit
https://groups.google.com/d/msgid/tiddlywiki/3513f218-eeb3-483d-8340-b7ab2b0678c9n%40googlegroups.com.