1.書寫jsp頁面 people.jsp
1.設計顯示格式以及內容顯示
2.設計顯示內容的范圍
2.書寫entity實體類 PeopleFormMap.java
書寫傳入的參數主要包括 要引用的數據庫名 以及主鍵字段 h_event id
3.書寫service層
PeopleService 繼承底層的 BaseService
4.書寫service實現類 PeopleServiceImpl
@peopleservice
5.書寫controller層 PeopleController Controller實現 界面和service實現類的數據交互
@RequestMapping(“/people”)
public class PeopleController extends BaseController{
private PeopleService peopleservice;
@ResponseBody
@RequestMapping("peoplelist")
public String peoplelist(String txtSelect ) throws Exception{
return "success";}
}
6.書寫js頁面
function initPeopleList(){
var url= rootPath + '/people/findByPage.shtml';
書寫想要顯示字段內容
封裝data{
}
}
7.mapping
書寫sql查詢語句
<mapper namespace="RiskForcastMapper">
<select id="" resultType="java.util.HashMap">
select * from .....
</select>