1.用户信息
user_id (pk)
phone
password
username
avtory(头像:存放的是路径)
real_name
real_idcard
2.商品(house)
house_id (pk)
user_id(房东的id) 作为用户表的id
title(房子标题)
area(城区) 作为城区表的外键
…
price
index_image_url 查询时方便
order_count 订单量
3.area(城区表)
area_id
area_name
4.house_image
image_id
image_url
house_id 作为house的外键
5.facility
facility_id
facility_name 与house具有多对多的关系
6.中间表:house_facility
id
house_id
facilitity_id
有一个订单就有一个评论信息
7. Order
order_id
user_id
house_id
create_time
start_date
end_date
once 单价
amount 金额
days 入住天数
status 下单状态
comment 评价
rejust_reason拒绝信息
评价和拒绝原因合二为一
通过status进行判断,如果为同意,就为评价,如果为拒绝,就为拒绝信息表