Assembla home | Assembla project page
 

Ticket #15 (closed Bug: fixed)

Opened 2 years ago

Last modified 1 year ago

Admin Menu display issue

Reported by: aprice30 Assigned to: aprice30
Priority: normal Milestone: Version 0.5
Component: Interface Version: 0.3.1
Severity: normal Keywords:
Cc:

Description

I have been developing some modules for my site using backendpro, but ran in one rather annoying bug.

When I visit a page which is part of a module (sub-nav item), both menugroups will open.

Attachments

menu_bug.jpg (24.8 kB) - added by aprice30 on 07/17/08 10:59:46.

Change History

07/17/08 10:59:46 changed by aprice30

  • attachment menu_bug.jpg added.

07/17/08 11:36:02 changed by aprice30

  • owner set to aprice30.
  • status changed from new to assigned.

I gave every <li> element an unique id, which made the main nav <li> close. When I tried to give the subnav <li> elements the same id as the main nav <li> it worked like a charm!

<ul id="menu">
    <li id="mnu_dashboard"><?=anchor('admin',$this->lang->line('backendpro_dashboard'),array('class'=>'icon_house'))?></li>
    <?php if(check('Logboek',NULL,FALSE)):?>
    <li id="mnu_uren"><?=anchor('logboek/admin/logboek','Urenregistratie',array('class'=>'icon_log'))?></li>
    <?php endif;?>
    <?php if(check('Contents',NULL,FALSE)):?>
    <li id="mnu_contents"><span class="icon_contents">Contents</span>
        <ul>
            <?php if(check('Nieuws',NULL,FALSE)):?><li id="mnu_contents"><?=anchor('contents/admin/nieuws',"Nieuws",array('class'=>'icon_nieuws'))?></li><?php endif;?>  
            <?php if(check('Portfolio',NULL,FALSE)):?><li id="mnu_contents"><?=anchor('contents/admin/portfolio',"Portfolio",array('class'=>'icon_shield'))?></li><?php endif;?>  
        </ul>
    </li>
    <?php endif;?>

    <?php if(check('System',NULL,FALSE)):?>
    
    <li id="mnu_system"><span class="icon_computer"><?=$this->lang->line('backendpro_system')?></span>
        <ul>
            <?php if(check('Members',NULL,FALSE)):?><li id="mnu_system"><?=anchor('auth/admin/members',$this->lang->line('backendpro_members'),array('class'=>'icon_group'))?></li><?php endif;?>  
            <?php if(check('Access Control',NULL,FALSE)):?><li id="mnu_system"><?=anchor('auth/admin/access_control',$this->lang->line('backendpro_access_control'),array('class'=>'icon_shield'))?></li><?php endif;?>  
            <?php if(check('Settings',NULL,FALSE)):?><li id="mnu_system"><?=anchor('admin/settings',$this->lang->line('backendpro_settings'),array('class'=>'icon_cog'))?></li><?php endif;?>  
        </ul>
    </li>
    <?php endif;?>
</ul>

The origonal code didn't assign any ID's to the LI's, but assigning non unique ID's makes code invalid.

07/18/08 06:29:08 changed by aprice30

It does not work by duplicating the ID’s. It only keeps the menu closed. When I open a subitem in the System menu, it closes the system menu.

11/11/08 19:44:44 changed by aprice30

  • milestone set to Version 0.4.

02/28/09 08:45:45 changed by aprice30

  • status changed from assigned to closed.
  • resolution set to fixed.

(In [220]) The BackendPro tree menu in the admin panel now saves its open/closes status rather than it being lost between different pages, Closes #15,#45