Add to delicious
Add to technorati
Add to technorati
Digg it
furl
Yahoo

Vanilla 1.1.4 is a product of Lussumo. More Information: Documentation, Community Support.

    • CommentAuthorque_capo
    • CommentTimeOct 29th 2009
     # 1

    I have a moddify to permissions options: Saludos!

    Is in the Wrapper.tpl.php from html themes.
    And create a table called cdp_permissions with sectors_rel int(11) and accounts_rel int(11)

    <!-- Navigation. -->
    <ul id="sectors">
    <?php
    $getNavigation = $Db->select(TABLE_PREFIX . "sectors");
    echo '<li><a href="javascript: void(0);" id="current" class="out" onclick="toggleNav();">' . SECTOR_TITLE . '</a>';
    echo '<ul id="hiddenLinks" style="display: none;">';

    while($sector = $Db->fetch_assoc($getNavigation))
    {
    $getPermissions = $Db->select(TABLE_PREFIX . "permissions");
    $visible = false;
    while($permission = $Db->fetch_assoc($getPermissions))
    {
    if($sector['id'] == $permission['cdp_sectors_rel'] && $permission['cdp_accounts_rel'] == $_SESSION['user']['id'])
    {
    $visible = true;
    }
    }

    if($visible)
    {
    $selected = (SECTOR_ID == $sector['id']) ? ' id="selected" ' : '';
    echo '<li><a href="index.php?module=overview&sector=' . $sector['id'] . '"' . $selected . '>' . $sector['title'] . '</a></li> ' . "\n";
    }
    }