private void checkIsPersonalTimesheetsTypeOfWorkHours(TypeOfWorkHours type) {
   Configuration configuration = configurationDAO.getConfiguration();
   if (configuration.getPersonalTimesheetsTypeOfWorkHours().getId().equals(type.getId())) {
     throw ValidationException.invalidValueException(
         "Cannot delete the type of work hours. It is configured as type of work hours for personal timesheets.",
         type);
   }
 }
 @Override
 @Transactional(readOnly = true)
 public boolean isDefaultCalendar(BaseCalendar baseCalendar) {
     Configuration configuration = configurationDAO.getConfiguration();
     if (configuration == null) {
         return false;
     }
     BaseCalendar defaultCalendar = configuration.getDefaultCalendar();
     if (defaultCalendar == null) {
         return false;
     }
     if (baseCalendar == null) {
         return false;
     }
     return baseCalendar.getId().equals(
             defaultCalendar
                     .getId());
 }