• 大小: 23.51MB
    文件类型: .zip
    金币: 1
    下载: 0 次
    发布日期: 2023-07-15
  • 语言: 其他
  • 标签: SSM  javaweb  毕业设计  

资源简介

本网站是基于SSM框架的房屋租赁网站,这是房东与房客的完整交互,并有上源图片,展示图片,具体页面效果请复制网址查看https://blog.csdn.net/weixin_38560145/article/details/90720685

资源截图

代码片段和文件信息

package controller;

import java.util.List;

import javax.servlet.http.HttpServletRequest;
import javax.servlet.http.HttpSession;

import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Controller;
import org.springframework.ui.Model;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RequestParam;

import com.github.pagehelper.PageHelper;
import com.github.pagehelper.PageInfo;

import Pojo.Apply;
import Pojo.Houselist;
import Pojo.User;
import Pojo.Userlist;
import Pojo.Zulist;
import service.ApplyService;
import service.HouselistService;
import service.UserlistService;

@Controller
public class ApplyController {
@Autowired
private UserlistService userlistService;
@Autowired
private HouselistService houselistService;
@Autowired
private ApplyService applyService;
//申请看房
@RequestMapping(“/applycheckuserlist“)
public String applycheckuserlist(HttpSession httpSessionModel modelInteger id){
User user1= (User) httpSession.getAttribute(“user“);
Integer user_id=user1.getId();
Userlist list=userlistService.findhasuserlist(user_id);
if(list==null){
model.addAttribute(“error“ “applycheck“);
return “redirect:houselist.action“;
}else{
Houselist houselist=houselistService.findid(id);
houselist.setStatus(“已被申请“);
houselistService.updatehousestatus(houselist);
Integer userlist_id=list.getId();
Apply apply=new Apply();
apply.setHouse_id(houselist.getHouseid());
apply.setAddress(houselist.getAddress());
apply.setPrice(houselist.getPrice());
apply.setArea(houselist.getArea());
apply.setStatus(“申请中“);
apply.setUserlist_id(userlist_id);
applyService.insertapply(apply);
model.addAttribute(“error“ “applysuccess“);
return “redirect:houselist.action“;


}

}
//管理员查看申请看房列表
@RequestMapping(“/findapplylist“)
public String findapplylist(Model model@RequestParam(required=falsedefaultValue=“1“) Integer page
            @RequestParam(required=falsedefaultValue=“6“) Integer pageSize) throws Exception{
 PageHelper.startPage(page pageSize);
List applylist=applyService.findapplylist();
PageInfo p=new PageInfo(applylist);
model.addAttribute(“applylist“applylist);
model.addAttribute(“p“ p);
model.addAttribute(“mainPage““applylist.jsp“);
return “admin/main1“;
}

@RequestMapping(“/applychangehousestatus“)
public String applychangehousestatus(HttpSession httpSessionModel modelString house_id)throws Exception{
User user1= (User) httpSession.getAttribute(“user“);
Integer user_id=user1.getId();
Userlist userlist=userlistService.findhasuserlist(user_id);
Houselist houselist=houselistService.findhouseid(house_id);
houselist.setStatus(“已租赁“);
houselistService.updatehousestatus(houselist);
Zulist zulist=new Zulist();
zulist.setHouse_id(house_id);
zulist.set

 属性            大小     日期    时间   名称
----------- ---------  ---------- -----  ----
     目录           0  2019-05-30 16:21  house毕设版\
     目录           0  2019-05-30 16:13  house毕设版\house\
     文件         866  2019-05-20 15:36  house毕设版\house\.classpath
     文件           8  2018-04-09 22:41  house毕设版\house\.gitignore
     目录           0  2019-05-30 16:13  house毕设版\house\.idea\
     目录           0  2019-05-30 16:13  house毕设版\house\.idea\libraries\
     文件         775  2019-04-14 21:00  house毕设版\house\.idea\libraries\Java_EE_6_Java_EE_6.xml
     文件         267  2019-04-14 20:53  house毕设版\house\.idea\misc.xml
     文件         257  2019-04-14 20:53  house毕设版\house\.idea\modules.xml
     文件       14371  2019-04-14 21:00  house毕设版\house\.idea\workspace.xml
     文件         905  2018-07-17 16:19  house毕设版\house\.project
     目录           0  2019-05-30 16:13  house毕设版\house\.settings\
     文件         567  2018-04-09 22:41  house毕设版\house\.settings\.jsdtscope
     文件         172  2018-07-17 15:41  house毕设版\house\.settings\org.eclipse.core.resources.prefs
     文件         670  2018-07-17 15:42  house毕设版\house\.settings\org.eclipse.jdt.core.prefs
     文件         468  2018-07-17 16:21  house毕设版\house\.settings\org.eclipse.wst.common.component
     文件         305  2018-07-17 15:42  house毕设版\house\.settings\org.eclipse.wst.common.project.facet.core.xml
     文件          49  2018-04-09 22:41  house毕设版\house\.settings\org.eclipse.wst.jsdt.ui.superType.container
     文件           6  2018-04-09 22:41  house毕设版\house\.settings\org.eclipse.wst.jsdt.ui.superType.name
     目录           0  2019-05-30 16:13  house毕设版\house\WebContent\
     目录           0  2019-05-30 16:13  house毕设版\house\WebContent\meta-INF\
     文件          39  2018-04-09 22:41  house毕设版\house\WebContent\meta-INF\MANIFEST.MF
     目录           0  2019-05-30 16:13  house毕设版\house\WebContent\WEB-INF\
     目录           0  2019-05-30 16:13  house毕设版\house\WebContent\WEB-INF\jsp\
     目录           0  2019-05-30 16:13  house毕设版\house\WebContent\WEB-INF\jsp\admin\
     文件        8587  2019-05-22 19:03  house毕设版\house\WebContent\WEB-INF\jsp\admin\addhetong.jsp
     文件        6533  2019-05-22 19:09  house毕设版\house\WebContent\WEB-INF\jsp\admin\addhouse.jsp
     文件        4491  2019-05-22 18:44  house毕设版\house\WebContent\WEB-INF\jsp\admin\addpaid.jsp
     文件        3590  2019-05-22 18:43  house毕设版\house\WebContent\WEB-INF\jsp\admin\addschedule.jsp
     文件        3149  2019-05-13 18:49  house毕设版\house\WebContent\WEB-INF\jsp\admin\ahouselist.jsp
     文件        3219  2019-05-23 14:10  house毕设版\house\WebContent\WEB-INF\jsp\admin\applylist.jsp
............此处省略441个文件信息

评论

共有 条评论