Page 490 - C++
P. 490

Lab Management
            A project to store record of items procured for use in lab.

            struct item_B
            {
                   int item_no;
                   int quantity;
                   float price;
            };
            struct date
            {
                   int dd,mm,yy;
            };
            class Item
            {
                   int Item_no;
                   char Description[20],Category[30],Type;
                   float Price;
                   int quantity_on_hand,Reorder_qty,Reorder_level;
                   public:
                   void IGetdata();
                   void IDisplaydate();
                   int Return_Itemno{  return Item_no;        }
                   char *Return_Category()      {      return Category;      }
                   int Check_Item()
                   {
                          if(Quantity_on_hand>=Reoder_level)
                                 return 1;
                          else
                                 return 0;
                   }
                   int Check_Item(int q)
                   {
                          if(q<=Reorder_qty)
                                 return 1;
                          else
                                 return 0;
                   }

                   void Update_Item(int q)
                   {
                          Quantity_on_hand+=q;
                   }
            };
            class Supplier
            {
                   int Supplier_no;
                   char Name[20],Address[30],phone[10],Mobile[15],pincode[10];
                   public:
                   void MGetdata();
                   void MDisplaydate();
                   int Return_Supplierno{       return Supplier_no;  }
                   };
   485   486   487   488   489   490   491   492   493   494   495