<?PHP
namespace Views;

class SideBarHtml
{
    public function __construct() {}
    public function showSideBar($departement, $user)
    {
        include_once("Classe/FunctionClasse.php");
        include("Parametre/" . getPath(1) . "/" . getPath(1) . ".php");

        extract($_REQUEST, EXTR_PREFIX_ALL | EXTR_REFS, 'v');

        if ($DisplaySideBAr) {


?>

            <nav id="sidebarMenu" class="col-md-3 col-lg-2 d-md-block bg-light sidebar collapse">
                <div class="position-sticky pt-3">
                    <ul class="nav flex-column">
                        <li class="nav-item">
                            <a class="nav-link <?php if (!isset($v_typePage) || (($v_typePage == "db") || ($v_typePage == "lsl") || ($v_page == ""))) echo "active"; ?>"
                                aria-current="page" href="index.php?page=vsts&typePage=db">
                                <svg width="24" height="24" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2"
                                    stroke-linecap="round" stroke-linejoin="round" class="feather feather-home" aria-hidden="true">
                                    <path d="M3 9l9-7 9 7v11a2 2 0 0 1-2 2H5a2 2 0 0 1-2-2z"></path>
                                    <polyline points="9 22 9 12 15 12 15 22"></polyline>
                                </svg>
                                Tableau de bord
                            </a>
                        </li>
                        <li class="nav-item">
                            <a class="nav-link <?php if ($v_typePage == "f") echo "active"; ?>"
                                href="index.php?page=vsts&typePage=f">
                                <svg width="24" height="24" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2"
                                    stroke-linecap="round" stroke-linejoin="round" class="feather feather-file" aria-hidden="true">
                                    <path d="M13 2H6a2 2 0 0 0-2 2v16a2 2 0 0 0 2 2h12a2 2 0 0 0 2-2V9z"></path>
                                    <polyline points="13 2 13 9 20 9"></polyline>
                                </svg>
                                Fournisseur
                            </a>
                        </li>
                        <li class="nav-item">
                            <a class="nav-link <?php if ($v_typePage == "v") echo "active"; ?>"
                                href="index.php?page=vsts&typePage=v">
                                <svg width="24" height="24" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2"
                                    stroke-linecap="round" stroke-linejoin="round" class="feather feather-users" aria-hidden="true">
                                    <circle cx="9" cy="21" r="1"></circle>
                                    <circle cx="20" cy="21" r="1"></circle>
                                    <path d="M1 1h4l2.68 13.39a2 2 0 0 0 2 1.61h9.72a2 2 0 0 0 2-1.61L23 6H6"></path>
                                </svg>
                                Visiteurs
                            </a>
                        </li>
                        <li class="nav-item">
                            <a class="nav-link <?php if ($v_typePage == "vv") echo "active"; ?>"
                                href="index.php?page=vsts&typePage=vv">
                                <svg width="24" height="24" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2"
                                    stroke-linecap="round" stroke-linejoin="round" class="feather feather-users" aria-hidden="true">
                                    <path d="M17 21v-2a4 4 0 0 0-4-4H5a4 4 0 0 0-4 4v2"></path>
                                    <circle cx="9" cy="7" r="4"></circle>
                                    <path d="M23 21v-2a4 4 0 0 0-3-3.87"></path>
                                    <path d="M16 3.13a4 4 0 0 1 0 7.75"></path>
                                </svg>
                                Visite fournisseur
                            </a>
                        </li>
                        <li class="nav-item">
                            <a class="nav-link <?php if ($v_typePage == "ab") echo "active"; ?>"
                                href="index.php?page=vsts&typePage=ab">
                                <svg width="24" height="24" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2"
                                    stroke-linecap="round" stroke-linejoin="round" class="feather feather-bar-chart-2"
                                    aria-hidden="true">
                                    <line x1="18" y1="20" x2="18" y2="10"></line>
                                    <line x1="12" y1="20" x2="12" y2="4"></line>
                                    <line x1="6" y1="20" x2="6" y2="14"></line>
                                </svg>
                                À propos
                            </a>
                        </li>
                    </ul>
                </div>
            </nav>
<?PHP
        }
    }
}

?>
