No Description

grouped_course.blade.php 6.9KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225
  1. @extends('layouts.master')
  2. @section('navigation')
  3. @if($role==1)
  4. @include('local.managers.admins._navigation')
  5. @elseif($role==2)
  6. @include('local.managers.sCoords._navigation')
  7. @elseif($role==3)
  8. @include('local.managers.pCoords._navigation')
  9. @else
  10. @include('local.professors._navigation')
  11. @endif
  12. @stop
  13. @section('main')
  14. <p>{{{ $grouped_courses[0]->program->name }}}</p>
  15. <a href="{{ action('CoursesController@print_course', array($grouped_courses[0]->code, $grouped_courses[0]->number, $grouped_courses[0]->semester->code )); }}" class="btn btn-primary pull-right" alt="print"><span class="glyphicon glyphicon-print"></span></a>
  16. <br>
  17. <br>
  18. <div class="row">
  19. <div class="col-md-12 graph" id="graph"></div>
  20. </div>
  21. <div class="row">
  22. <div class="col-md-5">
  23. <h3>Sections</h3>
  24. <table class="table table-striped table-condensed">
  25. <thead>
  26. <tr>
  27. <th>Identifier</th>
  28. <th>Professor</th>
  29. <th>Assessed</th>
  30. <th>Published</th>
  31. </tr>
  32. </thead>
  33. <tbody>
  34. @foreach($sections as $section)
  35. <tr>
  36. <td>{{ HTML::linkAction('CoursesController@showLimited', $section->code.$section->number.'-'.$section->section.' ('.$section->semester->code.')', array($section->id)) }}</td>
  37. <td>{{ $section->user->surnames }}, {{ $section->user->first_name }}</td>
  38. <td>
  39. @if(count($section->assessedActivities))
  40. <span class="glyphicon glyphicon-ok"></span>
  41. @endif
  42. </td>
  43. <td>
  44. @if(count($section->publishedActivities))
  45. <span class="glyphicon glyphicon-ok"></span>
  46. @endif
  47. </td>
  48. </tr>
  49. @endforeach
  50. </tbody>
  51. </table>
  52. </div>
  53. <div class="col-md-7">
  54. <h3>Transforming Action Overview</h3>
  55. <table class="table table-striped table-condensed">
  56. <thead>
  57. <tr>
  58. <th>Activity</th>
  59. <th>Section</th>
  60. <th>Transforming Action</th>
  61. <th>Comments</th>
  62. </tr>
  63. </thead>
  64. <tbody>
  65. @foreach ($activities as $activity)
  66. <tr>
  67. <td>{{ $activity->name }} </td>
  68. <td>{{ $activity->course->section }}</td>
  69. <td>{{ $activity->transforming_actions }}</td>
  70. <td>{{ $activity->assessment_comments }}</td>
  71. </tr>
  72. @endforeach
  73. </tbody>
  74. </table>
  75. </div>
  76. </div>
  77. @stop
  78. @section('included-js')
  79. <!-- HighCharts -->
  80. <script src="{{ asset('vendor/highcharts/highcharts.js') }}"></script>
  81. <!--script src="http://code.highcharts.com/modules/exporting.js"></script -->
  82. @stop
  83. @section('javascript')
  84. // --------------------------------------------------------------------------
  85. // Page load
  86. // --------------------------------------------------------------------------
  87. // --------------------------------------------------------------------------
  88. // Functions
  89. // --------------------------------------------------------------------------
  90. $(function () {
  91. $('#graph').highcharts({
  92. chart: {
  93. type: 'bar'
  94. },
  95. title: {
  96. text: 'Performance by Learning Outcome Criteria in {{ $title }}'
  97. },
  98. xAxis: {
  99. categories: [
  100. @foreach($outcomes as $outcome)
  101. "{{{ $outcome->name }}}",
  102. @endforeach
  103. ],
  104. labels: {
  105. style: {
  106. fontSize:'11px'
  107. },
  108. step:1,
  109. useHTML:true,
  110. formatter: function() {
  111. return '<div style="width:200px; word-break:break; text-overflow:ellipsis; overflow:hidden;">'+this.value+'</div>';
  112. },
  113. }
  114. },
  115. yAxis: {
  116. min: 0,
  117. max: 100,
  118. title: {
  119. text: 'Percentage'
  120. }
  121. },
  122. tooltip: {
  123. headerFormat: '<span style="font-size:10px">{point.key}</span><table>',
  124. pointFormat: '<tr><td style="color:{series.color};padding:0">{series.name}: </td>' +
  125. '<td style="padding:0"><b>{point.y:.2f}</b></td></tr>',
  126. footerFormat: '</table>',
  127. shared: true,
  128. useHTML: true
  129. },
  130. plotOptions: {
  131. bar: {
  132. //grouping: false,
  133. shadow: false,
  134. borderWidth: 0,
  135. },
  136. series: {
  137. pointPadding: 0,
  138. groupPadding: 0.075
  139. },
  140. },
  141. series: [{
  142. name: 'Expected Value',
  143. color: '#555555',
  144. dataLabels: {
  145. enabled: true,
  146. fontSize: 8,
  147. color: '#fff',
  148. align: 'right',
  149. format: '{y:.1f}%',
  150. style: {
  151. //fontWeight: 'bold'
  152. },
  153. y:-1
  154. },
  155. data: [
  156. @foreach($outcomes as $index => $outcome)
  157. @if(
  158. is_array($outcomes_attempted)
  159. && array_key_exists($outcome->id, $outcomes_attempted)
  160. && $outcomes_attempted[$outcome->id]!=0)
  161. {{{ $outcome->expected_outcome }}},
  162. @else
  163. 0,
  164. @endif
  165. @endforeach
  166. ]
  167. }, {
  168. name: 'Obtained Value',
  169. color: '#e70033',
  170. dataLabels: {
  171. enabled: true,
  172. fontSize: 8,
  173. color: '#fff',
  174. align: 'right',
  175. format: '{y:.1f}%',
  176. style: {
  177. //fontWeight: 'bold'
  178. },
  179. y:-1
  180. },
  181. data:[
  182. @foreach($outcomes as $index => $outcome)
  183. @if(
  184. is_array($outcomes_attempted)
  185. && array_key_exists($outcome->id, $outcomes_attempted)
  186. && $outcomes_attempted[$outcome->id]!=0)
  187. {{{ ($outcomes_achieved[$outcome->id]/$outcomes_attempted[$outcome->id])*100 }}},
  188. @else
  189. 0,
  190. @endif
  191. @endforeach
  192. ]
  193. }]
  194. });
  195. // Include dummy graph for outcomes
  196. @include('global.dummy-outcomes')
  197. });
  198. // --------------------------------------------------------------------------
  199. // Events
  200. // --------------------------------------------------------------------------
  201. @stop