# 1.项目简介
设计一个自助点餐系统,方便顾客自己点餐,并提供对餐厅销售情况的统计和管理功能。
## 1.1业务流程图
![](https://www.writebug.com/myres/static/uploads/2021/10/27/21c4c4f3d3ef9ce00fc6d69b5cd50315.writebug)
图一:管理员界面操作流程图
![](https://www.writebug.com/myres/static/uploads/2021/10/27/cc8b57fcb0e44bf5265b04f00e12fad0.writebug)
图二:顾客点菜界面
系统功能结构图
![](https://www.writebug.com/myres/static/uploads/2021/10/27/efdd335ef1978fdabef7b64033976927.writebug)
## 1.2类的设计
![](https://www.writebug.com/myres/static/uploads/2021/10/27/444043160bbddca47162955ca8573166.writebug)
# 2.程序代码与说明
## 2.1SystemMap.h
```c++
#
pragma once# ifndef SYSTEMMAP# define SYSTEMMAP# include < bits / stdc++.h > using namespace std;
class SystemMap
{
private: string frame;
public: SystemMap();
void showOutsideSystemMap(); // 外卖就餐页面
void showInsideSystemMap(); // 店内就餐页面
int showSystemMap(); //顾客选择系统页面
int showChoiceMap(); //系统的功能选择界面
int showRegMap();
int showClientChoiceMap();
int showQueryMap();
int showMenuChoice();
int showChangeMenuMap();
int showCilentOrderMessage();
int adminSystemMap();
int showOrderChangeMap();
int showPastSales();
};#
endif // !SYSTEMMAP
SystemMap.cpp# include "SystemMap.h"
SystemMap::SystemMap()
{
frame = "#";
}
int SystemMap::showSystemMap()
{
for(int i = 0; i < 60; i++) cout << frame;
cout << endl;
for(int i = 0; i < 60; i++)
{
if(i == 0 || i == 59) cout << frame;
else cout << " ";
}
cout << endl;
cout << "#\t\t\t欢迎光临本店";
for(int i = 0; i < 23; i++) cout << " ";
cout << "#\n";
for(int i = 0; i < 60; i++)
{
if(i == 0 || i == 59) cout << frame;
else cout << " ";
}
cout << endl;
cout << "#\t\t 请问您需要什么服务\t\t";
for(int i = 0; i < 11; i++) cout << " ";
cout << "#\n";
cout << "#\t\t 1:在店就餐";
for(int i = 0; i < 31; i++) cout << " ";
cout << "#\n";
cout << "#\t\t 2:外卖就餐";
for(int i = 0; i < 31; i++) cout << " ";
cout << "#\n";
for(int i = 0; i < 60; i++) cout << frame;
cout << endl;
cout << "\t\t 请问您选择的是:";
int choice;
cin >> choice;
return choice;
}
void SystemMap::showInsideSystemMap()
{
cout << "欢迎您在本店就餐,以下是菜单\n\n";
}
void SystemMap::showOutsideSystemMap()
{
cout << "欢迎您点本店的外卖,以下是菜单\n\n";
}
int SystemMap::showChoiceMap()
{
for(int i = 0; i < 60; i++) cout << frame;
cout << endl;
for(int i = 0; i < 60; i++)
{
if(i == 0 || i == 59) cout << frame;
else cout << " ";
}
cout << "\n#\t\t 欢迎来到榆榆餐厅";
for(int i = 0; i < 21; i++) cout << " ";
cout << "#\n";
cout << "#\t\t\t店长: 陈榆";
for(int i = 0; i < 23; i++) cout << " ";
cout << "#\n";
for(int i = 0; i < 60; i++)
{
if(i == 0 || i == 59) cout << frame;
else cout << " ";
}
cout << endl;
for(int i = 0; i < 60; i++) cout << frame;
cout << endl;
cout << "\t\t------------------------" << endl;
cout << "\t\t| 1:顾客服务 |" << endl;
cout << "\t\t| 2:管理员系统 |" << endl;
cout << "\t\t| 3:退出系统 |" << endl;
cout << "\t\t------------------------" << endl;
cout << "\t\t您的选择是:";
int choice;
cin >> choice;
return choice;
}
int SystemMap::adminSystemMap()
{
cout << "\t\t------------------------" << endl;
cout << "\t\t| 1:食物管理 |" << endl;
cout << "\t\t| 2:今日反馈 |" << endl;
cout << "\t\t| 3:订单管理 |" << endl;
cout << "\t\t| 4:历史销售情况 |" << endl;
cout << "\t\t| 5:退出 |" << endl;
cout << "\t\t------------------------" << endl;
int choice;
cin >> choice;
return choice;
}
int SystemMap::showRegMap()
{
cout << "\t\t------------------------" << endl;
cout << "\t\t| 1:新顾客点餐 |" << endl;
cout << "\t\t| 2:查询订单 |" << endl;
cout << "\t\t------------------------" << endl;
int choice;
cout << "\t\t您的选择是:";
cin >> choice;
return choice;
}
int SystemMap::showClientChoiceMap()
{
cout << "\t\t------------------------" << endl;
cout << "\t\t| 1:点菜 |" << endl;
cout << "\t\t| 2:修改订单 |" << endl;
cout << "\t\t| 3:提交订单 |" << endl;
cout << "\t\t------------------------" << endl;
int choice;
cout << "\t\t您的选择是:";
cin >> choice;
return choice;
}
int SystemMap::showQueryMap()
{
cout << "\t\t------------------------" << endl;
cout << "\t\t| 1:查询订单 |" << endl;
cout << "\t\t| 2:退出 |" << endl;
cout << "\t\t------------------------" << endl;
int choice;
cout << "\t\t您的选择是:";
cin >> choice;
return choice;
}
int SystemMap::showChangeMenuMap()
{
cout << "\t\t------------------------" << endl;
cout << "\t\t| 1:添加食物 |" << endl;
cout << "\t\t| 2:修改食物价格 |" << endl;
cout << "\t\t| 3:修改食物折扣 |" << endl;
cout << "\t\t| 4:删除食物 |" << endl;
cout << "\t\t| 5:退出食物管理系统 |" << endl;
cout << "\t\t------------------------" << endl;
cout << "\t\t您的选择是:";
int choice;
cin >> choice;
return choice;
}
int SystemMap::showMenuChoice()
{
cout << "\t\t------------------------" << endl;
cout << "\t\t| 1:原菜单 |" << endl;
cout << "\t\t| 2:新菜单 |" << endl;
cout << "\t\t------------------------" << endl;
int choice;
cout << "\t\t您的选择是:";
cin >> choice;
return choice;
}
int SystemMap::showCilentOrderMessage()
{
cout << "\t\t------------------------" << endl;
cout << "\t\t| 1:修改数量 |" << endl;
cout << "\t\t| 2:删除食物 |" << endl;
cout << "\t\t| 3:退出修改 |" << endl;
cout << "\t\t------------------------" << endl;
int choice;
cout << "\t\t您的选择是:";
cin >> choice;
return choice;
}
int SystemMap::showOrderChangeMap()
{
cout << "\t\t------------------------" << endl;
cout << "\t\t| 1:查找订单 |" << endl;
cout << "\t\t| 2:修改订单 |" << endl;
cout << "\t\t| 3:删除订单 |" << endl;
cout << "\t\t| 4:退出修改 |" << endl;
cout << "\t\t------------------------" << endl;
int choice;
cout << "\t\t您的选择是:";
cin >> choice;
return choice;
}
int SystemMap::showPastSales()
{
cout << "\t\t------------------------" << endl;
cout << "\t\t| 1:查找订单 |" << endl;
cout << "\t\t| 2:修改订单 |" << endl;
cout << "\t\t| 3:删除订单 |" << endl;
cout << "\t\t| 4:退出修改 |" << endl;
cout << "\t\t------------------------" << endl;
int choice;
cout << "\t\t您的选择是:";
cin >> choice;
return choice;
}
```
## 2.2AdminManager.h
```c++
#
pragma once# ifndef ADMINMANAGER# define ADMINMANAGER# include < bits / stdc++.h > #include "Admin.h"
using namespace std;
class AdminManager
{
public: AdminManager();
int adminNum;
Admin admin[100];
void addAdmin(string, string);
int getAdminNum();
int checkPassword(string, string);
};#
endif // !ADMINMANAGER
AdminManager.cpp# include "AdminManager.h"
AdminManager::AdminManager()
{
adminNum = 0;
}
void AdminManager::addAdmin(string ID, string p)
{
admin[adminNum].setId(ID);
admin[adminNum].setPassword(p);
admin[adminNum
没有合适的资源?快使用搜索试试~ 我知道了~
基于C++实现的(控制台)自助点餐系统【100012931】
共88个文件
ipch:10个
xml:10个
sarif:9个
1.该资源内容由用户上传,如若侵权请联系客服进行举报
2.虚拟产品一经售出概不退款(资源遇到问题,请及时私信上传者)
2.虚拟产品一经售出概不退款(资源遇到问题,请及时私信上传者)
版权申诉
5星 · 超过95%的资源 1 下载量 157 浏览量
2023-07-14
10:24:57
上传
评论
收藏 129.79MB ZIP 举报
温馨提示
C++实现自助点餐系统(大一面向对象课程设计) 设计一个自助点餐系统,方便顾客自己点餐,并提供对餐厅销售情况的统计和管理功能。
资源推荐
资源详情
资源评论
收起资源包目录
100012931-基于C++实现的(控制台)自助点餐系统.zip (88个子文件)
zizhudiancan
chenyu.vcxproj.filters 2KB
CoustManager.cpp 364B
AdminManager.cpp 658B
LICENSE 1KB
Food.cpp 747B
Menu.cpp 2KB
CoustManager.h 314B
SystemMap.cpp 5KB
.vs
ProjectSettings.json 42B
chenyu
v16
Browse.VC.db 41.89MB
.suo 49KB
ipch
AutoPCH
c4c429e748cf7190
MAIN.ipch 60.31MB
1ae22ef4bd5a530f
MENU.ipch 60.25MB
2d2fc5078dff5f6f
MAIN.ipch 60.31MB
f0902eefde022dcb
ADMIN.ipch 60.25MB
7e8ea0af8adace18
ADMINMANAGER.ipch 60.25MB
e75d2cd3d1043266
FOOD.ipch 60.25MB
643c9226f5ea995d
SYSTEMMAP.ipch 60.25MB
2669f67a686f64d1
COUSTMANAGER.ipch 60.25MB
f453eb456e5b2ebd
CLIENT.ipch 60.25MB
a16ae66def0aabe
CLIENTMANAGER.ipch 60.31MB
slnx.sqlite 292KB
VSWorkspaceState.json 107B
Admin.h 307B
main.cpp 15KB
Clientmanager.cpp 1KB
Clientmanager.h 331B
SystemMap.h 583B
Admin.cpp 304B
Food.h 539B
Client.cpp 4KB
AdminManager.h 315B
Client.h 817B
chenyu.vcxproj.user 165B
Menu.h 448B
Debug
main.nativecodeanalysis.sarif 158KB
chenyu.vcxproj.FileListAbsolute.txt 70B
main.nativecodeanalysis.xml 58B
chenyu.ilk 4.6MB
Clientmanager.nativecodeanalysis.sarif 320KB
AdminManager.nativecodeanalysis.xml 58B
vc142.idb 355KB
CoustManager.obj 47KB
Menu.obj 289KB
vc142.pdb 740KB
chenyu.Build.CppClean.log 823B
Client.nativecodeanalysis.xml 3KB
SystemMap.obj 206KB
SystemMap.nativecodeanalysis.sarif 54KB
SystemMap.nativecodeanalysis.xml 58B
vc.nativecodeanalysis.all.xml 6KB
Food.nativecodeanalysis.xml 1KB
chenyu.pdb 1.89MB
chenyu.log 69B
chenyu.exe 191KB
Client.nativecodeanalysis.sarif 367KB
CoustManager.nativecodeanalysis.xml 58B
Admin.nativecodeanalysis.xml 586B
chenyu.tlog
CL.write.1.tlog 7KB
chenyu.lastbuildstate 147B
CL.command.1.tlog 6KB
link.command.1.tlog 2KB
link.read.1.tlog 4KB
link.write.1.tlog 882B
CL.read.1.tlog 150KB
Food.nativecodeanalysis.sarif 210KB
Food.obj 197KB
Clientmanager.nativecodeanalysis.xml 4KB
AdminManager.obj 168KB
Clientmanager.obj 177KB
Admin.nativecodeanalysis.sarif 467KB
main.obj 434KB
Menu.nativecodeanalysis.xml 58B
Admin.obj 165KB
CoustManager.nativecodeanalysis.sarif 260KB
AdminManager.nativecodeanalysis.sarif 415KB
Client.obj 234KB
Menu.nativecodeanalysis.sarif 106KB
README.md 52KB
chenyu.vcxproj 7KB
chenyu.sln 1KB
Data
2020-6-1.txt 174B
food.txt 86B
2020-1-1order.txt 110B
2020-6-1order.txt 365B
2020-1-1.txt 170B
admin.txt 66B
自助点餐系统实验报告.doc 2.35MB
共 88 条
- 1
资源评论
- 2301_810859082024-04-02资源很赞,希望多一些这类资源。
神仙别闹
- 粉丝: 2704
- 资源: 7645
上传资源 快速赚钱
- 我的内容管理 展开
- 我的资源 快来上传第一个资源
- 我的收益 登录查看自己的收益
- 我的积分 登录查看自己的积分
- 我的C币 登录后查看C币余额
- 我的收藏
- 我的下载
- 下载帮助
安全验证
文档复制为VIP权益,开通VIP直接复制
信息提交成功