Foros de discusión

How to find if any portlet is deleted

avasek atok, modificado hace 8 años.

How to find if any portlet is deleted

Junior Member Mensajes: 41 Fecha de incorporación: 9/01/15 Mensajes recientes
Is there any API to check if a portlet exists in liferay system. We are storing portlet instance id's using service builder into a custom table, hence while iterating through the portlet instance id's I just want to know if there can be any liferay API, using which will I be able to identify if the portlet exists in the system or delete from the system.

Please suggest/share your experiences.
thumbnail
Meera Prince, modificado hace 8 años.

RE: How to find if any portlet is deleted

Liferay Legend Mensajes: 1111 Fecha de incorporación: 8/02/11 Mensajes recientes
Hi
We have table called portlet_ there you can see column acetive this may be help you and also we can have layout table there you can have typeSettings column where you can see available portlets for each page. from these i think we can do some logic so that it will full fill your need,

example type settings columns

layout-template-id=2_columns_iii
column-2=148_INSTANCE_mO1jLXZhY251,114,
column-1=33,

Regards,
Meera Prince
thumbnail
Jitendra Rajput, modificado hace 8 años.

RE: How to find if any portlet is deleted

Liferay Master Mensajes: 875 Fecha de incorporación: 7/01/11 Mensajes recientes
Meera Prince:
Hi
We have table called portlet_ there you can see column acetive this may be help you and also we can have layout table there you can have typeSettings column



Little correction table name is layout_ not portlet_
avasek atok, modificado hace 8 años.

RE: How to find if any portlet is deleted

Junior Member Mensajes: 41 Fecha de incorporación: 9/01/15 Mensajes recientes
I tried with some API's in liferay, but couldn't fine any the correct one to check if the portlet really exists in the liferay system (Demoticon.

I have written a layout listener and i am storing the type settings in a table.
This table data got corrupted. I am reading the type settings data stored from this table and want to check if those instances really exists in liferay system.
If not i want to delete the stale data from the table based on the portlet instance existence.

So want to know if there is any Liferay API to find out the existence of portlet instance

Thanks,