Selaa lähdekoodia

Merge branch 'dev' of rav.triplestart.com:jmudaka/stagfe2 into dev

= 3 vuotta sitten
vanhempi
commit
b557443e7b
28 muutettua tiedostoa jossa 689 lisäystä ja 92 poistoa
  1. 3 0
      public/css/style.css
  2. 2 1
      resources/views/app/admin/patients-table-extended.blade.php
  3. 1 1
      resources/views/app/patient/allergies-center.blade.php
  4. 13 7
      resources/views/app/patient/care-month/dashboard.blade.php
  5. 1 1
      resources/views/app/patient/careteam-center.blade.php
  6. 12 12
      resources/views/app/patient/dashboard.blade.php
  7. 1 1
      resources/views/app/patient/goals-center.blade.php
  8. 1 1
      resources/views/app/patient/medications-center.blade.php
  9. 103 0
      resources/views/app/patient/note/dashboard.blade.php
  10. 8 1
      resources/views/app/patient/note/segment/suggestions_and_updates.blade.php
  11. 1 1
      resources/views/app/patient/partials/measurements.blade.php
  12. 2 2
      resources/views/app/patient/point-based-partials/fhx.blade.php
  13. 2 2
      resources/views/app/patient/point-based-partials/pmhx.blade.php
  14. 2 2
      resources/views/app/patient/point-based-partials/shx.blade.php
  15. 2 2
      resources/views/app/patient/point-based-partials/sochx.blade.php
  16. 1 1
      resources/views/app/patient/point-based-partials/supplements.blade.php
  17. 100 0
      resources/views/app/patient/segment-templates/omega_history_family/summary-dashboard.blade.php
  18. 159 0
      resources/views/app/patient/segment-templates/omega_history_past_medical/summary-dashboard.blade.php
  19. 97 0
      resources/views/app/patient/segment-templates/omega_history_social/summary-dashboard.blade.php
  20. 91 0
      resources/views/app/patient/segment-templates/omega_history_surgical/summary-dashboard.blade.php
  21. 1 1
      resources/views/app/patient/supplements-center.blade.php
  22. 5 0
      resources/views/app/patient/tickets.blade.php
  23. 1 1
      resources/views/app/practice-management/remote-monitoring-row-markup-by-pro-type.blade.php
  24. 2 4
      resources/views/app/practice-management/rpm-matrix-by-pro-type.blade.php
  25. 2 1
      resources/views/app/practice-management/visit-templates/single.blade.php
  26. 17 0
      resources/views/app/practice-management/visit-templates/toggle-always-open.blade.php
  27. 2 2
      resources/views/layouts/patient.blade.php
  28. 57 48
      resources/views/layouts/template.blade.php

+ 3 - 0
public/css/style.css

@@ -41,6 +41,9 @@
 .w-70 {
   width: var(--w-70);
 }
+.text-warning-dark {
+    color: #856404!important;
+}
 .text-warning-mellow {
     color: #d8a714!important;
 }

+ 2 - 1
resources/views/app/admin/patients-table-extended.blade.php

@@ -332,8 +332,9 @@
 
     </table>
 </div>
-<div class="px-3 pt-3">
+<div class="px-3 pt-3 d-flex align-items-center">
     {{$patients->withQueryString()->links()}}
+    <div class="ml-4 mb-3">Showing <b>{{$patients->firstItem()}}</b> to <b>{{$patients->lastItem()}}</b> (page {{$patients->currentPage()}}) of <b>{{$patients->total()}}</b> patients</div>
 </div>
 
 <script>

+ 1 - 1
resources/views/app/patient/allergies-center.blade.php

@@ -60,7 +60,7 @@ if(!@$summaryView) {
             <thead>
             <tr class="">
                 @if($patient->core_note_id !== $note->id)
-                    <th class="border-bottom-0 text-secondary text-center width-30px">Rel.</th>
+                    <th class="border-bottom-0 text-secondary text-center width-30px text-nowrap">Rel.</th>
                 @endif
                 <th class="border-bottom-0 text-secondary">Name</th>
                 <th class="border-bottom-0 text-secondary w-30">Subjective</th>

+ 13 - 7
resources/views/app/patient/care-month/dashboard.blade.php

@@ -260,9 +260,15 @@
                                     @endif
                                 </div>
                                 @if($careMonth->showMeasurementDaysWarning())
-                                    <div class="alert alert-warning p-2 mt-1">
-                                        Need <b>{{16 - $careMonth->number_of_days_with_remote_measurements}} more days</b> with measurements before RM becomes billable.
-                                    </div>
+                                    <?php
+                                    $moreDays = 16 - $careMonth->number_of_days_with_remote_measurements;
+                                    if($moreDays < 0) $moreDays = 0;
+                                    ?>
+                                    @if($moreDays > 0)
+                                        <div class="alert alert-warning p-2 mt-1">
+                                            Need <b>{{$moreDays}} more day{{$moreDays !== 1 ? 's' : ''}}</b> with measurements before RM becomes billable.
+                                        </div>
+                                    @endif
                                 @endif
 
                                 <div class="mt-2">
@@ -336,13 +342,13 @@
                                 </div>
                                 @endif
 
-                                @if(($daysDiff !== -1 && $daysDiff <= 90) && 
+                                {{--@if(($daysDiff !== -1 && $daysDiff <= 90) &&
                                     $careMonth->number_of_days_with_remote_measurements >= 16 &&
                                     $careMonth->has_mcp_interacted_with_client_about_rm)
                                     <div class="mt-2 border border-info p-2">
                                         @include('app.rm-bills.inline', ['patient' => $patient, 'entityType' => 'CareMonth', 'entityUid' => $careMonth->uid, 'label' => 'RM'])
                                     </div>
-                                @endif
+                                @endif--}}
 
                                 <div class="mt-2">
                                     {{-- rm reasons --}}
@@ -1824,10 +1830,10 @@
 
         <hr class="m-negator my-3">
 
-        {{-- generic bills --}}
+        {{-- generic bills --}}{{--
         <div class="row">
             @include('app.generic-bills.inline', ['patient' => $patient, 'class' => 'col-12', 'entityType' => 'CareMonth', 'entityUid' => $careMonth->uid])
-        </div>
+        </div>--}}
 
     </div>
 

+ 1 - 1
resources/views/app/patient/careteam-center.blade.php

@@ -21,7 +21,7 @@ if(!@$careTeamMembers || !@$counts) {
             <thead>
             <tr class="">
                 @if($patient->core_note_id !== $note->id)
-                    <th class="border-bottom-0 text-secondary text-center width-30px">Rel.</th>
+                    <th class="border-bottom-0 text-secondary text-center width-30px text-nowrap">Rel.</th>
                 @endif
                 <th class="border-bottom-0 text-secondary">Name/Details</th>
                 <th class="border-bottom-0 text-secondary w-30">Subjective</th>

+ 12 - 12
resources/views/app/patient/dashboard.blade.php

@@ -49,7 +49,7 @@
                 @if($isOldClient && $hasAllergiesInCanvas)
                 <div class="pt-2 mt-2 border-top">
                     <div class="d-flex align-items-center pb-2">
-                        <h6 class="my-0 font-weight-bold text-secondary">Allergies</h6>
+                        <h6 class="my-0 font-weight-bold">Allergies</h6>
                         <div class="px-2 font-weight-bold alert alert-warning text-sm my-0 ml-2 py-1">Deprecated</div>
                     </div>
                     <div class="bg-light border p-2 mb-3">
@@ -67,7 +67,7 @@
                 @if($isOldClient && $hasRxInCanvas)
                 <div class="pt-2 mt-2 border-top">
                     <div class="d-flex align-items-center pb-2">
-                        <h6 class="my-0 font-weight-bold text-secondary">Current Medications</h6>
+                        <h6 class="my-0 font-weight-bold">Current Medications</h6>
                         <div class="px-2 font-weight-bold alert alert-warning text-sm my-0 ml-2 py-1">Deprecated</div>
                     </div>
                     <div class="bg-light border p-2 mb-3">
@@ -89,7 +89,7 @@
                 ?>
                 <div class="mt-2 pb-1" id="patient-dashboard-devices">
                     <div class="d-flex align-items-center mb-2 py-2 border-top border-bottom">
-                        <h6 class="my-0 font-weight-bold text-secondary">Devices</h6>
+                        <h6 class="my-0 font-weight-bold">Devices</h6>
                         @if($availableDevices > 0 && $pro->pro_type === 'ADMIN')
                         <span class="mx-2 text-secondary">|</span>
                         <span moe>
@@ -206,7 +206,7 @@
                 @if($isOldClient && $hasVitalsInCanvas)
                 <div class="pt-2 border-top">
                     <div class="d-flex align-items-center pb-2">
-                        <h6 class="my-0 font-weight-bold text-secondary">Vitals</h6>
+                        <h6 class="my-0 font-weight-bold">Vitals</h6>
                         <div class="px-2 font-weight-bold alert alert-warning text-sm my-0 ml-2 py-1">Deprecated</div>
                     </div>
                     <div class="bg-light border p-2 mb-3">
@@ -219,7 +219,7 @@
                 <?php $latestVitals = \App\Models\Point::where('client_id', $patient->id)->where('category', 'VITALS')->orderBy('id', 'DESC')->first(); ?>
                 <div class="pt-2 mt-2">
                     <div class="d-flex align-items-center pb-2">
-                        <h6 class="my-0 font-weight-bold text-secondary">Vitals
+                        <h6 class="my-0 font-weight-bold">Vitals
                             @if(!!$latestVitals && $latestVitals->note && $latestVitals->note->effective_dateest)
                                 <span class="text-secondary font-weight-normal pl-1">(as on
                                     <a href="{{route('patients.view.notes.view.dashboard', ['patient' => $patient, 'note' => $latestVitals->note])}}">{{friendlier_date($latestVitals->note->effective_dateest)}}</a>)
@@ -248,7 +248,7 @@
                 @if($isOldClient)
                     <div class="pt-2 mb-2 border-top">
                         <div class="d-flex align-items-center pb-2">
-                            <h6 class="my-0 font-weight-bold text-secondary">Current Problems / Focus Areas</h6>
+                            <h6 class="my-0 font-weight-bold">Current Problems / Focus Areas</h6>
                             <div class="px-2 font-weight-bold alert alert-warning text-sm my-0 ml-2 py-1">Deprecated</div>
                         </div>
                         <div class="bg-light border p-2 mb-3">
@@ -266,7 +266,7 @@
                 @if($isOldClient && $hasCareTeamInCanvas)
                     <div class="pt-2 mt-2 border-top">
                         <div class="d-flex align-items-center pb-2">
-                            <h6 class="my-0 font-weight-bold text-secondary">Care Team</h6>
+                            <h6 class="my-0 font-weight-bold">Care Team</h6>
                             <div class="px-2 font-weight-bold alert alert-warning text-sm my-0 ml-2 py-1">Deprecated</div>
                         </div>
                         <div class="bg-light border p-2 mb-3">
@@ -284,7 +284,7 @@
                 @if($isOldClient && $hasPmhxInCanvas)
                 <div class="pt-2 mt-2 border-top">
                     <div class="d-flex align-items-center pb-2">
-                        <h6 class="my-0 font-weight-bold text-secondary">Medical History</h6>
+                        <h6 class="my-0 font-weight-bold">Medical History</h6>
                         <div class="px-2 font-weight-bold alert alert-warning text-sm my-0 ml-2 py-1">Deprecated</div>
                     </div>
                     <div class="bg-light border p-2 mb-3">
@@ -302,7 +302,7 @@
                 @if($isOldClient && $hasPshxInCanvas)
                 <div class="mt-2 border-top pt-2">
                     <div class="d-flex align-items-center pb-2">
-                        <h6 class="my-0 font-weight-bold text-secondary">Surgical History</h6>
+                        <h6 class="my-0 font-weight-bold">Surgical History</h6>
                         <div class="px-2 font-weight-bold alert alert-warning text-sm my-0 ml-2 py-1">Deprecated</div>
                     </div>
                     <div class="bg-light border p-2 mb-3">
@@ -320,7 +320,7 @@
                 @if($isOldClient && $hasFhxInCanvas)
                 <div class="mt-2 border-top pt-2">
                     <div class="d-flex align-items-center pb-2">
-                        <h6 class="my-0 font-weight-bold text-secondary">Family History</h6>
+                        <h6 class="my-0 font-weight-bold">Family History</h6>
                         <div class="px-2 font-weight-bold alert alert-warning text-sm my-0 ml-2 py-1">Deprecated</div>
                     </div>
                     <div class="bg-light border p-2 mb-3">
@@ -338,7 +338,7 @@
                 @if($isOldClient && $hasSochxInCanvas)
                 <div class="mt-2 border-top pt-2">
                     <div class="d-flex align-items-center pb-2">
-                        <h6 class="my-0 font-weight-bold text-secondary">Social History</h6>
+                        <h6 class="my-0 font-weight-bold">Social History</h6>
                         <div class="px-2 font-weight-bold alert alert-warning text-sm my-0 ml-2 py-1">Deprecated</div>
                     </div>
                     <div class="bg-light border p-2 mb-3">
@@ -530,7 +530,7 @@
                 <div  class="mb-2 pt-3 pb-2 border-top">
                     <div class="">
                         <div class="d-flex align-items-start pb-2">
-                            <h6 class="my-0 font-weight-bold text-secondary">Client Memos</h6>
+                            <h6 class="my-0 font-weight-bold">Client Memos</h6>
                         </div>
                         <div moe class="w-100 p-2 border mb-3">
                             <form url="/api/clientMemo/create" show>

+ 1 - 1
resources/views/app/patient/goals-center.blade.php

@@ -21,7 +21,7 @@ if(!@$goals || !@$counts) {
             <thead>
             <tr class="">
                 @if($patient->core_note_id !== $note->id)
-                    <th class="border-bottom-0 text-secondary text-center width-30px">Rel.</th>
+                    <th class="border-bottom-0 text-secondary text-center width-30px text-nowrap">Rel.</th>
                 @endif
                 <th class="border-bottom-0 text-secondary">Goal</th>
                 <th class="border-bottom-0 text-secondary w-30">Subjective</th>

+ 1 - 1
resources/views/app/patient/medications-center.blade.php

@@ -50,7 +50,7 @@ if(!@$summaryView) {
             <thead>
             <tr class="">
                 @if($patient->core_note_id !== $note->id)
-                    <th class="border-bottom-0 text-secondary text-center width-30px">Rel.</th>
+                    <th class="border-bottom-0 text-secondary text-center width-30px text-nowrap">Rel.</th>
                 @endif
                 <th class="border-bottom-0 text-secondary">Name</th>
                 <th class="border-bottom-0 text-secondary w-30">Subj. Frequency / Experience</th>

+ 103 - 0
resources/views/app/patient/note/dashboard.blade.php

@@ -768,6 +768,109 @@ use App\Models\Handout;
                         ?>
                         <div class="{{ $note->is_signed_by_hcp ? 'note-signed-by-hcp' : '' }} {{$hasRightSegments ? 'w-30 border-right note-left-panel stag-scrollbar' : ''}}">
                             <div class="min-width-300px stag-scrollbar">
+                                <?php $isOldClient = (date_diff(date_create(config('app.point_impl_date')), date_create($patient->created_at))->invert === 1); ?>
+                                @if($isOldClient)
+                                    <div class="p-2 bg-light border-bottom">
+                                        <div class="d-flex align-items-baseline">
+                                            <div class="font-weight-bold font-size-14 text-warning-dark">
+                                                <i class="fa fa-clock text-secondary text-sm"></i>
+                                                Data from old notes
+                                            </div>
+                                            <a href="#" class="ml-3" onclick="$(this).parent().next().toggleClass('d-none'); return false;">Toggle</a>
+                                        </div>
+                                        <div class="mt-3 ml-3 d-none">
+                                            <?php $hasAllergiesInCanvas = $patient->hasDataInCanvas('allergies'); ?>
+                                            @if($hasAllergiesInCanvas)
+                                                <div class="uucol-4">
+                                                    <div class="d-flex align-items-center pb-2">
+                                                        <h6 class="my-0 font-weight-bold text-secondary">Allergies</h6>
+                                                    </div>
+                                                    <div class="bg-light border p-2 mb-3">
+                                                        @include('app.patient.canvas-sections.allergies.summary')
+                                                    </div>
+                                                </div>
+                                            @endif
+                                            <?php $hasRxInCanvas = $patient->hasDataInCanvas('rx'); ?>
+                                            @if($hasRxInCanvas)
+                                                <div class="uucol-4">
+                                                    <div class="d-flex align-items-center pb-2">
+                                                        <h6 class="my-0 font-weight-bold text-secondary">Current Medications</h6>
+                                                    </div>
+                                                    <div class="bg-light border p-2 mb-3">
+                                                        @include('app.patient.canvas-sections.rx.summary')
+                                                    </div>
+                                                </div>
+                                            @endif
+                                            <?php $hasDxInCanvas = $patient->hasDataInCanvas('dx'); ?>
+                                            @if($hasDxInCanvas)
+                                                <div class="uucol-4">
+                                                    <div class="d-flex align-items-center pb-2">
+                                                        <h6 class="my-0 font-weight-bold text-secondary">Current Problems / Focus Areas</h6>
+                                                    </div>
+                                                    <div class="bg-light border p-2 mb-3">
+                                                        @include('app.patient.canvas-sections.dx.summary')
+                                                    </div>
+                                                </div>
+                                            @endif
+                                            <?php $hasCareTeamInCanvas = $patient->hasDataInCanvas('care-team'); ?>
+                                            @if($hasCareTeamInCanvas)
+                                                <div class="uucol-4">
+                                                    <div class="d-flex align-items-center pb-2">
+                                                        <h6 class="my-0 font-weight-bold text-secondary">Care Team</h6>
+                                                    </div>
+                                                    <div class="bg-light border p-2 mb-3">
+                                                        @include('app.patient.canvas-sections.care-team.summary')
+                                                    </div>
+                                                </div>
+                                            @endif
+                                            <?php $hasPmhxInCanvas = $patient->hasDataInCanvas('pmhx'); ?>
+                                            @if($hasPmhxInCanvas)
+                                                <div class="uucol-4">
+                                                    <div class="d-flex align-items-center pb-2">
+                                                        <h6 class="my-0 font-weight-bold text-secondary">Medical History</h6>
+                                                    </div>
+                                                    <div class="bg-light border p-2 mb-3">
+                                                        @include('app.patient.canvas-sections.pmhx.summary')
+                                                    </div>
+                                                </div>
+                                            @endif
+                                            <?php $hasPshxInCanvas = $patient->hasDataInCanvas('pshx'); ?>
+                                            @if($hasPshxInCanvas)
+                                                <div class="mt-2 border-top pt-2">
+                                                    <div class="d-flex align-items-center pb-2">
+                                                        <h6 class="my-0 font-weight-bold text-secondary">Surgical History</h6>
+                                                    </div>
+                                                    <div class="bg-light border p-2 mb-3">
+                                                        @include('app.patient.canvas-sections.pshx.summary')
+                                                    </div>
+                                                </div>
+                                            @endif
+                                            <?php $hasFhxInCanvas = $patient->hasDataInCanvas('fhx'); ?>
+                                            @if($hasFhxInCanvas)
+                                                <div class="uucol-4">
+                                                    <div class="d-flex align-items-center pb-2">
+                                                        <h6 class="my-0 font-weight-bold text-secondary">Family History</h6>
+                                                    </div>
+                                                    <div class="bg-light border p-2 mb-3">
+                                                        @include('app.patient.canvas-sections.fhx.summary')
+                                                    </div>
+                                                </div>
+                                            @endif
+                                            <?php $hasSochxInCanvas = $patient->hasDataInCanvas('sochx'); ?>
+                                            @if($hasSochxInCanvas)
+                                                <div class="uucol-4">
+                                                    <div class="d-flex align-items-center pb-2">
+                                                        <h6 class="my-0 font-weight-bold text-secondary">Social History</h6>
+                                                    </div>
+                                                    <div class="bg-light border p-2 mb-3">
+                                                        @include('app.patient.canvas-sections.sochx.summary')
+                                                    </div>
+                                                </div>
+                                            @endif
+                                        </div>
+                                    </div>
+                                @endif
+
                                 @if($isVisitTemplateBased && $doesVisitTemplateLayoutExist)
                                     @include($visitLayoutPath)
                                 @elseif($isVisitTemplateBased && !$doesVisitTemplateUiConfigExist)

+ 8 - 1
resources/views/app/patient/note/segment/suggestions_and_updates.blade.php

@@ -44,7 +44,14 @@
 </div>
 @if($segment->proposedSegmentSummarySuggestion && ($segment->proposedSegmentSummarySuggestion->status == 'PENDING' || $segment->proposedSegmentSummarySuggestion->status == 'REJECTED') )
     <div class=" m-2 p-2">
-        {!! $segment->proposedSegmentSummarySuggestion->summary_html !!}
+        <div class="d-flex align-items-start mb-2">
+            <b class="mr-2 width-70px">Original:</b>
+            <div class="border py-2 px-2 flex-grow-1 inline-html-container">{!! $segment->summary_html !!}</div>
+        </div>
+        <div class="d-flex align-items-start mb-2">
+            <b class="mr-2 width-70px">Proposed:</b>
+            <div class="border border-info py-2 px-2 flex-grow-1 inline-html-container">{!! $segment->proposedSegmentSummarySuggestion->summary_html !!}</div>
+        </div>
         @if($segment->proposedSegmentSummarySuggestion->status == 'REJECTED')
         <div class="alert alert-info">Your suggestion has been rejected.</div>
         @endif

+ 1 - 1
resources/views/app/patient/partials/measurements.blade.php

@@ -1,6 +1,6 @@
 <div class="mt-2 mb-3" id="patient-dashboard-measurements">
     <div class="d-flex align-items-center mb-2 py-2 border-top border-bottom">
-        <h6 class="my-0 font-weight-bold text-secondary">Measurements</h6>
+        <h6 class="my-0 font-weight-bold">Measurements</h6>
         <span class="mx-2 text-secondary">|</span>
         <a start show class="py-0 font-weight-normal"
            href="/patients/view/{{ $patient->uid }}/measurements">

+ 2 - 2
resources/views/app/patient/point-based-partials/fhx.blade.php

@@ -1,6 +1,6 @@
 <div class="pt-2 mt-2">
     <div class="d-flex align-items-center pb-2">
-        <h6 class="my-0 font-weight-bold text-secondary">Family History</h6>
+        <h6 class="my-0 font-weight-bold">Family History</h6>
         @if($isOldClient && @$hasFhxInCanvas)
             <div class="px-2 font-weight-bold alert alert-info text-sm my-0 ml-2 py-1">New</div>
         @endif
@@ -20,7 +20,7 @@
         @endif
     </div>
     <div class="bg-light border p-2 mb-3 point-content">
-        @include('app.patient.segment-templates.history_family.summary', compact('patient'))
+        @include('app.patient.segment-templates.omega_history_family.summary-dashboard', ['patient' => $patient, 'note' => $patient->coreNote])
     </div>
 </div>
 <script>

+ 2 - 2
resources/views/app/patient/point-based-partials/pmhx.blade.php

@@ -1,6 +1,6 @@
 <div class="pt-2 mt-2">
     <div class="d-flex align-items-center pb-2">
-        <h6 class="my-0 font-weight-bold text-secondary">Medical History</h6>
+        <h6 class="my-0 font-weight-bold">Medical History</h6>
         @if($isOldClient && @$hasPmhxInCanvas)
             <div class="px-2 font-weight-bold alert alert-info text-sm my-0 ml-2 py-1">New</div>
         @endif
@@ -20,7 +20,7 @@
         @endif
     </div>
     <div class="bg-light border p-2 mb-3 point-content">
-        @include('app.patient.segment-templates.past_medical_history.summary', compact('patient'))
+        @include('app.patient.segment-templates.omega_history_past_medical.summary-dashboard', ['patient' => $patient, 'note' => $patient->coreNote])
     </div>
 </div>
 <script>

+ 2 - 2
resources/views/app/patient/point-based-partials/shx.blade.php

@@ -1,6 +1,6 @@
 <div class="pt-2 mt-2">
     <div class="d-flex align-items-center pb-2">
-        <h6 class="my-0 font-weight-bold text-secondary">Surgical History</h6>
+        <h6 class="my-0 font-weight-bold">Surgical History</h6>
         @if($isOldClient && @$hasPshxInCanvas)
             <div class="px-2 font-weight-bold alert alert-info text-sm my-0 ml-2 py-1">New</div>
         @endif
@@ -20,7 +20,7 @@
         @endif
     </div>
     <div class="bg-light border p-2 mb-3 point-content">
-        @include('app.patient.segment-templates.history_surgical.summary', compact('patient'))
+        @include('app.patient.segment-templates.omega_history_surgical.summary-dashboard', ['patient' => $patient, 'note' => $patient->coreNote])
     </div>
 </div>
 <script>

+ 2 - 2
resources/views/app/patient/point-based-partials/sochx.blade.php

@@ -1,6 +1,6 @@
 <div class="pt-2 mt-2">
     <div class="d-flex align-items-center pb-2">
-        <h6 class="my-0 font-weight-bold text-secondary">Social History</h6>
+        <h6 class="my-0 font-weight-bold">Social History</h6>
         @if($isOldClient && @$hasSochxInCanvas)
             <div class="px-2 font-weight-bold alert alert-info text-sm my-0 ml-2 py-1">New</div>
         @endif
@@ -20,7 +20,7 @@
         @endif
     </div>
     <div class="bg-light border p-2 mb-3 point-content">
-        @include('app.patient.segment-templates.history_social.summary', compact('patient'))
+        @include('app.patient.segment-templates.omega_history_social.summary-dashboard', ['patient' => $patient, 'note' => $patient->coreNote])
     </div>
 </div>
 <script>

+ 1 - 1
resources/views/app/patient/point-based-partials/supplements.blade.php

@@ -3,7 +3,7 @@ $supplements = \App\Models\Point::getPointsOfCategory($patient, "SUPPLEMENT");
 ?>
 <div class="pt-2 mt-2">
     <div class="d-flex align-items-center pb-2">
-        <h6 class="my-0 font-weight-bold text-secondary">Current Supplements</h6>
+        <h6 class="my-0 font-weight-bold">Current Supplements</h6>
         @if($patient->coreNote)
             @if(!@$disallowPointEdits)
             <a native target="_blank"

+ 100 - 0
resources/views/app/patient/segment-templates/omega_history_family/summary-dashboard.blade.php

@@ -0,0 +1,100 @@
+<?php
+
+use App\Models\Client;
+use App\Models\Point;
+use App\Models\Note;
+/** @var Client $patient */
+/** @var Note $note */
+
+if(!@$note) {
+    $note = $patient->coreNote;
+}
+if(!@$sessionKey) {
+    $sessionKey = request()->cookie('sessionKey');
+}
+
+$point = Point::getOrCreateOnlyTopLevelPointOfCategory($note, 'FAMILY_HISTORY', $sessionKey, true);
+
+$contentData = $parsed = false;
+
+$rel = !!$point->relevanceToNote($note);
+
+if ($point->lastChildReview && $point->lastChildReview->data) {
+    $point->lastChildReview->data = json_decode($point->lastChildReview->data, true);
+    $contentData = $parsed = $point->lastChildReview->data;
+}
+
+$labels = [
+    'general_no_health_concern' => 'No health concern',
+    'general_arthritis' => 'Arthritis',
+    'general_asthma' => 'Asthma',
+    'general_bleeding_disorder' => 'Bleeding disorder',
+    'general_cad_lt_age_55' => 'CAD &gt; age 55',
+    'general_copd' => 'COPD',
+    'general_diabetes' => 'Diabetes',
+    'general_heart_attack' => 'Heart attack',
+    'general_heart_disease' => 'Heart disease',
+    'general_high_cholesterol' => 'High cholesterol',
+    'general_hypertension' => 'Hypertension',
+    'general_mental_illness' => 'Mental illness',
+    'general_osteoporosis' => 'Osteoporosis',
+    'general_stroke' => 'Stroke',
+    'cancer_breast_ca' => 'Breast cancer',
+    'cancer_colon_ca' => 'Colon cancer',
+    'cancer_other_ca' => 'Other cancer',
+    'cancer_ovarian_ca' => 'Ovarian cancer',
+    'cancer_uterine_ca' => 'Uterine cancer',
+];
+
+if($contentData && !@$contentData['unknown'] && !!$contentData['count']) {
+    for ($i = 0; $i < $contentData['count']; $i++) {
+?>
+<div class="<?= $i > 0 ? 'mt-2' : '' ?>">
+    <div class="">
+        <b><?= isset($contentData['items'][$i]['relationship']) ? $contentData['items'][$i]['relationship'] : '--' ?></b>
+        <?php if(isset($contentData['items'][$i]['status']) && !empty($contentData['items'][$i]['status'])): ?>
+        <span class="ml-1 text-secondary">(<?= $contentData['items'][$i]['status'] ?>)</span>
+        <?php endif; ?>
+    </div>
+    <div class="ml-3">
+        <?php
+        $positives = [];
+        $negatives = [];
+        foreach ($labels as $k => $v) {
+            if(isset($contentData['items'][$i][$k])) {
+                if(strtolower($contentData['items'][$i][$k]) === 'yes') {
+                    $positives[] = $v;
+                }
+                else {
+                    $negatives[] = $v;
+                }
+            }
+        }
+        ?>
+        @if(count($positives))
+            <div class=""><b>Positive for</b>: {!!  implode(', ', $positives) !!}</div>
+        @endif
+        @if(count($negatives))
+            <div class=""><b>Negative for</b>: {!!  implode(', ', $negatives) !!}</div>
+        @endif
+    </div>
+    <?php if(isset($contentData['items'][$i]['comments']) && !empty($contentData['items'][$i]['comments'])): ?>
+    <div class="ml-3 pt-1 client-rs-contents">
+        <b>Comments: </b><?= $contentData['items'][$i]['comments'] ?>
+    </div>
+    <?php endif; ?>
+</div>
+<?php
+    }
+}
+else if(@$contentData['unknown']) {
+    ?>
+    <div class="text-secondary">Family history is unknown/unavailable</div>
+    <?php
+}
+else {
+?>
+<div class="text-secondary">-</div>
+<?php
+}
+?>

+ 159 - 0
resources/views/app/patient/segment-templates/omega_history_past_medical/summary-dashboard.blade.php

@@ -0,0 +1,159 @@
+<?php
+
+use App\Models\Client;
+use App\Models\Point;
+use App\Models\Note;
+/** @var Client $patient */
+/** @var Note $note */
+
+if(!@$note) {
+    $note = $patient->coreNote;
+}
+
+$fields = [
+    [
+        "Head" => ["Trauma"],
+        "Eyes" => ["Blindness", "Cataracts", "Glaucoma", "Wears glasses/contacts"],
+        "Ears" => ["Hearing aids"],
+        "Nose/Sinuses" => ["Allergic Rhinitis", "Sinus infections"],
+        "Mouth/Throat/Teeth" => ["Dentures"],
+        "Cardiovascular" => ["Aneurysm", "Angina", "DVT", "Dysrhythmia", "HTN", "Murmur", "Myocardial infarction", "Other heart disease"],
+    ],
+    [
+        "Respiratory" => ["Asthma", "Bronchitis", "COPD - Bronchitis/Emphysema", "Pleuritis", "Pneumonia"],
+        "Gastrointestinal" => ["Cirrhosis", "GERD", "Gallbladder disease", "Heartburn", "Hemorrhoids", "Hepatitis", "Hiatal hernia", "Jaundice", "Ulcer"],
+        "Genitourinary" => ["Hernia", "Incontinence", "Nephrolithiasis", "Other kidney disease", "STDs", "UTI(s)"],
+    ],
+    [
+        "Musculoskeletal" => ["Arthritis", "Gout", "M/S injury"],
+        "Skin" => ["Dermatitis", "Mole(s)", "Other skin condition(s)", "Psoriasis"],
+        "Neurological" => ["Epilepsy", "Seizures", "Severe headaches, migraines", "Stroke", "TIA"],
+        "Psychiatric" => ["Bipolar disorder", "Depression", "Hallucinations, delusions", "Suicidal ideation", "Suicide attempts"],
+    ],
+    [
+        "Endocrine" => ["Goiter", "Hyperlipidemia", "Hypothyroidism", "Thyroid disease", "Thyroiditis", "Type I DM", "Type II DM"],
+        "Heme/Onc" => ["Anemia", "Cancer"],
+        "Infectious" => ["HIV", "STDs", "Tuberculosis (dz)", "Tuberculosis (exposure)"],
+    ]
+];
+
+$contentData = [
+    "bloodType" => "",
+    "bloodRH" => "",
+    "common" => [],
+    "customFields" => [],
+    "comments" => "",
+];
+$isempty = false;
+
+if(!@$sessionKey) {
+    $sessionKey = request()->cookie('sessionKey');
+}
+
+$point = Point::getOrCreateOnlyTopLevelPointOfCategory($note, 'PAST_MEDICAL_HISTORY', $sessionKey, true);
+
+$contentData = $parsed = false;
+
+$rel = !!$point->relevanceToNote($note);
+
+if ($point->lastChildReview && $point->lastChildReview->data) {
+    $point->lastChildReview->data = json_decode($point->lastChildReview->data, true);
+    $contentData = $parsed = $point->lastChildReview->data;
+}
+
+if ($contentData) {
+
+    $blood = [];
+    if(isset($contentData['bloodType'])) {
+        $blood[] = $contentData['bloodType'];
+    }
+    if(isset($contentData['bloodRH'])) {
+        $blood[] = $contentData['bloodRH'];
+    }
+    $blood = implode(" ", $blood);
+    if(!empty(trim($blood))) { ?>
+        <div class="mb-2">
+            <div><b>Blood Type &amp; RH: </b><?= $blood ?></div>
+        </div>
+    <?php }
+
+	$commonMap = [];
+
+    for ($i = 0; $i < count($fields); $i++):
+        foreach($fields[$i] as $head => $values):
+            for($k = 0; $k < count($values); $k++):
+		        $value = $values[$k];
+                $fName = $head . '_' . sanitize_field_name($values[$k]);
+                if(@$contentData['common'][$fName]) {
+                    if(!isset($commonMap[$head])) {
+                        $commonMap[$head] = [];
+                    }
+                    $commonMap[$head][] = ['value' => $value, 'fName' => $fName, 'comments' => @$contentData['common'][$fName.'__comments']];
+                ?>
+                    <div class="d-none">
+                        <?= ucwords($head) ?>
+                        <i class="fa fa-arrow-right text-sm text-secondary"></i>
+                        <span class="font-weight-bold"><?= $values[$k] ?></span>
+                        <?php if(@$contentData['common'][$fName . '__comments']): ?>
+                            <span class="text-sm ml-1 text-secondary">(<?= $contentData['common'][$fName . '__comments'] ?>)</span>
+                        <?php endif; ?>
+                    </div>
+                <?php
+                }
+            endfor;
+        endforeach;
+    endfor;
+
+	// var_dump(json_encode($commonMap));
+	?> <div> <?php
+	foreach($commonMap as $head => $set):
+		?>
+		<div>
+			<span class="font-weight-bold"><?= ucwords($head) ?></span>
+			<i class="fa fa-arrow-right text-secondary d-none_"></i>
+			<span class="">
+			<?php $out = []; foreach($set as $item) { $out[] = '<span class="__font-weight-bold">' . $item['value'] . '</span>' . ($item['comments'] ? ('<span class="text-sm ml-1 text-secondary">(' . $item['comments'] . ')</span>') : ''); } if(!empty($out)) echo ' • '; echo implode(' • ', $out); ?>
+			</span>
+		</div>
+		<?php
+	endforeach;
+	?>
+
+	<?php
+
+    // custom fields
+
+    if(isset($contentData['customFields']) && count($contentData['customFields'])):
+        ?> <div class=""> <?php
+        for ($i = 0; $i < count($contentData['customFields']); $i++):
+            $item = $contentData['customFields'][$i];
+            if($item['value']): ?>
+                <span>
+                    <span class="font-weight-bold">Other: </span>
+		            <i class="fa fa-arrow-right d-none"></i>
+                </span>
+                <span>
+                    <span class="__font-weight-bold"><?= $item['label'] ?></span>
+                    <?php if($item['comments']): ?>
+                        <span class="text-sm ml-1 text-secondary">(<?= $item['comments'] ?>)</span>
+                    <?php endif; ?>
+                </span>
+            <?php
+            endif;
+        endfor;
+        ?> </div> <?php
+    endif;
+
+	echo '</div>';
+
+    if(isset($contentData['comments']) && !empty(trim($contentData['comments']))) { ?>
+        <div class="mt-2 mb-1">
+            <b>Comments: </b><?= $contentData['comments'] ?>
+        </div>
+    <?php }
+
+} else {
+    echo '<div class="text-secondary">-</div>';
+}
+?>
+

+ 97 - 0
resources/views/app/patient/segment-templates/omega_history_social/summary-dashboard.blade.php

@@ -0,0 +1,97 @@
+<?php
+
+use App\Models\Client;
+use App\Models\Point;
+use App\Models\Note;
+/** @var Client $patient */
+/** @var Note $note */
+/** @var Segment $segment */
+
+$fields = [
+    [
+        "Tobacco" => ["Current every day smoker", "Current some day smoker", "Former smoker", "Heavy tobacco smoker", "Light tobacco smoker", "Never smoker", "Smoker, current status unknown", "Unknown if ever smoked "],
+    ],
+    [
+        "Alcohol" => ["Do not drink", "Drink daily", "Frequently drink", "Hx of Alcoholism", "Occasional drink"],
+        "Drug Abuse" => ["IVDU", "Illicit drug use", "No illicit drug use"],
+    ],
+    [
+        "Cardiovascular" => ["Eat healthy meals", "Regular exercise", "Take daily aspirin"],
+        "Safety" => ["Household Smoke detector", "Keep Firearms in home", "Wear seatbelts"],
+    ],
+    [
+        "Sexual Activity" => ["Exposure to STI", "Homosexual encounters", "Not sexually active", "Safe sex practices", "Sexually active"],
+        "Birth Gender" => ["Male", "Female", "Undifferentiated"],
+    ]
+];
+
+if(!@$note) {
+    $note = $patient->coreNote;
+}
+if(!@$sessionKey) {
+    $sessionKey = request()->cookie('sessionKey');
+}
+
+$point = Point::getOrCreateOnlyTopLevelPointOfCategory($note, 'SOCIAL_HISTORY', $sessionKey, true);
+
+$contentData = $parsed = false;
+
+$rel = !!$point->relevanceToNote($note);
+
+if ($point->lastChildReview && $point->lastChildReview->data) {
+    $point->lastChildReview->data = json_decode($point->lastChildReview->data, true);
+    $contentData = $parsed = $point->lastChildReview->data;
+
+    $prevHead = ''; $items = [];
+    for ($i = 0; $i < count($fields); $i++) {
+        foreach($fields[$i] as $head => $values) {
+            $items = [];
+            for($k = 0; $k < count($values); $k++) {
+                $fName = $head . '_' . sanitize_field_name($values[$k]);
+                if(@$contentData['common'][$fName]) {
+                    $items[] = $values[$k] . (@$contentData['common'][$fName . '__comments'] ? '<span class="text-sm ml-1 text-secondary">(' . $contentData['common'][$fName . '__comments'] . ')</span>' : '');
+                }
+            }
+            if(count($items) && trim(implode('', $items)) !== '') {
+            ?>
+                <div>
+                    <b><?= $head ?></b>
+                    <i class="fa fa-arrow-right text-sm text-secondary"></i>
+                    <?= implode(' • ', $items) ?>
+                </div>
+            <?php
+            }
+        }
+    }
+
+    // custom fields
+
+    if(isset($contentData['customFields']) && count($contentData['customFields'])):
+        ?> <div class=""> <?php
+        for ($i = 0; $i < count($contentData['customFields']); $i++):
+            $item = $contentData['customFields'][$i];
+            if($item['value']): ?>
+                <div>
+                    Custom
+                    <i class="fa fa-arrow-right text-sm text-secondary"></i>
+                    <span class="font-weight-bold"><?= $item['label'] ?></span>
+                    <?php if($item['comments']): ?>
+                        <span class="text-sm ml-1 text-secondary">(<?= $item['comments'] ?>)</span>
+                    <?php endif; ?>
+                </div>
+            <?php
+            endif;
+        endfor;
+        ?> </div> <?php
+    endif;
+
+    if(isset($contentData['comments']) && !empty(trim($contentData['comments']))) { ?>
+        <div class="mt-2 mb-1">
+            <b>Comments: </b><?= $contentData['comments'] ?>
+        </div>
+    <?php }
+}
+else {
+    echo '<span class="text-secondary">-</span>';
+}
+?>

+ 91 - 0
resources/views/app/patient/segment-templates/omega_history_surgical/summary-dashboard.blade.php

@@ -0,0 +1,91 @@
+<?php
+
+use App\Models\Client;
+use App\Models\Point;
+use App\Models\Note;
+/** @var Client $patient */
+/** @var Note $note */
+/** @var Segment $segment */
+
+if(!@$note) {
+    $note = $patient->coreNote;
+}
+if(!@$sessionKey) {
+    $sessionKey = request()->cookie('sessionKey');
+}
+
+$fields = [
+    [
+        "" => ["Aneurysm repair", "Appendectomy", "Back surgery", "Bariatric surgery/gastric bypass", "Bilateral tubal ligation", "Breast resection/mastectomy", "CABG", "Carotid endarterectomy/stent", "Carpal tunnel release surgery",]
+    ],
+    [
+        "" => ["Cataract/lens surgery", "Cesarean section", "Cholecystectomy/bile duct surgery", "Dilation and curettage", "Hemorrhoid surgery", "Hip arthroplasty", "Hip replacement", "Hysterectomy", "Inguinal hernia repair",]
+    ],
+    [
+        "" => ["Knee arthroplasty", "LASIK", "Laminectomy", "Nasal surgery", "PTCA/PCI", "Pacemaker/defibrillator", "Prostate surgery", "Prostatectomy", "Rotator cuff surgery",]
+    ],
+    [
+        "" => ["Sinus surgery", "Skin cancer excision", "Spinal fusion", "TAH-BSO", "TURP", "Tonsillectomy/Adenoidectomy", "Vasectomy",]
+    ]
+];
+
+$point = Point::getOrCreateOnlyTopLevelPointOfCategory($note, 'SURGICAL_HISTORY', $sessionKey, true);
+
+$contentData = $parsed = false;
+
+$rel = !!$point->relevanceToNote($note);
+
+if ($point->lastChildReview && $point->lastChildReview->data) {
+    $point->lastChildReview->data = json_decode($point->lastChildReview->data, true);
+    $contentData = $parsed = $point->lastChildReview->data;
+
+    for ($i = 0; $i < count($fields); $i++):
+        foreach($fields[$i] as $head => $values):
+            for($k = 0; $k < count($values); $k++):
+                $fName = $head . '_' . sanitize_field_name($values[$k]);
+                if(@$contentData['common'][$fName]): ?>
+                    <div>
+                        <!--Common
+                        <i class="fa fa-arrow-right text-sm text-secondary"></i>-->
+                        <span class="font-weight-bold"><?= $values[$k] ?></span>
+                        <?php if(@$contentData['common'][$fName . '__comments']): ?>
+                            <span class="text-sm ml-1 text-secondary">(<?= $contentData['common'][$fName . '__comments'] ?>)</span>
+                        <?php endif; ?>
+                    </div>
+                <?php
+                endif;
+            endfor;
+        endforeach;
+    endfor;
+
+    // custom fields
+
+    if(isset($contentData['customFields']) && count($contentData['customFields'])):
+        ?> <div class=""> <?php
+        for ($i = 0; $i < count($contentData['customFields']); $i++):
+            $item = $contentData['customFields'][$i];
+            if($item['value']): ?>
+                <div>
+                    <!--Custom
+                    <i class="fa fa-arrow-right text-sm text-secondary"></i>-->
+                    <span class="font-weight-bold"><?= $item['label'] ?></span>
+                    <?php if($item['comments']): ?>
+                        <span class="text-sm ml-1 text-secondary">(<?= $item['comments'] ?>)</span>
+                    <?php endif; ?>
+                </div>
+            <?php
+            endif;
+        endfor;
+        ?> </div> <?php
+    endif;
+
+    if(isset($contentData['comments']) && !empty(trim($contentData['comments']))) { ?>
+        <div class="mt-2 mb-1">
+            <b>Comments: </b><?= $contentData['comments'] ?>
+        </div>
+    <?php }
+}
+else {
+    echo '<span class="text-secondary">-</span>';
+}
+?>

+ 1 - 1
resources/views/app/patient/supplements-center.blade.php

@@ -19,7 +19,7 @@ list($supplements, $counts) = Point::getPointsOfCategoryExtended($patient, 'SUPP
             <thead>
             <tr class="">
                 @if($patient->core_note_id !== $note->id)
-                <th class="border-bottom-0 text-secondary text-center width-30px">Rel.</th>
+                <th class="border-bottom-0 text-secondary text-center width-30px text-nowrap">Rel.</th>
                 @endif
                 <th class="border-bottom-0 text-secondary">Name</th>
                 <th class="border-bottom-0 text-secondary width-50px">Edit</th>

+ 5 - 0
resources/views/app/patient/tickets.blade.php

@@ -949,6 +949,11 @@
                             $(document).on('focus', '#ticketsApp input.form-control', function() {
                                 $(this).select();
                             });
+
+                            $(document).off('stag-popup-closed.add-edit-popup-closure')
+                            $(document).on('stag-popup-closed.add-edit-popup-closure', function() {
+                                $('input.date-input').datepicker('hide');
+                            });
                         },
                         inWords: function (num) {
                             try {

+ 1 - 1
resources/views/app/practice-management/remote-monitoring-row-markup-by-pro-type.blade.php

@@ -221,7 +221,7 @@
                     Yes 
                     @if($iPatient->mcp_rm_generic_bill_id)
                         (Billable: ${{friendly_money($iPatient->mcp_rm_generic_bill_expected_payment_amount)}})
-
+                        
                         <div moe
                                 class="d-inline-block {{ $iPatient->mcp_rm_generic_bill_generic_pro_id !== $pro->id ? 'moe-disabled' : '' }}"
                                 title="{{ $iPatient->mcp_rm_generic_bill_generic_pro_id !== $pro->id ? 'Only the bill\'s pro can sign' : '' }}">

+ 2 - 4
resources/views/app/practice-management/rpm-matrix-by-pro-type.blade.php

@@ -43,7 +43,7 @@
             <div class="card-header px-2 py-2 d-flex align-items-baseline">
                 <form class="d-block w-100" action="" method="GET">
 
-                    <div class="d-flex align-items-baseline">
+                    <div class="d-flex align-items-end">
                         <span class="mr-4">
                             <span class="font-size-14">Remote Monitoring</span>
                             <i class="fas fa-arrow-right text-sm mx-1"></i>
@@ -108,9 +108,7 @@
                         </div>
                     </div>
 
-                    <hr class="m-neg-3 my-2"/>
-
-                    <div class="d-flex align-items-start">
+                    <div class="d-flex align-items-start mt-2 pt-1 border-top">
 
                         <div>
                             <label class="mb-0 text-sm {{request()->input('f_name') ? 'text-info' : 'text-secondary'}}">Name</label>

+ 2 - 1
resources/views/app/practice-management/visit-templates/single.blade.php

@@ -21,8 +21,9 @@
             <div class="d-flex align-items-center justify-content-between">
                 <strong>{{ $visitTemplate->title }}</strong>
                 <div>
-                @include('app.practice-management.visit-templates.clone', ['template' => $visitTemplate ])
+                    @include('app.practice-management.visit-templates.clone', ['template' => $visitTemplate ])
                     @include('app.practice-management.visit-templates.toggle-mark-as-slim', ['template' => $visitTemplate ])
+                    @include('app.practice-management.visit-templates.toggle-always-open', ['template' => $visitTemplate ])
                     @include('app.practice-management.visit-templates.update', ['template' => $visitTemplate ])
                 </div>
             </div>

+ 17 - 0
resources/views/app/practice-management/visit-templates/toggle-always-open.blade.php

@@ -0,0 +1,17 @@
+<div class="mr-2" moe relative>
+	@if($template->segments_always_open)
+		<a class="btn btn-sm btn-success text-white" href="" show start>Unmark as Segments-Always-Open</a>
+	@else
+		<a class="btn btn-sm btn-primary text-white" href="" show start>Mark as Segments-Always-Open</a>
+	@endif
+	<form url="/api/visitTemplate/{{ $template->segments_always_open ? 'undoMarkSegmentsAlwaysOpen' : 'markSegmentsAlwaysOpen' }}" right>
+	<input type="hidden" name="uid" value="{{ $template->uid }}" />
+		<div class="mb-2">
+			<label>Are you sure?</label>
+		</div>
+		<div class="mb-0">
+			<button class="btn btn-primary btn-sm" submit>Submit</button>
+			<button class="btn btn-default border btn-sm" cancel>Cancel</button>
+		</div>
+	</form>
+</div>

+ 2 - 2
resources/views/layouts/patient.blade.php

@@ -23,7 +23,7 @@ $isOldClient = (date_diff(date_create(config('app.point_impl_date')), date_creat
 					<li class="nav-item">
 						<a class="nav-link {{ strpos($routeName, 'patients.view.dashboard') === 0 ? 'active' : '' }}" href="{{ route('patients.view.dashboard', ['patient' => $patient]) }}">Dashboard</a>
 					</li>
-					@if($performer->pro->pro_type == 'ADMIN')
+					@if($performer->pro->pro_type == 'ADMIN' && $isOldClient)
 					<li class="nav-item">
 						<a class="nav-link {{ strpos($routeName, 'patients.view.migrate-canvas') === 0 ? 'active' : '' }}" href="{{ route('patients.view.migrate-canvas', ['patient' => $patient]) }}">Canvas Migrate</a>
 					</li>
@@ -135,7 +135,7 @@ $isOldClient = (date_diff(date_create(config('app.point_impl_date')), date_creat
 					<li class="nav-item">
 						<a class="nav-link {{ strpos($routeName, 'patients.view.patient-tickets') === 0 && @$type === '' ? 'active' : '' }}" href="{{ route('patients.view.patient-tickets', ['patient' => $patient, 'type' => '']) }}">Tickets</a>
 					</li>
-					@if($isOldClient)
+					@if($isOldClient && 0)
 					<li class="nav-item">
 						<a class="nav-link {{ strpos($routeName, 'patients.view.patient-tickets') === 0 ? 'active' : '' }}" href="{{ route('patients.view.patient-tickets', ['patient' => $patient]) }}" title="Deprecated">ERx / Orders
 							<span class="text-secondary text-sm pl-2">(dep)</span>

+ 57 - 48
resources/views/layouts/template.blade.php

@@ -128,22 +128,61 @@
                         <i class="mr-1 fas fa-tasks"></i> Practice
                     </a>
                     <div class="dropdown-menu mcp-theme-1 no-overflow-menu p-0" aria-labelledby="practice-management">
-                        @if($pro->pro_type !== 'ADMIN')
-                            @if($pro->is_enrolled_as_mcp)
-                            <a class="dropdown-item" href="{{ route('practice-management.rpm-matrix-mcp') }}">RPM (MCP)</a>
-                            @endif
-                            @if($pro->is_considered_for_rmm)
-                            <a class="dropdown-item" href="{{ route('practice-management.rpm-matrix-rmm') }}">RPM (RMM)</a>
-                            @endif
-                            @if($pro->is_considered_for_rme)
-                            <a class="dropdown-item" href="{{ route('practice-management.rpm-matrix-rme') }}">RPM (RME)</a>
-                            @endif
-                            <a class="dropdown-item" href="{{ route('practice-management.client-ccm-rm-status') }}">Client RM Status</a>
-                        @else
+                        @if($pro->is_enrolled_as_mcp)
+                        <a class="dropdown-item" href="{{ route('practice-management.rpm-matrix-mcp') }}">RPM (MCP)</a>
+                        @endif
+                        @if($pro->is_considered_for_rmm)
+                        <a class="dropdown-item" href="{{ route('practice-management.rpm-matrix-rmm') }}">RPM (RMM)</a>
+                        @endif
+                        @if($pro->is_considered_for_rme)
+                        <a class="dropdown-item" href="{{ route('practice-management.rpm-matrix-rme') }}">RPM (RME)</a>
+                        @endif
+                        <a class="dropdown-item" href="{{ route('practice-management.client-ccm-rm-status') }}">Client RM Status</a>
+
+                        @if($pro->is_enrolled_as_mcp && $pro->is_considered_for_mcp_assignment)
+
+                            <a class="dropdown-item" href="{{ route('practice-management.financialTransactions') }}">Financial Transactions</a>
+                            <a class="dropdown-item" href="{{ route('practice-management.myTextShortcuts') }}">Text Shortcuts</a>
+                            <a class="dropdown-item" href="{{ route('practice-management.myFavorites') }}">Favorites</a>
+                            <a class="dropdown-item" href="{{ route('practice-management.proAvailability') }}">Availability</a>
+                            <a class="dropdown-item" href="{{ route('practice-management.proCalendar') }}">Calendar</a>
+                            <a class="dropdown-item" href="{{ route('practice-management.remoteMonitoringReport') }}">Remote Monitoring Report</a>
+
+                            <a class="dropdown-item" href="{{ route('practice-management.rpmMatrix') }}">RPM Matrix</a>
+
+                            <a class="dropdown-item" href="{{ route('mcp.notes') }}">Notes</a>
+                            <a class="dropdown-item" href="{{ route('mcp.memos') }}">Memos</a>
+                            <a class="dropdown-item" href="{{ route('mcp.appointments') }}">Appointments</a>
+                            <a class="dropdown-item" href="{{ route('mcp.bills') }}">Bills</a>
+                            <a class="dropdown-item" href="{{ route('mcp.erx_and_orders') }}">ERx & Orders</a>
+                            <a class="dropdown-item" href="{{ route('mcp.reports') }}">Reports</a>
+                            <a class="dropdown-item" href="{{ route('mcp.supply_orders') }}">Supply Orders</a>
+                            <a class="dropdown-item" href="{{ route('mcp.client_messages') }}">Messages</a>
+                            <a class="dropdown-item" href="{{ route('mcp.patients_accounts_invites') }}">Patients Accounts Invites</a>
+                            <a class="dropdown-item" href="{{ route('mcp.clients_bdt_devices') }}">Clients BDT Devices</a>
+                        @elseif($pro->isDefaultNA())
+
+                            <a class="dropdown-item" href="/practice-management/my-teams">My Teams</a>
+                            <a class="dropdown-item" href="{{ route('dna.encounters') }}">Encounters</a>
+                            <a class="dropdown-item" href="{{ route('dna.appointments') }}">Appointments</a>
+                            <a class="dropdown-item" href="{{ route('dna.careMonths') }}">Care Months</a>
+                            <a class="dropdown-item" href="{{ route('dna.financialTransactions') }}">Financial Transactions</a>
+                            <a class="dropdown-item" href="{{ route('dna.myBills') }}">My Bills</a>
+                            <a class="dropdown-item" href="{{ route('dna.myClinicalTeams') }}">My Clinical Teams</a>
+                        @endif
+                        <a class="dropdown-item" href="{{ route('practice-management.my-flyers') }}">My Flyers</a>
+                    </div>
+                </li>
+
+                @if($pro->pro_type === 'ADMIN')
+                    <li class="nav-item dropdown">
+                        <a class="nav-link dropdown-toggle" href="#" id="practice-management" data-toggle="dropdown" aria-haspopup="true" aria-expanded="false">
+                            <i class="mr-1 fas fa-tasks"></i> Admin
+                        </a>
+                        <div class="dropdown-menu mcp-theme-1 no-overflow-menu p-0" aria-labelledby="practice-management">
                             <a class="dropdown-item" href="{{ route('practice-management.remote-monitoring-admin') }}">Remote Monitoring (admin)</a>
                             <a class="dropdown-item" href="{{ route('practice-management.daily-treatment-services') }}">Daily Treatment Services</a>
-                        @endif
-                        @if($pro->pro_type == 'ADMIN')
+
                             <a class="dropdown-item" href="{{ route('practice-management.client-pro-changes') }}">Client Pro Changes</a>
                             <a class="dropdown-item" href="{{ route('practice-management.rpmMatrix') }}">RPM Matrix</a>
                             {{--<a class="dropdown-item" href="{{ route('practice-management.previousBills') }}">Previous Bills</a>--}}
@@ -178,7 +217,7 @@
                             <a class="dropdown-item" href="{{ route('practice-management.rmActionReport') }}">RM Action Report</a>
                             <a class="dropdown-item" href="{{ route('practice-management.hcp-note-activity') }}">HCP Note Activity</a>
                             <a class="dropdown-item" href="{{ route('practice-management.allNotes') }}">All Notes</a>
-                            
+
                             @if($pro->id == '1' || $pro->id == '16')
                                 <a class="dropdown-item" href="{{ route('practice-management.treatmentServiceUtil') }}">Treatment Service Util.</a>
                             @endif
@@ -202,40 +241,10 @@
                             <a class="dropdown-item" href="{{ route('admin.part_b_patients') }}">Part B Patients</a>
                             <a class="dropdown-item" href="{{ route('admin.bdt_devices') }}">BDT Devices</a>
                             <a class="dropdown-item" href="{{ route('admin.patientsMissingDefasultSettings') }}">Patients Missing Default Settings</a>
-                        @elseif($pro->is_enrolled_as_mcp && $pro->is_considered_for_mcp_assignment)
-
-                            <a class="dropdown-item" href="{{ route('practice-management.financialTransactions') }}">Financial Transactions</a>
-                            <a class="dropdown-item" href="{{ route('practice-management.myTextShortcuts') }}">Text Shortcuts</a>
-                            <a class="dropdown-item" href="{{ route('practice-management.myFavorites') }}">Favorites</a>
-                            <a class="dropdown-item" href="{{ route('practice-management.proAvailability') }}">Availability</a>
-                            <a class="dropdown-item" href="{{ route('practice-management.proCalendar') }}">Calendar</a>
-                            <a class="dropdown-item" href="{{ route('practice-management.remoteMonitoringReport') }}">Remote Monitoring Report</a>
-
-                            <a class="dropdown-item" href="{{ route('practice-management.rpmMatrix') }}">RPM Matrix</a>
 
-                            <a class="dropdown-item" href="{{ route('mcp.notes') }}">Notes</a>
-                            <a class="dropdown-item" href="{{ route('mcp.memos') }}">Memos</a>
-                            <a class="dropdown-item" href="{{ route('mcp.appointments') }}">Appointments</a>
-                            <a class="dropdown-item" href="{{ route('mcp.bills') }}">Bills</a>
-                            <a class="dropdown-item" href="{{ route('mcp.erx_and_orders') }}">ERx & Orders</a>
-                            <a class="dropdown-item" href="{{ route('mcp.reports') }}">Reports</a>
-                            <a class="dropdown-item" href="{{ route('mcp.supply_orders') }}">Supply Orders</a>
-                            <a class="dropdown-item" href="{{ route('mcp.client_messages') }}">Messages</a>
-                            <a class="dropdown-item" href="{{ route('mcp.patients_accounts_invites') }}">Patients Accounts Invites</a>
-                            <a class="dropdown-item" href="{{ route('mcp.clients_bdt_devices') }}">Clients BDT Devices</a>
-                        @elseif($pro && $pro->isDefaultNA())
-
-                            <a class="dropdown-item" href="/practice-management/my-teams">My Teams</a>
-                            <a class="dropdown-item" href="{{ route('dna.encounters') }}">Encounters</a>
-                            <a class="dropdown-item" href="{{ route('dna.appointments') }}">Appointments</a>
-                            <a class="dropdown-item" href="{{ route('dna.careMonths') }}">Care Months</a>
-                            <a class="dropdown-item" href="{{ route('dna.financialTransactions') }}">Financial Transactions</a>
-                            <a class="dropdown-item" href="{{ route('dna.myBills') }}">My Bills</a>
-                            <a class="dropdown-item" href="{{ route('dna.myClinicalTeams') }}">My Clinical Teams</a>
-                        @endif
-                        <a class="dropdown-item" href="{{ route('practice-management.my-flyers') }}">My Flyers</a>
-                    </div>
-                </li>
+                        </div>
+                    </li>
+                @endif
             </ul>
             {{-- if pro is working on a client and is not in tht client
             <div class="current-work mr-2">