Added CSV header support and persistence for employees

<SRS> SRS02 : Employee Management </SRS>

<Changes>
 - Added header handling in FileManager load by skipping first line during deserialization
 - Added support for writing headers using T::getHeaders() in FileManager save
 - Implemented getHeaders() for Employee and GeneralEmployee models
 - Added saveEmployees functionality in EmployeeManagementService
 - Added persistStates method in ZenvyController
 - Added deserialization failure check with exception handling
 - Minor formatting cleanup in FileIO
</Changes>

<Review>
Smitha Mohan
</Review>
This commit is contained in:
2026-04-10 19:41:08 +05:30
parent eac6fa72df
commit c50700e70c
11 changed files with 64 additions and 3 deletions
@@ -47,6 +47,15 @@ void UserInterface::run()
util::pressEnter();
}
}
try
{
m_controller->persistStates();
}
catch (const std::exception& e)
{
std::cout << "Exception: " << e.what() << std::endl;
return;
}
}
bool UserInterface::handleOperation(int choice)