No Description

assessment_report.blade.php 16KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274
  1. @extends('layouts.master')
  2. @section('navigation')
  3. @if (Auth::user()->role == 1)
  4. @include('local.managers.admins._new_navigation')
  5. @elseif(Auth::user()->role == 2)
  6. @include('local.managers.sCoords._new_navigation')
  7. @elseif(Auth::user()->role == 3)
  8. @include('local.managers.pCoords._new_navigation')
  9. @endif
  10. @stop
  11. @section('main')
  12. <div class="row">
  13. <div class="col-md-12">
  14. <p>This report contains performance information for all your School's Programs with assessed courses during the
  15. following semester(s):</p>
  16. <ul>
  17. @foreach (Session::get('semesters_info') as $semester_info)
  18. <li>{{ $semester_info }}</li>
  19. @endforeach
  20. </ul>
  21. @if (!$school->programs->isEmpty())
  22. <p class="hidden-print">Unlinked programs did not assess this outcome.</p>
  23. <h3>Table of Contents</h3>
  24. <ol id="table-of-contents" class="upper-roman">
  25. </ol>
  26. <h3 id="{{ $outcome->id }}" class="outcome">{{ $outcome->name }}</h3>
  27. <table class="table table-condensed table-bordered">
  28. <thead>
  29. <tr>
  30. <th colspan="12">
  31. <h4 id="{{ $outcome->id }}-{{ $school->id }}" class="school table-header">
  32. {{ $school->name }}
  33. </h4>
  34. </th>
  35. </tr>
  36. <tr class="center-text">
  37. <th>Academic Program</th>
  38. <th>Findings</th>
  39. </tr>
  40. </thead>
  41. <tbody>
  42. @foreach ($school->programs as $program)
  43. @if ($program->assessesOutcome($outcome->id))
  44. <tr>
  45. <td id="{{ $outcome->id }}-{{ $school->id }}-{{ $program->id }}"
  46. class="program col-md-3">
  47. <h5>{{ $program->name }}</h5>
  48. </td>
  49. <td class="col-md-9">
  50. <!-- For each grouped course -->
  51. @foreach ($program->courses as $index2 => $course)
  52. <!-- If grouped course has activities that evaluate the outcome -->
  53. <?php
  54. $sections_evaluating = Course::has('activities')
  55. ->whereNotNull('outcomes_attempted')
  56. ->whereRaw('outcomes_attempted not like \'%"' . $outcome->id . '":0%\'')
  57. ->with([
  58. 'activities' => function ($query) use (&$outcome) {
  59. $query->whereNotNull('outcomes_attempted');
  60. $query->whereRaw('outcomes_attempted not like \'%"' . $outcome->id . '":0%\'');
  61. },
  62. ])
  63. ->where('code', $course->code)
  64. ->where('number', $course->number)
  65. ->whereIn('semester_id', Session::get('semesters_ids'))
  66. ->get();
  67. ?>
  68. @if (count($sections_evaluating))
  69. <a class="to-top hidden-print" href="">
  70. <span class="glyphicon glyphicon-arrow-up"></span>
  71. To Top
  72. </a>
  73. <h4>{{ $course->code }}-{{ $course->number }}</h4>
  74. <!-- For each section -->
  75. @foreach ($sections_evaluating as $index3 => $section)
  76. <h5><u>Instance {{ $index3 + 1 }}</u></h5>
  77. <!-- For each activity in the section -->
  78. @foreach ($section->activities as $index4 => $activity)
  79. <!-- If activity has a rubric and the rubric has the outcome being evaluated -->
  80. @if (array_key_exists($outcome->id, (array) $activity->o_att_array) && $activity->o_att_array[$outcome->id] >= 1)
  81. <h5>Measure {{ $index4 + 1 }}</h5>
  82. <p>A rubric was used in the
  83. {{ $section->code }}-{{ $section->number }}
  84. ({{ $section->name }})
  85. course
  86. ({{ date('M Y', strtotime($course->updated_at)) }}) to
  87. assess students’ <u>{{ strtolower($outcome->name) }}</u>
  88. in the activity:
  89. "<strong>{{ $activity->name }}</strong>". N=
  90. {{ count($section->students) }}. </p>
  91. <p>The expected performance level was that
  92. <strong>{{ $activity->rubric->expected_percentage }}%</strong>
  93. of students participating in the activity would score
  94. <strong>{{ $activity->rubric->expected_points }}
  95. points</strong> or more in the 1-8 point scale used.
  96. </p>
  97. <p>The results for each criterion were as follows:</p>
  98. <table class="table table-condensed table-bordered">
  99. @foreach ((array) $activity->cap_array as $index5 => $cap)
  100. <?php
  101. $criterion = Criterion::find($index5);
  102. ?>
  103. @if ($criterion['outcome_id'] == $outcome->id && $cap >= $activity->rubric->expected_percentage)
  104. <tr>
  105. <td>{{ $criterion['name'] }}</td>
  106. <td class="col-md-1 success">
  107. {{ $cap }}%</td>
  108. </tr>
  109. @elseif($criterion['outcome_id'] == $outcome->id && $cap < $activity->rubric->expected_percentage)
  110. <tr>
  111. <td>{{ $criterion['name'] }}</td>
  112. <td class="col-md-1 danger">
  113. {{ $cap }}%</td>
  114. </tr>
  115. @endif
  116. @endforeach
  117. </table>
  118. <ul>
  119. </ul>
  120. <p>
  121. <?php
  122. $o_att_array = $activity->o_att_array;
  123. $o_ach_array = $activity->o_ach_array;
  124. $percentage = ($o_ach_array[$outcome->id] / $o_att_array[$outcome->id]) * 100;
  125. ?>
  126. @if ($percentage >= 100)
  127. The expected goal was reached in <strong>all</strong>
  128. (100%) of the criteria assessed. Therefore, the goal for
  129. this outcome ({{ $outcome->expected_outcome }}%) was
  130. <strong>met</strong>.
  131. @elseif ($percentage < 1)
  132. The expected goal was reached in <strong>none</strong>
  133. (0%) of the criteria assessed. Therefore, the goal for
  134. this outcome ({{ $outcome->expected_outcome }}%) was
  135. <strong>not met</strong>.
  136. @elseif ($percentage >= $outcome->expected_outcome)
  137. The expected goal was reached in
  138. <strong>{{ $o_ach_array[$outcome->id] }}</strong> out
  139. of the
  140. <strong>{{ $o_att_array[$outcome->id] }}</strong>
  141. ({{ round($percentage, 2) }}%) criteria assessed.
  142. Therefore, the goal for this outcome
  143. ({{ $outcome->expected_outcome }}%) was
  144. <strong>met</strong>.
  145. @elseif ($percentage < $outcome->expected_outcome)
  146. The expected goal was reached in
  147. <strong>{{ $o_ach_array[$outcome->id] }}</strong> out
  148. of the
  149. <strong>{{ $o_att_array[$outcome->id] }}</strong>
  150. ({{ round($percentage, 2) }}%) criteria assessed.
  151. Therefore, the goal for this outcome
  152. ({{ $outcome->expected_outcome }}%) was <strong> not
  153. met</strong>.
  154. @endif
  155. </p>
  156. <h5><strong>Transformative Actions</strong></h5>
  157. @if ($activity->transforming_actions)
  158. {{ $activity->transforming_actions }}
  159. @else
  160. None
  161. @endif
  162. <br><br>
  163. @else
  164. <h5>Measure {{ $index4 + 1 }}</h5>
  165. <em>Outcome not measured.</em>
  166. @endif
  167. @endforeach
  168. @endforeach
  169. <hr>
  170. @endif
  171. @endforeach
  172. </td>
  173. </tr>
  174. @else
  175. <tr>
  176. <td id="{{ $outcome->id }}-{{ $school->id }}-{{ $program->id }}"
  177. class="program no-courses col-md-3">{{ $program->name }}</td>
  178. <td class="col-md-9">
  179. This program does not assess {{ $outcome->name }}.
  180. </td>
  181. </tr>
  182. @endif
  183. @endforeach
  184. </tbody>
  185. </table>
  186. @else
  187. <p class="lead">No programs have assessed courses during the selected semesters.</p>
  188. @endif
  189. </div>
  190. </div>
  191. @stop
  192. @section('javascript')
  193. // Hide tables that have no courses
  194. $('.no-courses').each(function() {
  195. // $(this).closest('tr').hide();
  196. });
  197. // Hide tables with empty bodies
  198. $('tbody').each(function() {
  199. if($(this).children(':visible').length==0)
  200. {
  201. $(this).closest('table').hide();
  202. }
  203. });
  204. // Build table of contents
  205. var outcome = $('.outcome');
  206. var str ='';
  207. str+='<li><a href="#'+outcome.attr('id')+'">'+outcome.text()+'</a>
  208. <ol class="schools upper-alpha">';
  209. $('[id^='+outcome.attr('id')+'-].school:visible').each(function(e){
  210. var school = $(this);
  211. str+='<li><a href="#'+school.attr('id')+'">'+school.text()+'</a>
  212. <ol class="programs">';
  213. $('[id^='+school.attr('id')+'-].program:visible').each(function(e){
  214. var program = $(this);
  215. if(!program.hasClass('no-courses'))
  216. str+='<li><a href="#'+program.attr('id')+'">'+program.text()+'</a></li>';
  217. else
  218. str+='<li>'+program.text()+'</li>';
  219. });
  220. str+='</ol>
  221. </li>';
  222. });
  223. str+='</ol>
  224. </li>';
  225. // console.log(str);
  226. $('#table-of-contents').append(str);
  227. // ----------------------------------------------------------------------------
  228. // Events
  229. //
  230. $('.to-top').on('click', function(e) {
  231. e.preventDefault();
  232. $(this).scrollTop(0);
  233. $('html').animate({scrollTop:0}, 1);
  234. $('body').animate({scrollTop:0}, 1);
  235. })
  236. @stop