2016-10-18 14:03:03 +00:00
|
|
|
<?php define('__ROOT__', dirname(dirname(dirname(__FILE__))) );
|
|
|
|
require_once __ROOT__.'/autoloader.php';
|
|
|
|
use \viewer\core\Viewer;
|
2016-02-03 22:22:18 +00:00
|
|
|
?>
|
|
|
|
|
2016-02-02 13:03:22 +00:00
|
|
|
<!-- [1] Gestion du sous-menu de gauche -->
|
|
|
|
|
2016-02-02 22:29:30 +00:00
|
|
|
<nav class='sub-menu-side'>
|
2016-02-10 07:54:23 +00:00
|
|
|
<span data-sublink='view'>
|
2016-10-18 14:03:03 +00:00
|
|
|
<span class='svg'><?php echo file_get_contents( __PUBLIC__.'/src/static/sub-menu-side/view.svg' ); ?></span>
|
2016-02-02 22:56:48 +00:00
|
|
|
<span>Tout afficher</span>
|
|
|
|
</span>
|
|
|
|
|
2016-02-03 08:00:06 +00:00
|
|
|
<span data-sublink='create'>
|
2016-10-18 14:03:03 +00:00
|
|
|
<span class='svg'><?php echo file_get_contents( __PUBLIC__.'/src/static/sub-menu-side/create.svg' ); ?></span>
|
2016-02-02 22:56:48 +00:00
|
|
|
<span>Creation</span>
|
|
|
|
</span>
|
|
|
|
|
2016-02-03 08:00:06 +00:00
|
|
|
<span data-sublink='remove'>
|
2016-10-18 14:03:03 +00:00
|
|
|
<span class='svg'><?php echo file_get_contents( __PUBLIC__.'/src/static/sub-menu-side/remove.svg' ); ?></span>
|
2016-02-02 22:56:48 +00:00
|
|
|
<span>Suppression</span>
|
|
|
|
</span>
|
|
|
|
|
2016-02-03 08:00:06 +00:00
|
|
|
<span data-sublink='edit'>
|
2016-10-18 14:03:03 +00:00
|
|
|
<span class='svg'><?php echo file_get_contents( __PUBLIC__.'/src/static/sub-menu-side/edit.svg' ); ?></span>
|
2016-02-02 22:56:48 +00:00
|
|
|
<span>Modification</span>
|
|
|
|
</span>
|
|
|
|
|
2016-07-18 14:49:00 +00:00
|
|
|
<span data-sublink='groups'>
|
2016-10-18 14:03:03 +00:00
|
|
|
<span class='svg'><?php echo file_get_contents( __PUBLIC__.'/src/static/sub-menu-side/filter.svg' ); ?></span>
|
2016-07-18 14:49:00 +00:00
|
|
|
<span>Groupes</span>
|
2016-02-02 22:56:48 +00:00
|
|
|
</span>
|
|
|
|
|
2016-02-02 13:03:22 +00:00
|
|
|
</nav>
|
|
|
|
|
2016-02-03 10:30:46 +00:00
|
|
|
|
|
|
|
|
2016-02-10 07:54:23 +00:00
|
|
|
<?php
|
|
|
|
|
2016-07-04 13:45:29 +00:00
|
|
|
$post = [];
|
2016-02-10 07:54:23 +00:00
|
|
|
foreach($_POST as $k=>$v)
|
|
|
|
array_push($post, $k);
|
|
|
|
|
|
|
|
$sublink = $post[0];
|
|
|
|
|
|
|
|
|
2016-02-15 09:22:47 +00:00
|
|
|
/* [1] Affichage des machines
|
|
|
|
=========================================================*/
|
2016-07-09 12:13:08 +00:00
|
|
|
debug();
|
2016-02-10 07:54:23 +00:00
|
|
|
echo "<section data-sublink='view' class='list'>";
|
|
|
|
|
2016-10-18 14:03:03 +00:00
|
|
|
$machineView = new Viewer('machine.view', []);
|
2016-07-12 10:06:46 +00:00
|
|
|
$machineView->view();
|
2016-02-10 07:54:23 +00:00
|
|
|
|
|
|
|
echo '</section>';
|
2016-02-14 20:58:49 +00:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
/* [2] Creation de machine
|
|
|
|
=========================================================*/
|
|
|
|
echo "<section data-sublink='create'>";
|
|
|
|
|
2016-02-15 09:22:47 +00:00
|
|
|
echo "<form class='valid'>";
|
|
|
|
echo "<input id='create_name' type='text' placeholder='Name'><br>";
|
|
|
|
echo "<button id='create_submit'>Créer</button>";
|
|
|
|
echo "</form>";
|
|
|
|
|
|
|
|
echo '</section>';
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
/* [3] Suppression de machine
|
|
|
|
=========================================================*/
|
|
|
|
echo "<section data-sublink='remove'>";
|
|
|
|
|
|
|
|
echo "<form class='invalid'>";
|
2016-02-17 10:24:26 +00:00
|
|
|
echo "<input id='remove_search_keyword' type='text' class='search' placeholder='Recherche...'><br>";
|
2016-02-17 11:09:23 +00:00
|
|
|
echo "<input id='remove_search_id' type='hidden' value=''>";
|
|
|
|
// Indice du resultat
|
|
|
|
echo "<span class='remove_search_view'>machine <span class='remove_search_num'>0</span> sur <span class='remove_search_sum'>0</span></span><br><br>";
|
2016-02-17 10:24:26 +00:00
|
|
|
echo "<button id='remove_search_submit' class='search'>Trouver</button><br>";
|
2016-07-02 15:10:41 +00:00
|
|
|
|
2016-02-17 10:24:26 +00:00
|
|
|
echo "<br><br><hr class='OR' data-label='PUIS' /><br><br>";
|
|
|
|
|
2016-02-15 21:08:49 +00:00
|
|
|
echo "<input id='remove_name' type='text' placeholder='Name'><br>";
|
2016-07-14 07:38:03 +00:00
|
|
|
echo "<button id='remove_submit' disabled>Supprimer</button>";
|
2016-02-15 09:22:47 +00:00
|
|
|
echo "</form>";
|
|
|
|
|
|
|
|
echo '</section>';
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
/* [4] Modification de machine
|
|
|
|
=========================================================*/
|
|
|
|
echo "<section data-sublink='edit'>";
|
|
|
|
|
|
|
|
echo "<form class='neutral'>";
|
2016-02-16 13:36:23 +00:00
|
|
|
echo "<input id='edit_search_keyword' type='text' class='search' placeholder='Recherche...'><br>";
|
2016-02-17 11:09:23 +00:00
|
|
|
echo "<input id='edit_search_id' type='hidden' value=''>";
|
|
|
|
// Indice du resultat
|
|
|
|
echo "<span class='edit_search_view'>machine <span class='edit_search_num'>0</span> sur <span class='edit_search_sum'>0</span></span><br><br>";
|
2016-02-17 10:24:26 +00:00
|
|
|
echo "<button id='edit_search_submit' class='search'>Trouver</button><br>";
|
2016-07-02 15:10:41 +00:00
|
|
|
|
2016-02-17 10:24:26 +00:00
|
|
|
echo "<br><br><hr class='OR' data-label='PUIS' /><br><br>";
|
2016-07-02 15:10:41 +00:00
|
|
|
|
2016-02-15 11:27:01 +00:00
|
|
|
echo "<input id='edit_name' type='text' placeholder='Name'><br>";
|
2016-02-16 21:59:01 +00:00
|
|
|
echo "<button id='edit_submit' disabled>Modifier</button>";
|
2016-02-14 20:58:49 +00:00
|
|
|
echo "</form>";
|
|
|
|
|
|
|
|
echo '</section>';
|
2016-07-18 14:49:00 +00:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
/* [4] Gestion des groupes
|
|
|
|
=========================================================*/
|
|
|
|
echo "<section data-sublink='groups' class='list'>";
|
|
|
|
|
2016-10-18 14:03:03 +00:00
|
|
|
$grouplist = new Viewer('machine.groups', []);
|
2016-07-18 14:49:00 +00:00
|
|
|
$grouplist->view();
|
|
|
|
|
|
|
|
echo '</section>';
|