<?php
$links = array(
    array(
        'title' =>  'Visualizar',
        'url' => array('revendas/view', array('id'=>$model->REV_IDREVENDA)),
        'activeClass' => 'view',
        'enabled' => true,
    ),
    array(
        'title' =>  'Editar',
        'url' => array('revendas/update', array('id'=>$model->REV_IDREVENDA)),
        'activeClass' => 'update',
        'enabled' => true,
    ),
    array(
        'title' =>  'Ativar/Inativar',
        'url' => array('revendas/situacao', array('id'=> $model->REV_IDREVENDA)),
        'activeClass' => 'situacao',
        'enabled' => true,
    )
);
?>

<ul id="menu-clientes" class="nav-pills nav navbar-nav navbar-fixed-top ">
    <?php foreach($links as $link) { ?>
        <?php if ($link['enabled']) { ?>
            <li <?= $link['activeClass'] == $active ? 'class="active"' : '' ?>>
                <a href="<?php echo Yii::app()->createUrl($link['url'][0], $link['url'][1]);?>">
                    <?php echo $link['title']; ?>
                </a>
            </li>
        <?php } ?>
   <?php } ?>
</ul>
