Giter Club home page Giter Club logo

food's Introduction

项目思维导图连接地址 : 链接:https://gitmind.cn/app/doc/2071528469 密码:1618

项目运行

  • 如果路由跳转出现BUG,应该是写完项目有些默认路由跳转没有更新,直接修改对应路由就好
  • cd backend , 然后运行npm install安装依赖 , nodemon app.js开启后端服务器 , 有可能会有报错 , 提示数据库没有totalprice字段 , 可以自行更新字段(interger类型) ,其他bug暂时没有发现.数据库用的sqlite
  • cd frontend , 然后运行npm install安装依赖 , npm run start运行React app

需求分析

1 : 用户无需登录

2 : 实时同步功能

3 : 厨房实时收到订单(核心功能)

  • 用户侧 :

二维码的地址:

/landing/restaurant/25/desk/8

页面显示的内容

餐厅名称 , 桌号,人数选择 ,开始点餐按钮

  • 点餐页面

/restaurant/25/desk/8?customs = 3

显示菜单,购物车,实时同步

获取菜单

/api/menus?restaurantId=25

websocket :

​ 自己点的菜发往服务器

​ 接受其他人点的菜

​ 服务端要存储当前桌面已经点的所有的菜

下单 :

post /api/placeholder

post   /api/placeholder
{
deskId ,restaurantId
	
}

商户侧

登陆注册,

创建餐厅

订单管理

订单信息

​ 桌面id ,餐厅id,人数,菜品列表,菜品分类

菜品信息

名称,描述,价格,图片url,id,restaurantId,上架状态

菜品管理 :

获取菜品,get /reataurant/3/food

删除菜品,delete restaurant/3/food/5

增加菜品,post /restaurant/3/food

修改菜品(增删改查) put restaurant/3/food/5

桌面管理

桌面信息:

​ 桌面名称,容纳人数,id,restaurant

数据库设计

restaurant

id name password title

foods

id rid name desc price img status categroy status(0n/off)

desks

id rid name capacity

orders

id rid did customs details({id,count,name},{},{}) status(complted)

food's People

Contributors

zhoujingfighting avatar

Watchers

 avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.