All Downloads are FREE. Search and download functionalities are using the official Maven repository.

commerce.broadleaf-framework-web.2.1.0-GA.source-code.bl-framework-web-applicationContext.xml Maven / Gradle / Ivy

<?xml version="1.0" encoding="UTF-8"?>
<beans xmlns="http://www.springframework.org/schema/beans"
       xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
       xmlns:aop="http://www.springframework.org/schema/aop"
       xmlns:tx="http://www.springframework.org/schema/tx"
       xmlns:context="http://www.springframework.org/schema/context"
       xsi:schemaLocation="http://www.springframework.org/schema/beans http://www.springframework.org/schema/beans/spring-beans-3.1.xsd
           http://www.springframework.org/schema/aop http://www.springframework.org/schema/aop/spring-aop-3.1.xsd
           http://www.springframework.org/schema/tx http://www.springframework.org/schema/tx/spring-tx-3.1.xsd http://www.springframework.org/schema/context http://www.springframework.org/schema/context/spring-context-3.1.xsd">

    <!-- Scan Broadleaf defined web utility classes -->
    <context:component-scan base-package="org.broadleafcommerce.core.web"/>

	<bean id="blOrderState"
          class="org.broadleafcommerce.core.web.order.OrderState" scope="request"/>

    <bean id="orderStateAOP"
          class="org.broadleafcommerce.core.web.order.OrderStateAOP"/>

    <aop:config>
        <aop:aspect id="orderStateAspect" ref="orderStateAOP">
            <aop:pointcut id="orderRetrievalMethod"
                          expression="execution(* org.broadleafcommerce.core.order.dao.OrderDao.readCartForCustomer(org.broadleafcommerce.profile.core.domain.Customer))"/>
            <aop:around method="processOrderRetrieval" pointcut-ref="orderRetrievalMethod"/>
        </aop:aspect>
    </aop:config>
    
	<bean id="blDialect" class="org.broadleafcommerce.common.web.dialect.BLCDialect">
	    <property name="processors">
		  <set>
			<ref bean="blContentProcessor"/>
			<ref bean="blAddSortLinkProcessor" />
			<ref bean="blCategoriesProcessor" />
			<ref bean="blFormProcessor" />
			<ref bean="blHeadProcessor" />
		    <ref bean="blNamedOrderProcessor" />
		    <ref bean="blPaginationPageLinkProcessor" />
			<ref bean="blPriceTextDisplayProcessor" />
			<ref bean="blProductOptionValueProcessor" />
			<ref bean="blProductOptionsProcessor" />
			<ref bean="blRatingsProcessor" />
			<ref bean="blRelatedProductProcessor" />
			<ref bean="blRemoveFacetValuesLinkProcessor" />
			<ref bean="blToggleFacetLinkProcessor" />
			<ref bean="blUrlRewriteProcessor" />
		  </set>
		</property>  	
	</bean> 
	
	<bean id="blWebTemplateResolver" class="org.thymeleaf.templateresolver.ServletContextTemplateResolver">
		<property name="prefix" value="/WEB-INF/templates/" />
		<property name="suffix" value=".html" />
		<property name="templateMode" value="HTML5" />
		<property name="cacheable" value="false"/>
		<property name="characterEncoding" value="UTF-8" />
	</bean>	
	
	<bean id="blEmailTemplateResolver" class="org.thymeleaf.templateresolver.ClassLoaderTemplateResolver">
		<property name="prefix" value="emailTemplates/" />
		<property name="suffix" value=".html" />
		<property name="templateMode" value="HTML5" />
		<property name="cacheable" value="false"/>
		<property name="characterEncoding" value="UTF-8" />
	</bean>
	
	<bean id="thymeleafSpringStandardDialect" class="org.thymeleaf.spring3.dialect.SpringStandardDialect" />
	
	<bean id="blWebTemplateEngine" class="org.thymeleaf.spring3.SpringTemplateEngine">
		<property name="templateResolvers">
			<set>
				<ref bean="blWebTemplateResolver" />
			</set>
		</property>
		<property name="dialects">
			<set>
				<ref bean="thymeleafSpringStandardDialect" />
				<ref bean="blDialect" />
			</set>
		</property>
	</bean>	
	
	<bean id="blEmailTemplateEngine" class="org.thymeleaf.spring3.SpringTemplateEngine">
		<property name="templateResolvers">
			<set>
				<ref bean="blEmailTemplateResolver" />
			</set>
		</property>
		<property name="dialects">
			<set>
				<ref bean="thymeleafSpringStandardDialect" />
				<ref bean="blDialect" />
			</set>
		</property>
	</bean>
	
</beans>




© 2015 - 2025 Weber Informatics LLC | Privacy Policy