No Description

programs.blade.php 6.1KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152
  1. @extends('layouts.master')
  2. @section('navigation')
  3. @if ($role == 1)
  4. @include('local.managers.admins._new_navigation')
  5. @elseif($role == 2)
  6. @include('local.managers.sCoords._new_navigation')
  7. @elseif($role == 3)
  8. @include('local.managers.pCoords._new_navigation')
  9. @endif
  10. @stop
  11. @section('main')
  12. <button class="btn btn-lg btn-primary pull-right" id='show'>Custom Report</button>
  13. <div class="" id='make_report'>
  14. <hr>
  15. <b>
  16. <h3>Report Options</h3><br>
  17. </b>
  18. {{-- For for adding a new outcome --}}
  19. {{ Form::open(['action' => 'ProgramsController@showReport']) }}
  20. <div class="row">
  21. <div class="col-md-1">
  22. </div>
  23. <div class="col-md-5">
  24. {{ Form::label('name', 'Select which semesters to report on') }}<br>
  25. @foreach ($semesters as $semester)
  26. @if ($semester->is_visible)
  27. <div class="form-group">
  28. <input type="checkbox" id="semester{{ $semester->id }}" name="semester{{ $semester->id }}"
  29. value="semester{{ $semester->id }}">
  30. <label for="semester{{ $semester->id }}">{{ $semester->name }}({{ $semester->code }})</label>
  31. {{-- {{ Form::checkbox('semester'.$semester->id, $semester->name, array('class' => 'form-control', 'id'=>$semester->id)) }}
  32. {{ Form::label('semester'.$semester->id, $semester->name.'('.$semester->code.')') }}<br> --}}
  33. </div>
  34. @endif
  35. @endforeach
  36. </div>
  37. <div class="col-md-6">
  38. {{ Form::label('divulgacion', 'Select metodos de divulgacion') }}<br>
  39. <div class="form-group">
  40. <input type="checkbox" id="profesores" name="profesores" value="Profesores (pares)">
  41. <label for="profesores">Profesores (pares)</label>
  42. </div>
  43. <div class="form-group">
  44. <input type="checkbox" id="comiteDepartamental" name="comiteDepartamental"
  45. value="Comites de curriculo departamental">
  46. <label for="comiteDepartamental">Comites de curriculo departamental</label>
  47. </div>
  48. <div class="form-group">
  49. <input type="checkbox" id="comiteFacultadEscuela" name="comiteFacultadEscuela"
  50. value="Comites de curriculo de Facultad o Escuela">
  51. <label for="comiteFacultadEscuela">Comites de curriculo de Facultad o Escuela</label>
  52. </div>
  53. <div class="form-group">
  54. <input type="checkbox" id="pleno" name="pleno" value="Pleno de la Facultad">
  55. <label for="pleno">Pleno de la Facultad</label>
  56. </div>
  57. <div class="form-group">
  58. <input type="checkbox" id="estudiantes" name="estudiantes" value="Estudiantes">
  59. <label for="estudiantes">Estudiantes</label>
  60. </div>
  61. <div class="form-group">
  62. <input type="checkbox" id="administrativos" name="administrativos" value="Administrativos">
  63. <label for="administrativos">Administrativos</label>
  64. </div>
  65. <div class="form-group">
  66. <input type="checkbox" id="senado" name="senado" value="Senado">
  67. <label for="senado">Senado</label>
  68. </div>
  69. <div class="form-group">
  70. <input type="checkbox" id="comunidadWeb" name="comunidadWeb" value="Comunidad (pagina web)">
  71. <label for="comunidadWeb">Comunidad (pagina web)</label>
  72. </div>
  73. <div class="form-group">
  74. <input type="checkbox" id="otros" name="otros" value="Otros">
  75. <label for="otros">Otro- <input type="text" id='otherBox'></label>
  76. </div>
  77. </div>
  78. </div>
  79. <div class="row">
  80. <div class=""><button type="submit" id='submit' class="btn btn-lg btn-primary center-block">Create
  81. Report</button></div>
  82. </div>
  83. {{ Form::close() }}
  84. <hr>
  85. <button class="btn btn-lg btn-primary pull-right" id='hide'>Hide Form</button>
  86. </div>
  87. <div class="row">
  88. <div class="col-md-12">
  89. <table class="table table-condensed table-stripedd datatable">
  90. <thead>
  91. <tr>
  92. <th>Name</th>
  93. <th>School</th>
  94. </tr>
  95. </thead>
  96. <tfoot>
  97. <tr class="column-search">
  98. <th><input class="column-search-bar form-control" type="text" placeholder="Buscar" /></th>
  99. <th><select class="column-search-select form-control">
  100. <option value=""></option>
  101. </select></th>
  102. </tr>
  103. </tfoot>
  104. <tbody>
  105. @foreach ($programs as $program)
  106. <tr>
  107. <td>{{ HTML::linkAction('ProgramsController@show', $program->name, [$program->id]) }}
  108. </td>
  109. <td>{{ $program->school->name }}</td>
  110. </tr>
  111. @endforeach
  112. </tbody>
  113. </table>
  114. </div>
  115. </div>
  116. @stop
  117. @section('included-js')
  118. <!-- Datatables -->
  119. @include('global._datatables_js')
  120. @stop
  121. @section('javascript')
  122. $('#make_report').hide();
  123. //show form
  124. $('#show').on('click', function(e)
  125. {
  126. $('#make_report').show();
  127. $('#show').hide();
  128. });
  129. //hide form
  130. $('#hide').on('click', function(e)
  131. {
  132. $('#make_report').hide();
  133. $('#show').show();
  134. });
  135. //on submit, change value of the checkbox input of id 'other'
  136. $('#submit').click(function(){
  137. $('#otros').val('Otro- '+$('#otherBox').val());
  138. });
  139. @stop