|
@@ -7,10 +7,10 @@
|
|
|
<div class="p-3 mcp-theme-1" id="patients-list">
|
|
|
<div class="card">
|
|
|
<div class="card-header px-3 py-2">
|
|
|
- <div class="d-flex justify-content-between">
|
|
|
+ <div class="d-flex align-items-start justify-content-between">
|
|
|
<div>
|
|
|
<strong class="mr-4">
|
|
|
- <i class="fas fa-list"></i>
|
|
|
+ <i class="fas fa-clipboard-list"></i>
|
|
|
Surveys
|
|
|
</strong>
|
|
|
</div>
|
|
@@ -18,40 +18,54 @@
|
|
|
@include("app.admin.surveys.partials.create")
|
|
|
</div>
|
|
|
</div>
|
|
|
-
|
|
|
+
|
|
|
</div>
|
|
|
{{-- <div class="p-3">
|
|
|
filter blade
|
|
|
</div> --}}
|
|
|
- <table class="table table-striped p-0 m-0 table-sm border-top border-bottom ">
|
|
|
+ <table class="table table-hover bg-white p-0 m-0 table-bordered table-sm border-top border-bottom ">
|
|
|
<thead class="bg-light">
|
|
|
<tr>
|
|
|
- <th class="border-0">Date</th>
|
|
|
- <th class="border-0">Internal Name</th>
|
|
|
- <th class="border-0">Title</th>
|
|
|
- <th class="border-0">Data</th>
|
|
|
- <th class="border-0">Entity Type</th>
|
|
|
- <th class="border-0">Name</th>
|
|
|
- <th class="border-0">Is Accessible to Target</th>
|
|
|
- <th class="border-0">Access Link</th>
|
|
|
+ <th class="border-0" style="width:150px">Created At</th>
|
|
|
+ <th class="border-0" style="width:150px">Title</th>
|
|
|
+ <th class="border-0" style="width:200px">Internal Name</th>
|
|
|
+ <th class="border-0" style="width:200px">Entity Type</th>
|
|
|
+ <th class="border-0">Entity</th>
|
|
|
+ <th class="border-0" style="width:180px">Survey Completed</th>
|
|
|
+ <th class="border-0" style="width:150px">Access Granted</th>
|
|
|
+ <th class="border-0" style="width:200px">Access Link</th>
|
|
|
</tr>
|
|
|
</thead>
|
|
|
<tbody>
|
|
|
@foreach($records as $record)
|
|
|
<tr>
|
|
|
<td>{{ friendly_date($record->created_at) }}</td>
|
|
|
- <td>{{ $record->internal_name }}</td>
|
|
|
<td>{{ $record->title }}</td>
|
|
|
- <td><?= parseRender(json_decode($record->survey_data ?? '{}')) ?></td>
|
|
|
+ <td>{{ $record->internal_name }}</td>
|
|
|
<td>{{ $record->entity_type }}</td>
|
|
|
<td>
|
|
|
- @if($record->entity_type === 'Client')
|
|
|
- {{ $record->getEntity()->displayName() }}
|
|
|
- @else
|
|
|
- ---
|
|
|
- @endif
|
|
|
- </td>
|
|
|
- <td>{{ $record->is_accessible_to_target ? 'YES' : 'NO' }}</td>
|
|
|
+ @if($record->entity_type === 'Client')
|
|
|
+ {{ $record->getEntity()->displayName() }}
|
|
|
+ @else
|
|
|
+ ---
|
|
|
+ @endif
|
|
|
+ </td>
|
|
|
+ <td>
|
|
|
+ @if($record->survey_data)
|
|
|
+ <span class="text-success">Yes</span>
|
|
|
+ @include('app.admin.surveys.partials.survey-results')
|
|
|
+ @else
|
|
|
+ <span class="text-danger">No</span>
|
|
|
+ @endif
|
|
|
+ </td>
|
|
|
+ {{-- <td><?= parseRender(json_decode($record->survey_data ?? '{}')) ?></td> --}}
|
|
|
+ <td>
|
|
|
+ @if($record->is_accessible_to_target)
|
|
|
+ <span class="text-success">Yes</span>
|
|
|
+ @else
|
|
|
+ <span class="text-danger">No</span>
|
|
|
+ @endif
|
|
|
+ </td>
|
|
|
<td>
|
|
|
@if($record->is_accessible_to_target)
|
|
|
<a href="{{ route('view-survey-form', $record->access_key) }}" target="_blank" class="mr-2" native>Open Link</a>
|
|
@@ -60,7 +74,7 @@
|
|
|
@include("app.admin.surveys.partials.grant-access-to-target")
|
|
|
@endif
|
|
|
</td>
|
|
|
-
|
|
|
+
|
|
|
</tr>
|
|
|
@endforeach
|
|
|
|
|
@@ -80,4 +94,4 @@
|
|
|
</div>
|
|
|
</div>
|
|
|
</div>
|
|
|
-@endsection
|
|
|
+@endsection
|