@Override public Departement update(Departement entity) { Departement dept = iDepartementDao.findOne(entity.getId()); dept.setCode(entity.getCode()); dept.setIntitule(entity.getIntitule()); dept.setAgence(iAgenceDao.findOne(entity.getAgence().getId())); return iDepartementDao.save(dept); }
@Override public Departement findOne(long id) { return iDepartementDao.findOne(id); }