Merge remote-tracking branch 'upstream/main' into DS-626

This commit is contained in:
Yana De Pauw
2020-09-18 15:06:16 +02:00
234 changed files with 14452 additions and 3958 deletions

View File

@@ -19,6 +19,7 @@ import org.dspace.content.MetadataSchemaEnum;
import org.dspace.content.WorkspaceItem;
import org.dspace.content.service.DSpaceObjectService;
import org.dspace.core.Context;
import org.dspace.eperson.EPerson;
import org.dspace.eperson.Group;
/**
@@ -130,6 +131,19 @@ public class ItemBuilder extends AbstractDSpaceObjectBuilder<Item> {
return this;
}
/**
* Create an admin group for the collection with the specified members
*
* @param members epersons to add to the admin group
* @return this builder
* @throws SQLException
* @throws AuthorizeException
*/
public ItemBuilder withAdminUser(EPerson ePerson) throws SQLException, AuthorizeException {
return setAdminPermission(item, ePerson, null);
}
@Override
public Item build() {
try {