add change_maximum size
Co-Authored-By: xxnitram <xxnitram@users.noreply.github.com>
This commit is contained in:
@ -40,7 +40,7 @@ public class ControllerService {
|
||||
* @param title Gruppentitel
|
||||
* @param description Gruppenbeschreibung
|
||||
*/
|
||||
public void createGroup(Account account, String title, String description, Boolean visibility, Long userMaximum, Long parent) throws EventException {
|
||||
public void createGroup(Account account, String title, String description, Boolean visibility, Boolean maxInfiniteUsers, Long userMaximum, Long parent) throws EventException {
|
||||
Visibility visibility1;
|
||||
Long groupId = eventService.checkGroup();
|
||||
|
||||
@ -51,6 +51,10 @@ public class ControllerService {
|
||||
createInviteLink(groupId);
|
||||
}
|
||||
|
||||
if(maxInfiniteUsers){
|
||||
userMaximum = 100000L;
|
||||
}
|
||||
|
||||
CreateGroupEvent createGroupEvent = new CreateGroupEvent(groupId, account.getName(), parent, GroupType.SIMPLE, visibility1, userMaximum);
|
||||
eventService.saveEvent(createGroupEvent);
|
||||
|
||||
@ -60,7 +64,7 @@ public class ControllerService {
|
||||
updateRole(account.getName(), groupId);
|
||||
}
|
||||
|
||||
public void createOrga(Account account, String title, String description, Boolean visibility, Boolean lecture, Long userMaximum, Long parent, List<User> users) throws EventException {
|
||||
public void createOrga(Account account, String title, String description, Boolean visibility, Boolean lecture, Boolean maxInfiniteUsers, Long userMaximum, Long parent, List<User> users) throws EventException {
|
||||
Visibility visibility1;
|
||||
Long groupId = eventService.checkGroup();
|
||||
|
||||
@ -77,6 +81,11 @@ public class ControllerService {
|
||||
groupType = GroupType.SIMPLE;
|
||||
}
|
||||
|
||||
|
||||
if(maxInfiniteUsers){
|
||||
userMaximum = 100000L;
|
||||
}
|
||||
|
||||
CreateGroupEvent createGroupEvent = new CreateGroupEvent(groupId, account.getName(), parent, groupType, visibility1, userMaximum);
|
||||
eventService.saveEvent(createGroupEvent);
|
||||
|
||||
|
||||
Reference in New Issue
Block a user