more search options but no supporting code yet

This commit is contained in:
ganome 2025-01-31 16:39:47 -07:00
parent 97ed88bd3a
commit 582224244d
Signed by untrusted user who does not match committer: Ganome
GPG Key ID: 944DE53336D81B83

View File

@ -36,13 +36,16 @@ int main() {
std::cout << "========================\n"; std::cout << "========================\n";
std::cout << "Welcome to the Universal Hardware database!\n"; std::cout << "Welcome to the Universal Hardware database!\n";
std::cout << "(S)earch for a part by model name\n"; std::cout << "(S)earch for a part by model name\n";
std::cout << "(Q)uit hardware database\n"; std::cout << "(Q)uit hardware database\n->";
std::cin >> quit; std::cin >> quit;
switch(tolower(quit)) { switch(tolower(quit)) {
case 's': case 's':
std::cout << "What would you like to search by?\n"; std::cout << "What would you like to search by?\n";
std::cout << "(M)odel name\n"; std::cout << "(M)odel name\n";
std::cout << "(Q)uit\n"; std::cout << "Manufacture(R)\n";
std::cout << "(Y)ear Released\n";
std::cout << "Main (C)lock\n";
std::cout << "(Q)uit\n->";
std::cin >> searchby; std::cin >> searchby;
switch(tolower(searchby)) { switch(tolower(searchby)) {
case 'm': case 'm':
@ -51,6 +54,15 @@ int main() {
msearchlower = boost::algorithm::to_lower_copy(msearch); msearchlower = boost::algorithm::to_lower_copy(msearch);
searchTable(dbFile, msearchlower); // Replace this string with a variable that is the query grabbed from the user! searchTable(dbFile, msearchlower); // Replace this string with a variable that is the query grabbed from the user!
break; break;
case 'r':
std::cout << "Coming Soon!!!\n";
break;
case 'y':
std::cout << "Coming Soon!!!\n";
break;
case 'c':
std::cout << "Coming Soon!!!\n";
break;
default: default:
break; break;
} }