一级菜单点击收起

This commit is contained in:
WEB许何哲\xuhez
2023-07-17 17:32:11 +08:00
parent 21a594a81e
commit ad60e1a624
2 changed files with 1032 additions and 930 deletions

File diff suppressed because it is too large Load Diff

View File

@@ -62,16 +62,16 @@ function makeMenus(env, menusData, fetchLoadMenus) {
return menusData[menuID]; return menusData[menuID];
}, },
getCurrentApp() { getCurrentApp() {
if (!currentAppId) { // if (!currentAppId) {
return; // return;
} // }
var target_tag = '.o_navbar_apps_menu a.main_link[data-menu='+currentAppId+']' // var target_tag = '.o_navbar_apps_menu a.main_link[data-menu='+currentAppId+']'
$(target_tag).addClass('active'); // $(target_tag).addClass('active');
if($(target_tag).hasClass('dropdown-btn')){ // if($(target_tag).hasClass('dropdown-btn')){
var ultag = $(target_tag).parent().find('.header-sub-menus') // var ultag = $(target_tag).parent().find('.header-sub-menus')
$(ultag).addClass('show'); // $(ultag).addClass('show');
} // }
return this.getMenu(currentAppId); // return this.getMenu(currentAppId);
}, },
getMenuAsTree(menuID) { getMenuAsTree(menuID) {
const menu = this.getMenu(menuID); const menu = this.getMenu(menuID);