1.检查是否添加了@controller注解
2.在springmvc.xml里添加controller注解扫描
3.在applicationContext.xml里添加service扫描,给mapper添加实体
<bean class="org.mybatis.spring.mapper.MapperScannerConfigurer">
<property name="basePackage" value="com.witty.shopping.mapper"></property>
</bean>