Foros de discusión

Override PortletAction in Liferay 7

Thirumal Reddy, modificado hace 7 años.

Override PortletAction in Liferay 7

Regular Member Mensajes: 216 Fecha de incorporación: 3/12/15 Mensajes recientes
Hi Guys,
How to Override PortletAction and RolesAdminPortlet
in Liferay 7.?

regards,
Thirumal.
thumbnail
David H Nebinger, modificado hace 7 años.

RE: Override PortletAction in Liferay 7

Liferay Legend Mensajes: 14915 Fecha de incorporación: 2/09/06 Mensajes recientes
Have you tried checking out the blade examples? They have one that fits your request: https://github.com/liferay/liferay-blade-samples/tree/master/liferay-gradle/blade.strutsportletaction.








Come meet me at the LSNA!
Thirumal Reddy, modificado hace 7 años.

RE: Override PortletAction in Liferay 7

Regular Member Mensajes: 216 Fecha de incorporación: 3/12/15 Mensajes recientes
Hi David,
I want override editRole method from RolesAdminPortlet.java class
i know how to override MCVAction and render command classes but i dont know how to override RolesAdminPortlet class
could you please give me some suggestion.

regards,
Thirumal.
thumbnail
David H Nebinger, modificado hace 7 años.

RE: Override PortletAction in Liferay 7

Liferay Legend Mensajes: 14915 Fecha de incorporación: 2/09/06 Mensajes recientes
Yeah, that's not possible. You'd have to create your own portlet to implement an override to a core method like that.






Come meet me at the LSNA!
Thirumal Reddy, modificado hace 7 años.

RE: Override PortletAction in Liferay 7

Regular Member Mensajes: 216 Fecha de incorporación: 3/12/15 Mensajes recientes
Hi David,
i didn't understand. could you please explain clearly.
thumbnail
David H Nebinger, modificado hace 7 años.

RE: Override PortletAction in Liferay 7

Liferay Legend Mensajes: 14915 Fecha de incorporación: 2/09/06 Mensajes recientes
there is no supported way to override an internal method of a class in a module, there is no supported "inhertitance" of modules that might allow you to replace a single method within the RolesAdminPortlet class.

your only option is going to be to create your own portlet which implements what you want, copying everything you need from the original module but it will still be your own portlet, not Liferay's.






Come meet me at the LSNA!
Thirumal Reddy, modificado hace 7 años.

RE: Override PortletAction in Liferay 7

Regular Member Mensajes: 216 Fecha de incorporación: 3/12/15 Mensajes recientes
Ok David.
If i create new portlet and i'll implement my requirements.
but even though by default liferay's method will be exceute.
what things i need to do to exceute newly created portlet methods insted of liferay's method.
Thirumal Reddy, modificado hace 7 años.

RE: Override PortletAction in Liferay 7

Regular Member Mensajes: 216 Fecha de incorporación: 3/12/15 Mensajes recientes
Hi David,
please give me replay.
with claer explanation.
I am new to OSGI technology.

thanks and regards,
Thirumal.
Thirumal Reddy, modificado hace 7 años.

RE: Override PortletAction in Liferay 7

Regular Member Mensajes: 216 Fecha de incorporación: 3/12/15 Mensajes recientes
Hi David,
How do i create a new portlet and do implement my requirement and default liferay implementation
and how to make my new portlet will work instade of Liferay's.
please give me replay david.

regards,
Thirumal.
Thirumal Reddy, modificado hace 7 años.

RE: Override PortletAction in Liferay 7

Regular Member Mensajes: 216 Fecha de incorporación: 3/12/15 Mensajes recientes
Hi David,
I have created a new portlet and implemented all the requirements.
but it is not executing default liferay module only exceuting.?
how can i make module excute.?

regards,
Thirumal.
Fazalmahammad Babaria, modificado hace 4 años.

RE: Override PortletAction in Liferay 7

New Member Mensajes: 16 Fecha de incorporación: 26/02/19 Mensajes recientes
Hiii Thirumal Reddy,
                 Have you got any solution for your problem because  i am also stucked in same situation and dont know how to override that.
Fazalmahammad Babaria, modificado hace 4 años.

RE: Override PortletAction in Liferay 7

New Member Mensajes: 16 Fecha de incorporación: 26/02/19 Mensajes recientes
Thats right sir but in my case i am getting no service for EditLayoutsAction so for that i have to override This class but dont know how i can. 
thumbnail
Suresh Nimmakayala, modificado hace 4 años.

RE: Override PortletAction in Liferay 7

Liferay Master Mensajes: 690 Fecha de incorporación: 18/08/04 Mensajes recientes
Fazalmahammad Babaria:

Thats right sir but in my case i am getting no service for EditLayoutsAction so for that i have to override This class but dont know how i can. 
you said i have stucked in same situation 
thread started as
"Hi Guys,
How to Override PortletAction and RolesAdminPortlet
in Liferay 7.?"

 what do you expect ?

create new thread and give more details with your problem

Thanks
Suresh