When developing
custom themes, we need to use Liferay services in VM. Its quite easy
but tricky. So, putting here a simple example-
Write following in init-custom.vm
Now you can use this service as follows:
Write following in init-custom.vm
#set($organizationLocalService = $serviceLocator.findService(
"com.liferay.portal.
service.OrganizationLocalServiceUtil"
)Now you can use this service as follows:
#set ($org = $organizationLocalService.getOrganization($myPlace.getClassPK($myPlace.getClassPK()))
No comments:
Post a Comment