Преглед на файлове

views de los resultados basados en los estudiantes

Carlos J Corrada Bravo преди 2 години
родител
ревизия
be6c1e5325
променени са 2 файла, в които са добавени 1102 реда и са изтрити 0 реда
  1. 532
    0
      app/views/local/managers/shared/program_student_result.blade.php
  2. 570
    0
      app/views/local/managers/shared/school_student_result.blade.php

+ 532
- 0
app/views/local/managers/shared/program_student_result.blade.php Целия файл

@@ -0,0 +1,532 @@
1
+@extends('layouts.master')
2
+
3
+
4
+@section('navigation')
5
+    @if($role==1)
6
+        @include('local.managers.admins._navigation')
7
+    @elseif($role==2)
8
+        @include('local.managers.sCoords._navigation')
9
+     @endif
10
+@stop
11
+
12
+@section('main')
13
+<a href="{{ action('ProgramsController@show', array($program->id)); }}" class="btn btn-primary pull-left" alt="print">Go to Performance by Program Courses</a>
14
+
15
+<a href="{{ action('ProgramsController@print_program', array($program->id)); }}" class="btn btn-primary pull-right" alt="print"><span class="glyphicon glyphicon-print"></span></a>
16
+<br>
17
+<br>
18
+<div class="row">
19
+    <ul id="resultsTabs" class="nav nav-tabs" role="tablist">
20
+        <li role="presentation" class="active"><a href="#combined" aria-controls="combined" role="tab">Combined</a></li>
21
+        <li role="presentation"><a href="#uncombined" aria-controls="uncombined" role="tab">Uncombined</a></li>
22
+    </ul>
23
+	<div>
24
+<!-- 	<div class="tab-content"> -->
25
+
26
+	<div role="tabpanel" class="tab-pane active" id="combined">
27
+	<div class="row">
28
+		<div class="col-md-12" id="graph2"></div>
29
+	</div>
30
+
31
+            <div class="row">
32
+                <div class="col-md-12">
33
+                    <h3>Performance of {{ $program->name }} Students by Combined Learning Outcome</h3>
34
+                    @if($outcomes->count()>0)
35
+                        <table class="table table-striped table-condensed datatable">
36
+                            <thead>
37
+                                <tr>
38
+                                    <th>Program Id</th>
39
+                                    <th>Program Is Graduate</th>
40
+                                    <th>Learning Outcome</th>
41
+                                    <th>Number Students</th>
42
+                                    <th>Number Students that Achieved the Target</th>
43
+                                    <th>Percentage of Students that Achieved the Target</th>
44
+                                </tr>
45
+                            </thead>
46
+                            <tfoot>
47
+                                <tr class="column-search">
48
+                                    <th><select class="column-search-select form-control"><option value=""></option></select></th>
49
+                                    <th><select class="column-search-select form-control"><option value=""></option></select></th>
50
+                                    <th><input class="column-search-bar form-control" type="text" placeholder="Search"/></th>
51
+                                    <th><input class="column-search-bar form-control" type="text" placeholder="Search"/></th>
52
+                                    <th><input class="column-search-bar form-control" type="text" placeholder="Search"/></th>
53
+                                    <th><select class="column-search-select form-control"><option value=""></option></select></th>
54
+                                </tr>
55
+                            </tfoot>
56
+                            <tbody>
57
+                                @foreach($outcomes_colap as $outcome)
58
+                                    <tr>
59
+										<td>{{{ $program->id }}}</td>
60
+										<td>{{{ $program->is_graduate }}}</td>
61
+										<td>{{ link_to_action('OutcomesController@show', $outcome->name, array($outcome->id), $attributes = array()) }}</td>
62
+										<td>{{{ $outcomes_attempted_colap[$outcome->id] }}}</td>
63
+										<td>{{{ $outcomes_achieved_colap[$outcome->id] }}}</td>
64
+										<td>
65
+											@if($outcomes_attempted[$outcome->id]!=0)
66
+												{{{ round($outcomes_achieved_colap[$outcome->id] / $outcomes_attempted_colap[$outcome->id]*100, 2) }}}%
67
+											@else
68
+												N/M
69
+											@endif
70
+										</td>
71
+                                    </tr>
72
+                                @endforeach
73
+                            </tbody>
74
+                        </table>
75
+                    @else
76
+                        <p class="lead"> No courses assigned.</p>
77
+                    @endif
78
+                </div>
79
+            </div>
80
+            </div>
81
+		<div role="tabpanel" class="tab-pane" id="uncombined">
82
+	<div class="row">
83
+		<div class="col-md-12" id="graph"></div>
84
+	</div>
85
+
86
+            <div class="row">
87
+                <div class="col-md-12">
88
+                    <h3>Performance of {{ $program->name }} Students by Uncombined Learning Outcome</h3>
89
+                    @if($outcomes->count()>0)
90
+                        <table class="table table-striped table-condensed datatable">
91
+                            <thead>
92
+                                <tr>
93
+                                    <th>Program Id</th>
94
+                                    <th>Program Is Graduate</th>
95
+                                    <th>Learning Outcome</th>
96
+                                    <th>Number Students</th>
97
+                                    <th>Number Students that Achieved the Target</th>
98
+                                    <th>Percentage of Students that Achieved the Target</th>
99
+                                </tr>
100
+                            </thead>
101
+                            <tfoot>
102
+                                <tr class="column-search">
103
+                                    <th><select class="column-search-select form-control"><option value=""></option></select></th>
104
+                                    <th><select class="column-search-select form-control"><option value=""></option></select></th>
105
+                                    <th><input class="column-search-bar form-control" type="text" placeholder="Search"/></th>
106
+                                    <th><input class="column-search-bar form-control" type="text" placeholder="Search"/></th>
107
+                                    <th><input class="column-search-bar form-control" type="text" placeholder="Search"/></th>
108
+                                    <th><select class="column-search-select form-control"><option value=""></option></select></th>
109
+                                </tr>
110
+                            </tfoot>
111
+                            <tbody>
112
+                                @foreach($outcomes as $outcome)
113
+                                    <tr>
114
+										<td>{{{ $program->id }}}</td>
115
+										<td>{{{ $program->is_graduate }}}</td>
116
+										<td>{{ link_to_action('OutcomesController@show', $outcome->name, array($outcome->id), $attributes = array()) }}</td>
117
+										<td>{{{ $outcomes_attempted[$outcome->id] }}}</td>
118
+										<td>{{{ $outcomes_achieved[$outcome->id] }}}</td>
119
+										<td>
120
+											@if($outcomes_attempted[$outcome->id]!=0)
121
+												{{{ round($outcomes_achieved[$outcome->id] / $outcomes_attempted[$outcome->id]*100, 2) }}}%
122
+											@else
123
+												N/M
124
+											@endif
125
+										</td>
126
+                                    </tr>
127
+                                @endforeach
128
+                            </tbody>
129
+                        </table>
130
+                    @else
131
+                        <p class="lead"> No courses assigned.</p>
132
+                    @endif
133
+                </div>
134
+            </div>
135
+</div>
136
+	</div>
137
+</div>
138
+ <!-- =================== tabs =================== -->
139
+<div class="row">
140
+    <!-- Nav tabs -->
141
+   <!-- Tab panes -->
142
+    <ul id="programTabs" class="nav nav-tabs" role="tablist">
143
+        <li role="presentation" class="active"><a href="#courses" aria-controls="courses" role="tab">Courses</a></li>
144
+        <li role="presentation"><a href="#contact" aria-controls="contact" role="tab">Contact Information</a></li>
145
+    </ul>
146
+    <div class="tab-content">
147
+
148
+       <div role="tabpanel" class="tab-pane active" id="courses">
149
+            <div class="row">
150
+                <div class="col-md-12">
151
+                    <h3>Courses in this program</h3>
152
+                    @if(count($grouped_courses)>0)
153
+                        <table class="table table-striped table-condensed datatable">
154
+                            <thead>
155
+                                <tr>
156
+                                    <th>Identifier</th>
157
+                                    <th>Name</th>
158
+                                    <th>Course Program</th>
159
+                                    <th>Number of Students</th>
160
+                                </tr>
161
+                            </thead>
162
+                            <tfoot>
163
+                                <tr class="column-search">
164
+                                    <th><input class="column-search-bar form-control" type="text" placeholder="Search"/></th>
165
+                                    <th><input class="column-search-bar form-control" type="text" placeholder="Search"/></th>
166
+                                <th><select class="column-search-select form-control"><option value=""></option></select></th>
167
+                                    <th><input class="column-search-bar form-control" type="text" placeholder="Search"/></th>
168
+                                </tr>
169
+                            </tfoot>
170
+                            <tbody>
171
+                                @foreach($grouped_courses as $grouped_course)
172
+                                    <tr>
173
+                                        <td class="col-md-2">{{ HTML::linkAction('CoursesController@showGrouped', $grouped_course->code.$grouped_course->number.' ('.$grouped_course->semester->code.')', array($grouped_course->code, $grouped_course->number, $grouped_course->semester->code)) }}</td>
174
+                                        <td class="col-md-4">{{{ $grouped_course->name}}}</td>
175
+                                        <td class="col-md-2">{{{ $grouped_course->program_code}}}</td>
176
+                                        <td class="col-md-3">{{{ $grouped_course->quantity }}}</td>
177
+                                    </tr>
178
+                                @endforeach
179
+                            </tbody>
180
+                        </table>
181
+                    @else
182
+                        <p class="lead"> No courses assigned.</p>
183
+                    @endif
184
+                </div>
185
+            </div>
186
+        </div>
187
+        <div role="tabpanel" class="tab-pane" id="contact">
188
+            <div class="row">
189
+                <div class="col-md-12">
190
+                    <h3>Contact Information</h3>
191
+                    <table class="table table-striped datatable">
192
+                        <thead>
193
+                            <tr>
194
+                                <th>Name</th>
195
+                                <th>Role</th>
196
+                                <th>Program</th>
197
+                                <th>Email</th>
198
+                                <th>Office Phone</th>
199
+                            </tr>
200
+                        </thead>
201
+                        <tfoot>
202
+                            <tr class="column-search">
203
+                                <th><input class="column-search-bar form-control" type="text" placeholder="Search"/></th>
204
+                                <th><select class="column-search-select form-control"><option value=""></option></select></th>
205
+                                <th><select class="column-search-select form-control"><option value=""></option></select></th>
206
+                                <th><input class="column-search-bar form-control" type="text" placeholder="Search"/></th>
207
+                                <th><input class="column-search-bar form-control" type="text" placeholder="Search"/></th>
208
+                            </tr>
209
+                        </tfoot>
210
+                        <tbody>
211
+                            @foreach($users as $user)
212
+                                <tr>
213
+                                    <td>{{ $user->surnames }}, {{ $user->first_name }}</td>
214
+
215
+                                    @if($user->role == 1)
216
+                                        <td>Administrator</td>
217
+                                        <td>All</td>
218
+                                    @elseif($user->role == 2)
219
+                                        <td>School Coordinator</td>
220
+                                        <td>All in {{ $program->school->name }}</td>
221
+                                    @elseif($user->role == 3)
222
+                                        <td>Program Coordinator</td>
223
+                                        <td>
224
+                                            @foreach ($user->programs as $program)
225
+                                                {{ $program->name }}&nbsp;
226
+                                            @endforeach
227
+                                        </td>
228
+                                    @else
229
+                                        <td>Professor</td>
230
+                                        <td>
231
+                                            @foreach ($user->programs as $program)
232
+                                                {{ $program->name }}&nbsp;
233
+                                            @endforeach
234
+                                        </td>
235
+                                    @endif
236
+
237
+                                    <td>
238
+                                        <a href="mailto:{{ $user->email }}">{{ $user->email }}</a>
239
+                                    </td>
240
+                                    <td>
241
+                                        @if($user->office_phone)
242
+                                            {{{ $user->office_phone }}}
243
+
244
+                                            @if($user->office_extension)
245
+                                                <span>ext.</span> {{{ $user->office_extension }}}
246
+                                            @endif
247
+                                        @else
248
+                                            Not set
249
+                                        @endif
250
+                                    </td>
251
+                                </tr>
252
+                            @endforeach
253
+                        </tbody>
254
+                    </table>
255
+                </div>
256
+            </div>
257
+        </div>
258
+    </div>
259
+</div>
260
+<!-- =================== end tabs =================== -->
261
+
262
+@stop
263
+
264
+@section('included-js')
265
+
266
+<!-- HighCharts -->
267
+<script src="{{ asset('vendor/highcharts/highcharts.js') }}"></script>
268
+<!--script src="http://code.highcharts.com/modules/exporting.js"></script -->
269
+
270
+<!-- Datatables -->
271
+@include('global._datatables_js')
272
+
273
+@stop
274
+
275
+@section('javascript')
276
+
277
+$('#programTabs a').click(function (e) {
278
+    e.preventDefault()
279
+    $(this).tab('show');
280
+});
281
+
282
+
283
+$('#graph').highcharts({
284
+    chart: {
285
+        type: 'bar'
286
+    },
287
+    title: {
288
+        text: 'Performance of {{ $program->name }} Students by Uncombined Learning Outcome'
289
+    },
290
+    legend: {
291
+                reversed: true,
292
+            },
293
+    xAxis: {
294
+        categories: [
295
+            @foreach($outcomes as $outcome)
296
+                "{{{ $outcome->name }}}<br>(N = {{{ $outcomes_attempted[$outcome->id] }}}, {{{ $outcomes_achieved[$outcome->id] }}})",
297
+            @endforeach
298
+        ],
299
+        labels: {
300
+            style: {
301
+                fontSize:'11px'
302
+            },
303
+            step:1,
304
+            useHTML:true,
305
+            formatter: function() {
306
+                return '<div style="width:200px; word-break:break; text-overflow:ellipsis; overflow:hidden;">'+this.value+'</div>';
307
+            },
308
+        }
309
+    },
310
+    yAxis: {
311
+        min: 0,
312
+        max: 100,
313
+        title: {
314
+            text: 'Percentage'
315
+        },
316
+			plotLines:[{
317
+		value:70,
318
+		color: '#000',
319
+		width:3,
320
+		zIndex:4,
321
+		label:{
322
+			text: 'Goal (70%)',
323
+			style: {
324
+				color: '#000',
325
+				fontSize: '14px',
326
+			}
327
+
328
+		}
329
+	}]
330
+
331
+    },
332
+    tooltip: {
333
+        headerFormat: '<span style="font-size:10px">{point.key}</span><table>',
334
+        pointFormat: '<tr><td style="color:{series.color};padding:0">{series.name}: </td>' +
335
+            '<td style="padding:0"><b>{point.y:.2f}</b></td></tr>',
336
+        footerFormat: '</table>',
337
+        shared: true,
338
+        useHTML: true
339
+    },
340
+    plotOptions: {
341
+        bar: {
342
+            //grouping: false,
343
+            shadow: false,
344
+            borderWidth: 0,
345
+        },
346
+        series: {
347
+        pointPadding: 0,
348
+        groupPadding: 0.075
349
+        },
350
+    },
351
+    series: [{
352
+        name: 'Expected Value',
353
+        color: '#555555',
354
+        dataLabels: {
355
+            enabled: true,
356
+            fontSize: 8,
357
+            color: '#fff',
358
+            align: 'right',
359
+            format: '{y:.1f}%',
360
+            style: {
361
+                //fontWeight: 'bold'
362
+            },
363
+            y:-1
364
+        },
365
+        data: [
366
+            @foreach($outcomes as $index => $outcome)
367
+                @if(
368
+                    is_array($outcomes_attempted)
369
+                    && array_key_exists($outcome->id, $outcomes_attempted)
370
+                    && $outcomes_attempted[$outcome->id]!=0)
371
+                @else
372
+                    0,
373
+                @endif
374
+            @endforeach
375
+        ]
376
+
377
+    },{
378
+        name: 'Obtained Value',
379
+        color: '#e70033',
380
+        dataLabels: {
381
+            enabled: true,
382
+            fontSize: 8,
383
+            color: '#fff',
384
+            align: 'right',
385
+            format: '{y:.1f}%',
386
+            style: {
387
+                //fontWeight: 'bold'
388
+            },
389
+            y:-1
390
+        },
391
+        data:[
392
+            @foreach($outcomes as $index => $outcome)
393
+                @if(
394
+                    is_array($outcomes_attempted)
395
+                    && array_key_exists($outcome->id, $outcomes_attempted)
396
+                    && $outcomes_attempted[$outcome->id]!=0)
397
+                    {{{ ($outcomes_achieved[$outcome->id]/$outcomes_attempted[$outcome->id])*100 }}},
398
+                @else
399
+                    0,
400
+                @endif
401
+            @endforeach
402
+        ]
403
+    }]
404
+});
405
+
406
+$('#graph2').highcharts({
407
+    chart: {
408
+        type: 'bar'
409
+    },
410
+    title: {
411
+        text: 'Performance of {{ $program->name }} Students by Combined Learning Outcome'
412
+    },
413
+    legend: {
414
+                reversed: true,
415
+            },
416
+    xAxis: {
417
+        categories: [
418
+            @foreach($outcomes_colap as $outcome)
419
+                "{{{ $outcome->name }}}<br>(N = {{{ $outcomes_attempted_colap[$outcome->id] }}}, {{{ $outcomes_achieved_colap[$outcome->id] }}})",
420
+            @endforeach
421
+        ],
422
+        labels: {
423
+            style: {
424
+                fontSize:'11px'
425
+            },
426
+            step:1,
427
+            useHTML:true,
428
+            formatter: function() {
429
+                return '<div style="width:200px; word-break:break; text-overflow:ellipsis; overflow:hidden;">'+this.value+'</div>';
430
+            },
431
+        }
432
+    },
433
+    yAxis: {
434
+        min: 0,
435
+        max: 100,
436
+        title: {
437
+            text: 'Percentage'
438
+        },
439
+        			plotLines:[{
440
+		value:70,
441
+		color: '#000',
442
+		width:3,
443
+		zIndex:4,
444
+		label:{
445
+			text: 'Goal (70%)',
446
+			style: {
447
+				color: '#000',
448
+				fontSize: '14px',
449
+			}
450
+
451
+		}
452
+	}]
453
+
454
+    },
455
+    tooltip: {
456
+        headerFormat: '<span style="font-size:10px">{point.key}</span><table>',
457
+        pointFormat: '<tr><td style="color:{series.color};padding:0">{series.name}: </td>' +
458
+            '<td style="padding:0"><b>{point.y:.2f}</b></td></tr>',
459
+        footerFormat: '</table>',
460
+        shared: true,
461
+        useHTML: true
462
+    },
463
+    plotOptions: {
464
+        bar: {
465
+            //grouping: false,
466
+            shadow: false,
467
+            borderWidth: 0,
468
+        },
469
+        series: {
470
+        pointPadding: 0,
471
+        groupPadding: 0.075
472
+        },
473
+    },
474
+    series: [{
475
+        name: 'Expected Value',
476
+        color: '#555555',
477
+        dataLabels: {
478
+            enabled: true,
479
+            fontSize: 8,
480
+            color: '#fff',
481
+            align: 'right',
482
+            format: '{y:.1f}%',
483
+            style: {
484
+                //fontWeight: 'bold'
485
+            },
486
+            y:-1
487
+        },
488
+        data: [
489
+            @foreach($outcomes_colap as $index => $outcome)
490
+                @if(
491
+                    is_array($outcomes_attempted_colap)
492
+                    && array_key_exists($outcome->id, $outcomes_attempted_colap)
493
+                    && $outcomes_attempted_colap[$outcome->id]!=0)
494
+                @else
495
+                    0,
496
+                @endif
497
+            @endforeach
498
+        ]
499
+
500
+    },{
501
+        name: 'Obtained Value',
502
+        color: '#e70033',
503
+        dataLabels: {
504
+            enabled: true,
505
+            fontSize: 8,
506
+            color: '#fff',
507
+            align: 'right',
508
+            format: '{y:.1f}%',
509
+            style: {
510
+                //fontWeight: 'bold'
511
+            },
512
+            y:-1
513
+        },
514
+        data:[
515
+            @foreach($outcomes_colap as $index => $outcome)
516
+                @if(
517
+                    is_array($outcomes_attempted_colap)
518
+                    && array_key_exists($outcome->id, $outcomes_attempted)
519
+                    && $outcomes_attempted_colap[$outcome->id]!=0)
520
+                    {{{ ($outcomes_achieved_colap[$outcome->id]/$outcomes_attempted_colap[$outcome->id])*100 }}},
521
+                @else
522
+                    0,
523
+                @endif
524
+            @endforeach
525
+        ]
526
+    }]
527
+});
528
+
529
+// Include dummy graph for outcomes
530
+@include('global.dummy-outcomes')
531
+
532
+@stop

+ 570
- 0
app/views/local/managers/shared/school_student_result.blade.php Целия файл

@@ -0,0 +1,570 @@
1
+@extends('layouts.master')
2
+
3
+
4
+@section('navigation')
5
+    @if($role==1)
6
+        @include('local.managers.admins._navigation')
7
+    @elseif($role==2)
8
+        @include('local.managers.sCoords._navigation')
9
+    @endif
10
+@stop
11
+
12
+@section('main')
13
+<a href="{{ action('SchoolsController@show', array($school->id)); }}" class="btn btn-primary pull-left" alt="print">Go to Performance by School Courses</a>
14
+
15
+<a href="{{ action('ProgramsController@print_program', array($school->id)); }}" class="btn btn-primary pull-right" alt="print"><span class="glyphicon glyphicon-print"></span></a>
16
+<br>
17
+<br>
18
+<div class="row">
19
+    <ul id="resultsTabs" class="nav nav-tabs" role="tablist">
20
+        <li role="presentation" class="active"><a href="#combined" aria-controls="combined" role="tab">Combined</a></li>
21
+        <li role="presentation"><a href="#uncombined" aria-controls="uncombined" role="tab">Uncombined</a></li>
22
+    </ul>
23
+	<div>
24
+<!-- 	<div class="tab-content"> -->
25
+
26
+	<div role="tabpanel" class="tab-pane active" id="combined">
27
+	<div class="row">
28
+		<div class="col-md-12" id="graph2"></div>
29
+	</div>
30
+
31
+            <div class="row">
32
+                <div class="col-md-12">
33
+                    <h3>Performance of {{ $school->name }} Students by Combined Learning Outcome</h3>
34
+                    @if($outcomes->count()>0)
35
+                        <table class="table table-striped table-condensed datatable">
36
+                            <thead>
37
+                                <tr>
38
+                                    <th>Learning Outcome</th>
39
+                                    <th>Program</th>
40
+                                    <th>Program Id</th>
41
+                                    <th>Program Is Graduate</th>
42
+                                    <th>Number Students</th>
43
+                                    <th>Number Students that Achieved the Target</th>
44
+                                    <th>Percentage of Students that Achieved the Target</th>
45
+                                    <th>Semesters</th>
46
+                                </tr>
47
+                            </thead>
48
+                            <tfoot>
49
+                                <tr class="column-search">
50
+                                    <th><input class="column-search-bar form-control" type="text" placeholder="Search"/></th>
51
+                                    <th><select class="column-search-select form-control"><option value=""></option></select></th>
52
+                                    <th><select class="column-search-select form-control"><option value=""></option></select></th>
53
+                                    <th><select class="column-search-select form-control"><option value=""></option></select></th>
54
+                                    <th><input class="column-search-bar form-control" type="text" placeholder="Search"/></th>
55
+                                    <th><input class="column-search-bar form-control" type="text" placeholder="Search"/></th>
56
+                                    <th><select class="column-search-select form-control"><option value=""></option></select></th>
57
+                                    <th><input class="column-search-bar form-control" type="text" placeholder="Search"/></th>
58
+                                </tr>
59
+                            </tfoot>
60
+                            <tbody>
61
+                                @foreach($programs as $program)
62
+                                  @foreach($outcomes_colap as $outcome)
63
+                                	@if(isset($outcomes_attempted_colap[$program->id][$outcome->id]))
64
+                                    <tr>
65
+										<td>{{ link_to_action('OutcomesController@show', $outcome->name, array($outcome->id), $attributes = array()) }}</td>
66
+										<td>{{{ $program->name }}}</td>
67
+										<td>{{{ $program->id }}}</td>
68
+										<td>{{{ $program->is_graduate }}}</td>
69
+										<td>{{{ $outcomes_attempted_colap[$program->id][$outcome->id] }}}</td>
70
+										<td>{{{ $outcomes_achieved_colap[$program->id][$outcome->id] }}}</td>
71
+										<td>
72
+											@if($outcomes_attempted_colap[$program->id][$outcome->id]!=0)
73
+												{{{ round($outcomes_achieved_colap[$program->id][$outcome->id] / $outcomes_attempted_colap[$program->id][$outcome->id]*100, 2) }}}%
74
+											@else
75
+												N/M
76
+											@endif
77
+										</td>
78
+										<td>
79
+										@if(isset($outcomes_attempted_colap_semesters[$program->id][$outcome->id]))
80
+											{{{ str_replace('"','',json_encode($outcomes_attempted_colap_semesters[$program->id][$outcome->id])) }}}
81
+										@else
82
+											N/M
83
+										@endif
84
+										
85
+										</td>
86
+                                    </tr>
87
+                       				@endif
88
+                                  @endforeach
89
+                                @endforeach
90
+                            </tbody>
91
+                        </table>
92
+                    @else
93
+                        <p class="lead"> No courses assigned.</p>
94
+                    @endif
95
+                </div>
96
+            </div>
97
+            </div>
98
+		<div role="tabpanel" class="tab-pane" id="uncombined">
99
+	<div class="row">
100
+		<div class="col-md-12" id="graph"></div>
101
+	</div>
102
+
103
+            <div class="row">
104
+                <div class="col-md-12">
105
+                    <h3>Performance of {{ $school->name }} Students by Uncombined Learning Outcome</h3>
106
+                    @if($outcomes->count()>0)
107
+                        <table class="table table-striped table-condensed datatable">
108
+                            <thead>
109
+                                <tr>
110
+                                    <th>Learning Outcome</th>
111
+                                    <th>Program</th>
112
+                                    <th>Program Id</th>
113
+                                    <th>Program Is Graduate</th>
114
+                                    <th>Number Students</th>
115
+                                    <th>Number Students that Achieved the Target</th>
116
+                                    <th>Percentage of Students that Achieved the Target</th>
117
+                                    <th>Semesters</th>
118
+                                </tr>
119
+                            </thead>
120
+                            <tfoot>
121
+                                <tr class="column-search">
122
+                                    <th><input class="column-search-bar form-control" type="text" placeholder="Search"/></th>
123
+                                    <th><select class="column-search-select form-control"><option value=""></option></select></th>
124
+                                    <th><select class="column-search-select form-control"><option value=""></option></select></th>
125
+                                    <th><select class="column-search-select form-control"><option value=""></option></select></th>
126
+                                    <th><input class="column-search-bar form-control" type="text" placeholder="Search"/></th>
127
+                                    <th><input class="column-search-bar form-control" type="text" placeholder="Search"/></th>
128
+                                    <th><select class="column-search-select form-control"><option value=""></option></select></th>
129
+                                    <th><input class="column-search-bar form-control" type="text" placeholder="Search"/></th>
130
+                                </tr>
131
+                            </tfoot>
132
+                            <tbody>
133
+                                @foreach($programs as $program)
134
+                               	   @foreach($outcomes as $outcome)
135
+  											@if(isset($outcomes_attempted[$program->id][$outcome->id]))
136
+                                  <tr>
137
+										<td>{{ link_to_action('OutcomesController@show', $outcome->name, array($outcome->id), $attributes = array()) }}</td>
138
+										<td>{{{ $program->name }}}</td>
139
+										<td>{{{ $program->id }}}</td>
140
+										<td>{{{ $program->is_graduate }}}</td>
141
+										<td>{{{ $outcomes_attempted[$program->id][$outcome->id] }}}</td>
142
+										<td>{{{ $outcomes_achieved[$program->id][$outcome->id] }}}</td>
143
+										<td>
144
+											@if($outcomes_attempted[$program->id][$outcome->id]!=0)
145
+												{{{ round($outcomes_achieved[$program->id][$outcome->id] / $outcomes_attempted[$program->id][$outcome->id]*100, 2) }}}%
146
+											@else
147
+												N/M
148
+											@endif
149
+										</td>
150
+										<td>
151
+											@if(isset($outcomes_attempted_semesters[$program->id][$outcome->id]))
152
+												{{{ str_replace('"','',json_encode($outcomes_attempted_semesters[$program->id][$outcome->id])) }}}
153
+											@else
154
+												N/M
155
+											@endif
156
+										
157
+										</td>
158
+                                    </tr>
159
+											@endif
160
+                                   @endforeach
161
+                                @endforeach
162
+                            </tbody>
163
+                        </table>
164
+                    @else
165
+                        <p class="lead"> No courses assigned.</p>
166
+                    @endif
167
+                </div>
168
+            </div>
169
+</div>
170
+	</div>
171
+</div>
172
+ <!-- =================== tabs =================== -->
173
+<div class="row">
174
+    <!-- Nav tabs -->
175
+   <!-- Tab panes -->
176
+    <ul id="programTabs" class="nav nav-tabs" role="tablist">
177
+        <li role="presentation" class="active"><a href="#courses" aria-controls="courses" role="tab">Courses</a></li>
178
+        <li role="presentation"><a href="#contact" aria-controls="contact" role="tab">Contact Information</a></li>
179
+    </ul>
180
+    <div class="tab-content">
181
+
182
+       <div role="tabpanel" class="tab-pane active" id="courses">
183
+            <div class="row">
184
+                <div class="col-md-12">
185
+                    <h3>Courses in this program</h3>
186
+                    @if(count($grouped_courses)>0)
187
+                        <table class="table table-striped table-condensed datatable">
188
+                            <thead>
189
+                                <tr>
190
+                                    <th>Identifier</th>
191
+                                    <th>Name</th>
192
+                                    <th>Course Program</th>
193
+                                    <th>Number of Students</th>
194
+                                </tr>
195
+                            </thead>
196
+                            <tfoot>
197
+                                <tr class="column-search">
198
+                                    <th><input class="column-search-bar form-control" type="text" placeholder="Search"/></th>
199
+                                    <th><input class="column-search-bar form-control" type="text" placeholder="Search"/></th>
200
+                                <th><select class="column-search-select form-control"><option value=""></option></select></th>
201
+                                    <th><input class="column-search-bar form-control" type="text" placeholder="Search"/></th>
202
+                                </tr>
203
+                            </tfoot>
204
+                            <tbody>
205
+                                @foreach($grouped_courses as $grouped_course)
206
+                                    <tr>
207
+                                        <td class="col-md-2">{{ HTML::linkAction('CoursesController@showGrouped', $grouped_course->code.$grouped_course->number.' ('.$grouped_course->semester->code.')', array($grouped_course->code, $grouped_course->number, $grouped_course->semester->code)) }}</td>
208
+                                        <td class="col-md-4">{{{ $grouped_course->name}}}</td>
209
+                                        <td class="col-md-2">{{{ $grouped_course->program_code}}}</td>
210
+                                        <td class="col-md-3">{{{ $grouped_course->quantity }}}</td>
211
+                                    </tr>
212
+                                @endforeach
213
+                            </tbody>
214
+                        </table>
215
+                    @else
216
+                        <p class="lead"> No courses assigned.</p>
217
+                    @endif
218
+                </div>
219
+            </div>
220
+        </div>
221
+        <div role="tabpanel" class="tab-pane" id="contact">
222
+            <div class="row">
223
+                <div class="col-md-12">
224
+                    <h3>Contact Information</h3>
225
+                    <table class="table table-striped datatable">
226
+                        <thead>
227
+                            <tr>
228
+                                <th>Name</th>
229
+                                <th>Role</th>
230
+                                <th>Program</th>
231
+                                <th>Email</th>
232
+                                <th>Office Phone</th>
233
+                            </tr>
234
+                        </thead>
235
+                        <tfoot>
236
+                            <tr class="column-search">
237
+                                <th><input class="column-search-bar form-control" type="text" placeholder="Search"/></th>
238
+                                <th><select class="column-search-select form-control"><option value=""></option></select></th>
239
+                                <th><select class="column-search-select form-control"><option value=""></option></select></th>
240
+                                <th><input class="column-search-bar form-control" type="text" placeholder="Search"/></th>
241
+                                <th><input class="column-search-bar form-control" type="text" placeholder="Search"/></th>
242
+                            </tr>
243
+                        </tfoot>
244
+                        <tbody>
245
+                            @foreach($users as $user)
246
+                                <tr>
247
+                                    <td>{{ $user->surnames }}, {{ $user->first_name }}</td>
248
+
249
+                                    @if($user->role == 1)
250
+                                        <td>Administrator</td>
251
+                                        <td>All</td>
252
+                                    @elseif($user->role == 2)
253
+                                        <td>School Coordinator</td>
254
+                                        <td>All in {{ $program->school->name }}</td>
255
+                                    @elseif($user->role == 3)
256
+                                        <td>Program Coordinator</td>
257
+                                        <td>
258
+                                            @foreach ($user->programs as $program)
259
+                                                {{ $program->name }}&nbsp;
260
+                                            @endforeach
261
+                                        </td>
262
+                                    @else
263
+                                        <td>Professor</td>
264
+                                        <td>
265
+                                            @foreach ($user->programs as $program)
266
+                                                {{ $program->name }}&nbsp;
267
+                                            @endforeach
268
+                                        </td>
269
+                                    @endif
270
+
271
+                                    <td>
272
+                                        <a href="mailto:{{ $user->email }}">{{ $user->email }}</a>
273
+                                    </td>
274
+                                    <td>
275
+                                        @if($user->office_phone)
276
+                                            {{{ $user->office_phone }}}
277
+
278
+                                            @if($user->office_extension)
279
+                                                <span>ext.</span> {{{ $user->office_extension }}}
280
+                                            @endif
281
+                                        @else
282
+                                            Not set
283
+                                        @endif
284
+                                    </td>
285
+                                </tr>
286
+                            @endforeach
287
+                        </tbody>
288
+                    </table>
289
+                </div>
290
+            </div>
291
+        </div>
292
+    </div>
293
+</div>
294
+<!-- =================== end tabs =================== -->
295
+
296
+@stop
297
+
298
+@section('included-js')
299
+
300
+<!-- HighCharts -->
301
+<script src="{{ asset('vendor/highcharts/highcharts.js') }}"></script>
302
+<!--script src="http://code.highcharts.com/modules/exporting.js"></script -->
303
+
304
+<!-- Datatables -->
305
+@include('global._datatables_js')
306
+
307
+@stop
308
+
309
+@section('javascript')
310
+
311
+$('#programTabs a').click(function (e) {
312
+    e.preventDefault()
313
+    $(this).tab('show');
314
+});
315
+
316
+
317
+$('#graph').highcharts({
318
+    chart: {
319
+        type: 'bar'
320
+    },
321
+    title: {
322
+        text: 'Performance of {{ $school->name }} Students by Uncombined Learning Outcome'
323
+    },
324
+    legend: {
325
+                reversed: true,
326
+            },
327
+    xAxis: {
328
+        categories: [
329
+            @foreach($outcomes as $outcome)
330
+            	@if(isset($outcomes_attempted_todo[$outcome->id]))
331
+                 "{{{ $outcome->name }}}<br>(N = {{{ $outcomes_attempted_todo[$outcome->id] }}}, {{{ $outcomes_achieved_todo[$outcome->id] }}})",
332
+            	@else
333
+                    "{{{ $outcome->name }}}<br>(N = 0, 0)",         	
334
+            	@endif
335
+            @endforeach
336
+        ],
337
+        labels: {
338
+            style: {
339
+                fontSize:'11px'
340
+            },
341
+            step:1,
342
+            useHTML:true,
343
+            formatter: function() {
344
+                return '<div style="width:200px; word-break:break; text-overflow:ellipsis; overflow:hidden;">'+this.value+'</div>';
345
+            },
346
+        }
347
+    },
348
+    yAxis: {
349
+        min: 0,
350
+        max: 100,
351
+        title: {
352
+            text: 'Percentage'
353
+        },
354
+			plotLines:[{
355
+		value:70,
356
+		color: '#000',
357
+		width:3,
358
+		zIndex:4,
359
+		label:{
360
+			text: 'Goal (70%)',
361
+			style: {
362
+				color: '#000',
363
+				fontSize: '14px',
364
+			}
365
+
366
+		}
367
+	}]
368
+
369
+    },
370
+    tooltip: {
371
+        headerFormat: '<span style="font-size:10px">{point.key}</span><table>',
372
+        pointFormat: '<tr><td style="color:{series.color};padding:0">{series.name}: </td>' +
373
+            '<td style="padding:0"><b>{point.y:.2f}</b></td></tr>',
374
+        footerFormat: '</table>',
375
+        shared: true,
376
+        useHTML: true
377
+    },
378
+    plotOptions: {
379
+        bar: {
380
+            //grouping: false,
381
+            shadow: false,
382
+            borderWidth: 0,
383
+        },
384
+        series: {
385
+        pointPadding: 0,
386
+        groupPadding: 0.075
387
+        },
388
+    },
389
+    series: [{
390
+        name: 'Expected Value',
391
+        color: '#555555',
392
+        dataLabels: {
393
+            enabled: true,
394
+            fontSize: 8,
395
+            color: '#fff',
396
+            align: 'right',
397
+            format: '{y:.1f}%',
398
+            style: {
399
+                //fontWeight: 'bold'
400
+            },
401
+            y:-1
402
+        },
403
+        data: [
404
+            @foreach($outcomes as $index => $outcome)
405
+                @if(
406
+                    is_array($outcomes_attempted_todo)
407
+                    && array_key_exists($outcome->id, $outcomes_attempted_todo)
408
+                    && $outcomes_attempted_todo[$outcome->id]!=0)
409
+                @else
410
+                    0,
411
+                @endif
412
+            @endforeach
413
+        ]
414
+
415
+    },{
416
+        name: 'Obtained Value',
417
+        color: '#e70033',
418
+        dataLabels: {
419
+            enabled: true,
420
+            fontSize: 8,
421
+            color: '#fff',
422
+            align: 'right',
423
+            format: '{y:.1f}%',
424
+            style: {
425
+                //fontWeight: 'bold'
426
+            },
427
+            y:-1
428
+        },
429
+        data:[
430
+            @foreach($outcomes as $index => $outcome)
431
+                @if(
432
+                    is_array($outcomes_attempted_todo)
433
+                    && array_key_exists($outcome->id, $outcomes_attempted_todo)
434
+                    && $outcomes_attempted_todo[$outcome->id]!=0)
435
+                    {{{ ($outcomes_achieved_todo[$outcome->id]/$outcomes_attempted_todo[$outcome->id])*100 }}},
436
+                @else
437
+                    0,
438
+                @endif
439
+            @endforeach
440
+        ]
441
+    }]
442
+});
443
+
444
+$('#graph2').highcharts({
445
+    chart: {
446
+        type: 'bar'
447
+    },
448
+    title: {
449
+        text: 'Performance of {{ $school->name }} Students by Combined Learning Outcome'
450
+    },
451
+    legend: {
452
+                reversed: true,
453
+            },
454
+    xAxis: {
455
+        categories: [
456
+            @foreach($outcomes_colap as $outcome)
457
+                "{{{ $outcome->name }}}<br>(N = {{{ $outcomes_attempted_colap_todo[$outcome->id] }}}, {{{ $outcomes_achieved_colap_todo[$outcome->id] }}})",
458
+            @endforeach
459
+        ],
460
+        labels: {
461
+            style: {
462
+                fontSize:'11px'
463
+            },
464
+            step:1,
465
+            useHTML:true,
466
+            formatter: function() {
467
+                return '<div style="width:200px; word-break:break; text-overflow:ellipsis; overflow:hidden;">'+this.value+'</div>';
468
+            },
469
+        }
470
+    },
471
+    yAxis: {
472
+        min: 0,
473
+        max: 100,
474
+        title: {
475
+            text: 'Percentage'
476
+        },
477
+        			plotLines:[{
478
+		value:70,
479
+		color: '#000',
480
+		width:3,
481
+		zIndex:4,
482
+		label:{
483
+			text: 'Goal (70%)',
484
+			style: {
485
+				color: '#000',
486
+				fontSize: '14px',
487
+			}
488
+
489
+		}
490
+	}]
491
+
492
+    },
493
+    tooltip: {
494
+        headerFormat: '<span style="font-size:10px">{point.key}</span><table>',
495
+        pointFormat: '<tr><td style="color:{series.color};padding:0">{series.name}: </td>' +
496
+            '<td style="padding:0"><b>{point.y:.2f}</b></td></tr>',
497
+        footerFormat: '</table>',
498
+        shared: true,
499
+        useHTML: true
500
+    },
501
+    plotOptions: {
502
+        bar: {
503
+            //grouping: false,
504
+            shadow: false,
505
+            borderWidth: 0,
506
+        },
507
+        series: {
508
+        pointPadding: 0,
509
+        groupPadding: 0.075
510
+        },
511
+    },
512
+    series: [{
513
+        name: 'Expected Value',
514
+        color: '#555555',
515
+        dataLabels: {
516
+            enabled: true,
517
+            fontSize: 8,
518
+            color: '#fff',
519
+            align: 'right',
520
+            format: '{y:.1f}%',
521
+            style: {
522
+                //fontWeight: 'bold'
523
+            },
524
+            y:-1
525
+        },
526
+        data: [
527
+            @foreach($outcomes_colap as $index => $outcome)
528
+                @if(
529
+                    is_array($outcomes_attempted_colap_todo)
530
+                    && array_key_exists($outcome->id, $outcomes_attempted_colap_todo)
531
+                    && $outcomes_attempted_colap_todo[$outcome->id]!=0)
532
+                @else
533
+                    0,
534
+                @endif
535
+            @endforeach
536
+        ]
537
+
538
+    },{
539
+        name: 'Obtained Value',
540
+        color: '#e70033',
541
+        dataLabels: {
542
+            enabled: true,
543
+            fontSize: 8,
544
+            color: '#fff',
545
+            align: 'right',
546
+            format: '{y:.1f}%',
547
+            style: {
548
+                //fontWeight: 'bold'
549
+            },
550
+            y:-1
551
+        },
552
+        data:[
553
+            @foreach($outcomes_colap as $index => $outcome)
554
+                @if(
555
+                    is_array($outcomes_attempted_colap_todo)
556
+                    && array_key_exists($outcome->id, $outcomes_attempted_todo)
557
+                    && $outcomes_attempted_colap_todo[$outcome->id]!=0)
558
+                    {{{ ($outcomes_achieved_colap_todo[$outcome->id]/$outcomes_attempted_colap_todo[$outcome->id])*100 }}},
559
+                @else
560
+                    0,
561
+                @endif
562
+            @endforeach
563
+        ]
564
+    }]
565
+});
566
+
567
+// Include dummy graph for outcomes
568
+@include('global.dummy-outcomes')
569
+
570
+@stop