page.sheet.machine.application.php 2.1 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455
  1. <?php
  2. User::check_access('host','read');
  3. require_once(__DIR__.SLASH.'MachineApplication.class.php');
  4. $machineapplication = MachineApplication::provide();
  5. if($machineapplication->id==0){
  6. $machineapplication->version = '1.0.0';
  7. }
  8. ?>
  9. <div id="machine-application-form" class="machine-application-form" data-action="host_machine_application_save" data-id="<?php echo $machineapplication->id; ?>">
  10. <div class="input-group mt-2">
  11. <div class="input-group-prepend">
  12. <div class="input-group-text">Libellé</div>
  13. </div>
  14. <input value="<?php echo $machineapplication->label; ?>" onchange="host_machine_application_save();" class="form-control" type="text" data-id="label" >
  15. </div>
  16. <div class="input-group mt-2">
  17. <div class="input-group-prepend">
  18. <div class="input-group-text">Référent</div>
  19. </div>
  20. <input value="<?php echo $machineapplication->referent; ?>" data-type="user" onchange="host_machine_application_save();" class="form-control" type="text" data-id="referent" >
  21. <div class="input-group-prepend">
  22. <div class="input-group-text">Version</div>
  23. </div>
  24. <input value="<?php echo $machineapplication->version; ?>" onchange="host_machine_application_save();" class="form-control" type="text" data-id="version" >
  25. </div>
  26. <div class="input-group mt-2">
  27. <div class="input-group-prepend">
  28. <div class="input-group-text">Url</div>
  29. </div>
  30. <input class="form-control" type="text" data-type="url" onchange="host_machine_application_save();" data-id="url" value="<?php echo $machineapplication->url; ?>">
  31. <div class="input-group-prepend">
  32. <div class="input-group-text">
  33. <input <?php echo $machineapplication->monitored == 1 ? 'checked="checked"' : '' ?> data-type="checkbox" type="checkbox" data-id="monitored" onchange="host_machine_application_save();"> A surveiller
  34. </div>
  35. </div>
  36. </div>
  37. <!-- <div class="input-group input-group-sm mt-2">
  38. <div class="input-group-prepend">
  39. <div class="input-group-text">Machine liée</div>
  40. </div>
  41. <input value="<?php echo $machineapplication->machine; ?>" onchange="host_machine_application_save();" class="form-control" type="number" id="machine" >
  42. </div> -->
  43. </div>