47b44ccaa0
<SRS> SRS02 : Employee Management </SRS> <Changes> - Added Payroll getHeaders, serialize and deserialize functions - Stored payrolls in DataStore - Loaded and saved payrolls along with employees - Linked payroll to employees during creation and load - Added employeeId to Payroll - Renamed TAG role to TALENT_ACQUISITION across the project - Added missing TalentExecutive case in Employee deserialization - Added constructor to TalentExecutive for FileManager integration - Renamed ID counters to m_uid for consistency - Updated salary values in ApplicationConfig </Changes> <Review> Smitha Mohan </Review>
63 lines
1.1 KiB
C++
63 lines
1.1 KiB
C++
#include "Booking.h"
|
|
|
|
int Booking::m_uid = 0;
|
|
|
|
const std::string& Booking::getBookingId() const
|
|
{
|
|
return m_id;
|
|
}
|
|
|
|
const util::Timestamp& Booking::getStartTime() const
|
|
{
|
|
return m_startTime;
|
|
}
|
|
|
|
const util::Timestamp& Booking::getEndTime() const
|
|
{
|
|
return m_endTime;
|
|
}
|
|
|
|
const std::string& Booking::getEmployeeId() const
|
|
{
|
|
return m_employeeId;
|
|
}
|
|
|
|
std::shared_ptr<Team> Booking::getTeam() const
|
|
{
|
|
return m_team;
|
|
}
|
|
|
|
void Booking::setBookingId(const std::string& id)
|
|
{
|
|
m_id = id;
|
|
}
|
|
|
|
void Booking::setStartTime(const util::Timestamp& startTime)
|
|
{
|
|
m_startTime = startTime;
|
|
}
|
|
|
|
void Booking::setEndTime(const util::Timestamp& endTime)
|
|
{
|
|
m_endTime = endTime;
|
|
}
|
|
|
|
void Booking::setEmployeeId(const std::string& employeeId)
|
|
{
|
|
m_employeeId = employeeId;
|
|
}
|
|
|
|
void Booking::setTeam(std::shared_ptr<Team> team)
|
|
{
|
|
m_team = team;
|
|
}
|
|
|
|
double Booking::getDurationInHours() const
|
|
{
|
|
return util::Timestamp::getDurationInHours(m_startTime, m_endTime);
|
|
}
|
|
|
|
double Booking::getDurationInMinutes() const
|
|
{
|
|
return util::Timestamp::getDurationInMinutes(m_startTime, m_endTime);
|
|
} |