浏览代码

Merge branch 'dev' into dev-vj

Vijayakrishnan 3 年之前
父节点
当前提交
b361135773

+ 8 - 0
app/Http/Controllers/PracticeManagementController.php

@@ -43,6 +43,7 @@ use PDF;
 use DateTime;
 use DateTimeZone;
 use Illuminate\Http\Request;
+use App\Models\SegmentTemplate;
 
 class PracticeManagementController extends Controller
 {
@@ -2453,6 +2454,13 @@ ORDER BY c.name_last, c.name_first
         return view('app.practice-management.memos', compact('memos', 'filters'));
     }
 
+    public function segmentTemplates(Request $request){
+        $segmentTemplates = SegmentTemplate::query();
+        $segmentTemplates = $segmentTemplates->orderBy('created_at', 'DESC');
+        $segmentTemplates = $segmentTemplates->paginate(20);
+        return view('app.practice-management.segment-templates', compact('segmentTemplates'));
+    }
+
 
     public function clientCcmRmStatus(Request $request){
         $filters = $request->all();

+ 5 - 19
resources/views/app/patient/send_email.blade.php

@@ -1,17 +1,3 @@
-<style>
-#outgoingEmailTemplate .ql-editor {
-    padding: 0 15px 15px 15px;
-}
-#outgoingEmailTemplate .ql-snow.ql-toolbar button, 
-#outgoingEmailTemplate .ql-snow .ql-toolbar button {
-    min-width: initial;
-    border: none;
-    background-color: #f7f7f7;
-}
-#outgoingEmailTemplate .ql-toolbar.ql-snow {
-    background-color: #f7f7f7;
-}
-</style>
 <div class="d-inline" id="outgoingEmailTemplate">
     <div moe wide center class="ml-auto">
         <a show href="" start>Send Email</a>
@@ -51,7 +37,7 @@
             </div>
             <div class="form-group">
                 <button class="btn btn-primary btn-sm" submit>Submit</button>
-                <button class="btn btn-primary btn-sm" cancel>Cancel</button>
+                <button class="btn btn-secondary btn-sm" cancel>Cancel</button>
             </div>
         </form>
     </div>
@@ -70,7 +56,8 @@
                     },
                     fromEmailAddresses: [
                         'carelink@leadershiphealth.org'
-                    ]
+                    ],
+                    quill: null
                 },
                 methods: {
                     setTemplate: function(evt) {
@@ -84,7 +71,7 @@
                         self.template = self.templates[value];
                         self.quill.root.innerHTML = self.template.default_message_body_tpl;
                     },
-                    loadOugoingEmailTemplates: function() {
+                    loadOutgoingEmailTemplates: function() {
                         var self = this;
                         $.get("{{ route('outgoingEmailTemplates') }}", {}, function(response) {
                             self.templates = response.data;
@@ -95,7 +82,6 @@
                         self.quill = new Quill('#htmlBody', {
                             theme: 'snow',
                             modules:{
-                                'syntax': true,
                                 'toolbar': [
                                 [{ 'font': [] }, { 'size': [] }],
                                 [ 'bold', 'italic', 'underline', 'strike' ],
@@ -114,7 +100,7 @@
                         });
                     },
                     init: function() {
-                        this.loadOugoingEmailTemplates();
+                        this.loadOutgoingEmailTemplates();
                         this.initQuillEditor();
                     }
                 },

+ 49 - 0
resources/views/app/practice-management/segment-templates.blade.php

@@ -0,0 +1,49 @@
+@extends ('layouts/template')
+
+@section('content')
+<div class="p-3 mcp-theme-1" id="patients-list">
+    <div class="card">
+
+        <div class="card-header border-bottom-0 px-1 py-2 d-flex align-items-center">
+            <strong class="mr-4">
+                <i class="fas fa-notes-medical"></i>
+                Segment Templates
+            </strong>
+        </div>
+
+        <div class="card-body p-0">
+            <table class="table table-sm table-striped border-top p-0 m-0">
+                <thead class="bg-light">
+                    <tr>
+                        <th class="border-0">Category</th>
+                        <th class="border-0">Patient</th>
+                        <th class="border-0">MCP</th>
+                        <th class="border-0 w-25">Summary</th>
+                        <th class="border-0">Created</th>
+                        <th class="border-0 delete-column">&nbsp;</th>
+                    </tr>
+                </thead>
+                <tbody>
+                    @foreach($segmentTemplates as $memo)
+                    <tr>
+                        <td></td>
+                        
+                    </tr>
+                    @endforeach
+
+                    @if(count($segmentTemplates) === 0)
+                    <tr>
+                        <td colspan="5">No records found!</td>
+                    </tr>
+                    @endif
+                </tbody>
+
+            </table>
+
+        </div>
+    </div>
+    <div class="mt-3">
+        {{ $segmentTemplates->appends(request()->input())->links() }}
+    </div>
+</div>
+@endsection

+ 1 - 0
resources/views/layouts/template.blade.php

@@ -180,6 +180,7 @@
                             <a class="dropdown-item" href="{{ route('practice-management.patientsAccountsInvites') }}">Patients Accounts Invites</a>
                             <a class="dropdown-item" href="{{ route('practice-management.clientsBdtDevices') }}">Clients BDT Devices</a>
                             <a class="dropdown-item" href="{{ route('practice-management.memos') }}">Memos</a>
+                            <a class="dropdown-item" href="{{ route('practice-management.segmentTemplates') }}">Segment Templates</a>
 
                         @elseif($pro->is_enrolled_as_mcp && $pro->is_considered_for_mcp_assignment)
 

+ 1 - 0
routes/web.php

@@ -252,6 +252,7 @@ Route::middleware('pro.auth')->group(function () {
         Route::get('patients-accounts-invites', 'PracticeManagementController@patientsAccountsInvites')->name('patientsAccountsInvites');
         Route::get('clients-bdt-devices', 'PracticeManagementController@clientsBdtDevices')->name('clientsBdtDevices');
         Route::get('memos', 'PracticeManagementController@memos')->name('memos');
+        Route::get('segment-templates', 'PracticeManagementController@segmentTemplates')->name('segmentTemplates');
         Route::get('client-ccm-rm-status', 'PracticeManagementController@clientCcmRmStatus')->name('client-ccm-rm-status');
 
         Route::get('hcp-note-activity', 'PracticeManagementController@hcpNoteActivity')->name('hcp-note-activity');