From 33157758c34a8a1e5ae648266384ae3adfefc675 Mon Sep 17 00:00:00 2001 From: Rajbir Singh Date: Wed, 23 Oct 2024 14:52:58 +0200 Subject: [PATCH] PMT-40 Mapper --- src/main/java/de/hmmh/pmt/util/Mapper.java | 13 ++++++++++++- 1 file changed, 12 insertions(+), 1 deletion(-) diff --git a/src/main/java/de/hmmh/pmt/util/Mapper.java b/src/main/java/de/hmmh/pmt/util/Mapper.java index 7485c43..56098ae 100644 --- a/src/main/java/de/hmmh/pmt/util/Mapper.java +++ b/src/main/java/de/hmmh/pmt/util/Mapper.java @@ -72,5 +72,16 @@ public class Mapper { project.setPlannedEnd(dto.getPlannedEnd()); return project; } - + public de.hmmh.pmt.dtos.Project mapProject(Project project){ + de.hmmh.pmt.dtos.Project dto = new de.hmmh.pmt.dtos.Project(); + dto.setId(project.getId()); + dto.setName(project.getName()); + dto.setGoal(project.getGoal()); + dto.setCustomerId(project.getCustomerId()); + dto.setAdministratorId(project.getAdministratorId()); + dto.setStart(project.getStart()); + dto.setPlannedEnd(project.getPlannedEnd()); + dto.setRealEnd(project.getRealEnd()); + return dto; + } }