在线货单管理系统Word文件下载.docx
- 文档编号:20298955
- 上传时间:2023-01-21
- 格式:DOCX
- 页数:17
- 大小:201.25KB
在线货单管理系统Word文件下载.docx
《在线货单管理系统Word文件下载.docx》由会员分享,可在线阅读,更多相关《在线货单管理系统Word文件下载.docx(17页珍藏版)》请在冰豆网上搜索。
secret();
//调用密码函数
//first->
next=NULL;
if(first==NULL)
//{
cout<
<
"
初始化货物信息不成功"
;
//return0;
//}
myread(100);
//读入文件信息
system("
color3"
);
//颜色
wwx1();
//初始化利润统计的数组
cls"
//清屏
loop:
//标签
//wwx2();
//页面
cout<
\t\t===*********在线货物管理系统******===="
endl<
endl;
选择业务:
\n1.添加和管理货物2.销售货物3.查询货物\n4.删除货物5.利润统计6.退出使用\n"
prin();
intchoice=0;
cin>
>
choice;
system("
if(choice==1){ManageStore();
}
if(choice==2){SellStore();
if(choice==3){FindStore();
if(choice==4){delegoods();
if(choice==5){profit();
if(choice==6){wwx();
return0;
gotoloop;
2、Pay
voidpai()//冒泡排序
{intm,j=0;
m=num-1;
while(m>
0)
{m=num-1;
m=m-j;
j++;
Goods*p=first->
next;
Goods*q=p->
Goods*t=newGoods;
{
if(p->
price2>
q->
price2)//比较销售价格
{strcpy(t->
kind,p->
kind);
strcpy(t->
name,p->
name);
t->
price1=p->
price1;
t->
time1=p->
time1;
time2=p->
time2;
t->
count=p->
count;
price2=p->
price2;
strcpy(p->
kind,q->
strcpy(p->
name,q->
p->
price1=q->
p->
time1=q->
time2=q->
p->
count=q->
price2=q->
strcpy(q->
kind,t->
strcpy(q->
name,t->
q->
price1=t->
time1=t->
time2=t->
q->
count=t->
price2=t->
}
p=p->
q=p->
m--;
}if(j==num-1)m=-1;
elsem=1;
//判断是否循环结束
}
return;
3、Myread
voidmyread(inti)//从文件读入
{
intj;
color7"
FILE*FP=NULL;
FP=fopen("
d:
\\input.txt"
"
r"
if(FP==NULL)
{printf("
Cannotopenthefile.\n"
getch();
exit(0);
for(j=0;
j<
i;
j++)
{Goods*q=newGoods;
Goods*iP=newGoods;
shuchu(FP,iP);
if(!
strcmp(q->
name,iP->
name))
continue;
q=iP;
iP->
next=first->
first->
next=iP;
num++;
system("
fclose(FP);
return;
4、Mywrite
voidmywrite1()//刷新
{system("
color4"
Goods*iP=newGoods;
w"
Cannotopenthefile.\n"
exit(0);
iP=first->
for(inti=0;
i<
num;
i++)
{
shuru(FP,iP);
iP=iP->
fclose(FP);
5、EditGoodsinfo
voidEditGoodsInfo(charname[20])//编辑
//wwx2();
Goods*p=NULL;
Goods*q=newGoods;
Goods*t=newGoods;
p=FindOneInfo(name);
intk=0;
选择修改项1·
货物名2·
种类3·
保质期4·
货物件数5.销售价格6·
入店时间7·
返回上级菜单"
prin();
k;
switch(k)
case1:
请输入新的货物名"
cin>
name;
请输入新的货物名"
strcmp(t->
name))//验证是否输入一致
{cout<
修改成功"
getch();
elsecout<
两次输入不一致"
mywrite1();
break;
case2:
请输入新的货物类型"
cin>
kind;
kind))
mywrite1();
case3:
重新输入货物过期时间"
time2.year>
time2.month>
time2.day;
请重新输入货物过期时间"
if(t->
time2.year==q->
time2.year)
if(t->
time2.month==q->
time2.month)
{
if(t->
time2.day==q->
time2.day)
{
cout<
time2.year=t->
time2.year;
p->
time2.month=t->
time2.month;
time2.day=t->
cout<
time2.year<
time2.month<
}
else
输入日期不对"
else
输入月份不对"
else
cout<
输入年份不对"
mywrite1();
case6:
入店时间"
time1.year>
time1.month>
time1.day;
请重新输入货物入店时间"
time1.year==q->
time1.year)
{if((t->
time1.month==q->
time1.month))
{if((t->
time1.day==q->
time1.day))
{cout<
time1.year=t->
time1.year;
time1.month=t->
time1.month;
time1.day=t->
case4:
输入货物数量"
if(t->
count==q->
count)
mywrite1();
case5:
输入销售价格"
price2==q->
price2)
case7:
return;
default:
输入有错"
;
gotoloop;
五、测试数据及其结果分析
1、登陆界面
2、登陆后主菜单
3、卖家录入商品信息
4、销售商品信息
5、查看商品信息
6、修改商品信息
7、利润统计
8、退出系统
六、调试过程中的问题
七、参考文献和查阅的资料
在线订单管理系统>
八、程序设计总结
经过两周的课程设计实验,对编程有了更深刻的了解,在程序编译过程中,通过同伴不断地讨论、实验,最终才能成功的编译出正确的程序,让我了解到团队合作的重要性。
在此,感谢团队伙伴们在远方给予的帮助以及老师的体谅。
谢谢老师在本次实验中对本人的友好帮助。
- 配套讲稿:
如PPT文件的首页显示word图标,表示该PPT已包含配套word讲稿。双击word图标可打开word文档。
- 特殊限制:
部分文档作品中含有的国旗、国徽等图片,仅作为作品整体效果示例展示,禁止商用。设计者仅对作品中独创性部分享有著作权。
- 关 键 词:
- 在线 货单 管理 系统