Hi Guys
Im new to
JAVA and liferay, and i am trying to customise the CMS as per chapter 7 and 8 of the book Liferay Portal 5.2 Systems Development
However my problem is that although i have followed the instructions (Twice) i keep getting this error message. The issues occur when following pages 258,259,260.
The issue seems to lie when you follow the code to create the beans in ext-spring.xml.
The code given is
<bean id="com.ext.portal.service.ExtVelocityToolService" class="com.ext.portal.service.impl.ExtVelocityToolServiceImpl" /> <bean id="com.ext.portal.util.ExtVelocityToolUtil" class="com.ext.portal.util.ExtVelocityToolUtil">
<property name="extVelocityToolService" ref="com.ext.portal.service.ExtVelocityToolService" />
</bean><bean id="com.ext.portal.util.ExtVelocityToolUtil.velocity" class="org.springframework.aop.framework.ProxyFactoryBean" parent="baseVelocityUtil"> <property name="target" ref="com.ext.portal.service.ExtVelocityToolService" />
</bean>
But it produces this error
org.springframework.beans.factory.BeanCreationException: Error creating bean with name 'com.ext.portal.util.ExtVelocityToolUtil' defined in class path resource [META-INF/ext-spring.xml]: Initialization of bean failed; nested exception is org.springframework.beans.TypeMismatchException: Failed to convert property value of type [com.ext.portal.service.impl.ExtVelocityToolServiceImpl] to required type [com.ext.portal.service.ExtVelocityToolService] for property 'extVelocityToolService'; nested exception is java.lang.IllegalArgumentException: Cannot convert value of type [com.ext.portal.service.impl.ExtVelocityToolServiceImpl] to required type [com.ext.portal.service.ExtVelocityToolService] for property 'extVelocityToolService': no matching editors or conversion strategy found
at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.doCreateBean(AbstractAutowireCapableBeanFactory.java:480)
at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory$1.run(AbstractAutowireCapableBeanFactory.java:409)
Does anyone know how to fix this
thanks in advance for any help
Dan