mirror of
https://github.com/invoiceninja/invoiceninja.git
synced 2025-07-07 15:34:39 -04:00
Fixes for table header not showing
This commit is contained in:
parent
1f50512b89
commit
50bbd6ddfd
@ -217,6 +217,13 @@ trait DesignHelpers
|
|||||||
|
|
||||||
public function sharedFooterElements()
|
public function sharedFooterElements()
|
||||||
{
|
{
|
||||||
|
// We want to show headers for statements, no exceptions.
|
||||||
|
$statements = "
|
||||||
|
document.querySelectorAll('#statement-invoice-table > thead > tr > th, #statement-payment-table > thead > tr > th, #statement-aging-table > thead > tr > th').forEach(t => {
|
||||||
|
t.hidden = false;
|
||||||
|
});
|
||||||
|
";
|
||||||
|
|
||||||
// Unminified version, just for the reference.
|
// Unminified version, just for the reference.
|
||||||
// By default all table headers are hidden with HTML `hidden` property.
|
// By default all table headers are hidden with HTML `hidden` property.
|
||||||
// This will check for table data values & if they're not empty it will remove hidden from the column itself.
|
// This will check for table data values & if they're not empty it will remove hidden from the column itself.
|
||||||
@ -259,6 +266,7 @@ document.addEventListener('DOMContentLoaded', function() {
|
|||||||
$html_decode = 'document.addEventListener("DOMContentLoaded",function(){document.querySelectorAll(`[data-state="encoded-html"]`).forEach(e=>e.innerHTML=e.innerText)},!1);';
|
$html_decode = 'document.addEventListener("DOMContentLoaded",function(){document.querySelectorAll(`[data-state="encoded-html"]`).forEach(e=>e.innerHTML=e.innerText)},!1);';
|
||||||
|
|
||||||
return ['element' => 'div', 'elements' => [
|
return ['element' => 'div', 'elements' => [
|
||||||
|
['element' => 'script', 'content' => $statements],
|
||||||
['element' => 'script', 'content' => $javascript],
|
['element' => 'script', 'content' => $javascript],
|
||||||
['element' => 'script', 'content' => $html_decode],
|
['element' => 'script', 'content' => $html_decode],
|
||||||
]];
|
]];
|
||||||
|
Loading…
x
Reference in New Issue
Block a user