Display logo based on which group logged in user is part of

armanm32055672

01-02-2018

Hi,

I have a component that displays a logo on a page, I need to be able to dynamically change this logo depending on what group the user is a member of. For example let's say we have two users, James & Paul and they belong to two separate groups. James is in group A and Paul is is group B, I want to only show img for group A and a different img src if they are in group B.

Sudo:

<img class="ui image"

                  src="${

                    (

                      (user group == 'group A') ? ('show logo for group A')

                       😞

                          (user group == 'group B') ? ('show logo for group A')

                          😞

                              'default logo'

                           )

                        )

                     )

}"/>                                

How can I do this? I am having some trouble trying to reference user's group, I can do it with the name but need to be able to do it with it's group. 

-Arman

Answers (0)