AnsweredAssumed Answered

Customize header of Site

Question asked by redraccoon on Dec 1, 2016
Latest reply on Dec 1, 2016 by ddraper

Hello 

I'm using Aikau to customize my headers and it's working fine

 

Actually I'm hiding menu if you are not an admin

 

widgetUtils.deleteObjectFromArray(model.jsonModel, "id", "HEADER_SITE_MEMBERS");
widgetUtils.deleteObjectFromArray(model.jsonModel, "id", "HEADER_SITE_DASHBOARD");
widgetUtils.deleteObjectFromArray(model.jsonModel, "id", "HEADER_SITE_CONFIGURATION_DROPDOWN");

widgetUtils.deleteObjectFromArray(model.jsonModel, "id", "HEADER_SITE_DOCUMENTLIBRARY");
widgetUtils.deleteObjectFromArray(model.jsonModel, "id", "HEADER_SITE_DATA-LISTS");

 

1

 

as you can see it's not working for document library and data-lists,

when we explore the code we can see the difference of how they are created

 

in share-header.lib.js

 

2

 

For example the HEADER_SITE_MEMBERS is call with his name

**********

 id: "HEADER_SITE_MEMBERS",

**********

and the HEADER_SITE_DATA-LISTS 's name is created in the function with 

**********

  id: "HEADER_SITE_" + pages[i].pageId.toUpperCase(),

**********

 

wich I can understand, he has to create them depending of our widgets

 

But where i'm lost is why I can't delete them with their ID like the others ? 

I'm shure of the id because we can see it in the browser

 

So my questions is why are they not working the same way ? if it's a generated ID or a given ID it's not different once is in the share application ?

 

 

thank you in advance !

Outcomes