list页面都打不开了
不知道为什么,我照着这个代码抄了一遍,结果list页面都打不开了,配置文件我已经校验好几遍了,没有错啊!!
Message.xml:
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE mapper
PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
"http://mybatis.org/dtd/mybatis-3-mapper.dtd">
<mapper namespace="Message">
<resultMap type="com.imooc.bean.Message" id="MessageResult">
<id column="id" jdbcType="INTEGER" property="id"/>
<result column="COMMAND" jdbcType="VARCHAR" property="command"/>
<result column="CONTENT" jdbcType="VARCHAR" property="content"/>
<result column="DESCRIPTION" jdbcType="VARCHAR" property="description"/>
</resultMap>
<select id="queryMessageList" parameterType="com.imooc.bean.Message" resultMap="MessageResult">
select ID,COMMAND,DESCRIPTION,CONTENT from message where 1=1
<if test="command!=null and!"".equals(command.trim())">and COMMAND=#{command}</if>
<if test="description!=null and!"".equals(description.trim())">
and DESCRIPTION like '%' #{description} '%'
</if>
</select>
<delete id="deleteOne" parameterType="int">
delete from MESSAGE where ID= #{_parameter}
</delete>
<delete id="deleteBatch" parameterType="java.util.List">
delete from MESSAGE where ID in(
<foreach collection="list" item="item" separator=",">
#{item}
</foreach>
)
</delete>
</mapper>
web.xml
<?xml version="1.0" encoding="UTF-8"?>
<web-app version="2.5"
xmlns="http://java.sun.com/xml/ns/javaee"
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:schemaLocation="http://java.sun.com/xml/ns/javaee
http://java.sun.com/xml/ns/javaee/web-app_2_5.xsd">
<display-name></display-name>
<welcome-file-list>
<welcome-file>index.jsp</welcome-file>
</welcome-file-list>
<servlet>
<servlet-name>ListServlet</servlet-name>
<servlet-class>com.imooc.servlet.ListServlet</servlet-class>
</servlet>
<servlet-mapping>
<servlet-name>ListServlet</servlet-name>
<url-pattern>/List.action</url-pattern>
</servlet-mapping>
<servlet>
<servlet-name>DeleteOneServlet</servlet-name>
<servlet-class>com.imooc.servlet.DeleteOneServlet</servlet-class>
</servlet>
<servlet-mapping>
<servlet-name>DeleteOneServlet</servlet-name>
<url-pattern>/DeleteOneServlet.action</url-pattern>
</servlet-mapping>
<servlet>
<servlet-name>DeleteBatchServlet</servlet-name>
<servlet-class>com.imooc.servlet.DeleteBatchServlet</servlet-class>
</servlet>
<servlet-mapping>
<servlet-name>DeleteBatchServlet</servlet-name>
<url-pattern>/DeleteBatchServlet.action</url-pattern>
</servlet-mapping>
</web-app>