Views & Controller erstellt

This commit is contained in:
Richard Reiswich 2023-01-17 15:58:22 +01:00
parent e245233a23
commit 3bb141fb52
17 changed files with 313 additions and 2 deletions

View File

@ -0,0 +1,4 @@
package com.bib.essensbestellungsverwaltung;
public class AdminController {
}

View File

@ -0,0 +1,4 @@
package com.bib.essensbestellungsverwaltung;
public class LaunchController {
}

View File

@ -0,0 +1,38 @@
/*Richard Reiswich*/
package com.bib.essensbestellungsverwaltung;
import javafx.beans.NamedArg;
import javafx.fxml.FXML;
import javafx.scene.control.Button;
import javafx.scene.control.PasswordField;
import javafx.scene.control.TextField;
public class LoginController {
@FXML
private TextField tfEmail;
@FXML
private PasswordField pfPassword;
@FXML
private Button btLogin;
@FXML
private Button btSignUp;
@FXML
protected void onBtLoginClick(){
String email = tfEmail.getText();
String password = pfPassword.getText();
tfEmail.setText("");
pfPassword.setText("");
}
@FXML
protected void changeToSignUp(){
}
}

View File

@ -0,0 +1,4 @@
package com.bib.essensbestellungsverwaltung;
public class ParentController{
}

View File

@ -0,0 +1,24 @@
package com.bib.essensbestellungsverwaltung;
import javafx.event.ActionEvent;
import javafx.fxml.FXMLLoader;
import javafx.scene.Node;
import javafx.scene.Parent;
import javafx.scene.Scene;
import javafx.stage.Stage;
import java.io.IOException;
public class SceneController {
private Stage stage;
private Scene scene;
private Parent root;
public void switchToLoginScene(ActionEvent event) throws IOException{
Parent root = FXMLLoader.load(getClass().getResource("login-view.fxml"));
stage = (Stage) ((Node)event.getSource()).getScene().getWindow();
scene = new Scene(root);
stage.setScene(scene);
stage.show();
}
}

View File

@ -0,0 +1,4 @@
package com.bib.essensbestellungsverwaltung;
public class StartPageController {
}

View File

@ -0,0 +1,14 @@
<?xml version="1.0" encoding="UTF-8"?>
<?import java.lang.*?>
<?import java.util.*?>
<?import javafx.scene.*?>
<?import javafx.scene.control.*?>
<?import javafx.scene.layout.*?>
<AnchorPane xmlns="http://javafx.com/javafx"
xmlns:fx="http://javafx.com/fxml"
fx:controller="com.bib.essensbestellungsverwaltung.AdminController"
prefHeight="400.0" prefWidth="600.0">
</AnchorPane>

View File

@ -0,0 +1,14 @@
<?xml version="1.0" encoding="UTF-8"?>
<?import java.lang.*?>
<?import java.util.*?>
<?import javafx.scene.*?>
<?import javafx.scene.control.*?>
<?import javafx.scene.layout.*?>
<AnchorPane xmlns="http://javafx.com/javafx"
xmlns:fx="http://javafx.com/fxml"
fx:controller="com.bib.essensbestellungsverwaltung.AdminController"
prefHeight="400.0" prefWidth="600.0">
</AnchorPane>

View File

@ -0,0 +1,14 @@
<?xml version="1.0" encoding="UTF-8"?>
<?import java.lang.*?>
<?import java.util.*?>
<?import javafx.scene.*?>
<?import javafx.scene.control.*?>
<?import javafx.scene.layout.*?>
<AnchorPane xmlns="http://javafx.com/javafx"
xmlns:fx="http://javafx.com/fxml"
fx:controller="com.bib.essensbestellungsverwaltung.ParentController"
prefHeight="400.0" prefWidth="600.0">
</AnchorPane>

View File

@ -0,0 +1,14 @@
<?xml version="1.0" encoding="UTF-8"?>
<?import java.lang.*?>
<?import java.util.*?>
<?import javafx.scene.*?>
<?import javafx.scene.control.*?>
<?import javafx.scene.layout.*?>
<AnchorPane xmlns="http://javafx.com/javafx"
xmlns:fx="http://javafx.com/fxml"
fx:controller="com.bib.essensbestellungsverwaltung.AdminController"
prefHeight="400.0" prefWidth="600.0">
</AnchorPane>

View File

@ -0,0 +1,14 @@
<?xml version="1.0" encoding="UTF-8"?>
<?import java.lang.*?>
<?import java.util.*?>
<?import javafx.scene.*?>
<?import javafx.scene.control.*?>
<?import javafx.scene.layout.*?>
<AnchorPane xmlns="http://javafx.com/javafx"
xmlns:fx="http://javafx.com/fxml"
fx:controller="com.bib.essensbestellungsverwaltung.AdminController"
prefHeight="400.0" prefWidth="600.0">
</AnchorPane>

View File

@ -0,0 +1,14 @@
<?xml version="1.0" encoding="UTF-8"?>
<?import java.lang.*?>
<?import java.util.*?>
<?import javafx.scene.*?>
<?import javafx.scene.control.*?>
<?import javafx.scene.layout.*?>
<AnchorPane xmlns="http://javafx.com/javafx"
xmlns:fx="http://javafx.com/fxml"
fx:controller="com.bib.essensbestellungsverwaltung.AdminController"
prefHeight="400.0" prefWidth="600.0">
</AnchorPane>

View File

@ -0,0 +1,14 @@
<?xml version="1.0" encoding="UTF-8"?>
<?import java.lang.*?>
<?import java.util.*?>
<?import javafx.scene.*?>
<?import javafx.scene.control.*?>
<?import javafx.scene.layout.*?>
<AnchorPane xmlns="http://javafx.com/javafx"
xmlns:fx="http://javafx.com/fxml"
fx:controller="com.bib.essensbestellungsverwaltung.AdminController"
prefHeight="400.0" prefWidth="600.0">
</AnchorPane>

View File

@ -0,0 +1,14 @@
<?xml version="1.0" encoding="UTF-8"?>
<?import java.lang.*?>
<?import java.util.*?>
<?import javafx.scene.*?>
<?import javafx.scene.control.*?>
<?import javafx.scene.layout.*?>
<AnchorPane xmlns="http://javafx.com/javafx"
xmlns:fx="http://javafx.com/fxml"
fx:controller="com.bib.essensbestellungsverwaltung.AdminController"
prefHeight="400.0" prefWidth="600.0">
</AnchorPane>

View File

@ -12,11 +12,11 @@
<?import javafx.scene.text.Font?>
<?import javafx.scene.text.Text?>
<AnchorPane maxHeight="-Infinity" maxWidth="-Infinity" minHeight="-Infinity" minWidth="-Infinity" prefHeight="400.0" prefWidth="600.0" xmlns="http://javafx.com/javafx/19" xmlns:fx="http://javafx.com/fxml/1">
<AnchorPane maxHeight="-Infinity" maxWidth="-Infinity" minHeight="-Infinity" minWidth="-Infinity" prefHeight="400.0" prefWidth="600.0" xmlns="http://javafx.com/javafx/19" xmlns:fx="http://javafx.com/fxml/1" fx:controller="com.bib.essensbestellungsverwaltung.LaunchController">
<children>
<VBox alignment="CENTER" prefHeight="400.0" prefWidth="265.0" style="-fx-background-color: lightblue;">
<children>
<Text fill="WHITE" strokeType="OUTSIDE" strokeWidth="0.0" text="Essenbestellung">
<Text fill="WHITE" strokeType="OUTSIDE" strokeWidth="0.0" text="Essensbestellung">
<font>
<Font name="Yu Gothic Light" size="26.0" />
</font>

View File

@ -0,0 +1,14 @@
<?xml version="1.0" encoding="UTF-8"?>
<?import java.lang.*?>
<?import java.util.*?>
<?import javafx.scene.*?>
<?import javafx.scene.control.*?>
<?import javafx.scene.layout.*?>
<AnchorPane xmlns="http://javafx.com/javafx"
xmlns:fx="http://javafx.com/fxml"
fx:controller="com.bib.essensbestellungsverwaltung.ParentController"
maxHeight= "-Infinity" maxWidth="-Infinity">
</AnchorPane>

View File

@ -0,0 +1,107 @@
<?xml version="1.0" encoding="UTF-8"?>
<?import javafx.geometry.Insets?>
<?import javafx.scene.control.Button?>
<?import javafx.scene.control.PasswordField?>
<?import javafx.scene.control.TextField?>
<?import javafx.scene.effect.Blend?>
<?import javafx.scene.layout.AnchorPane?>
<?import javafx.scene.layout.HBox?>
<?import javafx.scene.layout.VBox?>
<?import javafx.scene.shape.Circle?>
<?import javafx.scene.text.Font?>
<?import javafx.scene.text.Text?>
<AnchorPane maxHeight="-400" maxWidth="-600" minHeight="-400" minWidth="-600" prefHeight="400.0" prefWidth="600.0" xmlns="http://javafx.com/javafx/19" xmlns:fx="http://javafx.com/fxml/1" fx:controller="com.bib.essensbestellungsverwaltung.AdminController">
<children>
<VBox alignment="CENTER" prefHeight="400.0" prefWidth="265.0" style="-fx-background-color: lightblue;">
<children>
<Text fill="WHITE" strokeType="OUTSIDE" strokeWidth="0.0" text="Essensbestellung">
<font>
<Font name="Yu Gothic Light" size="26.0" />
</font>
</Text>
</children>
<padding>
<Insets bottom="150.0" />
</padding>
</VBox>
<Circle fill="#67b5ff2e" layoutX="-23.0" layoutY="368.0" radius="100.0" stroke="BLACK" strokeType="INSIDE" strokeWidth="0.0" />
<Circle fill="#69b6ffb0" layoutX="235.0" layoutY="310.0" radius="158.0" stroke="BLACK" strokeType="INSIDE" strokeWidth="0.0" />
<Circle fill="#93c4f23d" layoutY="258.0" radius="106.0" stroke="BLACK" strokeType="INSIDE" strokeWidth="0.0" />
<VBox alignment="CENTER" layoutX="263.0" prefHeight="400.0" prefWidth="338.0" style="-fx-background-color: white;">
<children>
<TextField promptText="Email" style="-fx-background-color: transparent; -fx-border-color: lightgray; -fx-border-width: 0 0 1 0;">
<effect>
<Blend />
</effect>
<font>
<Font name="Microsoft Tai Le Bold" size="12.0" />
</font>
<VBox.margin>
<Insets bottom="10.0" left="10.0" right="10.0" top="10.0" />
</VBox.margin>
</TextField>
<TextField promptText="Email bestätigen" style="-fx-background-color: transparent; -fx-border-color: lightgray; -fx-border-width: 0 0 1 0;">
<effect>
<Blend />
</effect>
<font>
<Font name="Microsoft Tai Le Bold" size="12.0" />
</font>
<VBox.margin>
<Insets bottom="10.0" left="10.0" right="10.0" top="10.0" />
</VBox.margin>
</TextField>
<PasswordField promptText="Passwort" style="-fx-background-color: transparent; -fx-border-color: lightgray; -fx-border-width: 0 0 1 0;">
<font>
<Font name="Microsoft Tai Le Bold" size="12.0" />
</font>
<opaqueInsets>
<Insets />
</opaqueInsets>
<effect>
<Blend />
</effect>
<VBox.margin>
<Insets bottom="10.0" left="10.0" right="10.0" top="10.0" />
</VBox.margin>
</PasswordField>
<PasswordField promptText="Passwort bestätigen" style="-fx-background-color: transparent; -fx-border-color: lightgray; -fx-border-width: 0 0 1 0;">
<font>
<Font name="Microsoft Tai Le Bold" size="12.0" />
</font>
<opaqueInsets>
<Insets />
</opaqueInsets>
<effect>
<Blend />
</effect>
<VBox.margin>
<Insets bottom="10.0" left="10.0" right="10.0" top="10.0" />
</VBox.margin>
</PasswordField>
<HBox alignment="CENTER" prefHeight="30.0" prefWidth="238.0">
<children>
<Button mnemonicParsing="false" prefHeight="25.0" prefWidth="106.0" style="-fx-background-radius: 25; -fx-background-color: lightblue;" text="Konto erstellen" textFill="WHITE">
<font>
<Font name="Microsoft Tai Le Bold" size="12.0" />
</font></Button>
<Button id="btSignUp" mnemonicParsing="false" prefHeight="25.0" prefWidth="101.0" style="-fx-background-color: tranparent;" text="Anmelden" textFill="#7c7b7b" underline="true" />
</children>
<opaqueInsets>
<Insets top="15.0" />
</opaqueInsets>
<VBox.margin>
<Insets top="15.0" />
</VBox.margin>
</HBox>
</children>
<padding>
<Insets bottom="65.0" left="45.0" right="45.0" top="45.0" />
</padding>
</VBox>
<Circle fill="#1469b895" layoutX="133.0" layoutY="368.0" radius="106.0" stroke="BLACK" strokeType="INSIDE" strokeWidth="0.0" />
<Circle fill="#0088ff82" layoutX="77.0" layoutY="276.0" radius="53.0" stroke="BLACK" strokeType="INSIDE" strokeWidth="0.0" />
</children>
</AnchorPane>