Brak opisu

new-course-show.blade.php 3.9KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105
  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. @else
  10. @include('local.professors._navigation')
  11. @endif
  12. @stop
  13. @section('main')
  14. <div class="row">
  15. <div class="col-md-12">
  16. <p>{{ $course->name }}</p>
  17. </div>
  18. </div>
  19. <div class="row">
  20. <div class="col-md-12">
  21. <h3>Activities</h3>
  22. @if (!$activities->isEmpty())
  23. @if ($is_active_semester)
  24. <a href="{{ URL::action('ActivitiesController@newCreate', ['course_id' => $course->id]) }}"
  25. class="btn btn-sm btn-default pull-right">New Activity</a>
  26. @endif
  27. <table class="table table-striped table-condensed">
  28. <thead>
  29. <tr>
  30. <th>Name</th>
  31. <th>Date</th>
  32. <th>Updated</th>
  33. <th>Assessed</th>
  34. <th>Published</th>
  35. </tr>
  36. </thead>
  37. <tbody>
  38. @foreach ($activities as $activity)
  39. <tr>
  40. <td>{{ link_to_action('ActivitiesController@show', $activity->name, $parameters = ['id' => $activity->id]) }}
  41. </td>
  42. <td>{{ date('M d, Y', strtotime($activity->date)) }}</td>
  43. <td>{{ date('M d, Y', strtotime($activity->updated_at)) }}</td>
  44. <td>
  45. @if ($activity->outcomes_attempted != null)
  46. <span class="glyphicon glyphicon-ok"></span>
  47. @endif
  48. </td>
  49. <td>
  50. @if ($activity->outcomes_attempted != null && !$activity->draft && !$activity->diagnostic)
  51. <span class="glyphicon glyphicon-ok"></span>
  52. @endif
  53. </td>
  54. </tr>
  55. @endforeach
  56. @if (!$is_active_semester)
  57. <tr>
  58. <td colspan="3">
  59. <div class="alert alert-info">The semester for this course is inactive. You cannot create
  60. any more activities.</div>
  61. </td>
  62. </tr>
  63. @endif
  64. </tbody>
  65. </table>
  66. <p>Unplublished activity results are <strong>not considered</strong> in the graph above.</p>
  67. @else
  68. <div class="alert alert-info">
  69. @if ($is_active_semester)
  70. <p>
  71. No activities.
  72. <a data-toggle="modal" data-target="#newActivityModal">
  73. Create one.
  74. </a>
  75. </p>
  76. @else
  77. <p>The semester for this course is inactive. You cannot create any activities.</p>
  78. @endif
  79. </div>
  80. @endif
  81. </div>
  82. </div>
  83. @stop
  84. @section('included-js')
  85. <!-- HighCharts -->
  86. <script src="{{ asset('vendor/highcharts/highcharts.js') }}"></script>
  87. <!--script src="http://code.highcharts.com/modules/exporting.js"></script -->
  88. @stop
  89. @section('javascript')
  90. @stop