RepositoryEntry re = RepositoryManager.getInstance().lookupRepositoryEntryBySoftkey(repositorySoftkey, true);
if (CoordinatorManager.getCoordinator().getLocker().isLocked(re.getOlatResource(), null)){
Translator translator = Util.createPackageTranslator(this.getClass(), ureq.getLocale());
//so this resource is locked, let's find out who locked it
LockResult lockResult = CoordinatorManager.getCoordinator().getLocker().acquireLock(re.getOlatResource(), ureq.getIdentity(), null);
return MessageUIFactory.createInfoMessage(ureq, wControl, translator.translate("status.currently.locked.title"),
translator.translate("status.currently.locked", new String[] {lockResult.getOwner().getName()}));
}else{
ThreadLocalUserActivityLogger.addLoggingResourceInfo(LoggingResourceable.wrap(re, OlatResourceableType.iq));
return new IQDisplayController(moduleConfiguration, secCallback, ureq, wControl, callingResId, callingResDetail);
}