Thursday, September 9, 2010

Links to official standards

Adding links for most common standards which need to be referred while development
1. CLick on link below for email standards
Email Standards
Example : Sample 1

2. W3C's easy-to-use markup validation service, based on SGML and XML parsers.
http://validator.w3.org/

3. JSR-000286 Portlet Specification 2.0
Final release
JSR 168 final specifications

4. Scripting
ecma-international standards

5. Code Conventions for the Java Programming Language
Conventions

Tuesday, September 7, 2010

Quick Workaround & Temporary fixes

Theme > Change in portlet.vm for requirement to remove portlet title showing text "web content diplay"

Summary : #if( $portlet_title =='Web Content Display')
#else
$theme.iconPortlet() $portlet_title
#end

2>
Change is custom.css to acomdate tab space for 'BiggerNameTab' tab in navigation

Summary:
#navigation ul li.parent-nav-item {
text-align:center;
width:109px;

Wednesday, September 1, 2010

Enable user creation with duplicate email id

To enable user creation with duplicate email -id

If you don't have ant ext environment and still want to add this functionality leave me a note and I will send you steps for creating a separate jar and configurations to make your custom code work for your custom application.

For extension environment -- Write a new class in ext-environment

public class AbhishekUserLocalServiceImpl extends UserLocalServiceImpl
Now override two validate methods and make following changes

1. For method with signature
protected void validate(long userId, String screenName, String emailAddress, String firstName, String lastName, String smsSn)

remove ----> throw new DuplicateUserEmailAddressException();

from
if (userPersistence.fetchByC_EA(
user.getCompanyId(), emailAddress) != null) {

throw new DuplicateUserEmailAddressException();
}


2.
For method with signature

protected void validate(long companyId, long userId, boolean autoPassword, String password1,String password2, boolean autoScreenName, String screenName, String emailAddress, String firstName, String lastName, long[] organizationIds)

remove --->throw new DuplicateUserEmailAddressException();

from

if (Validator.isNotNull(emailAddress)) {
User user = userPersistence.fetchByC_EA(companyId, emailAddress);

if (user != null) {
throw new DuplicateUserEmailAddressException();
}
}