Skip to content
Snippets Groups Projects
Commit 82911421 authored by Anthony's avatar Anthony
Browse files

Transform th in td

parent 264d7121
No related branches found
No related tags found
No related merge requests found
...@@ -11,8 +11,17 @@ $(document).ready(function() { ...@@ -11,8 +11,17 @@ $(document).ready(function() {
$('.commentaireInfo').prop('popover', 'true'); $('.commentaireInfo').prop('popover', 'true');
$('.commentaireInfoGroup').show(); $('.commentaireInfoGroup').show();
// Comment popover
$('[spanid]').addClass('comment-trigger').on('click', function() { $('[spanid]').addClass('comment-trigger').on('click', function() {
let spanid = $(this).attr('spanid'); let spanid = $(this).attr('spanid');
$("[commentaireid=" + spanid + "]").toggle(); $("[commentaireid=" + spanid + "]").toggle();
}); });
// Simplify th in td
$('th').each(function () {
// Store the current content of the <th>
const content = $(this).html();
// Replace <th> with a <td> containing the same content
$(this).replaceWith(`<td>${content}</td>`);
});
}); });
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment