[offers][chore] Add profileId to AnalysisOffer

pull/500/head
Bryann Yeap Kok Keong 2 years ago
parent 7e06e07df4
commit b3eb2f6d6b

@ -87,6 +87,7 @@ const analysisOfferDtoMapper = (
background?.experiences
?.filter((exp) => exp.company != null)
.map((exp) => exp.company?.name ?? '') ?? [],
profileId: offer.profileId,
profileName,
title:
offer.jobType === JobType.FULLTIME
@ -708,20 +709,17 @@ export const dashboardOfferDtoMapper = (
if (offer.offersFullTime.baseSalary) {
dashboardOfferDto.baseSalary = valuationDtoMapper(
offer.offersFullTime.baseSalary
offer.offersFullTime.baseSalary,
);
}
if (offer.offersFullTime.bonus) {
dashboardOfferDto.bonus = valuationDtoMapper(
offer.offersFullTime.bonus
);
dashboardOfferDto.bonus = valuationDtoMapper(offer.offersFullTime.bonus);
}
if (offer.offersFullTime.stocks) {
dashboardOfferDto.stocks = valuationDtoMapper(
offer.offersFullTime.stocks
offer.offersFullTime.stocks,
);
}
} else if (offer.offersIntern) {
@ -736,12 +734,12 @@ export const dashboardOfferDtoMapper = (
export const getOffersResponseMapper = (
data: Array<DashboardOffer>,
paging: Paging,
jobType: JobType
jobType: JobType,
) => {
const getOffersResponse: GetOffersResponse = {
data,
jobType,
paging
paging,
};
return getOffersResponse;
};

@ -181,6 +181,7 @@ export type AnalysisOffer = {
monthYearReceived: Date;
negotiationStrategy: string;
previousCompanies: Array<string>;
profileId: string;
profileName: string;
title: string;
totalYoe: number;

Loading…
Cancel
Save