|
@@ -6,7 +6,7 @@
|
|
<span class="text-secondary mx-2">|</span>
|
|
<span class="text-secondary mx-2">|</span>
|
|
<div moe wide>
|
|
<div moe wide>
|
|
<a start show><i class="fa fa-edit"></i> Edit Address</a>
|
|
<a start show><i class="fa fa-edit"></i> Edit Address</a>
|
|
- <form url="/api/client/editAddress" class="mcp-theme-1">
|
|
|
|
|
|
+ <form url="/api/client/editAddress" class="mcp-theme-1" onbeforesubmit="setSettingsMailingAddress">
|
|
<input type="hidden" name="uid" value="{{$patient->uid}}">
|
|
<input type="hidden" name="uid" value="{{$patient->uid}}">
|
|
|
|
|
|
<p class="mb-2 font-weight-bold">Home Address</p>
|
|
<p class="mb-2 font-weight-bold">Home Address</p>
|
|
@@ -35,7 +35,7 @@
|
|
$patient->home_address_state == $patient->mailing_address_state &&
|
|
$patient->home_address_state == $patient->mailing_address_state &&
|
|
$patient->home_address_zip == $patient->mailing_address_zip);
|
|
$patient->home_address_zip == $patient->mailing_address_zip);
|
|
@endphp
|
|
@endphp
|
|
- <input type="checkbox" onchange="copyHomeToMailingAndReadOnly(this.checked)" {{ $isSame ? 'checked' : '' }}>
|
|
|
|
|
|
+ <input type="checkbox" id="settingsSameAsHome" onchange="copyHomeToMailingAndReadOnly(this.checked)" {{ $isSame ? 'checked' : '' }}>
|
|
<span class="ml-2">Same as home addess</span>
|
|
<span class="ml-2">Same as home addess</span>
|
|
</label>
|
|
</label>
|
|
<div class="mb-2">
|
|
<div class="mb-2">
|
|
@@ -211,6 +211,9 @@
|
|
</span>
|
|
</span>
|
|
|
|
|
|
<script>
|
|
<script>
|
|
|
|
+ window.setSettingsMailingAddress = function() {
|
|
|
|
+ copyHomeToMailingAndReadOnly($('#settingsSameAsHome').is(':checked'));
|
|
|
|
+ }
|
|
window.copyHomeToMailingAndReadOnly = function(_same) {
|
|
window.copyHomeToMailingAndReadOnly = function(_same) {
|
|
if(_same) {
|
|
if(_same) {
|
|
$('[name="mailingAddressLine1"]').val($('[name="homeAddressLine1"]').val()).prop('readonly', true);
|
|
$('[name="mailingAddressLine1"]').val($('[name="homeAddressLine1"]').val()).prop('readonly', true);
|