* Push Notification Setup and attempt
* Office Ordering * Allow editing of Task and Ticket Details after creation
This commit is contained in:
+22
-1
@@ -35,7 +35,28 @@
|
||||
<!-- Use a pdfjs-dist version compatible with the printing package (API/Worker versions must match) -->
|
||||
<script src="https://unpkg.com/pdfjs-dist@3.2.146/build/pdf.min.js"></script>
|
||||
<script src="https://unpkg.com/pdfjs-dist@3.2.146/build/pdf.worker.min.js"></script>
|
||||
<script src="packages/printing/printing.js"></script>
|
||||
<script>
|
||||
// Load printing.js only if the file exists to avoid 404/MIME errors in strict browsers.
|
||||
(function() {
|
||||
var localPath = 'packages/printing/printing.js';
|
||||
try {
|
||||
fetch(localPath, { method: 'HEAD' }).then(function(resp) {
|
||||
var contentType = resp.headers.get('content-type') || '';
|
||||
if (resp.ok && contentType.indexOf('javascript') !== -1) {
|
||||
var s = document.createElement('script');
|
||||
s.src = localPath;
|
||||
document.head.appendChild(s);
|
||||
} else {
|
||||
console.warn('printing.js not found locally; skipping load to avoid 404/MIME errors.');
|
||||
}
|
||||
}).catch(function() {
|
||||
console.warn('Error checking for printing.js; skipping script load.');
|
||||
});
|
||||
} catch (e) {
|
||||
console.warn('Exception while attempting to load printing.js', e);
|
||||
}
|
||||
})();
|
||||
</script>
|
||||
</head>
|
||||
<body>
|
||||
<script src="flutter_bootstrap.js" async></script>
|
||||
|
||||
Reference in New Issue
Block a user