prevent private lectures in frontend, still needs validation
Co-authored-by: [Mahgs] <maxoerter@gmx.de> Co-authored-by: Christoph <tobi@urpost.de>
This commit is contained in:
@ -61,13 +61,13 @@
|
|||||||
<input class="form-control" th:name="userMaximum"
|
<input class="form-control" th:name="userMaximum"
|
||||||
type="number" min="1" max="10000">
|
type="number" min="1" max="10000">
|
||||||
</div>
|
</div>
|
||||||
<div class="custom-control custom-checkbox">
|
<div class="custom-control custom-checkbox" id="privateCheckbox">
|
||||||
<input class="custom-control-input" id="visibility" th:name="visibility"
|
<input class="custom-control-input" id="visibility" th:name="visibility"
|
||||||
type="checkbox">
|
type="checkbox">
|
||||||
<label class="custom-control-label" for="visibility">Private
|
<label class="custom-control-label" for="visibility">Private
|
||||||
Gruppe</label>
|
Gruppe</label>
|
||||||
</div>
|
</div>
|
||||||
<div class="custom-control custom-checkbox">
|
<div class="custom-control custom-checkbox" id="lectureCheckbox">
|
||||||
<input class="custom-control-input" id="lecture" th:name="lecture"
|
<input class="custom-control-input" id="lecture" th:name="lecture"
|
||||||
type="checkbox">
|
type="checkbox">
|
||||||
<label class="custom-control-label" for="lecture">Veranstaltung</label>
|
<label class="custom-control-label" for="lecture">Veranstaltung</label>
|
||||||
@ -117,6 +117,18 @@
|
|||||||
});
|
});
|
||||||
});
|
});
|
||||||
|
|
||||||
|
$(document).ready(function () {
|
||||||
|
$('#lecture').change(function () {
|
||||||
|
$('#privateCheckbox').fadeToggle();
|
||||||
|
});
|
||||||
|
});
|
||||||
|
|
||||||
|
$(document).ready(function () {
|
||||||
|
$('#visibility').change(function () {
|
||||||
|
$('#lectureCheckbox').fadeToggle();
|
||||||
|
});
|
||||||
|
});
|
||||||
|
|
||||||
$(document).ready(function () {
|
$(document).ready(function () {
|
||||||
$('#maxInfiniteUsers').change(function () {
|
$('#maxInfiniteUsers').change(function () {
|
||||||
$('#userMaximum').fadeToggle();
|
$('#userMaximum').fadeToggle();
|
||||||
|
|||||||
@ -7,7 +7,6 @@ import mops.gruppen2.domain.Visibility;
|
|||||||
import mops.gruppen2.domain.event.Event;
|
import mops.gruppen2.domain.event.Event;
|
||||||
import mops.gruppen2.repository.EventRepository;
|
import mops.gruppen2.repository.EventRepository;
|
||||||
import org.junit.jupiter.api.BeforeEach;
|
import org.junit.jupiter.api.BeforeEach;
|
||||||
import org.junit.jupiter.api.Disabled;
|
|
||||||
import org.junit.jupiter.api.Test;
|
import org.junit.jupiter.api.Test;
|
||||||
import org.junit.jupiter.api.extension.ExtendWith;
|
import org.junit.jupiter.api.extension.ExtendWith;
|
||||||
import org.springframework.beans.factory.annotation.Autowired;
|
import org.springframework.beans.factory.annotation.Autowired;
|
||||||
@ -155,9 +154,8 @@ class GroupServiceTest {
|
|||||||
assertThat(groupService.getAllGroupWithVisibilityPublic("test1").size()).isEqualTo(3);
|
assertThat(groupService.getAllGroupWithVisibilityPublic("test1").size()).isEqualTo(3);
|
||||||
}
|
}
|
||||||
|
|
||||||
@Disabled
|
|
||||||
@Test
|
@Test
|
||||||
void getAllGroupWithVisibilityPublicTestIsUserInGroup() {
|
void getAllGroupWithVisibilityPublic_UserInGroup() {
|
||||||
// eventService.saveEvent(new CreateGroupEvent(uuidFromInt(0), "test1", null, GroupType.SIMPLE, Visibility.PUBLIC, 20L));
|
// eventService.saveEvent(new CreateGroupEvent(uuidFromInt(0), "test1", null, GroupType.SIMPLE, Visibility.PUBLIC, 20L));
|
||||||
// eventService.saveEvent(new AddUserEvent(uuidFromInt(0), "test1", "test", "test", "test@test"));
|
// eventService.saveEvent(new AddUserEvent(uuidFromInt(0), "test1", "test", "test", "test@test"));
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user