use of com.evolveum.midpoint.repo.sql.data.common.RAccessCertificationCampaign in project midpoint by Evolveum.
the class CertificationCaseHelper method addCertificationCampaignCases.
public void addCertificationCampaignCases(Session session, RObject object, boolean deleteBeforeAdd) {
if (!(object instanceof RAccessCertificationCampaign)) {
return;
}
RAccessCertificationCampaign campaign = (RAccessCertificationCampaign) object;
if (deleteBeforeAdd) {
LOGGER.trace("Deleting existing cases for {}", campaign.getOid());
deleteCertificationCampaignCases(session, campaign.getOid());
}
if (campaign.getCase() != null) {
for (RAccessCertificationCase aCase : campaign.getCase()) {
session.save(aCase);
}
}
}
Aggregations