From ecccfcd9f42501496ad7e5444ef9098f28a19b40 Mon Sep 17 00:00:00 2001 From: ulrich <not disclosed> Date: Sun, 15 Jan 2017 12:08:00 +0000 Subject: [PATCH] Readme hinzugefĆ¼gt --- src/java/de/uhilger/um/web/Initialiser.java | 7 +++++++ 1 files changed, 7 insertions(+), 0 deletions(-) diff --git a/src/java/de/uhilger/um/web/Initialiser.java b/src/java/de/uhilger/um/web/Initialiser.java index 41da73b..1895344 100644 --- a/src/java/de/uhilger/um/web/Initialiser.java +++ b/src/java/de/uhilger/um/web/Initialiser.java @@ -21,6 +21,7 @@ import de.uhilger.baselink.PersistenceManager; import de.uhilger.baselink.Record; import de.uhilger.um.api.UserMgr; +import de.uhilger.um.daten.User; import java.io.BufferedReader; import java.io.File; import java.io.FileInputStream; @@ -127,6 +128,12 @@ if(!dbVorhanden(db, sql.getProperty(SQL_DB_VORHANDEN))) { logger.info("Datenbank ist nicht vorhanden"); int[] ergebnis = db.executeScript(getSqlSkript()); + User admin = new User(); + admin.setId("admin"); + admin.setPw("admin"); + UserMgr um = new UserMgr(); + um.setServletContext(servletContext); + um.createUser(admin); } } catch(Exception ex) { logger.log(Level.INFO, ex.getMessage(), ex); -- Gitblit v1.9.3