Brak opisu

school.blade.php 38KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569570571572573574575576577578579580581582583584585586587588589590591592593594595596597598599600601602603604605606607608609610611612613614615616617618619620621622623624625626627628629630631632633634635636637638639640641642643644645646647648649650651652653654655656657658659660661662663664665666667668669670671672673674675676677678679680681682683684685686687688689690691692693694695696697698699700701702703704705706707708709710711712713714715716717718719720721722723724725726727728729730731732733734735736737738739740741742743744745746747748749750751752753754755756757758759760761762763764765766767768769770771772773774775776777778779780781
  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. @endif
  8. @stop
  9. @section('main')
  10. <a href="{{ action('SchoolsController@print_school', array($school->id)); }}" class="btn btn-primary pull-right" alt="print"><span class="glyphicon glyphicon-print"></span></a>
  11. <br>
  12. <br>
  13. <!-- Nav tabs -->
  14. <ul id="levelTabs" class="nav nav-tabs" role="tablist">
  15. <li role="presentation" class="active"><a href="#undergraduate" aria-controls="undergraduate" role="tab">Undergraduate</a></li>
  16. <li role="presentation"><a href="#graduate" aria-controls="graduate" role="tab">Graduate</a></li>
  17. </ul>
  18. <!-- Tab panes -->
  19. <div class="tab-content">
  20. <div role="tabpanel" class="tab-pane active" id="undergraduate">
  21. <div class="row">
  22. <div class="col-md-9 graph" id="graph-undergrad"></div>
  23. <div class="col-md-3">
  24. <br>
  25. <div class="panel panel-default panel-scrolling">
  26. <div class="panel-heading" role="tab" id="headingOne">
  27. <h4 class="panel-title">
  28. Programs
  29. </h4>
  30. </div>
  31. <div class="panel-collapse collapse in" role="tabpanel" aria-labelledby="headingOne">
  32. <table class="table table-striped table-condensed">
  33. <tr>
  34. <th>Name</th>
  35. <th>Participation</th>
  36. </tr>
  37. @foreach ($undergrad_programs as $program)
  38. <tr>
  39. <td>{{ HTML::linkAction('ProgramsController@show', $program->name, array($program->id)) }}</td>
  40. <td class="text-center">
  41. @if(in_array($program->id, $participating_programs))
  42. <span class="glyphicon glyphicon-ok"></span>
  43. @endif
  44. </td>
  45. </tr>
  46. @endforeach
  47. </table>
  48. </div>
  49. </div>
  50. </div>
  51. </div>
  52. <div>
  53. <!-- Nav tabs -->
  54. <ul id="undergradSchoolTabs" class="nav nav-tabs" role="tablist">
  55. <li role="presentation" class="active"><a href="#undergrad-outcomes-assessed" aria-controls="undergrad-outcomes-assessed" role="tab">Assessment Results by Learning Outcomes in Academic Programs</a></li>
  56. <li role="presentation"><a href="#undergrad-courses" aria-controls="undergrad-courses" role="tab"> Undergraduate Courses</a></li>
  57. <li role="presentation"><a href="#undergrad-sections" aria-controls="undergrad-sections" role="tab">Sections</a></li>
  58. </ul>
  59. <!-- Tab panes -->
  60. <div class="tab-content">
  61. <div role="tabpanel" class="tab-pane active" id="undergrad-outcomes-assessed">
  62. <div class="row">
  63. <div class="col-md-12">
  64. <table class="table table-striped table-condensed">
  65. <thead>
  66. <th>Learning Outcome</th>
  67. <th>Programs doing Assessment</th>
  68. <th>Programs Achieved</th>
  69. <th>Success Rate</th>
  70. </thead>
  71. <tbody>
  72. @foreach($outcomes_undergrad as $outcome)
  73. <tr>
  74. <td class="col-md-6">{{ link_to_action('OutcomesController@show', $outcome->name, array($outcome->id), $attributes = array()) }}</td>
  75. <td class="col-md-2">{{{ $attemptedUndergradProgramsPerOutcome[$outcome->id] }}}</td>
  76. <td class="col-md-2">{{{ $achievedUndergradProgramsPerOutcome[$outcome->id] }}}</td>
  77. <td class="col-md-2">
  78. @if($attemptedUndergradProgramsPerOutcome[$outcome->id]!=0)
  79. {{{ round($achievedUndergradProgramsPerOutcome[$outcome->id] / $attemptedUndergradProgramsPerOutcome[$outcome->id]*100, 2) }}}%
  80. @else
  81. N/M
  82. @endif
  83. </td>
  84. </tr>
  85. @endforeach
  86. </tbody>
  87. <tfoot></tfoot>
  88. <caption>N/M: Not Measured</caption>
  89. </table>
  90. </div>
  91. </div>
  92. </div>
  93. <div role="tabpanel" class="tab-pane" id="undergrad-courses">
  94. <div class="row">
  95. <div class="col-md-12">
  96. <br>
  97. <h3>Courses in this school</h3>
  98. <p>Note that some sections may have assessed activities but unpublished results. Unpublished results are <strong>not considered</strong>. Check the Sections tab for a breakdown.</p>
  99. @if($undergrad_school_sections_count>0)
  100. <table class="table table-striped table-condensed datatable">
  101. <thead>
  102. <tr>
  103. <th>Identifier</th>
  104. <th>Name</th>
  105. <th>Program</th>
  106. <th>Assessed and Published</th>
  107. </tr>
  108. </thead>
  109. <tfoot>
  110. <tr class="column-search">
  111. <th><input class="column-search-bar form-control" type="text" placeholder="Buscar"/></th>
  112. <th><input class="column-search-bar form-control" type="text" placeholder="Buscar"/></th>
  113. <th><input class="column-search-bar form-control" type="text" placeholder="Buscar"/></th>
  114. <th><select class="column-search-select form-control"><option value=""></option></select></th>
  115. </tr>
  116. </tfoot>
  117. <tbody>
  118. @foreach($undergrad_grouped_courses as $grouped_course)
  119. <tr>
  120. <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>
  121. <td class="col-md-4">{{{ $grouped_course->name}}}</td>
  122. <td class="col-md-2">{{{ $grouped_course->program->name }}}</td>
  123. <td class="col-md-1">
  124. @if($grouped_course->outcomes_attempted!=NULL)
  125. Yes
  126. @else
  127. No
  128. @endif
  129. </td>
  130. </tr>
  131. @endforeach
  132. </tbody>
  133. </table>
  134. @else
  135. <p class="lead"> No courses doing Assessment (0%)</p>
  136. @endif
  137. </div>
  138. </div>
  139. </div>
  140. <div role="tabpanel" class="tab-pane" id="undergrad-sections">
  141. <div class="row">
  142. <div class="col-md-12">
  143. <br>
  144. @if($undergrad_school_sections_count>0)
  145. <h3>Sections in this school</h3>
  146. <p class="lead"> {{{ $undergrad_assessed_sections_count }}} out of {{{ $undergrad_school_sections_count }}} section(s) doing Assessment ({{{ round($undergrad_assessed_sections_count/$undergrad_school_sections_count*100, 2) }}}%)</p>
  147. <p>Note that some sections may have assessed activities but unpublished results. Unplublished results are <strong>not considered</strong>.</p>
  148. <table class="table table-striped table-condensed datatable">
  149. <thead>
  150. <tr>
  151. <th>Identifier</th>
  152. <th>Name</th>
  153. <th>Program</th>
  154. <th>Professor</th>
  155. <th>Assessed Activities</th>
  156. <th>Published Results</th>
  157. </tr>
  158. </thead>
  159. <tfoot>
  160. <tr class="column-search">
  161. <th><input class="column-search-bar form-control" type="text" placeholder="Buscar"/></th>
  162. <th><input class="column-search-bar form-control" type="text" placeholder="Buscar"/></th>
  163. <th><input class="column-search-bar form-control" type="text" placeholder="Buscar"/></th>
  164. <th><input class="column-search-bar form-control" type="text" placeholder="Buscar"/></th>
  165. <th><select class="column-search-select form-control"><option value=""></option></select></th>
  166. <th><select class="column-search-select form-control"><option value=""></option></select></th>
  167. </tr>
  168. </tfoot>
  169. <tbody>
  170. @foreach($school->programs as $program)
  171. @foreach($program->courses as $course)
  172. @if(!$course->program->is_graduate)
  173. <tr>
  174. <td class="col-md-2">{{ HTML::linkAction('CoursesController@showLimited', $course->code.$course->number.'-'.$course->section.' ('.$course->semester->code.')', array('id'=>$course->id)) }}</td>
  175. <td class="col-md-3">{{{ $course->name}}}</td>
  176. <td class="col-md-2">{{{ $course->program->name }}}</td>
  177. <td class="col-md-3">{{{ $course->user->surnames }}}, {{{ $course->user->first_name }}}</td>
  178. <td class="col-md-1">
  179. @if(count($course->assessedActivities))
  180. Yes
  181. @else
  182. No
  183. @endif
  184. </td>
  185. <td class="col-md-1">
  186. @if(count($course->publishedActivities))
  187. Yes
  188. @else
  189. No
  190. @endif
  191. </td>
  192. </tr>
  193. @endif
  194. @endforeach
  195. @endforeach
  196. </tbody>
  197. </table>
  198. @else
  199. <p class="lead"> No sections doing Assessment (0%)</p>
  200. @endif
  201. </div>
  202. </div>
  203. </div>
  204. </div>
  205. </div>
  206. </div>
  207. <div role="tabpanel" class="tab-pane" id="graduate">
  208. <div class="row">
  209. <div class="col-md-9 graph" id="graph-grad"></div>
  210. <div class="col-md-3">
  211. <br>
  212. <div class="panel panel-default panel-scrolling">
  213. <div class="panel-heading" role="tab" id="headingOne">
  214. <h4 class="panel-title">
  215. Programs
  216. </h4>
  217. </div>
  218. <div class="panel-collapse collapse in" role="tabpanel" aria-labelledby="headingOne">
  219. <table class="table table-striped table-condensed">
  220. <tr>
  221. <th>Name</th>
  222. <th>Participation</th>
  223. </tr>
  224. @foreach ($grad_programs as $program)
  225. <tr>
  226. <td>{{ HTML::linkAction('ProgramsController@show', $program->name, array($program->id)) }}</td>
  227. <td class="text-center">
  228. @if(in_array($program->id, $participating_programs))
  229. <span class="glyphicon glyphicon-ok"></span>
  230. @endif
  231. </td>
  232. </tr>
  233. @endforeach
  234. </table>
  235. </div>
  236. </div>
  237. </div>
  238. </div>
  239. <div>
  240. <!-- Nav tabs -->
  241. <ul id="gradSchoolTabs" class="nav nav-tabs" role="tablist">
  242. <li role="presentation" class="active"><a href="#grad-outcomes-assessed" aria-controls="grad-outcomes-assessed" role="tab">Assessment Results by Learning Outcomes in Academic Programs</a></li>
  243. <li role="presentation"><a href="#grad-courses" aria-controls="grad-courses" role="tab"> Graduate Courses</a></li>
  244. <li role="presentation"><a href="#grad-sections" aria-controls="grad-sections" role="tab">Sections</a></li>
  245. </ul>
  246. <!-- Tab panes -->
  247. <div class="tab-content">
  248. <div role="tabpanel" class="tab-pane active" id="grad-outcomes-assessed">
  249. <div class="row">
  250. <div class="col-md-12">
  251. <table class="table table-striped table-condensed">
  252. <thead>
  253. <th>Learning Outcome</th>
  254. <th>Programs doing Assessment</th>
  255. <th>Programs Achieved</th>
  256. <th>Success Rate</th>
  257. </thead>
  258. <tbody>
  259. @foreach($outcomes_grad as $outcome)
  260. <tr>
  261. <td class="col-md-6">{{ link_to_action('OutcomesController@show', $outcome->name, array($outcome->id), $attributes = array()) }}</td>
  262. <td class="col-md-2">{{{ $attemptedGradProgramsPerOutcome[$outcome->id] }}}</td>
  263. <td class="col-md-2">{{{ $achievedGradProgramsPerOutcome[$outcome->id] }}}</td>
  264. <td class="col-md-2">
  265. @if($attemptedGradProgramsPerOutcome[$outcome->id]!=0)
  266. {{{ round($achievedGradProgramsPerOutcome[$outcome->id] / $attemptedGradProgramsPerOutcome[$outcome->id]*100, 2) }}}%
  267. @else
  268. N/M
  269. @endif
  270. </td>
  271. </tr>
  272. @endforeach
  273. </tbody>
  274. <tfoot></tfoot>
  275. <caption>N/M: Not Measured</caption>
  276. </table>
  277. </div>
  278. </div>
  279. </div>
  280. <div role="tabpanel" class="tab-pane" id="grad-courses">
  281. <div class="row">
  282. <div class="col-md-12">
  283. <br>
  284. <h3>Courses in this school</h3>
  285. <p>Note that some sections may have assessed activities but unpublished results. Unpublished results are <strong>not considered</strong>. Check the Sections tab for a breakdown.</p>
  286. @if($grad_school_sections_count>0)
  287. <table class="table table-striped table-condensed datatable">
  288. <thead>
  289. <tr>
  290. <th>Identifier</th>
  291. <th>Name</th>
  292. <th>Program</th>
  293. <th>Assessed and Published</th>
  294. </tr>
  295. </thead>
  296. <tfoot>
  297. <tr class="column-search">
  298. <th><input class="column-search-bar form-control" type="text" placeholder="Buscar"/></th>
  299. <th><input class="column-search-bar form-control" type="text" placeholder="Buscar"/></th>
  300. <th><input class="column-search-bar form-control" type="text" placeholder="Buscar"/></th>
  301. <th><select class="column-search-select form-control"><option value=""></option></select></th>
  302. </tr>
  303. </tfoot>
  304. <tbody>
  305. @foreach($grad_grouped_courses as $grouped_course)
  306. <tr>
  307. <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>
  308. <td class="col-md-4">{{{ $grouped_course->name}}}</td>
  309. <td class="col-md-2">{{{ $grouped_course->program->name }}}</td>
  310. <td class="col-md-1">
  311. @if($grouped_course->outcomes_attempted!=NULL)
  312. Yes
  313. @else
  314. No
  315. @endif
  316. </td>
  317. </tr>
  318. @endforeach
  319. </tbody>
  320. </table>
  321. @else
  322. <p class="lead"> No courses doing Assessment (0%)</p>
  323. @endif
  324. </div>
  325. </div>
  326. </div>
  327. <div role="tabpanel" class="tab-pane" id="grad-sections">
  328. <div class="row">
  329. <div class="col-md-12">
  330. <br>
  331. @if($grad_school_sections_count>0)
  332. <h3>Sections in this school</h3>
  333. <p class="lead"> {{{ $grad_assessed_sections_count }}} out of {{{ $grad_school_sections_count }}} section(s) doing Assessment ({{{ round($grad_assessed_sections_count/$grad_school_sections_count*100, 2) }}}%)</p>
  334. <p>Note that some sections may have assessed activities but unpublished results. Unplublished results are <strong>not considered</strong>.</p>
  335. <table class="table table-striped table-condensed datatable">
  336. <thead>
  337. <tr>
  338. <th>Identifier</th>
  339. <th>Name</th>
  340. <th>Program</th>
  341. <th>Professor</th>
  342. <th>Assessed Activities</th>
  343. <th>Published Results</th>
  344. </tr>
  345. </thead>
  346. <tfoot>
  347. <tr class="column-search">
  348. <th><input class="column-search-bar form-control" type="text" placeholder="Buscar"/></th>
  349. <th><input class="column-search-bar form-control" type="text" placeholder="Buscar"/></th>
  350. <th><input class="column-search-bar form-control" type="text" placeholder="Buscar"/></th>
  351. <th><input class="column-search-bar form-control" type="text" placeholder="Buscar"/></th>
  352. <th><select class="column-search-select form-control"><option value=""></option></select></th>
  353. <th><select class="column-search-select form-control"><option value=""></option></select></th>
  354. </tr>
  355. </tfoot>
  356. <tbody>
  357. @foreach($school->programs as $program)
  358. @foreach($program->courses as $course)
  359. @if($course->program->is_graduate)
  360. <tr>
  361. <td class="col-md-2">{{ HTML::linkAction('CoursesController@showLimited', $course->code.$course->number.'-'.$course->section.' ('.$course->semester->code.')', array('id'=>$course->id)) }}</td>
  362. <td class="col-md-3">{{{ $course->name}}}</td>
  363. <td class="col-md-2">{{{ $course->program->name }}}</td>
  364. <td class="col-md-3">{{{ $course->user->surnames }}}, {{{ $course->user->first_name }}}</td>
  365. <td class="col-md-1">
  366. @if(count($course->assessedActivities))
  367. Yes
  368. @else
  369. No
  370. @endif
  371. </td>
  372. <td class="col-md-1">
  373. @if(count($course->publishedActivities))
  374. Yes
  375. @else
  376. No
  377. @endif
  378. </td>
  379. </tr>
  380. @endif
  381. @endforeach
  382. @endforeach
  383. </tbody>
  384. </table>
  385. @else
  386. <p class="lead"> No sections doing Assessment (0%)</p>
  387. @endif
  388. </div>
  389. </div>
  390. </div>
  391. </div>
  392. </div>
  393. </div>
  394. </div>
  395. @stop
  396. @section('included-js')
  397. <!-- HighCharts -->
  398. <script src="{{ asset('vendor/highcharts/highcharts.js') }}"></script>
  399. <!--script src="http://code.highcharts.com/modules/exporting.js"></script -->
  400. <!-- Datatables -->
  401. @include('global._datatables_js')
  402. @stop
  403. @section('javascript')
  404. $(function () {
  405. $('#undergradSchoolTabs a').click(function (e) {
  406. e.preventDefault()
  407. $(this).tab('show');
  408. });
  409. $('#gradSchoolTabs a').click(function (e) {
  410. e.preventDefault()
  411. $(this).tab('show');
  412. });
  413. $('#levelTabs a').click(function (e) {
  414. e.preventDefault()
  415. $(this).tab('show');
  416. $('#graph-undergrad').highcharts({
  417. chart: {
  418. type: 'bar'
  419. },
  420. title: {
  421. text: 'Undergraduate Performance by Learning Outcome Criteria in {{ $school->name }}'
  422. },
  423. legend: {
  424. reversed: true,
  425. },
  426. xAxis: {
  427. categories: [
  428. @foreach($outcomes_undergrad as $outcome)
  429. "{{{ $outcome->name }}}",
  430. @endforeach
  431. ],
  432. labels: {
  433. style: {
  434. fontSize:'11px'
  435. },
  436. step:1,
  437. useHTML:true,
  438. formatter: function() {
  439. return '<div style="width:200px; word-break:break; text-overflow:ellipsis; overflow:hidden;">'+this.value+'</div>';
  440. },
  441. }
  442. },
  443. yAxis: {
  444. min: 0,
  445. max: 100,
  446. title: {
  447. text: 'Percentage'
  448. }
  449. },
  450. tooltip: {
  451. headerFormat: '<span style="font-size:10px">{point.key}</span><table>',
  452. pointFormat: '<tr><td style="color:{series.color};padding:0">{series.name}: </td>' +
  453. '<td style="padding:0"><b>{point.y:.2f}</b></td></tr>',
  454. footerFormat: '</table>',
  455. shared: true,
  456. useHTML: true
  457. },
  458. plotOptions: {
  459. bar: {
  460. //grouping: false,
  461. shadow: false,
  462. borderWidth: 0,
  463. },
  464. series: {
  465. pointPadding: 0,
  466. groupPadding: 0.075
  467. },
  468. },
  469. series: [{
  470. name: 'Expected Value',
  471. color: '#555555',
  472. dataLabels: {
  473. enabled: true,
  474. fontSize: 8,
  475. color: '#fff',
  476. align: 'right',
  477. format: '{y:.1f}%',
  478. style: {
  479. //fontWeight: 'bold'
  480. },
  481. y:-1
  482. },
  483. data: [
  484. @foreach($outcomes_undergrad as $index => $outcome)
  485. @if(
  486. is_array($undergrad_outcomes_attempted)
  487. && array_key_exists($outcome->id, $undergrad_outcomes_attempted)
  488. && $undergrad_outcomes_attempted[$outcome->id]!=0)
  489. {{{ $outcome->expected_outcome }}},
  490. @else
  491. 0,
  492. @endif
  493. @endforeach
  494. ],
  495. pointPadding: 0,
  496. }, {
  497. name: 'Obtained Value',
  498. color: '#e70033',
  499. dataLabels: {
  500. enabled: true,
  501. fontSize: 8,
  502. color: '#fff',
  503. align: 'right',
  504. format: '{y:.1f}%',
  505. style: {
  506. //fontWeight: 'bold'
  507. },
  508. y:-1
  509. },
  510. data:[
  511. @foreach($outcomes_undergrad as $index => $outcome)
  512. @if(
  513. is_array($undergrad_outcomes_attempted)
  514. && array_key_exists($outcome->id, $undergrad_outcomes_attempted)
  515. && $undergrad_outcomes_attempted[$outcome->id]!=0)
  516. {{{ ($undergrad_outcomes_achieved[$outcome->id]/$undergrad_outcomes_attempted[$outcome->id])*100 }}},
  517. @else
  518. 0,
  519. @endif
  520. @endforeach
  521. ],
  522. pointPadding: 0,
  523. }]
  524. });
  525. $('#graph-grad').highcharts({
  526. chart: {
  527. type: 'bar'
  528. },
  529. title: {
  530. text: 'Graduate Performance by Learning Outcome Criteria in {{ $school->name }}'
  531. },
  532. legend: {
  533. reversed: true,
  534. },
  535. xAxis: {
  536. categories: [
  537. @foreach($outcomes_grad as $outcome)
  538. "{{{ $outcome->name }}}",
  539. @endforeach
  540. ],
  541. labels: {
  542. style: {
  543. fontSize:'11px'
  544. },
  545. step:1,
  546. useHTML:true,
  547. formatter: function() {
  548. return '<div style="width:200px; word-break:break; text-overflow:ellipsis; overflow:hidden;">'+this.value+'</div>';
  549. },
  550. }
  551. },
  552. yAxis: {
  553. min: 0,
  554. max: 100,
  555. title: {
  556. text: 'Percentage'
  557. }
  558. },
  559. tooltip: {
  560. headerFormat: '<span style="font-size:10px">{point.key}</span><table>',
  561. pointFormat: '<tr><td style="color:{series.color};padding:0">{series.name}: </td>' +
  562. '<td style="padding:0"><b>{point.y:.2f}</b></td></tr>',
  563. footerFormat: '</table>',
  564. shared: true,
  565. useHTML: true
  566. },
  567. plotOptions: {
  568. bar: {
  569. //grouping: false,
  570. shadow: false,
  571. borderWidth: 0,
  572. },
  573. series: {
  574. pointPadding: 0,
  575. groupPadding: 0.075
  576. },
  577. },
  578. series: [{
  579. name: 'Expected Value',
  580. color: '#555555',
  581. dataLabels: {
  582. enabled: true,
  583. fontSize: 8,
  584. color: '#fff',
  585. align: 'right',
  586. format: '{y:.1f}%',
  587. style: {
  588. //fontWeight: 'bold'
  589. },
  590. y:-1
  591. },
  592. data: [
  593. @foreach($outcomes_grad as $index => $outcome)
  594. @if(
  595. is_array($grad_outcomes_attempted)
  596. && array_key_exists($outcome->id, $grad_outcomes_attempted)
  597. && $grad_outcomes_attempted[$outcome->id]!=0)
  598. {{{ $outcome->expected_outcome }}},
  599. @else
  600. 0,
  601. @endif
  602. @endforeach
  603. ],
  604. pointPadding: 0,
  605. }, {
  606. name: 'Obtained Value',
  607. color: '#e70033',
  608. dataLabels: {
  609. enabled: true,
  610. fontSize: 8,
  611. color: '#fff',
  612. align: 'right',
  613. format: '{y:.1f}%',
  614. style: {
  615. //fontWeight: 'bold'
  616. },
  617. y:-1
  618. },
  619. data:[
  620. @foreach($outcomes_grad as $index => $outcome)
  621. @if(
  622. is_array($grad_outcomes_attempted)
  623. && array_key_exists($outcome->id, $grad_outcomes_attempted)
  624. && $grad_outcomes_attempted[$outcome->id]!=0)
  625. {{{ ($grad_outcomes_achieved[$outcome->id]/$grad_outcomes_attempted[$outcome->id])*100 }}},
  626. @else
  627. 0,
  628. @endif
  629. @endforeach
  630. ],
  631. pointPadding: 0,
  632. }]
  633. });
  634. });
  635. $('#graph-undergrad').highcharts({
  636. chart: {
  637. type: 'bar'
  638. },
  639. title: {
  640. text: 'Undergraduate Performance by Learning Outcome Criteria in {{ $school->name }}'
  641. },
  642. legend: {
  643. reversed: true,
  644. },
  645. xAxis: {
  646. categories: [
  647. @foreach($outcomes_undergrad as $outcome)
  648. "{{{ $outcome->name }}}",
  649. @endforeach
  650. ],
  651. labels: {
  652. style: {
  653. fontSize:'11px'
  654. },
  655. step:1,
  656. useHTML:true,
  657. formatter: function() {
  658. return '<div style="width:200px; word-break:break; text-overflow:ellipsis; overflow:hidden;">'+this.value+'</div>';
  659. },
  660. }
  661. },
  662. yAxis: {
  663. min: 0,
  664. max: 100,
  665. title: {
  666. text: 'Percentage'
  667. }
  668. },
  669. tooltip: {
  670. headerFormat: '<span style="font-size:10px">{point.key}</span><table>',
  671. pointFormat: '<tr><td style="color:{series.color};padding:0">{series.name}: </td>' +
  672. '<td style="padding:0"><b>{point.y:.2f}</b></td></tr>',
  673. footerFormat: '</table>',
  674. shared: true,
  675. useHTML: true
  676. },
  677. plotOptions: {
  678. bar: {
  679. //grouping: false,
  680. shadow: false,
  681. borderWidth: 0,
  682. },
  683. series: {
  684. pointPadding: 0,
  685. groupPadding: 0.075
  686. },
  687. },
  688. series: [{
  689. name: 'Expected Value',
  690. color: '#555555',
  691. dataLabels: {
  692. enabled: true,
  693. fontSize: 8,
  694. color: '#fff',
  695. align: 'right',
  696. format: '{y:.1f}%',
  697. style: {
  698. //fontWeight: 'bold'
  699. },
  700. y:-1
  701. },
  702. data: [
  703. @foreach($outcomes_undergrad as $index => $outcome)
  704. @if(
  705. is_array($undergrad_outcomes_attempted)
  706. && array_key_exists($outcome->id, $undergrad_outcomes_attempted)
  707. && $undergrad_outcomes_attempted[$outcome->id]!=0)
  708. {{{ $outcome->expected_outcome }}},
  709. @else
  710. 0,
  711. @endif
  712. @endforeach
  713. ],
  714. pointPadding: 0,
  715. }, {
  716. name: 'Obtained Value',
  717. color: '#e70033',
  718. dataLabels: {
  719. enabled: true,
  720. fontSize: 8,
  721. color: '#fff',
  722. align: 'right',
  723. format: '{y:.1f}%',
  724. style: {
  725. //fontWeight: 'bold'
  726. },
  727. y:-1
  728. },
  729. data:[
  730. @foreach($outcomes_undergrad as $index => $outcome)
  731. @if(
  732. is_array($undergrad_outcomes_attempted)
  733. && array_key_exists($outcome->id, $undergrad_outcomes_attempted)
  734. && $undergrad_outcomes_attempted[$outcome->id]!=0)
  735. {{{ ($undergrad_outcomes_achieved[$outcome->id]/$undergrad_outcomes_attempted[$outcome->id])*100 }}},
  736. @else
  737. 0,
  738. @endif
  739. @endforeach
  740. ],
  741. pointPadding: 0,
  742. }]
  743. });
  744. // Include dummy graph for outcomes
  745. @include('global.dummy-outcomes')
  746. });
  747. @stop