diff --git a/src/main/java/org/olat/core/util/vfs/callbacks/FullAccessWithLazyQuotaCallback.java b/src/main/java/org/olat/core/util/vfs/callbacks/FullAccessWithLazyQuotaCallback.java index 64cb697e66923d5cf52d7681a656415129077526..87612acda81b6f86fcf4a4a46f602d3b6d6d5ae3 100644 --- a/src/main/java/org/olat/core/util/vfs/callbacks/FullAccessWithLazyQuotaCallback.java +++ b/src/main/java/org/olat/core/util/vfs/callbacks/FullAccessWithLazyQuotaCallback.java @@ -19,7 +19,6 @@ */ package org.olat.core.util.vfs.callbacks; -import org.olat.admin.quota.QuotaConstants; import org.olat.core.commons.services.notifications.SubscriptionContext; import org.olat.core.util.vfs.Quota; import org.olat.core.util.vfs.QuotaManager; @@ -33,15 +32,18 @@ import org.olat.core.util.vfs.QuotaManager; public class FullAccessWithLazyQuotaCallback extends FullAccessWithQuotaCallback { private final String folderPath; + private final String defaultQuota; - public FullAccessWithLazyQuotaCallback(String folderPath) { + public FullAccessWithLazyQuotaCallback(String folderPath, String defaultQuota) { super(null); this.folderPath = folderPath; + this.defaultQuota = defaultQuota; } - public FullAccessWithLazyQuotaCallback(String folderPath, SubscriptionContext subscriptionContext) { + public FullAccessWithLazyQuotaCallback(String folderPath, String defaultQuota, SubscriptionContext subscriptionContext) { super(null, subscriptionContext); this.folderPath = folderPath; + this.defaultQuota = defaultQuota; } @Override @@ -50,7 +52,7 @@ public class FullAccessWithLazyQuotaCallback extends FullAccessWithQuotaCallback QuotaManager qm = QuotaManager.getInstance(); Quota q = qm.getCustomQuota(folderPath); if (q == null) { - Quota defQuota = qm.getDefaultQuota(QuotaConstants.IDENTIFIER_DEFAULT_GROUPS); + Quota defQuota = qm.getDefaultQuota(defaultQuota); q = QuotaManager.getInstance().createQuota(folderPath, defQuota.getQuotaKB(), defQuota.getUlLimitKB()); } super.setQuota(q); diff --git a/src/main/java/org/olat/course/PersistingCourseImpl.java b/src/main/java/org/olat/course/PersistingCourseImpl.java index 01b34af8ec32d5a92a4156dc4f5225a54ae597c6..8b3374444af9627bf6fdc499ff21b100a450ac48 100644 --- a/src/main/java/org/olat/course/PersistingCourseImpl.java +++ b/src/main/java/org/olat/course/PersistingCourseImpl.java @@ -28,6 +28,7 @@ package org.olat.course; import java.io.File; import java.io.Serializable; +import org.olat.admin.quota.QuotaConstants; import org.olat.core.CoreSpringFactory; import org.olat.core.commons.modules.bc.vfs.OlatRootFolderImpl; import org.olat.core.commons.persistence.DBFactory; @@ -247,7 +248,7 @@ public class PersistingCourseImpl implements ICourse, OLATResourceable, Serializ "could not create course's coursefolder path:" + fCourseFolder.getAbsolutePath(), null); } - FullAccessWithQuotaCallback secCallback = new FullAccessWithLazyQuotaCallback(isolatedCourseFolder.getRelPath()); + FullAccessWithQuotaCallback secCallback = new FullAccessWithLazyQuotaCallback(isolatedCourseFolder.getRelPath(), QuotaConstants.IDENTIFIER_DEFAULT_COURSE); isolatedCourseFolder.setLocalSecurityCallback(secCallback); return isolatedCourseFolder; } diff --git a/src/main/java/org/olat/group/GroupfoldersWebDAVMergeSource.java b/src/main/java/org/olat/group/GroupfoldersWebDAVMergeSource.java index d0e4179b3fb5ff832525b85b5d7513c20833f3a3..d6ed5aad7bdc16d53265e13876fa96410319622d 100644 --- a/src/main/java/org/olat/group/GroupfoldersWebDAVMergeSource.java +++ b/src/main/java/org/olat/group/GroupfoldersWebDAVMergeSource.java @@ -24,6 +24,7 @@ import java.util.HashSet; import java.util.List; import java.util.Set; +import org.olat.admin.quota.QuotaConstants; import org.olat.collaboration.CollaborationManager; import org.olat.collaboration.CollaborationTools; import org.olat.core.CoreSpringFactory; @@ -134,7 +135,7 @@ class GroupfoldersWebDAVMergeSource extends WebDAVMergeSource { VFSSecurityCallback secCallback; if(writeAccess) { SubscriptionContext sc = new SubscriptionContext(group, "toolfolder"); - secCallback = new FullAccessWithLazyQuotaCallback(folderPath, sc); + secCallback = new FullAccessWithLazyQuotaCallback(folderPath, QuotaConstants.IDENTIFIER_DEFAULT_GROUPS, sc); } else { secCallback = new ReadOnlyCallback(); } diff --git a/src/main/java/org/olat/modules/portfolio/ui/BinderPageListController.java b/src/main/java/org/olat/modules/portfolio/ui/BinderPageListController.java index adc51bc561a2622cad5dd4c8167afa8edae70ca1..a64228c2fc9b16ce15dd479da8e28e863cd09f56 100644 --- a/src/main/java/org/olat/modules/portfolio/ui/BinderPageListController.java +++ b/src/main/java/org/olat/modules/portfolio/ui/BinderPageListController.java @@ -356,7 +356,11 @@ public class BinderPageListController extends AbstractPageListController { String cmd = se.getCommand(); if("select-page".equals(cmd)) { PortfolioElementRow row = model.getObject(se.getIndex()); - doOpenRow(ureq, row, false); + if(row.isPendingAssignment()) { + doStartAssignment(ureq, row); + } else { + doOpenRow(ureq, row, false); + } } } } else if(previousSectionLink == source) { diff --git a/src/main/java/org/olat/modules/portfolio/ui/InvitationEditRightsController.java b/src/main/java/org/olat/modules/portfolio/ui/InvitationEditRightsController.java index 8475ae9688307be8932739677d129259b794cd53..6f28d87ce58b141c86a9a709d217dade6bc6d5f9 100644 --- a/src/main/java/org/olat/modules/portfolio/ui/InvitationEditRightsController.java +++ b/src/main/java/org/olat/modules/portfolio/ui/InvitationEditRightsController.java @@ -191,13 +191,15 @@ public class InvitationEditRightsController extends FormBasicController { linkEl.setElementCssClass("o_sel_pf_invitation_url"); linkEl.setLabel("invitation.link", null); - subjectEl = uifactory.addTextElement("subjectElem", "mail.subject", 128, mailTemplate.getSubjectTemplate(), inviteeCont); - subjectEl.setDisplaySize(60); - subjectEl.setMandatory(true); - - bodyEl = uifactory.addTextAreaElement("bodyElem", "mail.body", -1, 15, 60, true, mailTemplate.getBodyTemplate(), inviteeCont); - bodyEl.setHelpUrlForManualPage("E-Mail"); - bodyEl.setMandatory(true); + if(mailTemplate != null) { + subjectEl = uifactory.addTextElement("subjectElem", "mail.subject", 128, mailTemplate.getSubjectTemplate(), inviteeCont); + subjectEl.setDisplaySize(60); + subjectEl.setMandatory(true); + + bodyEl = uifactory.addTextAreaElement("bodyElem", "mail.body", -1, 15, 60, true, mailTemplate.getBodyTemplate(), inviteeCont); + bodyEl.setHelpUrlForManualPage("E-Mail"); + bodyEl.setMandatory(true); + } //binder MultipleSelectionElement accessEl = uifactory.addCheckboxesHorizontal("access-" + (counter++), null, formLayout, theKeys, theValues); diff --git a/src/main/java/org/olat/repository/_i18n/LocalStrings_de.properties b/src/main/java/org/olat/repository/_i18n/LocalStrings_de.properties index 7fac13043046c3b4282e68cad0eaa5dc70060d40..8d7f87d6003c9462a8716d2db0b4dbd60d4fff29 100644 --- a/src/main/java/org/olat/repository/_i18n/LocalStrings_de.properties +++ b/src/main/java/org/olat/repository/_i18n/LocalStrings_de.properties @@ -318,6 +318,7 @@ index.header=Lernressourcen index.header.alt=Suchen Sie nach Lernressourcen info.could.not.delete.entry=Der Eintrag konnte nicht gel\u00F6scht werden. info.entry.deleted=Der Eintrag wurde gel\u00F6scht. +info.entry.read.only=Der Eintrag ist erfolgreich beendet. info.header=<i class\='o_icon o_icon-lg o_icon_info_resource'> </i> info.message.change.title=Der Kurs wurde erfolgreich auf den Status [deaktiviert] gesetzt. launch.noaccess=Sie haben zu wenig Berechtigungen, um diese Lernressource zu starten. diff --git a/src/main/java/org/olat/repository/_i18n/LocalStrings_en.properties b/src/main/java/org/olat/repository/_i18n/LocalStrings_en.properties index a8eb6ee4f0908cf4b3fe3354eb8dd7546825386d..2d52836b4d9e1056955f04358d2e1c0dcac78575 100644 --- a/src/main/java/org/olat/repository/_i18n/LocalStrings_en.properties +++ b/src/main/java/org/olat/repository/_i18n/LocalStrings_en.properties @@ -314,6 +314,7 @@ index.header=Learning resources index.header.alt=Search for your learning resources info.could.not.delete.entry=This entry could not be deleted. info.entry.deleted=Entry deleted. +info.entry.read.only=Entry was successfully finished. info.header=<i class\='o_icon o_icon-lg o_icon_info_resource'> </i> info.message.change.title=This course has been changed successfully to [deactivated]. launch.noaccess=You have not enough access rights to launch this learning resource.