OOP Project/library management system.cpp
void Library::staff()
{
	cls();
	cout << "\t\t\t\t\t********** WELCOME STAFF **********\n\n";
	cout << "\t\t\t\t\t>> Choose any option\n\n";
	cout << "\t\t\t\t\t1. View Category of Books\n\n" << "\t\t\t\t\t2. Search for a Book\n\n" << "\t\t\t\t\t3. Modify Booklist\n\n" << "\t\t\t\t\t4. Go to Main Menu\n\n" << "\t\t\t\t\t5. Exit Application\n\n";
	cout << "\t\t\t\t\tEnter choice: ";
	int choice;
	cin >> choice;
	cout << endl << endl;
	switch (choice)
	{
	case 1:
		viewBooks(2);
		break;
	case 2:
		searchBook(2);
		break;
	case 3:
		modifyBooklist();
		break;
	case 4:
		cls();
		mainMenu();
		break;
	case 5:
		exit(0);
	default:
		cout << "\t\t\t\t\tInvalid choice.\n\n";
		cout << "\t\t\t\t\tPress any key to be able to enter a valid choice\n\n";
		(void)_getch();
		cls();
		staff();
	}
}
//function to display options for staff
function to display options for staff
function to display options for staff
void Library::staff()
{
	cls();
	cout << "\t\t\t\t\t********** WELCOME STAFF **********\n\n";
	cout << "\t\t\t\t\t>> Choose any option\n\n";
	cout << "\t\t\t\t\t1. View Category of Books\n\n" << "\t\t\t\t\t2. Search for a Book\n\n" << "\t\t\t\t\t3. Modify Booklist\n\n" << "\t\t\t\t\t4. Go to Main Menu\n\n" << "\t\t\t\t\t5. Exit Application\n\n";
	cout << "\t\t\t\t\tEnter choice: ";
	int choice;
	cin >> choice;
	cout << endl << endl;
	switch (choice)
	{
	case 1:
		viewBooks(2);
		break;
	case 2:
		searchBook(2);
		break;
	case 3:
		modifyBooklist();
		break;
	case 4:
		cls();
		mainMenu();
		break;
	case 5:
		exit(0);
	default:
		cout << "\t\t\t\t\tInvalid choice.\n\n";
		cout << "\t\t\t\t\tPress any key to be able to enter a valid choice\n\n";
		(void)_getch();
		cls();
		staff();
	}
}
void Library :: staff ( ) { cls ( ) ; cout << " \t \t \t \t \t \n \n " ; cout << " \t \t \t \t \t \n \n " ; cout << " \t \t \t \t \t \n \n " << " \t \t \t \t \t \n \n " << " \t \t \t \t \t \n \n " << " \t \t \t \t \t \n \n " << " \t \t \t \t \t \n \n " ; cout << " \t \t \t \t \t " ; int choice ; cin >> choice ; cout << endl << endl ; switch ( choice ) { case 1 : viewBooks ( 2 ) ; break ; case 2 : searchBook ( 2 ) ; break ; case 3 : modifyBooklist ( ) ; break ; case 4 : cls ( ) ; mainMenu ( ) ; break ; case 5 : exit ( 0 ) ; default : cout << " \t \t \t \t \t \n \n " ; cout << " \t \t \t \t \t \n \n " ; ( void ) _getch ( ) ; cls ( ) ; staff ( ) ; } }
function to display options for staff
function to display options for staff