setting.planning.php 4.0 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061626364656667686970717273747576777879
  1. <?php
  2. global $myUser;
  3. User::check_access('planning','configure');
  4. require_once(__DIR__.SLASH.'PlanningEventType.class.php');
  5. ?>
  6. <div class="row">
  7. <div class="col-md-12">
  8. <br>
  9. <?php if($myUser->can('planning', 'edit')) : ?>
  10. <div onclick="planning_setting_save();" class="btn btn-success float-right"><i class="fas fa-check"></i> Enregistrer</div>
  11. <?php endif; ?>
  12. <h3>Réglages planning</h3>
  13. <div class="clear"></div>
  14. <hr>
  15. </div>
  16. </div>
  17. <div class="row">
  18. <!-- search results -->
  19. <div class="col-md-12">
  20. <div class="tab-container noPrint">
  21. <ul class="nav nav-tabs" role="tablist">
  22. <li class="nav-item"><a data-toggle="tab" class="nav-link active" href="#tab-types" aria-controls="tab-types" aria-selected="false">Types d'événements</a></li>
  23. <li class="nav-item"><a data-toggle="tab" class="nav-link" href="#tab-settings" aria-controls="tab-settings" aria-selected="false">Paramètres</a></li>
  24. </ul>
  25. </div>
  26. <div class="tab-content">
  27. <!-- Onglet Types d'événement -->
  28. <div class="tab-pane show active in" id="tab-types" role="tabpanel" aria-labelledby="tab-types"><br>
  29. <div class="row">
  30. <div class="col-md-9">
  31. <h3>Types d'évenements</h3>
  32. </div>
  33. <div class="col-md-3 text-right ">
  34. <div class="btn btn-light" onclick="planning_event_type_add()"><i class="fas fa-plus"></i> Ajouter</div>
  35. <div class="btn btn-success" onclick="planning_event_type_save()"> Enregistrer</div>
  36. </div>
  37. </div>
  38. <ul class="planning-types mt-2">
  39. <li data-id="{{id}}" class="hidden planning-line {{class}}">
  40. <span class="planning-type-handler">
  41. <div class="planning-type-chip" style="background:{{color}};color:{{textcolor}}"><i class="{{icon}}"></i></div> {{label}}
  42. </span>
  43. <div class="planning-type-options">
  44. {{#editableOptions}}
  45. <div class="btn" onclick="$(this).parent().parent().find('.planning-type-properties').toggleClass('hidden');event.stopPropagation();">
  46. <i class="fas fa-cog text-muted "></i>
  47. </div>
  48. {{/editableOptions}}
  49. </div>
  50. <div class="planning-type-properties hidden">
  51. <div class="input-group mt-3 mb-3">
  52. <input data-type="icon" value="fas fa-info-circle" class="type-icon form-control input-group-prepend" type="text" value="{{icon}}">
  53. <input placeholder="Ajoutez un type d'évenement, ex : Congès" class="type-label form-control"type="text" value="{{label}}">
  54. <input type="text" value="{{color}}" class="type-color" data-type="color">
  55. </div>
  56. <label><input class="type-editable" data-type="checkbox" value="{{editable}}" type="checkbox">Editable</label>
  57. <small class="text-muted pl-2">Éditable par les utilisateurs n'ayants pas de droit superadmin</small>
  58. <div class="right mt-2" ><i onclick="planning_event_type_delete(this);" class="far fa-trash-alt pointer"></i></div>
  59. <div class="clear"></div>
  60. </div>
  61. </li>
  62. </ul>
  63. </div>
  64. <!-- Onglet Paramètres -->
  65. <div class="tab-pane" id="tab-settings" role="tabpanel" aria-labelledby="tab-settings"><br>
  66. <?php echo Configuration::html('planning'); ?>
  67. </div>
  68. </div>
  69. </div>
  70. </div>