基于协同过滤算法的民宿客栈订房系统
技術(shù)棧:SSM+協(xié)同過濾算法推薦+MYSQL+TOMCAT+JSP?? 私信
?協(xié)同過濾算法實(shí)現(xiàn)過程
public String execute() throws Exception {//遍歷所有客房信息
????????????? String result="input";
????????????? roomList=roomService.fetchRoomList();
????????????? if (!roomList.isEmpty()) {
???????????????????? result="success";
????????????? }
????????????? return result;
?????? }
public String execute() throws Exception {//根據(jù)選擇日期遍歷客房信息
???????????????????? String result="input";
???????????????????? HttpServletRequest request=ServletActionContext.getRequest();
???????????????????? String intime=request.getParameter("in_date");
???????????????????? String outtime=request.getParameter("out_date");
???????????????????? String room_type=request.getParameter("room_type");
????????????? roomList=roomService.fetchListByTime(intime,outtime,room_type);
???????????????????? if (roomList!=null) {
??????????????????????????? result="success";
??????????????????????????? request.setAttribute("in_date", intime);
??????????????????????????? request.setAttribute("out_date", outtime);
???????????????????? }
???????????????????? return result;
????????????? }
總結(jié)
以上是生活随笔為你收集整理的基于协同过滤算法的民宿客栈订房系统的全部內(nèi)容,希望文章能夠幫你解決所遇到的問題。
- 上一篇: php上传flv,使用PHP上传.WMV
- 下一篇: 奇迹服务器修改玛雅爆率,奇迹经验自动获取