cancel
Showing results for 
Search instead for 
Did you mean: 

Change Portal desktop dynamically

Former Member
0 Kudos

Hello Praveen,

This message is reference to the thread "Change Portal Desktop Based on Role" . If you remeber initially I could not able to find the setRuntimeDesktop method.

Now I am running my code in SP14 (different environment) its working fine.

IVIEW preview is working fine and setRuntimeDesktop() also setting the desktop at runtime. Could you please tell me where should I place this IView and where to subscribe event to run this IVIEW

that can change the desktop only at TLN event but not for sub nodes (detail navigation).

Thanks

Accepted Solutions (0)

Answers (3)

Answers (3)

Former Member
0 Kudos

Aim is to change the desktop dynamically when move across the Tabs (roles).

Role1 is assigned to Desktop1

Role2 is assigned to Desktop2.

Issue #1

When I click Role1, its not changing the destop immediately...I mean if I click twice on the same tab then its changing

Issue #2

Once the desktop is changed, only inner content area is reflecting the changes but NOT the Header area ( Masthead & TLN).

Please let me know did anyone came across the same issue.

Thanks

DK007
Active Participant
0 Kudos

Hello Hammad,

I have similar requirement, could you please let me know whether you got resolved it or not. I would like to know where should I have to place the code to change the desktop based on the selected/clicked role/tab in top-level navigation. I placed the code in masthead, but with no use. I would appreicate your help in this regard.

Regards,

Dheeram

former_member71614
Active Participant
0 Kudos

Hi,

You can try configuring cache connectors for your roles - if not already done. Has pro's and con's of course.

To do this, go to system administration --> Navigation --> Roles and then enable if not already done so. The drawback is if you make role changes you then need to flush this cache for them to become active. This may well adress your desktop caching.

You can also try add script or adjust your code to perform a full page load on mast head click actions and even add logic to cater for unneccesary updates.

Ajax is also an option for you perhaps as it will allow you to perform the updates to the theme more seamlessly (without doing full page reloads) - you can "cache" the themes upfront and then reference the header content on change.

hope this helps.

DK007
Active Participant
0 Kudos

Thanks for your time in looking into this message. I'm trying to hide a iview or use a different desktop page based on the link(top level role) the user has clicked/selected. This is not specific to a user/role. Its for all users in the portal. I have 2 sets of desktop pages, one is a normal one, which everyuser can see and other one is only when the user clicks a role on top-level navigation. I just need to know where should I place the code to set the desktop during runtime. Once again thanks for your time and help.

Regards,

Dheeram

DK007
Active Participant
0 Kudos

Thanks Basis Team for giving me the hint on using AJAX. I used AJAX in masthead, before EPCM.doNavigation event I called a custom component by passing the clicked/selected role/link and added code to change desktop based on some condition and setting the desktop by calling setRuntimeDesktop method with a desktop url. But I saw the change in the desktop only once, from then onwards the changes in the desktop are not getting reflected. Do I need to do any thing after setting the runtime desktop?

Appreciate your time and help.

Regards,

Dheeram

DK007
Active Participant
0 Kudos

Hello Experts,

Changes are getting reflected only when the browser is refreshed, but the issue with browser refresh is then its going back to home page/tab for the user. Is there any way to reset/refresh the content area only.

Anyone has any suggestion/comment on content/desktop innerpage refresh issue.

Very much appreciate your time.

Regards,

Dheeram

former_member71614
Active Participant
0 Kudos

Hi,

Can I suggest you run http trace and inspect the logs as this will identify what code is fired when you fire events in the page.

It is difficuilt for me to assist you because I cannot see the way the code is being executed.

Further to the portal content area (com.sap.portal.contentarea). If you see the following docs try set the target to reference the content area defiend in your framework page (you may be using a custom framework page). You should be in a position to query the object name defined for the content area defined in your framework page.

http://www.sdn.sap.com/irj/scn/go/portal/prtroot/docs/library/uuid/50d2aeb9-5f92-2d10-d38d-ded09c943...

Conceptually the principals are the same I believe.

Let me know how it goes.

Just another thought:

Check if you need to "wait" for the content area to load before applying the event - the iView needs to serve the content within before the them is applied. Check the iview attributes too, if they are cached then the content area will not be updated till the next refresh potentially

Edited by: Basis Team on Dec 23, 2010 7:40 AM

DK007
Active Participant
0 Kudos

Hi,

I want a different desktop based on the selected role. The AJAX code and TLN codes are getting executed successfully and the changes are getting reflected only when the browser is refreshed, but I want the changes to take effect immediately without browser refresh.

FYI. Desktop URL and Frameworkpage is getting updated in the session(I had debug statement, which is printing previous and current desktopurl and frameworkpage), but the Desktop Innerpage is not showing the changed desktop. Somehow the Desktop Inner Page is still using the old desktop even though a new desktop is set during runtime and session variable is updated. Is there any way to raise an event and information the desktop inner page to refresh?

Appreciate your help and time.

Regards,

Dheeram

Former Member
0 Kudos

Hi,

Check this it will ures full.

Role Based Changed

http://help.sap.com/saphelp_nw70/helpdata/EN/1e/e19f58136e654d9709befa464314f2/frameset.htm

Thanks & Regards,

Suresh Pagadala

0 Kudos

Hi,

Check this blog where the theme is switched dynamically when TLN is clicked:

So use similar logic to change the desktop dynamically when TLN is clicked.

Regards,

Praveen Gudapati