No Description

assessment_report.blade.php 13KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228
  1. @extends('layouts.master')
  2. @section('navigation')
  3. @include('local.managers.admins._navigation')
  4. @stop
  5. @section('main')
  6. <div class="row">
  7. <div class="col-md-12">
  8. <p>This report contains performance information for all Schools and Programs with assessed courses during the following semester(s):</p>
  9. <ul>
  10. @foreach (Session::get('semesters_info') as $semester_info)
  11. <li>{{ $semester_info }}</li>
  12. @endforeach
  13. </ul>
  14. <p class="hidden-print">Unlinked programs did not assess this outcome.</p>
  15. <!-- <h3>Table of Contents</h3> -->
  16. <!-- <ol id="table-of-contents" class="upper-roman">
  17. </ol> -->
  18. <h3 id="{{ $outcome->id }}" class="outcome">{{ $outcome->name }}</h3>
  19. <table class="table table-condensed table-bordered datatable">
  20. <thead>
  21. <tr class="center-text">
  22. <th>School or College</th>
  23. <th>Academic Program</th>
  24. <th>Assesses Outcome</th>
  25. <th>Findings</th>
  26. </tr>
  27. </thead>
  28. <tfoot>
  29. <tr class="column-search">
  30. <th><select class="column-search-select form-control"><option value=""></option></select></th>
  31. <th><select class="column-search-select form-control"><option value=""></option></select></th>
  32. <th><select class="column-search-select form-control"><option value=""></option></select></th>
  33. <th><input class="column-search-bar form-control" type="text" placeholder="Buscar"/></th>
  34. </tr>
  35. </tfoot>
  36. <tbody>
  37. @foreach ($schools as $school)
  38. @foreach ($school->programs as $program)
  39. @if($program->assessesOutcome($outcome->id))
  40. <tr>
  41. <td>{{ $school->name }}</td>
  42. <td>{{ $program->name }}</td>
  43. <td>Yes</td>
  44. <td>
  45. <!-- For each grouped course -->
  46. @foreach($program->courses as $course_index => $course)
  47. <!-- If grouped course has activities that evaluate the outcome -->
  48. <?php
  49. $sections_evaluating_outcome = Course::has('activities')
  50. ->whereNotNull('outcomes_attempted')
  51. ->whereRaw('outcomes_attempted not like \'%"'.$outcome->id.'":0%\'')
  52. ->with(array('activities'=>function($query) use(&$outcome){
  53. $query->whereNotNull('outcomes_attempted');
  54. $query->whereRaw('outcomes_attempted not like \'%"'.$outcome->id.'":0%\'');} ))
  55. ->where('code', $course->code)->where('number',$course->number)
  56. ->whereIn('semester_id', Session::get('semesters_ids'))
  57. ->get();
  58. ?>
  59. @if(count($sections_evaluating_outcome))
  60. <h4>{{ $course->code}}-{{ $course->number }}</h4>
  61. <!-- For each section -->
  62. @foreach($sections_evaluating_outcome as $section_index => $section)
  63. <h5><u>Instance {{ $section_index + 1}}</u></h5>
  64. <!-- For each activity in the section -->
  65. @foreach($section->activities as $activity_index => $activity)
  66. <!-- If activity has a rubric and the rubric has the outcome being evaluated -->
  67. @if(array_key_exists($outcome->id, (array)$activity->o_att_array) && $activity->o_att_array[$outcome->id] >=1)
  68. <h5>Measure {{ $activity_index + 1 }}</h5>
  69. <p>A rubric was used in the {{ $section->code }}-{{ $section->number }} ({{ $section->name }}) course ({{ date('M Y', strtotime($activity->date))}}) to assess students’ <u>{{ strtolower($outcome->name) }}</u> in the activity: "<strong>{{ $activity->name }}</strong>". N= {{ count($section->students) }}. </p>
  70. <p>The expected performance level was that <strong>{{ $activity->rubric->expected_percentage }}%</strong> of students participating in the activity would score <strong>{{ $activity->rubric->expected_points }} points</strong> or more in the 1-8 point scale used.</p>
  71. <p>The results for each criterion were as follows:</p>
  72. <?php
  73. $rubric_contents = json_decode($activity->rubric->contents);
  74. ?>
  75. <table class="table table-condensed table-bordered">
  76. <tbody>
  77. @foreach((array)$activity->cap_array as $criterion_id => $criteria_achieved_percentage)
  78. <tr>
  79. <?php
  80. $rubric_criterion_outcome_id = NULL;
  81. foreach ($rubric_contents as $rubric_criterion) {
  82. if($rubric_criterion->id == $criterion_id) {
  83. $rubric_criterion_outcome_id = $rubric_criterion->outcome_id;
  84. break;
  85. }
  86. }
  87. $criterion = Criterion::find($criterion_id);
  88. ?>
  89. @if($rubric_criterion_outcome_id == $outcome->id && $criteria_achieved_percentage >= $activity->rubric->expected_percentage )
  90. <td>{{ $criterion['name'] }}</td>
  91. <td class="col-md-1 success">{{ $criteria_achieved_percentage }}%</td>
  92. @elseif($rubric_criterion_outcome_id == $outcome->id && $criteria_achieved_percentage < $activity->rubric->expected_percentage )
  93. <td>{{ $criterion['name'] }}</td>
  94. <td class="col-md-1 danger">{{ $criteria_achieved_percentage }}%</td>
  95. @endif
  96. </tr>
  97. @endforeach
  98. </tbody>
  99. </table>
  100. <p>
  101. <?php
  102. $o_att_array = $activity->o_att_array;
  103. $o_ach_array = $activity->o_ach_array;
  104. $percentage = ($o_ach_array[$outcome->id]/$o_att_array[$outcome->id])*100;
  105. ?>
  106. @if($percentage >= 100)
  107. The expected goal was reached in <strong>all</strong> (100%) of the criteria assessed. Therefore, the goal for this outcome ({{ $outcome->expected_outcome }}%) was <strong>met</strong>.
  108. @elseif ($percentage < 1)
  109. The expected goal was reached in <strong>none</strong> (0%) of the criteria assessed. Therefore, the goal for this outcome ({{ $outcome->expected_outcome }}%) was <strong>not met</strong>.
  110. @elseif ($percentage >= $outcome->expected_outcome)
  111. The expected goal was reached in <strong>{{ $o_ach_array[$outcome->id] }}</strong> out of the <strong>{{ $o_att_array[$outcome->id] }}</strong> ({{ round($percentage, 2) }}%) criteria assessed. Therefore, the goal for this outcome ({{ $outcome->expected_outcome }}%) was <strong>met</strong>.
  112. @elseif ($percentage < $outcome->expected_outcome)
  113. The expected goal was reached in <strong>{{ $o_ach_array[$outcome->id] }}</strong> out of the <strong>{{ $o_att_array[$outcome->id] }}</strong> ({{ round($percentage, 2) }}%) criteria assessed. Therefore, the goal for this outcome ({{ $outcome->expected_outcome }}%) was <strong> not met</strong>.
  114. @endif
  115. </p>
  116. <h5><strong>Transforming Actions</strong></h5>
  117. @if($activity->transforming_actions)
  118. {{ $activity->transforming_actions }}
  119. @else
  120. None
  121. @endif
  122. <br><br>
  123. @else
  124. <h5>Measure {{ $activity_index + 1 }}</h5>
  125. <em>Outcome not measured.</em>
  126. @endif
  127. @endforeach
  128. @endforeach
  129. <hr>
  130. @endif
  131. @endforeach
  132. </td>
  133. </tr>
  134. @else
  135. <tr>
  136. <td>{{ $school->name }}</td>
  137. <td>{{ $program->name }}</td>
  138. <td>No</td>
  139. <td>
  140. This program does not assess {{ $outcome->name }}.
  141. </td>
  142. </tr>
  143. @endif
  144. @endforeach
  145. @endforeach
  146. </tbody>
  147. </table>
  148. </div>
  149. </div>
  150. <span class="js-vars"
  151. data-pdf-url="{{ URL::action('OutcomesController@assessmentReport') }}"
  152. ></span>
  153. @stop
  154. @section('included-js')
  155. @include('global._datatables_js')
  156. @stop
  157. @section('javascript')
  158. // Build table of contents
  159. var outcome = $('.outcome');
  160. var str ='';
  161. str+='<li><a href="#'+outcome.attr('id')+'">'+outcome.text()+'</a><ol class="schools upper-alpha">';
  162. /*$('[id^='+outcome.attr('id')+'-].school:visible').each(function(e){
  163. var school = $(this);
  164. str+='<li><a href="#'+school.attr('id')+'">'+school.text()+'</a><ol class="programs">';
  165. $('[id^='+school.attr('id')+'-].program:visible').each(function(e){
  166. var program = $(this);
  167. if(!program.hasClass('no-courses'))
  168. str+='<li><a href="#'+program.attr('id')+'">'+program.text()+'</a></li>';
  169. else
  170. str+='<li>'+program.text()+'</li>';
  171. });
  172. str+='</ol></li>';
  173. });*/
  174. str+='</ol></li>';
  175. //$('#table-of-contents').append(str);
  176. // ----------------------------------------------------------------------------
  177. // Events
  178. //
  179. $('.to-top').on('click', function(e) {
  180. e.preventDefault();
  181. $(this).scrollTop(0);
  182. $('html').animate({scrollTop:0}, 1);
  183. $('body').animate({scrollTop:0}, 1);
  184. })
  185. @stop