forked from openemr/openemr
-
Notifications
You must be signed in to change notification settings - Fork 13
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Feat openemr fix 7480 7494 email prescription (openemr#7495)
* Prep template to be moved to twig * openemr#7480 openemr#7494 email prescriptions This supports sending a prescription as a pdf to an email address, sending the prescription inline as a formatted html email, and sending the prescription in the native mail client using the mailto: protocol. Mailto: doesn't support email attachments so the pdf option currently doesn't work with this. When the Default Mail Client is selected (openemr#7494) then the mailto link is generated and if the browser or operating system has a mailto: protocol handler setup it will launch the registered handler with the subject and email body populated. * Initial refactor to make edit page extensible * Fixes openemr#7496 move erx general edit to twig Made it so the edit prescription dialog is in twig instead of in the old html format. This fixes openemr#7496. I've done some testing but probably need to do more testing to verify we've handled all the use cases. * Form save button position, bug fixes Fixed a bug in the eye base where the window closing wasn't working properly. Moved the prescription action buttons out of the demographics.php file and put them directly into the prescription dialog forms. This helps fix some UX buttons flow issues as well as allows us to move the buttons around as needed in the form. Added a feature to have the form buttons on top of the form or on the bottom. Tried to have an option to show both top and bottom but that fails in demographics. I put the option in the demographics as well as in the prescriptions form. Hopefully other forms will follow suite and allow the customization. * Fix escaping issue. * Not sure how this got left out but it did. * Fixes openemr#7525, openemr#7524 prescription faxing Made it so the prescription pdf faxing button will ask you to continue printing if the signature isn't setup properly (at least to let users know about it). Fixes openemr#7525. Fixed some php8 typecast errors preventing the pdf signature from printing in the print to fax button for prescriptions. openemr#7525. * Switch to promise for erx dialog * Handling variable escaping. * Mark deprecated function
- Loading branch information
Showing
10 changed files
with
1,058 additions
and
635 deletions.
There are no files selected for viewing
Large diffs are not rendered by default.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,37 @@ | ||
<?php | ||
|
||
namespace OpenEMR\Common\Forms; | ||
|
||
class FormActionBarSettings | ||
{ | ||
const ACTION_BAR_DISPLAY_FORM_TOP = '0'; | ||
const ACTION_BAR_DISPLAY_FORM_BOTTOM = '1'; | ||
|
||
// TODO: @adunsulag demographics_full.php does NOT like the TOP_AND_BOTTOM option so going to skip this for now as a valid setting. | ||
const ACTION_BAR_DISPLAY_FORM_TOP_AND_BOTTOM = '2'; | ||
public static function getGlobalSettingsList() | ||
{ | ||
return array( | ||
self::ACTION_BAR_DISPLAY_FORM_TOP => xl('Top of Form (default)') | ||
,self::ACTION_BAR_DISPLAY_FORM_BOTTOM => xl('Bottom of Form') | ||
// ,self::ACTION_BAR_DISPLAY_FORM_TOP_AND_BOTTOM => xl('Top and Bottom of Form') | ||
); | ||
} | ||
|
||
public static function getDefaultSetting() | ||
{ | ||
return self::ACTION_BAR_DISPLAY_FORM_TOP; | ||
} | ||
|
||
public static function shouldDisplayTopActionBar() | ||
{ | ||
// probably could make this more efficient by doing integer position comparisons, but the global values are stored as strings... | ||
return $GLOBALS['form_actionbar_position'] == self::ACTION_BAR_DISPLAY_FORM_TOP | ||
|| $GLOBALS['form_actionbar_position'] == self::ACTION_BAR_DISPLAY_FORM_TOP_AND_BOTTOM; | ||
} | ||
public static function shouldDisplayBottomActionBar() | ||
{ | ||
return $GLOBALS['form_actionbar_position'] == self::ACTION_BAR_DISPLAY_FORM_BOTTOM | ||
|| $GLOBALS['form_actionbar_position'] == self::ACTION_BAR_DISPLAY_FORM_TOP_AND_BOTTOM; | ||
} | ||
} |
Oops, something went wrong.