Tuesday 18 August 2015

Coding standards to develop artifact

1. If we get any errors, while performing add/update operations then return previous request & response (which contains user entered data). By using the snippet:

PortalUtil.copyRequestParameters(request, response);

2. If necessary we need to write custom validator, to validate custom entities.

3. While writing implementation to CRUD operations in Liferay's service builder xxxxLocalServiceImpl class, make sure that you are not re-writing available operations in xxxxLocalServiceBaseImpl.

xxxLocalServiceBaseImpl CRUD operations are available. We are extending it in our xxxxLocalServiceImpl. So, no need to write again those CRUD operations on xxxxLocalServiceImpl class.


No comments:

Post a Comment