FIX_OFFLINE AND ONLINE INVOICE LISTING PAGE
This commit is contained in:
parent
9b5417f786
commit
1c3e47b623
@ -146,7 +146,7 @@
|
|||||||
<!-- Placeholder for status -->
|
<!-- Placeholder for status -->
|
||||||
<a href="#" class="" id="downloadPdfButton" title="Invoice PDF" style="font-size: large;"><i class="ri-file-download-line"></i> </a>
|
<a href="#" class="" id="downloadPdfButton" title="Invoice PDF" style="font-size: large;"><i class="ri-file-download-line"></i> </a>
|
||||||
<a href="#" class="ri-printer-line" id="printPdfButton" title="Print Invoice" style="font-size: large; margin-left: 8px;"></a>
|
<a href="#" class="ri-printer-line" id="printPdfButton" title="Print Invoice" style="font-size: large; margin-left: 8px;"></a>
|
||||||
<button type="button" class="close" data-dismiss="modal" aria-label="Close" style="font-size: 27px; margin-bottom: 2px;">
|
<button type="button" class="close" data-dismiss="modal" aria-label="Close" onclick="reloadBodyContent()" style="font-size: 27px; margin-bottom: 2px;">
|
||||||
<span id="statusText"></span>
|
<span id="statusText"></span>
|
||||||
<span aria-hidden="true">×</span>
|
<span aria-hidden="true">×</span>
|
||||||
</button>
|
</button>
|
||||||
@ -269,4 +269,16 @@
|
|||||||
};
|
};
|
||||||
});
|
});
|
||||||
});
|
});
|
||||||
|
function reloadBodyContent() {
|
||||||
|
console.log("Inside Reload Function");
|
||||||
|
fetch(window.location.href) // Fetch the current page's content
|
||||||
|
.then(response => response.text())
|
||||||
|
.then(html => {
|
||||||
|
const parser = new DOMParser();
|
||||||
|
const doc = parser.parseFromString(html, 'text/html');
|
||||||
|
document.body.innerHTML = doc.body.innerHTML; // Replace the body content
|
||||||
|
// Reinitialize any required scripts if needed
|
||||||
|
})
|
||||||
|
.catch(error => console.error('Error reloading body:', error));
|
||||||
|
}
|
||||||
</script>
|
</script>
|
||||||
@ -154,8 +154,7 @@
|
|||||||
<a href="#" class="" id="editInvoiceButton" title="Edit Invoice"style="font-size: large;margin-left: 8px;"><i class="ri-pencil-line"></i> </a>
|
<a href="#" class="" id="editInvoiceButton" title="Edit Invoice"style="font-size: large;margin-left: 8px;"><i class="ri-pencil-line"></i> </a>
|
||||||
<a href="#" class="ri-printer-line" id="printPdfButton" title="Print Invoice"style="font-size: large;margin-left: 8px;"></a>
|
<a href="#" class="ri-printer-line" id="printPdfButton" title="Print Invoice"style="font-size: large;margin-left: 8px;"></a>
|
||||||
<h5 class="modal-title" id="pdfPreviewModalLabel"></h5>
|
<h5 class="modal-title" id="pdfPreviewModalLabel"></h5>
|
||||||
<button type="button" class="close" data-dismiss="modal" aria-label="Close"style="font-size: 27px;
|
<button type="button" class="close" data-dismiss="modal" aria-label="Close" onclick="reloadBodyContent()" style="font-size: 27px;margin-bottom: 2px;">
|
||||||
margin-bottom: 2px;">
|
|
||||||
<span id="statusText"></span>
|
<span id="statusText"></span>
|
||||||
<span aria-hidden="true">×</span>
|
<span aria-hidden="true">×</span>
|
||||||
</button>
|
</button>
|
||||||
@ -286,6 +285,18 @@
|
|||||||
|
|
||||||
});
|
});
|
||||||
});
|
});
|
||||||
|
function reloadBodyContent() {
|
||||||
|
console.log("Inside Reload Function");
|
||||||
|
fetch(window.location.href) // Fetch the current page's content
|
||||||
|
.then(response => response.text())
|
||||||
|
.then(html => {
|
||||||
|
const parser = new DOMParser();
|
||||||
|
const doc = parser.parseFromString(html, 'text/html');
|
||||||
|
document.body.innerHTML = doc.body.innerHTML; // Replace the body content
|
||||||
|
// Reinitialize any required scripts if needed
|
||||||
|
})
|
||||||
|
.catch(error => console.error('Error reloading body:', error));
|
||||||
|
}
|
||||||
</script>
|
</script>
|
||||||
|
|
||||||
|
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user