<div class="ui main menu" id="navbar">
    
    <a class="icon item" id="launch_icon">
        <i class="large content icon"></i>
    </a>
    
    <?php if(Auth::guard('usuario')->user()->local->id_tipo_local == 1 && Auth::guard('usuario')->user()->id_rol != 3): ?> 
    <a class="item labeled" id="venta_icon"  href="<?php echo e(url('/venta/nuevo/')); ?>">
        <i class="circular green inverted dollar sign icon" style="margin-right: 10px"></i>Hacer una Venta
    </a>
    <?php endif; ?>

    <div class="right menu">
        

        <div class="ui pointing dropdown item" id="menu_sucursales" title="En que local estoy ahora">
            <i class="circular brown inverted university icon" style="margin-right: 10px"></i>
            <div class="text"><?php echo e(ucwords(mb_strtolower(Auth::guard('usuario')->user()->local->nombre))); ?></div>
            
        </div>

        <div class="ui dropdown item labeled icon "  id="menu_notificaciones" title="Notificaciones">
            <i class="bell large icon grey"></i>
            <div class="ui red label mini circular alert_icon"  id="numero_alertas"></div>
            <div class="menu transition hidden margin_dropdown border_shadow" id="item_alertas">
                
            </div>
        </div>

        <div class="ui pointing dropdown item">
            <img class="ui mini circular image" src="<?php echo e(asset(Auth::guard('usuario')->user()->url_avatar)); ?>" alt="avatar" style="margin-right: 10px">
            <span id="menu_usuario" ><?php echo e(ucwords(mb_strtolower(Auth::guard('usuario')->user()->nombres))); ?></span><i class="dropdown icon"></i>
            <div class="menu transition hidden margin_dropdown border_shadow" tabindex="-1" >
                <a class="item" href="<?php echo e(url('/personal/perfil/'.Auth::guard("usuario")->user()->username.'')); ?>"><i class="user icon"></i>Mi cuenta</a>
                <div class="ui divider"></div>
                <a class="item" href="<?php echo e(route('logout')); ?>"  onclick="event.preventDefault(); document.getElementById('logout-form').submit()"><i class="power off icon"></i>Cerrar sesión</a>
            </div>
        </div>
        <form id="logout-form" action="<?php echo e(route('logout')); ?>" method="POST" style="display: none;">
            <?php echo e(csrf_field()); ?>

        </form>
        <div style="width: 5px !important"> </div>
 
    </div>
</div>
