invitation.setAllowEntry(true);
return invitation;
}
} else if (invitation.getIsValidByTime()) {
OmTimeZone tz = invitation.getOmTimeZone() == null
? omTimeZoneDaoImpl.getOmTimeZone(configurationDao.getConfValue("default.timezone", String.class, "Europe/Berlin"))
: invitation.getOmTimeZone();
Calendar now = Calendar.getInstance(TimeZone.getTimeZone(tz.getIcal()));
Calendar start = Calendar.getInstance(TimeZone.getTimeZone(tz.getIcal()));
start.setTime(invitation.getValidFrom());
Calendar end = Calendar.getInstance(TimeZone.getTimeZone(tz.getIcal()));
end.setTime(invitation.getValidTo());
if (now.after(start) && now.before(end)) {
this.updateInvitation(invitation);
// invitation.setInvitationpass(null);
invitation.setAllowEntry(true);