Forum

Welcome to ProjeQtOr new Forum. We migrated old forum to the new website.
You will find all your posts here, with your usual account.
Just one point : you’ll have to reinitialize your password. Use “Lost password” feature.

add a submenu in th...
 
Notifications
Clear all

add a submenu in the left menu

6 Posts
2 Users
0 Reactions
4,630 Views
(@yassine)
Posts: 26
Active Member
Topic starter
 
[#778]

I am trying to develop a new module I want to add a submenu in the left menu I try to add a field in the table MENU but it's not included when creating dynamic menu


 
Posted : 01 Nov 2012 19H02
babynus
(@babynus)
Posts: 14966
Main Contributor Admin
 

you also need to add habilitations for this new screen.
this can be done through access to screen menu


 
Posted : 01 Nov 2012 19H54
(@yassine)
Posts: 26
Active Member
Topic starter
 

i can't understand your advice :S


 
Posted : 01 Nov 2012 20H00
babynus
(@babynus)
Posts: 14966
Main Contributor Admin
 

When you try to add a new menu, to display a new screen, you add item in table Menu.
You also need to add lines in table habilitation for each profile allowed to access the new screen. Without this, new lenu does not appear.
You can update table habilitation directly, or use the screen "Pramaeters" => "Access rights" => "access to forms". You should have a new line for your new screen. Just check the profiles allowed to access the screen and save...
Then disconned/reconnect to see changes.


 
Posted : 01 Nov 2012 22H16
(@yassine)
Posts: 26
Active Member
Topic starter
 

thanks for your answer, i want to know where's the relation between the menu and the content (on click : appel de la page qui contient le contenu associé)


 
Posted : 05 Nov 2012 12H51
babynus
(@babynus)
Posts: 14966
Main Contributor Admin
 

Hi,

It will depend on menu.type value. See code in /view/menuTree.php, line 165 :

    if (item.type=='object') {
        loadMenuBarObject(item.id,item.name);
    } else if (item.type=='item') {
        loadMenuBarItem(item.id, item.name);
    } else if (item.type=='class') {
      cleanContent("detailDiv");
	    formChangeInProgress=false;
	    loadContent("objectMain.php?objectClass="+item.objectClass,"centerDiv"); 
    } else if (item.type=='menu') {
       // Nothing
    } else {
	    showInfo(i18n("messageSelectedNotAvailable", new Array(item.name)));
	  }

For type "object", access is generic.
For type "item", the javascript function "loadMenuBarItem" must be completed in /view/js/projectorDialog.js


 
Posted : 05 Nov 2012 14H11
Share:

Scroll to Top