Skip to Content
author's profile photo Former Member
Former Member

Restricting User Access to specific navigation node in backoffice

Hi,

We are customizing backoffice to show the specific sections within backoffice to a user.

For instance; an SEO guy can only see a custom item type displayed in explorer tree. He should not be able to see the other items.

We also need a way to assign backoffice roles to the users to restrict. How do we restrict this to the user?

Saurabh

Add a comment
10|10000 characters needed characters exceeded

Related questions

5 Answers

  • Best Answer
    Posted on Oct 21, 2016 at 11:11 AM

    Disabled node means that your user doesn't have access to this type. You can change it as follows: User -> User Groups -> (select your 'backofficerole1') -> Open 'Key' action (Principal Permission Action) -> Add SEOConfiguration and assign appropriate permissions

    Add a comment
    10|10000 characters needed characters exceeded

  • Posted on Oct 18, 2016 at 09:35 AM
    Add a comment
    10|10000 characters needed characters exceeded

    • Former Member

      It doesn't work as the documentation you provided talks about is removing a specific node access. I am trying to grant access to a specific custom item type created and shown in left navigation in backoffice.

  • author's profile photo Former Member
    Former Member
    Posted on Oct 21, 2016 at 07:55 AM

    I created "backofficerole1" and assigned it to a user "testuser".

    Next I created a custom component and assigned the backofficerole1 to it as follows:

     context component="explorer-tree" merge-by="principal" principal="backofficerole1">
              <n:explorer-tree xmlns:n="http://www.hybris.com/cockpitng/config/explorertree">
                  <n:navigation-node id="SEO Configuration">
                      <n:type-node id="SEOConfiguration" code="SEOConfiguration" />
                  </n:navigation-node>
              </n:explorer-tree>
          </context>
      
     
      <context type="SEOConfiguration"  component="listview" principal="backofficerole1">
          <list:list-view xmlns:list="http://www.hybris.com/cockpitng/component/listView">
              <list:column qualifier="code" />
              <list:column qualifier="pageType" />
              <list:column qualifier="title" />
              <list:column qualifier="aliasName" />
              <list:column qualifier="keyword" />
              <list:column qualifier="description" />
              <list:column qualifier="metaname" />
              <list:column qualifier="metacontent" />
          </list:list-view>
      </context>
    
    

    I tried restricting this node to backofficerole1 but it is coming as disabled for testuser.

    Changes done as per documentation but still not working. any thoughts?

    Add a comment
    10|10000 characters needed characters exceeded

  • Posted on Oct 21, 2016 at 10:21 AM

    Hi,

    I've checked your code snippet:

      <context component="explorer-tree" merge-by="principal" principal="backofficerole1">
               <n:explorer-tree xmlns:n="http://www.hybris.com/cockpitng/config/explorertree">
                   <n:navigation-node id="SEO Configuration">
                       <n:type-node id="SEOConfiguration" code="SEOConfiguration" />
                   </n:navigation-node>
               </n:explorer-tree>
           </context>
    
    

    And tree node is visible only for testuser. Important question is: Did you create 'backofficerole1' as a backoffice role? You can check it as follows:

    User -> User Groups -> (select backofficerole1) -> Administration tab -> Metadata -> Type (it should be equal to 'BackofficeRole')

    Regards

    Lukasz

    Add a comment
    10|10000 characters needed characters exceeded

  • Posted on Oct 21, 2016 at 10:38 AM
    -1

    Hi!

    Node in ExplorerTree is disabled when a user has no read-rights for specified type. Check if backofficerole1 has right to read SEOConfiguration.

    Best regards, Jacek

    Add a comment
    10|10000 characters needed characters exceeded

Before answering

You should only submit an answer when you are proposing a solution to the poster's problem. If you want the poster to clarify the question or provide more information, please leave a comment instead, requesting additional details. When answering, please include specifics, such as step-by-step instructions, context for the solution, and links to useful resources. Also, please make sure that you answer complies with our Rules of Engagement.
You must be Logged in to submit an answer.

Up to 10 attachments (including images) can be used with a maximum of 1.0 MB each and 10.5 MB total.