summaryrefslogtreecommitdiffstats
path: root/dozentenmodul/src/main/java/gui/intro/Login_GUI.java
diff options
context:
space:
mode:
Diffstat (limited to 'dozentenmodul/src/main/java/gui/intro/Login_GUI.java')
-rw-r--r--dozentenmodul/src/main/java/gui/intro/Login_GUI.java30
1 files changed, 25 insertions, 5 deletions
diff --git a/dozentenmodul/src/main/java/gui/intro/Login_GUI.java b/dozentenmodul/src/main/java/gui/intro/Login_GUI.java
index 11b1c515..261c6464 100644
--- a/dozentenmodul/src/main/java/gui/intro/Login_GUI.java
+++ b/dozentenmodul/src/main/java/gui/intro/Login_GUI.java
@@ -1,6 +1,5 @@
package gui.intro;
-import java.awt.Choice;
import java.awt.Color;
import java.awt.Component;
import java.awt.Image;
@@ -9,7 +8,6 @@ import java.awt.event.ActionEvent;
import java.awt.event.ActionListener;
import java.awt.event.WindowAdapter;
import java.awt.event.WindowEvent;
-import java.util.Arrays;
import java.util.List;
import java.util.concurrent.ExecutionException;
@@ -40,6 +38,7 @@ import org.apache.thrift.TException;
import org.openslx.imagemaster.thrift.iface.ImageServer.Client;
import org.openslx.imagemaster.thrift.iface.UserInfo;
+//import server.generated.Server.Client;
import thrift.MasterThriftConnection;
import thrift.ThriftConnection;
import util.GuiOrganizer;
@@ -111,7 +110,7 @@ public class Login_GUI extends JFrame {
UIManager.setLookAndFeel(UIManager.getSystemLookAndFeelClassName());
} catch (ClassNotFoundException | InstantiationException
| IllegalAccessException | UnsupportedLookAndFeelException e) {
- // TODO Auto-generated catch block
+
e.printStackTrace();
}
// Titel des Fensters setzen
@@ -417,10 +416,10 @@ public class Login_GUI extends JFrame {
setStatus(Color.red, "Fehler: bwIDM-Login fehlgeschlagen!", null);
}
} catch (InterruptedException e) {
- // TODO Auto-generated catch block
+
e.printStackTrace();
} catch (ExecutionException e) {
- // TODO Auto-generated catch block
+
e.printStackTrace();
}
}
@@ -460,6 +459,27 @@ public class Login_GUI extends JFrame {
}// end performLogin
private void showMainMenu() {
+
+
+
+ /*
+ * TODO check if user has already been regisistered. if not, do so
+ *
+ *
+ */
+ //import server.generated.Server.Client;
+ server.generated.Server.Client client_2 = models.Client.clientcon.getClient();
+ try {
+ String pk_institution = client_2.setInstitution(person.verantwortlicher.getHochschule());
+ LOGGER.info("Institution of user is: "+pk_institution);
+ client_2.setPerson(person.verantwortlicher.getUserID(), person.verantwortlicher.getName(), person.verantwortlicher.getVorname(), person.verantwortlicher.getEMail(), pk_institution);
+ LOGGER.info("user data, ID="+person.verantwortlicher.getUserID()+" , Name="+person.verantwortlicher.getName()+" , Vorname="+ person.verantwortlicher.getVorname()+" , E-Mail="+ person.verantwortlicher.getEMail()+" , Institution="+ pk_institution);
+ } catch (TException e) {
+ // TODO Auto-generated catch block
+ e.printStackTrace();
+ }
+
+
// Pruefe ob Bills Of Rights schon akzeptiert wurden,
// wenn nicht zeige diese an
if (!Config.getBillOfRights()) {