Răsfoiți Sursa

Lifestyle center - rel logic fix

Vijayakrishnan 3 ani în urmă
părinte
comite
7ba1862576

+ 2 - 2
resources/views/app/patient/behavior-center.blade.php

@@ -29,9 +29,9 @@ $points = [
 
             @foreach($points as $p)
                 <?php $point = $p['point']; ?>
-                <?php $rel = $point->relevanceToNote($note); ?>
+                <?php $rel = $point ? $point->relevanceToNote($note) : false; ?>
                 <tr class="{{$rel ? 'relevant-to-visit' : ''}} point-row" data-uid="{{$point ? $point->uid : ''}}">
-                    @if($patient->core_note_id !== $note->id)
+                    @if($point && $patient->core_note_id !== $note->id)
                         @include('app.patient.wizard-partials.relevance-column', ['point' => $point])
                     @endif
                     <td>

+ 2 - 2
resources/views/app/patient/exercise-center.blade.php

@@ -27,9 +27,9 @@ $points = [
 
             @foreach($points as $p)
                 <?php $point = $p['point']; ?>
-                <?php $rel = $point->relevanceToNote($note); ?>
+                <?php $rel = $point ? $point->relevanceToNote($note) : false; ?>
                 <tr class="{{$rel ? 'relevant-to-visit' : ''}} point-row" data-uid="{{$point ? $point->uid : ''}}">
-                    @if($patient->core_note_id !== $note->id)
+                    @if($point && $patient->core_note_id !== $note->id)
                         @include('app.patient.wizard-partials.relevance-column', ['point' => $point])
                     @endif
                     <td>

+ 2 - 2
resources/views/app/patient/nutrition-center.blade.php

@@ -36,9 +36,9 @@ $points = [
         <table class="table table-sm table-bordered bg-white mb-2 point-table read">
             @foreach($points as $p)
                 <?php $point = $p['point']; ?>
-                <?php $rel = $point->relevanceToNote($note); ?>
+                <?php $rel = $point ? $point->relevanceToNote($note) : false; ?>
                 <tr class="{{$rel ? 'relevant-to-visit' : ''}} point-row" data-uid="{{$point ? $point->uid : ''}}">
-                    @if($patient->core_note_id !== $note->id)
+                    @if($point && $patient->core_note_id !== $note->id)
                         @include('app.patient.wizard-partials.relevance-column', ['point' => $point])
                     @endif
                     <td>