소스 검색

setting associate pros

Peter Muturi 3 년 전
부모
커밋
9508fd0b8d
2개의 변경된 파일15개의 추가작업 그리고 4개의 파일을 삭제
  1. 5 0
      app/Models/Client.php
  2. 10 4
      resources/views/app/patient/settings.blade.php

+ 5 - 0
app/Models/Client.php

@@ -45,6 +45,11 @@ class Client extends Model
         return $this->hasOne(Pro::class, 'id', 'mcp_pro_id');
     }
 
+    public function rd()
+    {
+        return $this->hasOne(Pro::class, 'id', 'rd_pro_id');
+    }
+
     public function pcp()
     {
         return $this->hasOne(Pro::class, 'id', 'physician_pro_id');

+ 10 - 4
resources/views/app/patient/settings.blade.php

@@ -136,7 +136,7 @@
                                     <select class="form-control form-control-sm" name="sex">
                                         <option value="">--select--</option>
                                         <option value="M" @if($patient->sex === 'M') selected @endif>Male</option>
-                                        <option value="F" @if($patient->sex === 'F') selected @endif>Female</option>                                       
+                                        <option value="F" @if($patient->sex === 'F') selected @endif>Female</option>
                                     </select>
                                 </div>
                                 <div>
@@ -358,6 +358,12 @@
                             @endif
                         @endif
                     </div>
+                    <div class="mb-1">
+                      MCP Pro: <b>{{ $patient->mcp->name_display ?? ''}}</b>
+                    </div>
+                    <div class="mb-1">
+                      RD Pro: <b>{{ $patient->rd->name_display ?? ''}}</b>
+                    </div>
                 </div>
 
                 <hr class="m-negator-3 my-3">
@@ -411,7 +417,7 @@
                                     <label class="mb-1 text-secondary text-sm">Claim Address Zip</label>
                                     <input type="text" class="form-control form-control-sm" value="{{ $patient->claim_address_zip }}" name="claimAddressZip" />
                                 </div>
-                                
+
                                 <div>
                                     <button submit class="btn btn-sm btn-primary mr-1">Submit</button>
                                     <button cancel class="btn btn-sm btn-default border">Cancel</button>
@@ -435,8 +441,8 @@
                         <div>
                             Claim Address Zip: <b>{{ $patient->claim_address_zip ?? '' }}</b>
                         </div>
-                        
-                        
+
+
                     </div>
                 </div>