Skip to content

Commit

Permalink
Various changes and fixes (#7424)
Browse files Browse the repository at this point in the history
* Various changes and fixes
- Add Prescriptions and Insurance to hide dashboard items
- Fix recent exception in Crypto styling to error log.

* - add alert if fax view is blocked by braowser.

* - resolve possible JS function naming conflict with address template
  • Loading branch information
sjpadgett committed May 7, 2024
1 parent 6e94bfb commit 6cef758
Show file tree
Hide file tree
Showing 5 changed files with 398 additions and 380 deletions.
12 changes: 10 additions & 2 deletions interface/modules/custom_modules/oe-module-faxsms/messageUI.php
Expand Up @@ -190,7 +190,11 @@ function showDocument(_base64, _contentType = 'image/tiff') {
'width=' + width / 1.75 + ', height=' + height +
', top=' + top + ', left=' + left
);
win.document.write("<iframe width='100%' height='100%' style='border:none;' src='" + dataUrl + "'></iframe>");
if (win === null) {
alert(xl('Please allow popups for this site'));
} else {
win.document.write("<iframe width='100%' height='100%' style='border:none;' src='" + dataUrl + "'></iframe>");
}
}

function viewDocument(e = '', dataUrl) {
Expand All @@ -212,7 +216,11 @@ function viewDocument(e = '', dataUrl) {
'width=' + width / 1.75 + ', height=' + height +
', top=' + top + ', left=' + left
);
win.document.write("<iframe width='100%' height='100%' style='border:none;' src='" + dataUrl + "'></iframe>");
if (win === null) {
alert(xl('Please allow popups for this site'));
} else {
win.document.write("<iframe width='100%' height='100%' style='border:none;' src='" + dataUrl + "'></iframe>");
}
}

function getDocument(e, docuri, docid, downFlag, deleteFlag = '') {
Expand Down
Expand Up @@ -194,21 +194,21 @@
let prevAltPharmacy = <?php echo js_escape($prev_alt_pharmacy); ?>;

if (pid > 0) {
init(prevPrimPharmacy, prevAltPharmacy);
initPharmacyDisplay(prevPrimPharmacy, prevAltPharmacy);
}
//checking if weno_pharmacy div exists initialize select2
let pharmacySelector = document.getElementById("weno_pharmacy");
if (pharmacySelector !== null) {
createWenoPharmacySelect2();
}
//checking if city div div exists and initialize select2
//checking if city div exists and initialize select2
var citySelector = document.getElementById("weno_city");
if (citySelector !== null) {
createWenoCitySelect2();
}
};

function init(prevPrimPharmacy, prevAltPharmacy) {
function initPharmacyDisplay(prevPrimPharmacy, prevAltPharmacy) {
let jsPrim = JSON.parse(prevPrimPharmacy);
let jsAlt = JSON.parse(prevAltPharmacy);

Expand Down

0 comments on commit 6cef758

Please sign in to comment.