cancel
Showing results for 
Search instead for 
Did you mean: 

How To: iView Personalisation link from inside iView?

Former Member
0 Kudos

Hi, in our EP6 SP2 implementation, as a design choice, we are not using HTMLB trays. Thus iView personalization is slightly problematic.

I have a world time iView that displays 5 cities times, and I need the user to be able to select their cities. This iView is a JSPDynPage. I would like to fire the iView personalise event from an icon contained in the iView.

I would really appreciate some guidance of which class and method to use.

Many Thanks in advance,

Mark

Accepted Solutions (1)

Accepted Solutions (1)

Oliver_S
Product and Topic Expert
Product and Topic Expert
0 Kudos

Abstractportalcomponent:

2 methods.

public void doHandleEditData(IPortalComponentRequest request, IPortalRequestEvent event)

{

IPortalComponent delegateComponent = getPersonalizationDelegate(request);

if(delegateComponent instanceof IEventListenerComponent)

((IEventListenerComponent)delegateComponent).handleEvent(request, event);

}

private IPortalComponent getPersonalizationDelegate(IPortalComponentRequest request)

{

IPortalComponentContext context = request.getComponentContext();

IPortalComponentProfile profile = context.getProfile();

String delegateClassName = profile.getProperty("PersonalizationClass");

if(delegateClassName != null)

try

{

Class delegateClass = Class.forName(delegateClassName, true, getClass().getClassLoader());

return (IPortalComponent)delegateClass.newInstance();

}

catch(Exception e)

{

throw new PortalComponentException("Failed to load personalization delegate " + delegateClassName, e);

}

else

return PortalRuntime.getRuntimeResources().getDefaultPersonalizationDelegate();

}

Former Member
0 Kudos

Many thanks Oliver, for your quick and helpful response.

That answers 90% of my question. My challenge is how to call the methods from my MVC JSPDynPage. How do I link my HTMLB event from my link to the methods you have provided?

Thanks,

Mark

Answers (1)

Answers (1)

Former Member
0 Kudos

.