Project on Canteen Management


//CANTEEN MANAGEMENT SOFTWARE
#include<iostream.h>
#include<conio.h>
#include<string.h>
#include<stdio.h>
#include<process.h>
#include<iomanip.h>
#include<dos.h>
#include<graphics.h>

void dev()
{
clrscr();
for(int x=50;x>=20;x–)
{
textcolor(YELLOW+LIGHTGRAY);
delay(160);
gotoxy(x,12);
cputs(”  P R O J E C T   “);
gotoxy(x,14);
cputs(”  D E V E L O P E D  B Y  :  “);
gotoxy(x,16);
cputs(“w.w.w computernotes.in  #”);

}
gotoxy(x,24);
cputs(“PRESS ANY KEY TO CONTINUE”);
getch();
}
void main()
{
clrscr();
dev();
int gdriver=DETECT,gmode,errorcode;
initgraph(&gdriver,&gmode,”c:\\tc\\bgi”);
errorcode=graphresult();
if(errorcode!=grOk)
{
cout<<grapherrormsg(errorcode)<<“\n”;
getch();
}
settextstyle(1,0,3);
outtextxy(75,1,” W E L C O M E  “);
outtextxy(275,150,”T O     “);
outtextxy(5,300,” C A N T E E N    M A N A G E M E N T   S O F T W A R E “);
outtextxy(9,400,”Press any key to continue “);
getch();
cleardevice();

clrscr();
unsigned int sum,add,ch,i,j,e,f,g,h,k,l,w,x,y,z;
unsigned int bir=15,per=40,der=110,mur=8,par=110,cor=90,twr=1199, lur=17,tir=107,
rer=1499;
int qubis=1000,abis=0,qupep=1000,apep=0,quden=110,aden=0,qumun=1000,amun=0,quperk=500,aperk=0,qucoc=400,acoc=0,qutit=100,atit=0,qulux=1000,alux=0,qutid=1000,atid=0,quree=300,aree=0;
unsigned int m=0,n=0,o=0,p=0,q=0,r=0,s=0,t=0,u=0,v=0;
char name[50],rank[10],pur,c[20],a[15],b[15],ok,addr[40];
clrscr();
main:;
cout<<“\n\n\n\t\t\t     APTECH CANTEEN MANAGEMENT”;
cout<<“\n\n\nCONSUMER INFORMATION”;
cout<<“\n\n\n\n NAME:”;
gets(name);
cout<<“\n\n ADDRESS:”;
gets(addr);
cout<<“\n RANK:”;
gets(rank);
cout<<“\n SERVICE NO.:”;
cin>>a;
cout<<“\n SMART CARD NO.:”;
cin>>b;
cout<<“\n PHONE NO.:”;
cin>>c;
cout<<“\n ENTER BILL NO.:”;
cin>>i;
again:;
clrscr();
cout<<“\n\n 1.MENU & PURCHASE”;
cout<<“\n\n 2.DETAILS”;
cout<<“\n\n 3.NEW CUSTOMER”;
cout<<“\n\n 4.QUANTITY AVAILABLE”;
cout<<“\n\n 5.EXIT”;
cout<<“\n\n ENTER YOUR CHOICE in(1/2/3/4/5):”;
cin>>ch;
clrscr();
switch(ch)
{
case 1:
cout<<“\nITEMS\t\t\t\t\t\t\t      RATE(RS)”;
cout<<“\n\nBISCUTE\t\t\t\t\t\t\t\t10  “;
cout<<“\n\nPEPSODENT\t\t\t\t\t\t\t40”;
cout<<“\n\nDENIM POWDER\t\t\t\t\t\t\t130   “;
cout<<“\n\nDAIRY MILK\t\t\t\t\t\t\t\t10  “;
cout<<“\n\nPARK AVENUE PERFUME\t\t\t\t\t\t130   “;
cout<<“\n\nCOCONUT HAIR OIL\t\t\t\t\t\t100  “;
cout<<“\n\nTITAN WATCH\t\t\t\t\t\t\t1299   “;
cout<<“\n\nREXSONA SOAP\t\t\t\t\t\t\t20   “;
cout<<“\n\nTIDE SURF\t\t\t\t\t\t\t\t140   “;
cout<<“\n\nREEBOK SHOES\t\t\t\t\t\t\t1599   “;
start:
cout<<“\n\nDO YOU WANT TO PURCHASE(Y/N):\n”;
cin>>pur;
if(pur==’Y’||pur==’y’)
{switch(pur)
case 1:
clrscr();
cout<<“\n\n\n\t\t\t\tPURCHASE LIST”;
bisc:;
cout<<“\nBISCUTE(MAX 30): “;
cin>>m;

if(m>30)
{
cout<<“Enter Quantity Smaller than 30”;
getch();
goto bisc;
}
else
abis=qubis-m;
peps:;
cout<<“\nPEPSODENT(MAX 2): “;
cin>>n;
if(n>2)
{
cout<<“Enter Quantity Smaller than 2”;
getch();
goto peps;
}
else
apep=qupep-n;
deni:;
cout<<“\nDENIM POWDER(MAX 2): “;
cin>>o;
if(o>2)
{
cout<<“Enter Quantity Smaller then 2”;
getch();
goto deni;
}
else
aden=quden-o;
dair:;
cout<<“\nDAIRY MILK(MAX 50): “;
cin>>p;

if(p>50)
{
cout<<“Enter Quantity Smaller then 50”;
getch();
goto dair;
}
else
amun=qumun-p;
park:;
cout<<“\nPARK AVENUE PERFUME(MAX 2): “;
cin>>q;

if(q>2)
{
cout<<“Enter Quantity Smaller then 2”;
getch();
goto park;
}
else
aperk=quperk-q;
cocon:;
cout<<“\nCOCONUT HAIR OIL(MAX 2): “;
cin>>r;

if(r>2)
{
cout<<“Enter Quantity Smaller then 2”;
getch();
goto cocon;
}
else
acoc=qucoc-r;
tit:;
cout<<“\nTITAN WATCH(MAX 2): “;
cin>>s;

if(s>2)
{
cout<<“Enter Quantity Smaller then 2”;
getch();

goto tit;
}
else
atit=qutit-s;
rex:;
cout<<“\nREXSONA SOAP(MAX 10): “;
cin>>t;

if(t>10)
{
cout<<“Enter Quantity Smaller then 10”;
getch();
goto rex;
}
else
alux=qulux-t;
tide:;
cout<<“\nTIDE SURF(MAX 2): “;
cin>>u;

if(u>2)
{
cout<<“Enter Quantity Smaller then 2”;
getch();
goto tide;
}
else
atid=qutid-u;
reb:;
cout<<“\nREEBOK SHOES(MAX 4): “;
cin>>v;

if(v>4)
{
cout<<“Enter Quantity Smaller then 4”;
getch();
goto reb;
}
else
aree=quree-v;
cout<<“\n”;
clrscr();
cout<<“\n\n\n\n\n\n\t\t\t\APTECH CANTEEN\n”;
cout<<“\n\n\t\t\t\t  CASH MEMO\n”;
cout<<“\n\nBILL NO.:”<<i;
cout<<“\n\nNAME:”;
cout<<name;
cout<<“\n\n Address:”<<addr;
cout<<“\n\nRANK:”<<rank;
cout<<“\n\nSERVICE NO.:”<<a;
cout<<“\n\nSMART CARD NO.:”<<b;
cout<<“\n\nPHONE NO.:”<<c;
cout<<“\n\n\n\n\n”;
cout<<“===============================================================================”;
cout<<“\nITEMS”            <<setw(40)<<“QUANTITY”<<setw(35)<<“PRICE(Rs.)”;
cout<<“===============================================================================”;
if(m>0)
cout<<“\n\nBISCUTE”        <<setw(38)<<m<<setw(28)<<“Rs.”<<m*bir;
if(n>0)
cout<<“\n\nPEPSODENT”        <<setw(36)<<n<<setw(28)<<“Rs.”<<n*per;
if(o>0)
cout<<“\n\nDENIM POWDER”     <<setw(33)<<o<<setw(28)<<“Rs.”<<o*der;
if(p>0)
cout<<“\n\nDAIRY MILK”            <<setw(40)<<p<<setw(28)<<“Rs.”<<p*mur;
if(q>0)
cout<<“\n\nPARK AVENUE PERFUME”<<setw(26)<<q<<setw(28)<<“Rs.”<<q*par;
if(r>0)
cout<<“\n\nCOCONUT HAIR OIL” <<setw(29)<<r<<setw(28)<<“Rs.”<<r*cor;
if(s>0)
cout<<“\n\nTITAN WATCH”      <<setw(34)<<s<<setw(28)<<“Rs.”<<s*twr;
if(t>0)
cout<<“\n\nREXSONA SOAP”         <<setw(37)<<t<<setw(28)<<“Rs.”<<t*lur;
if(u>0)
cout<<“\n\nTIDE SURF”             <<setw(41)<<u<<setw(28)<<“Rs.”<<u*tir;
if(v>0)
cout<<“\n\nREEBOK SHOES”     <<setw(33)<<v<<setw(28)<<“Rs.”<<v*rer;
e=m*bir;
f=n*per;
g=o*der;

h=p*mur;
k=q*par;
l=r*cor;
w=s*twr;
x=t*lur;
y=u*tir;
z=v*rer;
sum=e+f+g+h+k+l+w+x+y+z;
add=m+n+o+p+q+r+s+t+u+v;
cout<<“\n===============================================================================”;
cout<<“\nTOTAL:”<<setw(40)<<add<<setw(27)<<“Rs.”<<sum;
cout<<“\n\nTHANK YOU .\t\t\t     VISIT US AGAIN\n”;
getch();
clrscr();
goto again;
}
else
{goto again;

}

case 2:
cout<<“\n\n\n\n\n\t\t\t\tCANTEEN DETAILS”;
cout<<“\n\n#TIMING:\n\n 10 AM TO 02 PM \n 04 PM TO 06 PM”;
cout<<“\n\n#CANTEEN WILL CLOSED ON SUNDAY”;
cout<<“\n\n#GOODS ONCE SOLD WILL NOT BE EXCHANGED/REPLACED”;
cout<<“\n\n#TAKE YOUR SMART CARD WITH YOU”;
cout<<“\n\n#COLLECT YOUR SMART CARD & BILL AFTER PAYMENT”;
cout<<“\n\n#DO NOT BREAK ANY CANTEEN ITEMS”;
cout<<“\n\n\n\n*******THANKYOU********”;
getch();
clrscr();
goto again;
case 3:
goto main;
case 4:
if(m>0||n>0||o>0||p>0||q>0||r>0||s>0||t>0||u>0||v>0)
{cout<<“\n\t\t\tItems Avaliable in Canteen.\n\n\n”;
cout<<“===============================================================================”;
cout<<“\nITEMS”            <<setw(40)<<“QUANTITY”;
cout<<“\n===============================================================================”;
cout<<“\n\n\nBISCUTE”        <<setw(38)<<abis;
cout<<“\n\n\nPEPSODENT”        <<setw(36)<<apep;
cout<<“\n\n\nDENIM POWDER”     <<setw(33)<<aden;
cout<<“\n\n\nDAIRY MILK”            <<setw(40)<<amun;
cout<<“\n\n\nPARK AVENUE PERFUME”<<setw(26)<<aperk;
cout<<“\n\n\nCOCONUT HAIR OIL” <<setw(29)<<acoc;
cout<<“\n\n\nTITAN WATCH”      <<setw(34)<<atit;
cout<<“\n\n\nREXSONA SOAP”         <<setw(37)<<alux;
cout<<“\n\n\nTIDE SURF”             <<setw(41)<<atid;
cout<<“\n\n\nREEBOK SHOES”     <<setw(33)<<aree;
cout<<“\n*******************************************************************************”;
getch();
goto again;
}
else
{{cout<<“\n\t\t\tItems Avaliable in Canteen.\n\n\n”;
cout<<“===============================================================================”;
cout<<“\nITEMS”            <<setw(40)<<“QUANTITY”;
cout<<“\n===============================================================================”;
cout<<“\n\n\nBISCUTE”        <<setw(38)<<qubis;
cout<<“\n\n\nPEPSODENT”        <<setw(36)<<qupep;
cout<<“\n\n\nDENIM POWDER”     <<setw(33)<<quden;
cout<<“\n\n\nDAIRY MILK”            <<setw(40)<<qumun;
cout<<“\n\n\nPARK AVENUE PERFUME”<<setw(26)<<quperk;
cout<<“\n\n\nCOCONUT HAIR OIL” <<setw(29)<<qucoc;
cout<<“\n\n\nTITAN WATCH”      <<setw(34)<<qutit;
cout<<“\n\n\nREXSONA SOAP”         <<setw(37)<<qulux;
cout<<“\n\n\nTIDE SURF”             <<setw(41)<<qutid;
cout<<“\n\n\nREEBOK SHOES”     <<setw(33)<<quree;
cout<<“\n\n*******************************************************************************”;
getch();
goto again;
}
case 5:
cout<<“\n\n\n\n\n\n\n\n\n\t\t\t\t   THANKS”;
cout<<“press enter key for exit”;
exit(0);
getch();
default:
cout<<“Your choice is wrong”;
getch();
goto again;
}}}

Comments are closed.