diff options
Diffstat (limited to 'dozentenmodul/src/main/java/org/openslx/dozmod/gui/wizard/LectureWizard.java')
-rw-r--r-- | dozentenmodul/src/main/java/org/openslx/dozmod/gui/wizard/LectureWizard.java | 13 |
1 files changed, 8 insertions, 5 deletions
diff --git a/dozentenmodul/src/main/java/org/openslx/dozmod/gui/wizard/LectureWizard.java b/dozentenmodul/src/main/java/org/openslx/dozmod/gui/wizard/LectureWizard.java index 31469ff3..6d88cb90 100644 --- a/dozentenmodul/src/main/java/org/openslx/dozmod/gui/wizard/LectureWizard.java +++ b/dozentenmodul/src/main/java/org/openslx/dozmod/gui/wizard/LectureWizard.java @@ -54,8 +54,9 @@ public class LectureWizard extends Wizard implements UiFeedback { addPage(new LectureImageListPage(this, state)); addPage(new LectureOptionsPage(this, state)); addPage(new LectureCustomPermissionPage(this, state)); - if (MetaDataCache.getLocations() != null && !MetaDataCache.getLocations().isEmpty()) + if (MetaDataCache.getLocations() != null && !MetaDataCache.getLocations().isEmpty()) { addPage(new LectureLocationSelectionPage(this, state)); + } } @Override @@ -97,13 +98,15 @@ public class LectureWizard extends Wizard implements UiFeedback { uuid = ThriftActions.createLecture(JOptionPane.getFrameForComponent(this), lectureWriteFromState()); if (uuid == null) return false; - else - state.uuid = uuid; + + state.uuid = uuid; // now push the permissions if we have any - if (state.permissionMap != null && !state.permissionMap.isEmpty()) + if (state.permissionMap != null && !state.permissionMap.isEmpty()) { if (!ThriftActions.writeLecturePermissions(JOptionPane.getFrameForComponent(this), state.uuid, - state.permissionMap)) + state.permissionMap)) { return false; + } + } // all good, refresh cache and change to LectureList Gui.showMessageBox(this, "Veranstaltung erstellt!", MessageType.INFO, null, null); |