applicationContext.xml 1.4 KB

12345678910111213141516171819202122232425262728
  1. <?xml version="1.0" encoding="UTF-8"?>
  2. <beans xmlns="http://www.springframework.org/schema/beans"
  3. xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
  4. xmlns:context="http://www.springframework.org/schema/context"
  5. xmlns:tx="http://www.springframework.org/schema/tx"
  6. xmlns:mvc="http://www.springframework.org/schema/mvc"
  7. xsi:schemaLocation="http://www.springframework.org/schema/beans http://www.springframework.org/schema/beans/spring-beans.xsd
  8. http://www.springframework.org/schema/context http://www.springframework.org/schema/context/spring-context.xsd
  9. http://www.springframework.org/schema/tx http://www.springframework.org/schema/tx/spring-tx.xsd
  10. http://www.springframework.org/schema/mvc http://www.springframework.org/schema/mvc/spring-mvc.xsd
  11. ">
  12. <mvc:annotation-driven/>
  13. <mvc:default-servlet-handler/>
  14. <import resource="classpath:dataSource.xml"/>
  15. <context:component-scan base-package="com.sziit"/>
  16. <bean class="org.springframework.web.servlet.view.InternalResourceViewResolver">
  17. <property name="prefix" value="/WEB-INF/views/"/>
  18. <property name="suffix" value=".jsp"/>
  19. </bean>
  20. <bean id="multipartResolver" class="org.springframework.web.multipart.commons.CommonsMultipartResolver">
  21. <property name="defaultEncoding" value="UTF-8"/>
  22. <!-- 大小为字节-->
  23. <property name="maxUploadSize" value="1048576"/>
  24. </bean>
  25. </beans>