Map phaseMap = AppConstantImpl.getInstance().getPhaseMap();
Iterator iterator = phaseMap.keySet().iterator();
while(iterator.hasNext()){
Object key = iterator.next();
Phase phase = new Phase();
phase.setName(phaseMap.get(key).toString());
phase.setNumber((Integer)key);
phase.setProject(project);
project.getPhaseItems().add(phase);
}
entityManager.persist(project);
}