Forráskód Böngészése

Add pcp->mcp? condition and primary-form

Vijayakrishnan Krishnan 4 éve
szülő
commit
2fc68a7902
1 módosított fájl, 5 hozzáadás és 2 törlés
  1. 5 2
      resources/views/app/patient/intake.blade.php

+ 5 - 2
resources/views/app/patient/intake.blade.php

@@ -1,12 +1,15 @@
 @extends ('layouts.patient')
 @section('inner-content')
     <?
-    	$myName = implode(' ', array_filter([$patient->mcp->name_first, $patient->mcp->name_last]));
+        $myName = '-';
+        if($patient->mcp) {
+            $myName = implode(' ', array_filter([$patient->mcp->name_first, $patient->mcp->name_last]));
+        }
     	$theirName = ($patient->name_prefix ?? ($patient->sex === 'M' ? 'Mr.' : 'Ms.'))
     		.' '.($patient->name_last ?? $patient->name_first);
     ?>
 
-    <section class=intake>
+    <section class="intake primary-form">
         <p>Hello, {{$theirName}}. My name is {{$myName}}.</p>
         <p>We will have about 15-20 minutes together, and I’m going to ask you some questions to help customize your personalized wellness plan that we will send along with the weight scale, blood pressure cuff, and infrared thermometer - that you can use to stay healthy during quarantine. Is this OK with you?</p>