Foros de discusión
How to make custom asset in liferay 7?
Abhishek Jain, modificado hace 7 años.
How to make custom asset in liferay 7?
Regular Member Mensajes: 226 Fecha de incorporación: 20/08/16 Mensajes recientes
I am following the tutorial on https://dev.liferay.com/develop/tutorials/-/knowledge_base/7-0/adding-updating-and-deleting-assets-for-custom-entities. I created a custom entity named School3. In -School3LocalServiceImpl, I am invoking a method like as follows:-
@Override
public School3 updateSchool3(School3 school3) {
AssetEntry assetEntry = assetEntryLocalService.updateEntry(
userId, School3.getGroupId(), page.getCreateDate(),
page.getModifiedDate(), School3.class.getName(),
page.getResourcePrimKey(), page.getUuid(), 0,
assetCategoryIds, assetTagNames, true, true, null, null,
page.getCreateDate(), null, ContentTypes.TEXT_HTML,
page.getTitle(), null, null, null, null, 0, 0, null);
return super.updateSchool3(school3);
}
Here page is not resolved. How to initialize it? Please help. Any help would be appreciated.
@Override
public School3 updateSchool3(School3 school3) {
AssetEntry assetEntry = assetEntryLocalService.updateEntry(
userId, School3.getGroupId(), page.getCreateDate(),
page.getModifiedDate(), School3.class.getName(),
page.getResourcePrimKey(), page.getUuid(), 0,
assetCategoryIds, assetTagNames, true, true, null, null,
page.getCreateDate(), null, ContentTypes.TEXT_HTML,
page.getTitle(), null, null, null, null, 0, 0, null);
return super.updateSchool3(school3);
}
Here page is not resolved. How to initialize it? Please help. Any help would be appreciated.
Pankaj Kathiriya, modificado hace 7 años.
RE: How to make custom asset in liferay 7? (Respuesta)
Liferay Master Mensajes: 722 Fecha de incorporación: 5/08/10 Mensajes recientes
You should not follow example blindly.
It clearly says that the example code is from class WikiPageLocalServiceImpl that means that page object referring to wiki page.
It clearly says that the example code is from class WikiPageLocalServiceImpl that means that page object referring to wiki page.
Abhishek Jain, modificado hace 7 años.
RE: How to make custom asset in liferay 7?
Regular Member Mensajes: 226 Fecha de incorporación: 20/08/16 Mensajes recientes
Thanks Pankaj ... I am sorry for the blunder I committed..