first steps for currentOrder Tree Table

This commit is contained in:
Hendrik Schutter 2018-10-04 23:46:42 +02:00
parent 105c168157
commit 5f1b0d9ae1
8 changed files with 514 additions and 594 deletions

View File

@ -75,51 +75,7 @@ class DBController
return true;
}
}
// table Position section
public void createTablePositionen()
{ // create table position
System.out.println("Erstelle Tabelle Positionen");
try {
Statement stmt = connection.createStatement();
stmt.executeUpdate("DROP TABLE IF EXISTS positionen;");
stmt.executeUpdate(
"CREATE TABLE positionen (posid, name, value, cat, color);");
} catch (SQLException e) {
System.err.println("Couldn't handle DB-Query");
e.printStackTrace();
}
// create 25 demo/default data entries
for (int i = 0; i < 25; i++) {
fillPositionen_Positionen(i + 1, "Noch frei", (float) 0.00, 6,
"#ad0000");
}
}
public void createTableCategory()
{ // create table position
System.out.println("Erstelle Tabelle Kategorie");
try {
Statement stmt = connection.createStatement();
stmt.executeUpdate("DROP TABLE IF EXISTS category;");
stmt.executeUpdate("CREATE TABLE category (catid, catname);");
} catch (SQLException e) {
System.err.println("Couldn't handle DB-Query");
e.printStackTrace();
}
fillCategory_Category(1, "Essen");
fillCategory_Category(2, "alkoholische Getränke");
fillCategory_Category(3, "alkoholfreie Getränke");
fillCategory_Category(4, "Kuchen");
fillCategory_Category(5, "Standard");
}
public String getCategoryNameFromPositionen(int pID)
{
// System.out.println("getCategoryName: " + pID);
@ -154,36 +110,25 @@ class DBController
}
public void setName_Category(int pID, String pName)
{ // Setzte den Namen
// table Position section //
public void createTablePositionen()
{ // create table position
System.out.println("Erstelle Tabelle Positionen");
try {
Statement stmt = connection.createStatement();
stmt.executeUpdate("UPDATE category SET catname = '" + pName
+ "'WHERE catid =" + pID + ";");
} catch (SQLException e) {
System.err.println("Couldn't handle DB-Query");
e.printStackTrace();
}
}
public void fillCategory_Category(int pID, String pName)
{
System.out.println("Erstelle neuen Kategorie Eintrag");
try {
PreparedStatement ps = connection
.prepareStatement("INSERT INTO category VALUES (?, ?);");
ps.setInt(1, pID); // primary
ps.setString(2, pName);
ps.addBatch();
connection.setAutoCommit(false);
ps.executeBatch(); // SQL execution
connection.setAutoCommit(true);
stmt.executeUpdate("DROP TABLE IF EXISTS positionen;");
stmt.executeUpdate(
"CREATE TABLE positionen (posid, name, value, cat, color);");
} catch (SQLException e) {
System.err.println("Couldn't handle DB-Query");
e.printStackTrace();
}
// create 25 demo/default data entries
for (int i = 0; i < 25; i++) {
fillPositionen_Positionen(i + 1, "Noch frei", (float) 0.00, 6,
"#ad0000");
}
}
public void fillPositionen_Positionen(int pID, String pName, float pValue,
@ -223,21 +168,6 @@ class DBController
}
}
public String getName_Category(int pID)
{ // Gibt das Datum zurück
try {
Statement stmt = connection.createStatement();
ResultSet rs = stmt.executeQuery(
"SELECT catid, catname FROM category WHERE catid = " + pID
+ ";");
return rs.getString("catname");
} catch (SQLException e) {
System.err.println("Couldn't handle DB-Query");
e.printStackTrace();
return "Error 404";
}
}
public String getValue_Positionen(int pID)
{ // Gibt das Konto zurück
try {
@ -375,7 +305,76 @@ class DBController
}
}
// table Jobs section
// table Category section //
public void createTableCategory()
{ // create table position
System.out.println("Erstelle Tabelle Kategorie");
try {
Statement stmt = connection.createStatement();
stmt.executeUpdate("DROP TABLE IF EXISTS category;");
stmt.executeUpdate("CREATE TABLE category (catid, catname);");
} catch (SQLException e) {
System.err.println("Couldn't handle DB-Query");
e.printStackTrace();
}
fillCategory_Category(1, "Essen");
fillCategory_Category(2, "alkoholische Getränke");
fillCategory_Category(3, "alkoholfreie Getränke");
fillCategory_Category(4, "Kuchen");
fillCategory_Category(5, "Standard");
}
public void setName_Category(int pID, String pName)
{ // Setzte den Namen
try {
Statement stmt = connection.createStatement();
stmt.executeUpdate("UPDATE category SET catname = '" + pName
+ "'WHERE catid =" + pID + ";");
} catch (SQLException e) {
System.err.println("Couldn't handle DB-Query");
e.printStackTrace();
}
}
public void fillCategory_Category(int pID, String pName)
{
System.out.println("Erstelle neuen Kategorie Eintrag");
try {
PreparedStatement ps = connection
.prepareStatement("INSERT INTO category VALUES (?, ?);");
ps.setInt(1, pID); // primary
ps.setString(2, pName);
ps.addBatch();
connection.setAutoCommit(false);
ps.executeBatch(); // SQL execution
connection.setAutoCommit(true);
} catch (SQLException e) {
System.err.println("Couldn't handle DB-Query");
e.printStackTrace();
}
}
public String getName_Category(int pID)
{ // Gibt das Datum zurück
try {
Statement stmt = connection.createStatement();
ResultSet rs = stmt.executeQuery(
"SELECT catid, catname FROM category WHERE catid = " + pID
+ ";");
return rs.getString("catname");
} catch (SQLException e) {
System.err.println("Couldn't handle DB-Query");
e.printStackTrace();
return "Error 404";
}
}
// table Jobs section //
public void erstelleTabelleJobs()
{ // Erstelle Tabelle mit Reihen
System.out.println("Erstelle Tabelle Jobs");
@ -383,11 +382,28 @@ class DBController
Statement stmt = connection.createStatement();
stmt.executeUpdate("DROP TABLE IF EXISTS jobs;");
stmt.executeUpdate(
"CREATE TABLE jobs (id, time, positionen, state, value);");
"CREATE TABLE jobs (jobid, time, positionen_name, positionen_value, positionen_cat, state, jobvalue);");
} catch (SQLException e) {
System.err.println("Couldn't handle DB-Query");
e.printStackTrace();
}
}
public int getLatestJobNumber_Job() {
try {
Statement stmt = connection.createStatement();
ResultSet rs = stmt.executeQuery(
"SELECT jobid from jobs ORDER BY jobid DESC LIMIT 1;");
return rs.getInt("jobid");
} catch (SQLException e) {
//System.err.println("Couldn't handle DB-Query");
//e.printStackTrace();
}
System.out.println("XXXXXXXXXXX 1 XXXXXXXXXXX");
return 1;
}
}

82
src/application/Job.java Normal file
View File

@ -0,0 +1,82 @@
package application;
import java.util.ArrayList;
public class Job
{
private int jobnumber;
private int jobvalue;
private String jobtime;
private ArrayList<Integer> positionenQuantity;
private ArrayList<String> positionenName;
private ArrayList<Float> positionenValue;
private ArrayList<String> positionenCat;
public Job(int pJobnumber)
{
this.jobnumber = pJobnumber;
System.out.println("Neuer Job: " + this.jobnumber);
positionenQuantity = new ArrayList<Integer>();
positionenName = new ArrayList<String>();
positionenValue = new ArrayList<Float>();
positionenCat = new ArrayList<String>();
//System.out.println("Größe: " + positionenName.size());
}
public void addPosition(String pPositionenName, float pPositionenValue,
String pPositionenCat)
{
//System.out.println("addName");
for (int i = 0; i < positionenName.size(); i++) {
if (positionenName.get(i).equals(pPositionenName)) {
// Item is already in list, increase quantity
positionenQuantity.set(i, positionenQuantity.get(i) + 1);
//System.out.println("Item exists, increasing quantity");
return;
}
}
positionenName.add(pPositionenName);
positionenValue.add(pPositionenValue);
positionenCat.add(pPositionenCat);
positionenQuantity.add(1);
}
public void printJobOnConsole()
{
System.out.println("---------------------------------------------");
System.out.println("JobNummer: " + jobnumber);
System.out.println("---------------------------------------------");
//System.out.println("Größe: " + positionenName.size());
for (int i = 0; i < positionenName.size(); i++) {
System.out.println(
positionenQuantity.get(i) + " " + positionenName.get(i) + " "
+ positionenValue.get(i) + " " + positionenCat.get(i));
/*
System.out.println("i is: " + i);
System.out.println(positionenName.get(i));
System.out.println(positionenQuantity.get(i));
*/
}
System.out.println("---------------------------------------------");
}
}

View File

@ -79,6 +79,7 @@ public class Main extends Application
mwc.fillCategory();
mwc.loadGridButtons();
mwc.getSelectedCat(); //Load DB entries in Chois Box
mwc.createFirstJob();
} else {
// config.xml NOT found, first start of app
System.out.println("keine XML gefunden!");

View File

@ -17,63 +17,36 @@
<?import javafx.scene.shape.Line?>
<?import javafx.scene.text.Font?>
<AnchorPane fx:id="mainAnchorpane" maxHeight="732.0"
maxWidth="1366.0" minHeight="732.0" minWidth="1366.0"
prefHeight="732.0" prefWidth="1366.0"
xmlns="http://javafx.com/javafx/9" xmlns:fx="http://javafx.com/fxml/1"
fx:controller="application.MainWindowController">
<AnchorPane fx:id="mainAnchorpane" maxHeight="732.0" maxWidth="1366.0" minHeight="732.0" minWidth="1366.0" prefHeight="732.0" prefWidth="1366.0" xmlns="http://javafx.com/javafx/9" xmlns:fx="http://javafx.com/fxml/1" fx:controller="application.MainWindowController">
<children>
<TabPane layoutX="4.0" layoutY="5.0"
nodeOrientation="RIGHT_TO_LEFT" prefHeight="924.0" prefWidth="1536.0"
tabClosingPolicy="UNAVAILABLE" AnchorPane.bottomAnchor="0.0"
AnchorPane.leftAnchor="0.0" AnchorPane.rightAnchor="0.0"
AnchorPane.topAnchor="0.0">
<TabPane layoutX="4.0" layoutY="5.0" nodeOrientation="RIGHT_TO_LEFT" prefHeight="924.0" prefWidth="1536.0" tabClosingPolicy="UNAVAILABLE" AnchorPane.bottomAnchor="0.0" AnchorPane.leftAnchor="0.0" AnchorPane.rightAnchor="0.0" AnchorPane.topAnchor="0.0">
<tabs>
<Tab text="Einstellungen">
<content>
<AnchorPane minHeight="0.0" minWidth="0.0"
prefHeight="180.0" prefWidth="200.0">
<AnchorPane minHeight="0.0" minWidth="0.0" prefHeight="180.0" prefWidth="200.0">
<children>
<Button fx:id="ueberbtn" layoutX="84.0" layoutY="79.0"
mnemonicParsing="false" onAction="#ueberbtnAction"
prefHeight="0.0" prefWidth="46.0" text="Über" />
<TitledPane alignment="CENTER" animated="false"
collapsible="false" contentDisplay="CENTER" layoutX="790.0"
layoutY="10.0" prefHeight="270.0" prefWidth="566.0"
text="Datenbank Einstellungen">
<Button fx:id="ueberbtn" layoutX="84.0" layoutY="79.0" mnemonicParsing="false" onAction="#ueberbtnAction" prefHeight="0.0" prefWidth="46.0" text="Über" />
<TitledPane alignment="CENTER" animated="false" collapsible="false" contentDisplay="CENTER" layoutX="790.0" layoutY="10.0" prefHeight="270.0" prefWidth="566.0" text="Datenbank Einstellungen">
<content>
<AnchorPane fx:id="paneDB" minHeight="0.0"
minWidth="0.0" prefHeight="238.0" prefWidth="564.0">
<AnchorPane fx:id="paneDB" minHeight="0.0" minWidth="0.0" prefHeight="238.0" prefWidth="564.0">
<children>
<Label fx:id="labelDBName" alignment="TOP_RIGHT"
contentDisplay="RIGHT" layoutX="329.0" layoutY="10.0"
prefHeight="34.0" prefWidth="229.0" text="Datenbankname:">
<Label fx:id="labelDBName" alignment="TOP_RIGHT" contentDisplay="RIGHT" layoutX="329.0" layoutY="10.0" prefHeight="34.0" prefWidth="229.0" text="Datenbankname:">
<font>
<Font name="Cantarell Regular" size="18.0" />
</font>
</Label>
<JFXTextField fx:id="tftNewDBName"
alignment="CENTER" layoutX="25.0" layoutY="10.0"
prefHeight="25.0" prefWidth="376.0" />
<Label fx:id="labelDBStatus" alignment="TOP_RIGHT"
contentDisplay="RIGHT" layoutX="1.0" layoutY="75.0"
prefHeight="34.0" prefWidth="551.0"
text="Keine Datenbank gefunden!">
<JFXTextField fx:id="tftNewDBName" alignment="CENTER" layoutX="25.0" layoutY="10.0" prefHeight="25.0" prefWidth="376.0" />
<Label fx:id="labelDBStatus" alignment="TOP_RIGHT" contentDisplay="RIGHT" layoutX="1.0" layoutY="75.0" prefHeight="34.0" prefWidth="551.0" text="Keine Datenbank gefunden!">
<font>
<Font name="Cantarell Regular" size="18.0" />
</font>
</Label>
<Button fx:id="btnCreateNewDatabase" layoutX="317.0"
layoutY="126.0" mnemonicParsing="false"
onAction="#btnCreateNewDatabaseAction"
text="Neue Datenbank anlegen">
<Button fx:id="btnCreateNewDatabase" layoutX="317.0" layoutY="126.0" mnemonicParsing="false" onAction="#btnCreateNewDatabaseAction" text="Neue Datenbank anlegen">
<font>
<Font name="Cantarell Regular" size="13.0" />
</font>
</Button>
<Button fx:id="btnOpenFolder" layoutX="99.0"
layoutY="126.0" mnemonicParsing="false"
onAction="#btnOpenFolderAction" text="Speicherort öffnen">
<Button fx:id="btnOpenFolder" layoutX="99.0" layoutY="126.0" mnemonicParsing="false" onAction="#btnOpenFolderAction" text="Speicherort öffnen">
<font>
<Font name="Cantarell Regular" size="13.0" />
</font>
@ -85,69 +58,41 @@
<Font name="Cantarell Regular" size="13.0" />
</font>
</TitledPane>
<TitledPane fx:id="titlePaneCat" alignment="CENTER"
animated="false" collapsible="false" contentDisplay="CENTER"
layoutX="170.0" layoutY="10.0" prefHeight="270.0"
prefWidth="566.0"
text="Kategorien (z.B. Getränke, Essen oder Kuchen)"
textAlignment="CENTER">
<TitledPane fx:id="titlePaneCat" alignment="CENTER" animated="false" collapsible="false" contentDisplay="CENTER" layoutX="170.0" layoutY="10.0" prefHeight="270.0" prefWidth="566.0" text="Kategorien (z.B. Getränke, Essen oder Kuchen)" textAlignment="CENTER">
<content>
<AnchorPane minHeight="0.0" minWidth="0.0"
prefHeight="260.0" prefWidth="564.0">
<AnchorPane minHeight="0.0" minWidth="0.0" prefHeight="260.0" prefWidth="564.0">
<children>
<Label fx:id="labelCat01" alignment="TOP_RIGHT"
contentDisplay="RIGHT" layoutX="434.0" layoutY="10.0"
prefHeight="34.0" prefWidth="124.0" text="Kategorie 1:">
<Label fx:id="labelCat01" alignment="TOP_RIGHT" contentDisplay="RIGHT" layoutX="434.0" layoutY="10.0" prefHeight="34.0" prefWidth="124.0" text="Kategorie 1:">
<font>
<Font name="Cantarell Regular" size="18.0" />
</font>
</Label>
<Label fx:id="labelCat02" alignment="TOP_RIGHT"
contentDisplay="RIGHT" layoutX="442.0" layoutY="50.0"
prefHeight="34.0" prefWidth="116.0" text="Kategorie 2:">
<Label fx:id="labelCat02" alignment="TOP_RIGHT" contentDisplay="RIGHT" layoutX="442.0" layoutY="50.0" prefHeight="34.0" prefWidth="116.0" text="Kategorie 2:">
<font>
<Font name="Cantarell Regular" size="18.0" />
</font>
</Label>
<Label fx:id="labelCat05" alignment="TOP_RIGHT"
contentDisplay="RIGHT" layoutX="448.0" layoutY="170.0"
prefHeight="34.0" prefWidth="110.0" text="Kategorie 5:">
<Label fx:id="labelCat05" alignment="TOP_RIGHT" contentDisplay="RIGHT" layoutX="448.0" layoutY="170.0" prefHeight="34.0" prefWidth="110.0" text="Kategorie 5:">
<font>
<Font name="Cantarell Regular" size="18.0" />
</font>
</Label>
<Label fx:id="labelCat04" alignment="TOP_RIGHT"
contentDisplay="RIGHT" layoutX="454.0" layoutY="130.0"
prefHeight="34.0" prefWidth="104.0" text="Kategorie 4:">
<Label fx:id="labelCat04" alignment="TOP_RIGHT" contentDisplay="RIGHT" layoutX="454.0" layoutY="130.0" prefHeight="34.0" prefWidth="104.0" text="Kategorie 4:">
<font>
<Font name="Cantarell Regular" size="18.0" />
</font>
</Label>
<Label fx:id="labelCat03" alignment="TOP_RIGHT"
contentDisplay="RIGHT" layoutX="451.0" layoutY="90.0"
prefHeight="34.0" prefWidth="107.0" text="Kategorie 3:">
<Label fx:id="labelCat03" alignment="TOP_RIGHT" contentDisplay="RIGHT" layoutX="451.0" layoutY="90.0" prefHeight="34.0" prefWidth="107.0" text="Kategorie 3:">
<font>
<Font name="Cantarell Regular" size="18.0" />
</font>
</Label>
<JFXTextField fx:id="tftKat01"
alignment="CENTER" layoutX="50.0" layoutY="5.0"
prefHeight="25.0" prefWidth="376.0" />
<JFXTextField fx:id="tftKat02"
alignment="CENTER" layoutX="50.0" layoutY="45.0"
prefHeight="25.0" prefWidth="376.0" />
<JFXTextField fx:id="tftKat03"
alignment="CENTER" layoutX="50.0" layoutY="85.0"
prefHeight="25.0" prefWidth="376.0" />
<JFXTextField fx:id="tftKat04"
alignment="CENTER" layoutX="50.0" layoutY="125.0"
prefHeight="25.0" prefWidth="376.0" />
<JFXTextField fx:id="tftKat05"
alignment="CENTER" layoutX="50.0" layoutY="165.0"
prefHeight="25.0" prefWidth="376.0" />
<Button fx:id="btnSaveCat" layoutX="200.0"
layoutY="204.0" mnemonicParsing="false"
onAction="#btnSaveCatAction" text="Kategorien speichern">
<JFXTextField fx:id="tftKat01" alignment="CENTER" layoutX="50.0" layoutY="5.0" prefHeight="25.0" prefWidth="376.0" />
<JFXTextField fx:id="tftKat02" alignment="CENTER" layoutX="50.0" layoutY="45.0" prefHeight="25.0" prefWidth="376.0" />
<JFXTextField fx:id="tftKat03" alignment="CENTER" layoutX="50.0" layoutY="85.0" prefHeight="25.0" prefWidth="376.0" />
<JFXTextField fx:id="tftKat04" alignment="CENTER" layoutX="50.0" layoutY="125.0" prefHeight="25.0" prefWidth="376.0" />
<JFXTextField fx:id="tftKat05" alignment="CENTER" layoutX="50.0" layoutY="165.0" prefHeight="25.0" prefWidth="376.0" />
<Button fx:id="btnSaveCat" layoutX="200.0" layoutY="204.0" mnemonicParsing="false" onAction="#btnSaveCatAction" text="Kategorien speichern">
<font>
<Font name="Cantarell Regular" size="13.0" />
</font>
@ -165,109 +110,66 @@
</Tab>
<Tab text="Positionen bearbeiten">
<content>
<AnchorPane minHeight="0.0" minWidth="0.0"
prefHeight="180.0" prefWidth="200.0">
<AnchorPane minHeight="0.0" minWidth="0.0" prefHeight="180.0" prefWidth="200.0">
<children>
<TreeTableView fx:id="entryTreeTable"
layoutX="11.0" layoutY="10.0" prefHeight="502.0"
prefWidth="1346.0">
<TreeTableView fx:id="entryTreeTable" layoutX="11.0" layoutY="10.0" prefHeight="502.0" prefWidth="1346.0">
<columns>
<TreeTableColumn fx:id="columnColor"
editable="false" maxWidth="237.3333740234375"
minWidth="164.0" prefWidth="164.0" resizable="false"
sortable="false" text="Farbe" />
<TreeTableColumn fx:id="columnCat"
editable="false" maxWidth="800.0"
minWidth="176.33331298828125" prefWidth="370.0"
resizable="false" sortable="false" text="Kategorie" />
<TreeTableColumn fx:id="columnPrize"
editable="false" maxWidth="693.3333129882812"
minWidth="44.33331298828125" prefWidth="126.66668701171875"
resizable="false" sortable="false" text="Preis" />
<TreeTableColumn fx:id="columnPositionsEdit"
editable="false" maxWidth="1581.6666870117188"
minWidth="38.0" prefWidth="543.3333129882812"
resizable="false" sortable="false" text="Positionen" />
<TreeTableColumn fx:id="columnPosnumber"
editable="false" maxWidth="1218.0" minWidth="60.666748046875"
prefWidth="148.6666259765625" resizable="false"
sortable="false" text="Nummer" />
<TreeTableColumn fx:id="columnColor" editable="false" maxWidth="428.0" minWidth="119.333251953125" prefWidth="119.333251953125" resizable="false" sortable="false" text="Farbe" />
<TreeTableColumn fx:id="columnCat" editable="false" maxWidth="800.0" minWidth="94.0" prefWidth="300.0" resizable="false" sortable="false" text="Kategorie" />
<TreeTableColumn fx:id="columnPrize" editable="false" maxWidth="693.3333129882812" minWidth="44.33331298828125" prefWidth="140.33331298828125" resizable="false" sortable="false" text="Preis" />
<TreeTableColumn fx:id="columnPositionsEdit" editable="false" maxWidth="1581.6666870117188" minWidth="38.0" prefWidth="596.333251953125" resizable="false" sortable="false" text="Positionen" />
<TreeTableColumn fx:id="columnPosnumber" editable="false" maxWidth="1218.0" minWidth="59.0" prefWidth="144.666748046875" resizable="false" sortable="false" text="Nummer" />
</columns>
<columnResizePolicy>
<TreeTableView
fx:constant="CONSTRAINED_RESIZE_POLICY" />
<TreeTableView fx:constant="CONSTRAINED_RESIZE_POLICY" />
</columnResizePolicy>
</TreeTableView>
<Button fx:id="btnSaveEntry" layoutX="494.0"
layoutY="631.0" mnemonicParsing="false"
onAction="#btnSaveEntryAction"
text="Ausgewählten Eintrag speichern">
<Button fx:id="btnSaveEntry" layoutX="494.0" layoutY="631.0" mnemonicParsing="false" onAction="#btnSaveEntryAction" text="Ausgewählten Eintrag speichern">
<font>
<Font name="Cantarell Regular" size="17.0" />
</font>
</Button>
<Button fx:id="btnClearEntry" layoutX="462.0"
layoutY="525.0" mnemonicParsing="false"
onAction="#btnClearEntryAction"
text="Ausgewählten Eintrag zurücksetzten">
<Button fx:id="btnClearEntry" layoutX="462.0" layoutY="525.0" mnemonicParsing="false" onAction="#btnClearEntryAction" text="Ausgewählten Eintrag zurücksetzten">
<font>
<Font name="Cantarell Regular" size="17.0" />
</font>
</Button>
<TitledPane fx:id="titledPaneEntry"
alignment="CENTER" animated="false" collapsible="false"
contentDisplay="CENTER" layoutX="792.0" layoutY="525.0"
prefHeight="163.0" prefWidth="565.0" text="Eintrag editieren">
<TitledPane fx:id="titledPaneEntry" alignment="CENTER" animated="false" collapsible="false" contentDisplay="CENTER" layoutX="792.0" layoutY="525.0" prefHeight="163.0" prefWidth="565.0" text="Eintrag editieren">
<content>
<AnchorPane minHeight="0.0" minWidth="0.0"
prefHeight="180.0" prefWidth="200.0">
<AnchorPane minHeight="0.0" minWidth="0.0" prefHeight="180.0" prefWidth="200.0">
<children>
<Label fx:id="lableNewPosition" alignment="TOP_RIGHT"
contentDisplay="RIGHT" layoutX="455.0" layoutY="10.0"
prefHeight="34.0" prefWidth="105.0" text="Position:">
<Label fx:id="lableNewPosition" alignment="TOP_RIGHT" contentDisplay="RIGHT" layoutX="455.0" layoutY="10.0" prefHeight="34.0" prefWidth="105.0" text="Position:">
<font>
<Font name="Cantarell Regular" size="18.0" />
</font>
</Label>
<JFXTextField fx:id="tftNewPosition"
alignment="CENTER" layoutX="160.0" layoutY="10.0"
prefHeight="25.0" prefWidth="279.0">
<JFXTextField fx:id="tftNewPosition" alignment="CENTER" layoutX="160.0" layoutY="10.0" prefHeight="25.0" prefWidth="279.0">
<font>
<Font name="Cantarell Regular" size="13.0" />
</font>
</JFXTextField>
<Label fx:id="labelNewValue" alignment="TOP_RIGHT"
contentDisplay="RIGHT" layoutX="442.0" layoutY="50.0"
prefHeight="34.0" prefWidth="118.0" text="Preis in Euro:">
<Label fx:id="labelNewValue" alignment="TOP_RIGHT" contentDisplay="RIGHT" layoutX="442.0" layoutY="50.0" prefHeight="34.0" prefWidth="118.0" text="Preis in Euro:">
<font>
<Font name="Cantarell Regular" size="18.0" />
</font>
</Label>
<JFXTextField fx:id="tftNewValue"
alignment="CENTER" layoutX="380.0" layoutY="50.0"
prefHeight="25.0" prefWidth="58.0">
<JFXTextField fx:id="tftNewValue" alignment="CENTER" layoutX="380.0" layoutY="50.0" prefHeight="25.0" prefWidth="58.0">
<font>
<Font name="Cantarell Regular" size="13.0" />
</font>
</JFXTextField>
<Label fx:id="lableNewColor" alignment="TOP_RIGHT"
contentDisplay="RIGHT" layoutX="455.0" layoutY="90.0"
prefHeight="34.0" prefWidth="105.0" text="Farbe:">
<Label fx:id="lableNewColor" alignment="TOP_RIGHT" contentDisplay="RIGHT" layoutX="455.0" layoutY="90.0" prefHeight="34.0" prefWidth="105.0" text="Farbe:">
<font>
<Font name="Cantarell Regular" size="18.0" />
</font>
</Label>
<ChoiceBox fx:id="colorChoise" layoutX="346.0"
layoutY="90.0" prefHeight="25.0" prefWidth="96.0" />
<Label fx:id="lableSelectCat" alignment="TOP_RIGHT"
contentDisplay="RIGHT" layoutX="204.0" layoutY="90.0"
prefHeight="34.0" prefWidth="105.0" text="Kategorie:">
<ChoiceBox fx:id="colorChoise" layoutX="346.0" layoutY="90.0" prefHeight="25.0" prefWidth="96.0" />
<Label fx:id="lableSelectCat" alignment="TOP_RIGHT" contentDisplay="RIGHT" layoutX="204.0" layoutY="90.0" prefHeight="34.0" prefWidth="105.0" text="Kategorie:">
<font>
<Font name="Cantarell Regular" size="18.0" />
</font>
</Label>
<ChoiceBox fx:id="catChoise" layoutX="25.0"
layoutY="90.0" prefHeight="25.0" prefWidth="180.0" />
<ChoiceBox fx:id="catChoise" layoutX="25.0" layoutY="90.0" prefHeight="25.0" prefWidth="180.0" />
</children>
</AnchorPane>
</content>
@ -281,65 +183,37 @@
</Tab>
<Tab text="Aufträge">
<content>
<AnchorPane minHeight="0.0" minWidth="0.0"
prefHeight="850.0" prefWidth="1536.0">
<AnchorPane minHeight="0.0" minWidth="0.0" prefHeight="850.0" prefWidth="1536.0">
<children>
<TreeTableView fx:id="jobsTreeTable"
layoutX="11.0" layoutY="10.0" prefHeight="541.0"
prefWidth="1346.0">
<TreeTableView fx:id="jobsTreeTable" layoutX="11.0" layoutY="10.0" prefHeight="541.0" prefWidth="1346.0">
<columns>
<TreeTableColumn fx:id="columnJobValue"
editable="false" prefWidth="90.6666259765625"
resizable="false" text="Betrag" />
<TreeTableColumn fx:id="columnState"
editable="false" prefWidth="91.0" resizable="false"
text="Zustand" />
<TreeTableColumn fx:id="columnPositions"
editable="false" prefWidth="981.333251953125"
resizable="false" sortable="false" text="Positionen" />
<TreeTableColumn fx:id="columnTime"
editable="false" prefWidth="99.666748046875"
resizable="false" text="Zeit" />
<TreeTableColumn fx:id="columnJobNumber"
editable="false" maxWidth="3000.0"
prefWidth="83.6666259765625" resizable="false" text="Nummer" />
<TreeTableColumn fx:id="columnJobValue" editable="false" prefWidth="90.6666259765625" resizable="false" text="Betrag" />
<TreeTableColumn fx:id="columnState" editable="false" prefWidth="91.0" resizable="false" text="Zustand" />
<TreeTableColumn fx:id="columnPositions" editable="false" prefWidth="981.333251953125" resizable="false" sortable="false" text="Positionen" />
<TreeTableColumn fx:id="columnTime" editable="false" prefWidth="99.666748046875" resizable="false" text="Zeit" />
<TreeTableColumn fx:id="columnJobNumber" editable="false" maxWidth="3000.0" prefWidth="83.6666259765625" resizable="false" text="Nummer" />
</columns>
</TreeTableView>
<Button fx:id="btnReprintJob" layoutX="378.0"
layoutY="603.0" mnemonicParsing="false"
onAction="#btnReprintJobAction"
text="Ausgewählter Auftrag drucken">
<Button fx:id="btnReprintJob" layoutX="378.0" layoutY="603.0" mnemonicParsing="false" onAction="#btnReprintJobAction" text="Ausgewählter Auftrag drucken">
<font>
<Font name="Cantarell Regular" size="17.0" />
</font>
</Button>
<TitledPane fx:id="titlePaneStats" alignment="CENTER"
collapsible="false" contentDisplay="CENTER" layoutX="992.0"
layoutY="561.0" prefHeight="118.0" prefWidth="365.0"
text="Statistik - 30.03.2018 15:15 Uhr">
<TitledPane fx:id="titlePaneStats" alignment="CENTER" collapsible="false" contentDisplay="CENTER" layoutX="992.0" layoutY="561.0" prefHeight="118.0" prefWidth="365.0" text="Statistik - 30.03.2018 15:15 Uhr">
<content>
<AnchorPane minHeight="0.0" minWidth="0.0"
prefHeight="59.0" prefWidth="483.0">
<AnchorPane minHeight="0.0" minWidth="0.0" prefHeight="59.0" prefWidth="483.0">
<children>
<Label fx:id="lableJobCount" alignment="TOP_RIGHT"
contentDisplay="RIGHT" layoutX="17.0" layoutY="2.0"
prefHeight="34.0" prefWidth="340.0"
text="Anzahl Aufträge: 2781">
<Label fx:id="lableJobCount" alignment="TOP_RIGHT" contentDisplay="RIGHT" layoutX="17.0" layoutY="2.0" prefHeight="34.0" prefWidth="340.0" text="Anzahl Aufträge: 2781">
<font>
<Font name="Cantarell Regular" size="18.0" />
</font>
</Label>
<Label fx:id="labelAvgJob" alignment="TOP_RIGHT"
contentDisplay="RIGHT" layoutX="17.0" layoutY="30.0"
prefHeight="34.0" prefWidth="340.0"
text="Durchschnittlicher Auftragswert: 12,90€">
<Label fx:id="labelAvgJob" alignment="TOP_RIGHT" contentDisplay="RIGHT" layoutX="17.0" layoutY="30.0" prefHeight="34.0" prefWidth="340.0" text="Durchschnittlicher Auftragswert: 12,90€">
<font>
<Font name="Cantarell Regular" size="18.0" />
</font>
</Label>
<Label fx:id="lableAllValue" alignment="TOP_RIGHT"
contentDisplay="RIGHT" layoutX="17.0" layoutY="60.0"
prefHeight="34.0" prefWidth="340.0" text="Gesamt: 1088,48€">
<Label fx:id="lableAllValue" alignment="TOP_RIGHT" contentDisplay="RIGHT" layoutX="17.0" layoutY="60.0" prefHeight="34.0" prefWidth="340.0" text="Gesamt: 1088,48€">
<font>
<Font name="Cantarell Regular" size="18.0" />
</font>
@ -348,17 +222,12 @@
</AnchorPane>
</content>
</TitledPane>
<Button fx:id="btnCancelJob" layoutX="44.0"
layoutY="603.0" mnemonicParsing="false"
onAction="#btnCancelJobAction"
text="Ausgewählter Auftrag stornieren">
<Button fx:id="btnCancelJob" layoutX="44.0" layoutY="603.0" mnemonicParsing="false" onAction="#btnCancelJobAction" text="Ausgewählter Auftrag stornieren">
<font>
<Font name="Cantarell Regular" size="17.0" />
</font>
</Button>
<Button fx:id="btnCalcStats" layoutX="712.0"
layoutY="603.0" mnemonicParsing="false"
onAction="#btnCalcStatsAction" text="Statistiken berrechnen">
<Button fx:id="btnCalcStats" layoutX="712.0" layoutY="603.0" mnemonicParsing="false" onAction="#btnCalcStatsAction" text="Statistiken berrechnen">
<font>
<Font name="Cantarell Regular" size="17.0" />
</font>
@ -369,350 +238,188 @@
</Tab>
<Tab text="Neuer Auftrag">
<content>
<AnchorPane minHeight="0.0" minWidth="0.0"
prefHeight="850.0" prefWidth="1536.0">
<AnchorPane minHeight="0.0" minWidth="0.0" prefHeight="850.0" prefWidth="1536.0">
<children>
<TreeTableView fx:id="tableCurrentOrder"
layoutX="15.0" layoutY="85.0" prefHeight="379.0"
prefWidth="382.0">
<TreeTableView fx:id="tableCurrentOrder" layoutX="15.0" layoutY="85.0" prefHeight="379.0" prefWidth="382.0">
<columns>
<TreeTableColumn fx:id="columnPosition"
editable="false" prefWidth="304.3333740234375"
resizable="false" sortable="false" text="Position" />
<TreeTableColumn fx:id="columnQuantity"
editable="false" prefWidth="80.6666259765625"
resizable="false" sortable="false" text="Anzahl" />
<TreeTableColumn fx:id="columnPosition" editable="false" prefWidth="282.3333740234375" resizable="false" sortable="false" text="Position" />
<TreeTableColumn fx:id="columnQuantity" editable="false" prefWidth="81.66668701171875" resizable="false" sortable="false" text="Anzahl" />
</columns>
</TreeTableView>
<GridPane gridLinesVisible="true" layoutX="430.0"
layoutY="15.0" prefHeight="670.0" prefWidth="920.0">
<GridPane gridLinesVisible="true" layoutX="430.0" layoutY="15.0" prefHeight="670.0" prefWidth="920.0">
<columnConstraints>
<ColumnConstraints hgrow="SOMETIMES"
minWidth="10.0" prefWidth="100.0" />
<ColumnConstraints hgrow="SOMETIMES"
minWidth="10.0" prefWidth="100.0" />
<ColumnConstraints hgrow="SOMETIMES"
minWidth="10.0" prefWidth="100.0" />
<ColumnConstraints hgrow="SOMETIMES"
minWidth="10.0" prefWidth="100.0" />
<ColumnConstraints hgrow="SOMETIMES"
minWidth="10.0" prefWidth="100.0" />
<ColumnConstraints hgrow="SOMETIMES" minWidth="10.0" prefWidth="100.0" />
<ColumnConstraints hgrow="SOMETIMES" minWidth="10.0" prefWidth="100.0" />
<ColumnConstraints hgrow="SOMETIMES" minWidth="10.0" prefWidth="100.0" />
<ColumnConstraints hgrow="SOMETIMES" minWidth="10.0" prefWidth="100.0" />
<ColumnConstraints hgrow="SOMETIMES" minWidth="10.0" prefWidth="100.0" />
</columnConstraints>
<rowConstraints>
<RowConstraints minHeight="10.0"
prefHeight="30.0" vgrow="SOMETIMES" />
<RowConstraints minHeight="10.0"
prefHeight="30.0" vgrow="SOMETIMES" />
<RowConstraints minHeight="10.0"
prefHeight="30.0" vgrow="SOMETIMES" />
<RowConstraints minHeight="10.0"
prefHeight="30.0" vgrow="SOMETIMES" />
<RowConstraints minHeight="10.0"
prefHeight="30.0" vgrow="SOMETIMES" />
<RowConstraints minHeight="10.0" prefHeight="30.0" vgrow="SOMETIMES" />
<RowConstraints minHeight="10.0" prefHeight="30.0" vgrow="SOMETIMES" />
<RowConstraints minHeight="10.0" prefHeight="30.0" vgrow="SOMETIMES" />
<RowConstraints minHeight="10.0" prefHeight="30.0" vgrow="SOMETIMES" />
<RowConstraints minHeight="10.0" prefHeight="30.0" vgrow="SOMETIMES" />
</rowConstraints>
<children>
<JFXButton fx:id="gridButton04" buttonType="RAISED"
maxWidth="235.0" minWidth="179.0"
onAction="#gridButton04Action" prefHeight="169.0"
prefWidth="235.0" ripplerFill="#655252" text="leer 0,00€"
textAlignment="CENTER" wrapText="true"
GridPane.columnIndex="1">
<JFXButton fx:id="gridButton04" buttonType="RAISED" maxWidth="235.0" minWidth="179.0" onAction="#gridButton04Action" prefHeight="169.0" prefWidth="235.0" ripplerFill="#655252" text="leer 0,00€" textAlignment="CENTER" wrapText="true" GridPane.columnIndex="1">
<font>
<Font name="Cantarell Regular" size="24.0" />
</font>
</JFXButton>
<JFXButton fx:id="gridButton05" buttonType="RAISED"
maxWidth="235.0" minWidth="179.0"
onAction="#gridButton05Action" prefHeight="169.0"
prefWidth="235.0" ripplerFill="#655252" text="leer 0,00€"
textAlignment="CENTER" wrapText="true">
<JFXButton fx:id="gridButton05" buttonType="RAISED" maxWidth="235.0" minWidth="179.0" onAction="#gridButton05Action" prefHeight="169.0" prefWidth="235.0" ripplerFill="#655252" text="leer 0,00€" textAlignment="CENTER" wrapText="true">
<font>
<Font name="Cantarell Regular" size="24.0" />
</font>
</JFXButton>
<JFXButton fx:id="gridButton03" buttonType="RAISED"
maxWidth="235.0" minWidth="179.0"
onAction="#gridButton03Action" prefHeight="169.0"
prefWidth="235.0" ripplerFill="#655252" text="leer 0,00€"
textAlignment="CENTER" wrapText="true"
GridPane.columnIndex="2">
<JFXButton fx:id="gridButton03" buttonType="RAISED" maxWidth="235.0" minWidth="179.0" onAction="#gridButton03Action" prefHeight="169.0" prefWidth="235.0" ripplerFill="#655252" text="leer 0,00€" textAlignment="CENTER" wrapText="true" GridPane.columnIndex="2">
<font>
<Font name="Cantarell Regular" size="24.0" />
</font>
</JFXButton>
<JFXButton fx:id="gridButton02" buttonType="RAISED"
maxWidth="235.0" minWidth="179.0"
onAction="#gridButton02Action" prefHeight="169.0"
prefWidth="235.0" ripplerFill="#655252" text="leer 0,00€"
textAlignment="CENTER" wrapText="true"
GridPane.columnIndex="3">
<JFXButton fx:id="gridButton02" buttonType="RAISED" maxWidth="235.0" minWidth="179.0" onAction="#gridButton02Action" prefHeight="169.0" prefWidth="235.0" ripplerFill="#655252" text="leer 0,00€" textAlignment="CENTER" wrapText="true" GridPane.columnIndex="3">
<font>
<Font name="Cantarell Regular" size="24.0" />
</font>
</JFXButton>
<JFXButton fx:id="gridButton01" buttonType="RAISED"
maxWidth="235.0" minWidth="179.0"
onAction="#gridButton01Action" prefHeight="134.0"
prefWidth="179.0" ripplerFill="#655252" text="leer 0,00€"
textAlignment="CENTER" wrapText="true"
GridPane.columnIndex="4">
<JFXButton fx:id="gridButton01" buttonType="RAISED" maxWidth="235.0" minWidth="179.0" onAction="#gridButton01Action" prefHeight="134.0" prefWidth="179.0" ripplerFill="#655252" text="leer 0,00€" textAlignment="CENTER" wrapText="true" GridPane.columnIndex="4">
<font>
<Font name="Cantarell Regular" size="24.0" />
</font>
</JFXButton>
<JFXButton fx:id="gridButton10" buttonType="RAISED"
maxWidth="235.0" minWidth="179.0"
onAction="#gridButton10Action" prefHeight="169.0"
prefWidth="235.0" ripplerFill="#655252" text="leer 0,00€"
textAlignment="CENTER" wrapText="true" GridPane.rowIndex="1">
<JFXButton fx:id="gridButton10" buttonType="RAISED" maxWidth="235.0" minWidth="179.0" onAction="#gridButton10Action" prefHeight="169.0" prefWidth="235.0" ripplerFill="#655252" text="leer 0,00€" textAlignment="CENTER" wrapText="true" GridPane.rowIndex="1">
<font>
<Font name="Cantarell Regular" size="24.0" />
</font>
</JFXButton>
<JFXButton fx:id="gridButton09" buttonType="RAISED"
maxWidth="235.0" minWidth="179.0"
onAction="#gridButton09Action" prefHeight="169.0"
prefWidth="235.0" ripplerFill="#655252" text="leer 0,00€"
textAlignment="CENTER" wrapText="true"
GridPane.columnIndex="1" GridPane.rowIndex="1">
<JFXButton fx:id="gridButton09" buttonType="RAISED" maxWidth="235.0" minWidth="179.0" onAction="#gridButton09Action" prefHeight="169.0" prefWidth="235.0" ripplerFill="#655252" text="leer 0,00€" textAlignment="CENTER" wrapText="true" GridPane.columnIndex="1" GridPane.rowIndex="1">
<font>
<Font name="Cantarell Regular" size="24.0" />
</font>
</JFXButton>
<JFXButton fx:id="gridButton08" buttonType="RAISED"
maxWidth="235.0" minWidth="179.0"
onAction="#gridButton08Action" prefHeight="169.0"
prefWidth="235.0" ripplerFill="#655252" text="leer 0,00€"
textAlignment="CENTER" wrapText="true"
GridPane.columnIndex="2" GridPane.rowIndex="1">
<JFXButton fx:id="gridButton08" buttonType="RAISED" maxWidth="235.0" minWidth="179.0" onAction="#gridButton08Action" prefHeight="169.0" prefWidth="235.0" ripplerFill="#655252" text="leer 0,00€" textAlignment="CENTER" wrapText="true" GridPane.columnIndex="2" GridPane.rowIndex="1">
<font>
<Font name="Cantarell Regular" size="24.0" />
</font>
</JFXButton>
<JFXButton fx:id="gridButton07" buttonType="RAISED"
maxWidth="235.0" minWidth="179.0"
onAction="#gridButton07Action" prefHeight="169.0"
prefWidth="235.0" ripplerFill="#655252" text="leer 0,00€"
textAlignment="CENTER" wrapText="true"
GridPane.columnIndex="3" GridPane.rowIndex="1">
<JFXButton fx:id="gridButton07" buttonType="RAISED" maxWidth="235.0" minWidth="179.0" onAction="#gridButton07Action" prefHeight="169.0" prefWidth="235.0" ripplerFill="#655252" text="leer 0,00€" textAlignment="CENTER" wrapText="true" GridPane.columnIndex="3" GridPane.rowIndex="1">
<font>
<Font name="Cantarell Regular" size="24.0" />
</font>
</JFXButton>
<JFXButton fx:id="gridButton06" buttonType="RAISED"
maxWidth="235.0" minWidth="179.0"
onAction="#gridButton06Action" prefHeight="169.0"
prefWidth="235.0" ripplerFill="#655252" text="leer 0,00€"
textAlignment="CENTER" wrapText="true"
GridPane.columnIndex="4" GridPane.rowIndex="1">
<JFXButton fx:id="gridButton06" buttonType="RAISED" maxWidth="235.0" minWidth="179.0" onAction="#gridButton06Action" prefHeight="169.0" prefWidth="235.0" ripplerFill="#655252" text="leer 0,00€" textAlignment="CENTER" wrapText="true" GridPane.columnIndex="4" GridPane.rowIndex="1">
<font>
<Font name="Cantarell Regular" size="24.0" />
</font>
</JFXButton>
<JFXButton fx:id="gridButton15" buttonType="RAISED"
maxWidth="235.0" minWidth="179.0"
onAction="#gridButton15Action" prefHeight="169.0"
prefWidth="235.0" ripplerFill="#655252" text="leer 0,00€"
textAlignment="CENTER" wrapText="true" GridPane.rowIndex="2">
<JFXButton fx:id="gridButton15" buttonType="RAISED" maxWidth="235.0" minWidth="179.0" onAction="#gridButton15Action" prefHeight="169.0" prefWidth="235.0" ripplerFill="#655252" text="leer 0,00€" textAlignment="CENTER" wrapText="true" GridPane.rowIndex="2">
<font>
<Font name="Cantarell Regular" size="24.0" />
</font>
</JFXButton>
<JFXButton fx:id="gridButton14" buttonType="RAISED"
maxWidth="235.0" minWidth="179.0"
onAction="#gridButton14Action" prefHeight="169.0"
prefWidth="235.0" ripplerFill="#655252" text="leer 0,00€"
textAlignment="CENTER" wrapText="true"
GridPane.columnIndex="1" GridPane.rowIndex="2">
<JFXButton fx:id="gridButton14" buttonType="RAISED" maxWidth="235.0" minWidth="179.0" onAction="#gridButton14Action" prefHeight="169.0" prefWidth="235.0" ripplerFill="#655252" text="leer 0,00€" textAlignment="CENTER" wrapText="true" GridPane.columnIndex="1" GridPane.rowIndex="2">
<font>
<Font name="Cantarell Regular" size="24.0" />
</font>
</JFXButton>
<JFXButton fx:id="gridButton13" buttonType="RAISED"
maxWidth="235.0" minWidth="179.0"
onAction="#gridButton13Action" prefHeight="169.0"
prefWidth="235.0" ripplerFill="#655252" text="leer 0,00€"
textAlignment="CENTER" wrapText="true"
GridPane.columnIndex="2" GridPane.rowIndex="2">
<JFXButton fx:id="gridButton13" buttonType="RAISED" maxWidth="235.0" minWidth="179.0" onAction="#gridButton13Action" prefHeight="169.0" prefWidth="235.0" ripplerFill="#655252" text="leer 0,00€" textAlignment="CENTER" wrapText="true" GridPane.columnIndex="2" GridPane.rowIndex="2">
<font>
<Font name="Cantarell Regular" size="24.0" />
</font>
</JFXButton>
<JFXButton fx:id="gridButton12" buttonType="RAISED"
maxWidth="235.0" minWidth="179.0"
onAction="#gridButton12Action" prefHeight="169.0"
prefWidth="235.0" ripplerFill="#655252" text="leer 0,00€"
textAlignment="CENTER" wrapText="true"
GridPane.columnIndex="3" GridPane.rowIndex="2">
<JFXButton fx:id="gridButton12" buttonType="RAISED" maxWidth="235.0" minWidth="179.0" onAction="#gridButton12Action" prefHeight="169.0" prefWidth="235.0" ripplerFill="#655252" text="leer 0,00€" textAlignment="CENTER" wrapText="true" GridPane.columnIndex="3" GridPane.rowIndex="2">
<font>
<Font name="Cantarell Regular" size="24.0" />
</font>
</JFXButton>
<JFXButton fx:id="gridButton11" buttonType="RAISED"
maxWidth="235.0" minWidth="179.0"
onAction="#gridButton11Action" prefHeight="169.0"
prefWidth="235.0" ripplerFill="#655252" text="leer 0,00€"
textAlignment="CENTER" wrapText="true"
GridPane.columnIndex="4" GridPane.rowIndex="2">
<JFXButton fx:id="gridButton11" buttonType="RAISED" maxWidth="235.0" minWidth="179.0" onAction="#gridButton11Action" prefHeight="169.0" prefWidth="235.0" ripplerFill="#655252" text="leer 0,00€" textAlignment="CENTER" wrapText="true" GridPane.columnIndex="4" GridPane.rowIndex="2">
<font>
<Font name="Cantarell Regular" size="24.0" />
</font>
</JFXButton>
<JFXButton fx:id="gridButton20" buttonType="RAISED"
maxWidth="235.0" minWidth="179.0"
onAction="#gridButton20Action" prefHeight="169.0"
prefWidth="235.0" ripplerFill="#655252" text="leer 0,00€"
textAlignment="CENTER" wrapText="true" GridPane.rowIndex="3">
<JFXButton fx:id="gridButton20" buttonType="RAISED" maxWidth="235.0" minWidth="179.0" onAction="#gridButton20Action" prefHeight="169.0" prefWidth="235.0" ripplerFill="#655252" text="leer 0,00€" textAlignment="CENTER" wrapText="true" GridPane.rowIndex="3">
<font>
<Font name="Cantarell Regular" size="24.0" />
</font>
</JFXButton>
<JFXButton fx:id="gridButton19" buttonType="RAISED"
maxWidth="235.0" minWidth="179.0"
onAction="#gridButton19Action" prefHeight="169.0"
prefWidth="235.0" ripplerFill="#655252" text="leer 0,00€"
textAlignment="CENTER" wrapText="true"
GridPane.columnIndex="1" GridPane.rowIndex="3">
<JFXButton fx:id="gridButton19" buttonType="RAISED" maxWidth="235.0" minWidth="179.0" onAction="#gridButton19Action" prefHeight="169.0" prefWidth="235.0" ripplerFill="#655252" text="leer 0,00€" textAlignment="CENTER" wrapText="true" GridPane.columnIndex="1" GridPane.rowIndex="3">
<font>
<Font name="Cantarell Regular" size="24.0" />
</font>
</JFXButton>
<JFXButton fx:id="gridButton18" buttonType="RAISED"
maxWidth="235.0" minWidth="179.0"
onAction="#gridButton18Action" prefHeight="169.0"
prefWidth="235.0" ripplerFill="#655252" text="leer 0,00€"
textAlignment="CENTER" wrapText="true"
GridPane.columnIndex="2" GridPane.rowIndex="3">
<JFXButton fx:id="gridButton18" buttonType="RAISED" maxWidth="235.0" minWidth="179.0" onAction="#gridButton18Action" prefHeight="169.0" prefWidth="235.0" ripplerFill="#655252" text="leer 0,00€" textAlignment="CENTER" wrapText="true" GridPane.columnIndex="2" GridPane.rowIndex="3">
<font>
<Font name="Cantarell Regular" size="24.0" />
</font>
</JFXButton>
<JFXButton fx:id="gridButton17" buttonType="RAISED"
maxWidth="235.0" minWidth="179.0"
onAction="#gridButton17Action" prefHeight="169.0"
prefWidth="235.0" ripplerFill="#655252" text="leer 0,00€"
textAlignment="CENTER" wrapText="true"
GridPane.columnIndex="3" GridPane.rowIndex="3">
<JFXButton fx:id="gridButton17" buttonType="RAISED" maxWidth="235.0" minWidth="179.0" onAction="#gridButton17Action" prefHeight="169.0" prefWidth="235.0" ripplerFill="#655252" text="leer 0,00€" textAlignment="CENTER" wrapText="true" GridPane.columnIndex="3" GridPane.rowIndex="3">
<font>
<Font name="Cantarell Regular" size="24.0" />
</font>
</JFXButton>
<JFXButton fx:id="gridButton16" buttonType="RAISED"
maxWidth="235.0" minWidth="179.0"
onAction="#gridButton16Action" prefHeight="169.0"
prefWidth="235.0" ripplerFill="#655252" text="leer 0,00€"
textAlignment="CENTER" wrapText="true"
GridPane.columnIndex="4" GridPane.rowIndex="3">
<JFXButton fx:id="gridButton16" buttonType="RAISED" maxWidth="235.0" minWidth="179.0" onAction="#gridButton16Action" prefHeight="169.0" prefWidth="235.0" ripplerFill="#655252" text="leer 0,00€" textAlignment="CENTER" wrapText="true" GridPane.columnIndex="4" GridPane.rowIndex="3">
<font>
<Font name="Cantarell Regular" size="24.0" />
</font>
</JFXButton>
<JFXButton fx:id="gridButton25" buttonType="RAISED"
maxWidth="235.0" minWidth="179.0"
onAction="#gridButton25Action" prefHeight="169.0"
prefWidth="235.0" ripplerFill="#655252" text="leer 0,00€"
textAlignment="CENTER" wrapText="true" GridPane.rowIndex="4">
<JFXButton fx:id="gridButton25" buttonType="RAISED" maxWidth="235.0" minWidth="179.0" onAction="#gridButton25Action" prefHeight="169.0" prefWidth="235.0" ripplerFill="#655252" text="leer 0,00€" textAlignment="CENTER" wrapText="true" GridPane.rowIndex="4">
<font>
<Font name="Cantarell Regular" size="24.0" />
</font>
</JFXButton>
<JFXButton fx:id="gridButton23" buttonType="RAISED"
maxWidth="235.0" minWidth="179.0"
onAction="#gridButton23Action" prefHeight="169.0"
prefWidth="235.0" ripplerFill="#655252" text="leer 0,00€"
textAlignment="CENTER" wrapText="true"
GridPane.columnIndex="2" GridPane.rowIndex="4">
<JFXButton fx:id="gridButton23" buttonType="RAISED" maxWidth="235.0" minWidth="179.0" onAction="#gridButton23Action" prefHeight="169.0" prefWidth="235.0" ripplerFill="#655252" text="leer 0,00€" textAlignment="CENTER" wrapText="true" GridPane.columnIndex="2" GridPane.rowIndex="4">
<font>
<Font name="Cantarell Regular" size="24.0" />
</font>
</JFXButton>
<JFXButton fx:id="gridButton22" buttonType="RAISED"
maxWidth="235.0" minWidth="179.0"
onAction="#gridButton22Action" prefHeight="169.0"
prefWidth="235.0" ripplerFill="#655252" text="leer 0,00€"
textAlignment="CENTER" wrapText="true"
GridPane.columnIndex="3" GridPane.rowIndex="4">
<JFXButton fx:id="gridButton22" buttonType="RAISED" maxWidth="235.0" minWidth="179.0" onAction="#gridButton22Action" prefHeight="169.0" prefWidth="235.0" ripplerFill="#655252" text="leer 0,00€" textAlignment="CENTER" wrapText="true" GridPane.columnIndex="3" GridPane.rowIndex="4">
<font>
<Font name="Cantarell Regular" size="24.0" />
</font>
</JFXButton>
<JFXButton fx:id="gridButton21" buttonType="RAISED"
maxWidth="235.0" minWidth="179.0"
onAction="#gridButton21Action" prefHeight="169.0"
prefWidth="235.0" ripplerFill="#655252" text="leer 0,00€"
textAlignment="CENTER" wrapText="true"
GridPane.columnIndex="4" GridPane.rowIndex="4">
<JFXButton fx:id="gridButton21" buttonType="RAISED" maxWidth="235.0" minWidth="179.0" onAction="#gridButton21Action" prefHeight="169.0" prefWidth="235.0" ripplerFill="#655252" text="leer 0,00€" textAlignment="CENTER" wrapText="true" GridPane.columnIndex="4" GridPane.rowIndex="4">
<font>
<Font name="Cantarell Regular" size="24.0" />
</font>
</JFXButton>
<JFXButton fx:id="gridButton24" buttonType="RAISED"
maxWidth="235.0" minWidth="179.0"
onAction="#gridButton24Action" prefHeight="169.0"
prefWidth="235.0" ripplerFill="#655252" text="leer 0,00€"
textAlignment="CENTER" wrapText="true"
GridPane.columnIndex="1" GridPane.rowIndex="4">
<JFXButton fx:id="gridButton24" buttonType="RAISED" maxWidth="235.0" minWidth="179.0" onAction="#gridButton24Action" prefHeight="169.0" prefWidth="235.0" ripplerFill="#655252" text="leer 0,00€" textAlignment="CENTER" wrapText="true" GridPane.columnIndex="1" GridPane.rowIndex="4">
<font>
<Font name="Cantarell Regular" size="24.0" />
</font>
</JFXButton>
</children>
</GridPane>
<Button fx:id="btnPrintBill" contentDisplay="CENTER"
defaultButton="true" graphicTextGap="1.0" layoutX="75.0"
layoutY="599.0" maxHeight="88.0" minHeight="75.0"
mnemonicParsing="false" onAction="#btnPrintBillAction"
prefHeight="88.0" prefWidth="258.0" text="Drucken"
wrapText="true">
<Button fx:id="btnPrintBill" contentDisplay="CENTER" defaultButton="true" graphicTextGap="1.0" layoutX="75.0" layoutY="599.0" maxHeight="88.0" minHeight="75.0" mnemonicParsing="false" onAction="#btnPrintBillAction" prefHeight="88.0" prefWidth="258.0" text="Drucken" wrapText="true">
<font>
<Font name="Cantarell Bold" size="48.0" />
</font>
</Button>
<Button fx:id="btnDeleteSelectedPosition" layoutX="43.0"
layoutY="475.0" mnemonicParsing="false"
onAction="#btnDeleteSelectedPositionAction" prefHeight="17.0"
prefWidth="332.0" text="Ausgewählte Position löschen"
textAlignment="CENTER">
<Button fx:id="btnDeleteSelectedPosition" layoutX="43.0" layoutY="475.0" mnemonicParsing="false" onAction="#btnDeleteSelectedPositionAction" prefHeight="17.0" prefWidth="332.0" text="Ausgewählte Position löschen" textAlignment="CENTER">
<font>
<Font name="Cantarell Regular" size="20.0" />
</font>
</Button>
<Label fx:id="labelAllPrize" alignment="CENTER"
contentDisplay="CENTER" layoutX="10.0" layoutY="505.0"
prefHeight="15.0" prefWidth="386.0" text="0,00 €"
textAlignment="CENTER">
<Label fx:id="labelAllPrize" alignment="CENTER" contentDisplay="CENTER" layoutX="10.0" layoutY="505.0" prefHeight="15.0" prefWidth="386.0" text="0,00 €" textAlignment="CENTER">
<font>
<Font name="Open Sans" size="70.0" />
</font>
</Label>
<Label fx:id="labelJobCounter" alignment="TOP_RIGHT"
contentDisplay="CENTER" layoutX="5.0" layoutY="45.0"
prefHeight="34.0" prefWidth="392.0" text="Auftragsnummer: 0"
textAlignment="CENTER">
<Label fx:id="labelJobCounter" alignment="TOP_RIGHT" contentDisplay="CENTER" layoutX="5.0" layoutY="45.0" prefHeight="34.0" prefWidth="392.0" text="Auftragsnummer: 0" textAlignment="CENTER">
<font>
<Font name="Cantarell Regular" size="26.0" />
</font>
</Label>
<Label fx:id="labelTime" alignment="TOP_RIGHT"
layoutX="7.0" layoutY="11.0" maxHeight="33.0" maxWidth="392.0"
minHeight="33.0" minWidth="392.0" prefHeight="33.0"
prefWidth="392.0" text="Uhrzeit: 12:15">
<Label fx:id="labelTime" alignment="TOP_RIGHT" layoutX="7.0" layoutY="11.0" maxHeight="33.0" maxWidth="392.0" minHeight="33.0" minWidth="392.0" prefHeight="33.0" prefWidth="392.0" text="Uhrzeit: 12:15">
<font>
<Font name="Cantarell Regular" size="26.0" />
</font>
</Label>
<JFXButton fx:id="btnLock" buttonType="RAISED"
cancelButton="true" layoutX="1.0" layoutY="6.0"
lineSpacing="2.0" onAction="#btnLockAction" prefHeight="42.0"
prefWidth="180.0" ripplerFill="BLACK" text="Kasse sperren"
textAlignment="CENTER" textFill="#c91c1c"
textOverrun="LEADING_WORD_ELLIPSIS">
<JFXButton fx:id="btnLock" buttonType="RAISED" cancelButton="true" layoutX="1.0" layoutY="6.0" lineSpacing="2.0" onAction="#btnLockAction" prefHeight="42.0" prefWidth="180.0" ripplerFill="BLACK" text="Kasse sperren" textAlignment="CENTER" textFill="#c91c1c" textOverrun="LEADING_WORD_ELLIPSIS">
<font>
<Font name="Cantarell Regular" size="19.0" />
</font>
</JFXButton>
<Line endX="800.0" layoutX="62.0" layoutY="465.0"
rotate="90.0" startX="-100.0" strokeWidth="4.0" />
<Line endX="800.0" layoutX="62.0" layoutY="465.0" rotate="90.0" startX="-100.0" strokeWidth="4.0" />
</children>
</AnchorPane>
</content>

View File

@ -35,7 +35,6 @@ import javafx.scene.control.Label;
import javafx.scene.layout.AnchorPane;
import javafx.scene.layout.GridPane;
import javafx.util.Pair;
import sun.jvm.hotspot.tools.SysPropsDumper;
public class MainWindowController
{
@ -51,38 +50,38 @@ public class MainWindowController
private AnchorPane paneDB;
@FXML
private TreeTableView<tableData> tableCurrentOrder;
private TreeTableView<tableDataCurrentOrder> tableCurrentOrder;
@FXML
private TreeTableColumn<tableData, String> columnQuantity;
private TreeTableColumn<tableDataCurrentOrder, Integer> columnQuantity;
@FXML
private TreeTableColumn<tableData, String> columnPosition;
private TreeTableColumn<tableDataCurrentOrder, String> columnPosition;
@FXML
private TreeTableColumn<tableData, Integer> idSpalte01 = new TreeTableColumn<>(
private TreeTableColumn<tableDataCurrentOrder, Integer> idSpalte01 = new TreeTableColumn<>(
"tableCurrentOrder");
@FXML
private TreeTableView<tableData> jobsTreeTable;
private TreeTableView<tableDataJob> jobsTreeTable;
@FXML
private TreeTableColumn<tableData, String> columnJobValue;
private TreeTableColumn<tableDataJob, String> columnJobValue;
@FXML
private TreeTableColumn<tableData, String> columnState;
private TreeTableColumn<tableDataJob, String> columnState;
@FXML
private TreeTableColumn<tableData, String> columnPositions;
private TreeTableColumn<tableDataJob, String> columnPositions;
@FXML
private TreeTableColumn<tableData, String> columnTime;
private TreeTableColumn<tableDataJob, String> columnTime;
@FXML
private TreeTableColumn<tableData, String> columnJobNumber;
private TreeTableColumn<tableDataJob, String> columnJobNumber;
@FXML
private TreeTableColumn<tableData, Integer> idSpalte02 = new TreeTableColumn<>(
private TreeTableColumn<tableDataJob, Integer> idSpalte02 = new TreeTableColumn<>(
"jobsTreeTable");
@FXML
@ -321,13 +320,17 @@ public class MainWindowController
private String databaseName;
private boolean lockState = false;
private boolean isPrintBtnDisabled = true;
private Job currentJob = null;
@FXML
TreeItem<tableData> rootCurrentJob = new TreeItem<>(
new tableData(0, "0", "0"));
TreeItem<tableDataCurrentOrder> rootCurrentJob = new TreeItem<>(
new tableDataCurrentOrder("0", 0));
@FXML
TreeItem<tableData> rootJobs = new TreeItem<>(new tableData(0, "0", "0"));
TreeItem<tableDataCurrentOrder> rootJobs = new TreeItem<>(new tableDataCurrentOrder("0", 0));
@FXML
TreeItem<tableDataPositionen> rootPositionen = new TreeItem<>(
@ -487,158 +490,167 @@ public class MainWindowController
@FXML
public void btnPrintBillAction(ActionEvent event)
{
System.out.println("Button!");
//System.out.println("Button!");
currentJob.printJobOnConsole();
currentJob = null;
currentJob = new Job(dbc.getLatestJobNumber_Job());
btnPrintBill.setDisable(true);
isPrintBtnDisabled = true;
}
@FXML
public void gridButton01Action(ActionEvent event)
{
System.out.println("Test Button!");
handelGridButtons(1);
}
@FXML
public void gridButton02Action(ActionEvent event)
{
System.out.println("Button!");
handelGridButtons(2);
}
@FXML
public void gridButton03Action(ActionEvent event)
{
System.out.println("Button!");
handelGridButtons(3);
}
@FXML
public void gridButton04Action(ActionEvent event)
{
System.out.println("Button!");
handelGridButtons(4);
}
@FXML
public void gridButton05Action(ActionEvent event)
{
System.out.println("Button!");
handelGridButtons(5);
}
@FXML
public void gridButton06Action(ActionEvent event)
{
System.out.println("Button!");
handelGridButtons(6);
}
@FXML
public void gridButton07Action(ActionEvent event)
{
System.out.println("Button!");
handelGridButtons(7);
}
@FXML
public void gridButton08Action(ActionEvent event)
{
System.out.println("Button!");
handelGridButtons(8);
}
@FXML
public void gridButton09Action(ActionEvent event)
{
System.out.println("Button!");
handelGridButtons(9);
}
@FXML
public void gridButton10Action(ActionEvent event)
{
System.out.println("Button!");
handelGridButtons(10);
}
@FXML
public void gridButton11Action(ActionEvent event)
{
System.out.println("Button!");
handelGridButtons(11);
}
@FXML
public void gridButton12Action(ActionEvent event)
{
System.out.println("Button!");
handelGridButtons(12);
}
@FXML
public void gridButton13Action(ActionEvent event)
{
System.out.println("Button!");
handelGridButtons(13);
}
@FXML
public void gridButton14Action(ActionEvent event)
{
System.out.println("Button!");
handelGridButtons(14);
}
@FXML
public void gridButton15Action(ActionEvent event)
{
System.out.println("Button!");
handelGridButtons(15);
}
@FXML
public void gridButton16Action(ActionEvent event)
{
System.out.println("Button!");
handelGridButtons(16);
}
@FXML
public void gridButton17Action(ActionEvent event)
{
System.out.println("Button!");
handelGridButtons(17);
}
@FXML
public void gridButton18Action(ActionEvent event)
{
System.out.println("Button!");
handelGridButtons(18);
}
@FXML
public void gridButton19Action(ActionEvent event)
{
System.out.println("Button!");
handelGridButtons(19);
}
@FXML
public void gridButton20Action(ActionEvent event)
{
System.out.println("Button!");
handelGridButtons(20);
}
@FXML
public void gridButton21Action(ActionEvent event)
{
System.out.println("Button!");
handelGridButtons(21);
}
@FXML
public void gridButton22Action(ActionEvent event)
{
System.out.println("Button!");
handelGridButtons(22);
}
@FXML
public void gridButton23Action(ActionEvent event)
{
System.out.println("Button!");
handelGridButtons(23);
}
@FXML
public void gridButton24Action(ActionEvent event)
{
System.out.println("Button!");
handelGridButtons(24);
}
@FXML
public void gridButton25Action(ActionEvent event)
{
System.out.println("Button!");
handelGridButtons(25);
}
@FXML
@ -665,7 +677,10 @@ public class MainWindowController
System.out.println("initUI");
tftNewDBName.setText(getDatabaseName());
tftKat05.setDisable(true);
btnPrintBill.setDisable(true);
isPrintBtnDisabled = true;
initPositionen();
initCurrentOrderTreeTableView();
}
@ -980,7 +995,17 @@ public class MainWindowController
btnCalcStats.setDisable(pState);
btnClearEntry.setDisable(pState);
btnDeleteSelectedPosition.setDisable(pState);
btnPrintBill.setDisable(pState);
if((!isPrintBtnDisabled) && (!pState)) {
// print was not disabled and will be enabled again
btnPrintBill.setDisable(pState);
}
if(pState) {
// disable allways
btnPrintBill.setDisable(pState);
}
btnReprintJob.setDisable(pState);
btnSaveEntry.setDisable(pState);
btnCancelJob.setDisable(pState);
@ -995,7 +1020,7 @@ public class MainWindowController
catChoise.setDisable(pState);
tableCurrentOrder.setDisable(pState);
jobsTreeTable.setDisable(pState);
//jobsTreeTable.setDisable(pState);
entryTreeTable.setDisable(pState);
labelAllPrize.setVisible(!pState);
@ -1095,6 +1120,61 @@ public class MainWindowController
}
}
private void handelGridButtons(int pID)
{
System.out.println("Button: " + pID);
currentJob.addPosition(dbc.getName_Positionen(pID),
Float.parseFloat(dbc.getValue_Positionen(pID)),
dbc.getCategoryNameFromPositionen(pID));
btnPrintBill.setDisable(false);
isPrintBtnDisabled = false;
tableDataCurrentOrder test01 = new tableDataCurrentOrder("Test", 42);
rootCurrentJob.getChildren().remove(0,
rootCurrentJob.getChildren().size());
rootCurrentJob.getChildren().add(new TreeItem<tableDataCurrentOrder>(test01));
}
private void initCurrentOrderTreeTableView() {
columnQuantity.setStyle("-fx-alignment: CENTER;");
columnPosition.setStyle("-fx-alignment: CENTER;");
tableCurrentOrder.setRoot(rootCurrentJob);
tableCurrentOrder.setShowRoot(false);
tableCurrentOrder.setEditable(false);
columnQuantity.setCellValueFactory(
cellData -> cellData.getValue().getValue().quantityProperty().asObject());
columnPosition.setCellValueFactory(
cellData -> cellData.getValue().getValue().positionProperty());
}
public void createFirstJob()
{
currentJob = new Job(dbc.getLatestJobNumber_Job());
}
public void updateTimeLabel()
{
// System.out.println(getSystemTime());

View File

@ -1,68 +0,0 @@
package application;
import javafx.beans.property.IntegerProperty;
import javafx.beans.property.SimpleIntegerProperty;
import javafx.beans.property.SimpleStringProperty;
import javafx.beans.property.StringProperty;
public class tableData
{ // Datenobjekt mit der ID, Datum und Konto
private final IntegerProperty id = new SimpleIntegerProperty();
private final StringProperty datum = new SimpleStringProperty();
private final StringProperty konto = new SimpleStringProperty();
public tableData(final int id, final String datum, final String konto)
{
this.id.set(id);
this.datum.set(datum);
this.konto.set(konto);
}
public IntegerProperty idProperty()
{
return id;
}
public StringProperty datumProperty()
{
return datum;
}
public StringProperty kontoProperty()
{
return konto;
}
public int getID()
{
return idProperty().get();
}
public String getDatum()
{
return datumProperty().get();
}
public String getKonto()
{
return kontoProperty().get();
}
public final void setID(int id)
{
idProperty().set(id);
}
public final void setdatum(String datum)
{
datumProperty().set(datum);
}
public final void setkonto(String konto)
{
kontoProperty().set(konto);
}
}

View File

@ -0,0 +1,51 @@
package application;
import javafx.beans.property.IntegerProperty;
import javafx.beans.property.SimpleIntegerProperty;
import javafx.beans.property.SimpleStringProperty;
import javafx.beans.property.StringProperty;
public class tableDataCurrentOrder
{
private final StringProperty position = new SimpleStringProperty();
private final IntegerProperty quantity = new SimpleIntegerProperty();
public tableDataCurrentOrder(final String pPosition, final Integer pQuantity)
{
this.position.set(pPosition);
this.quantity.set(pQuantity);
}
public StringProperty positionProperty()
{
return position;
}
public IntegerProperty quantityProperty()
{
return quantity;
}
public String getPosition()
{
return positionProperty().get();
}
public Integer getQuantity()
{
return quantityProperty().get();
}
public final void setPosition(String pPosition)
{
positionProperty().set(pPosition);
}
public final void setQuantity(int pQuantity)
{
quantityProperty().set(pQuantity);
}
}

View File

@ -0,0 +1,51 @@
package application;
import javafx.beans.property.IntegerProperty;
import javafx.beans.property.SimpleIntegerProperty;
import javafx.beans.property.SimpleStringProperty;
import javafx.beans.property.StringProperty;
public class tableDataJob
{
private final StringProperty position = new SimpleStringProperty();
private final IntegerProperty quantity = new SimpleIntegerProperty();
public tableDataJob(final String pPosition, final Integer pQuantity)
{
this.position.set(pPosition);
this.quantity.set(pQuantity);
}
public StringProperty positionProperty()
{
return position;
}
public IntegerProperty quantityProperty()
{
return quantity;
}
public String getPosition()
{
return positionProperty().get();
}
public Integer getQuantity()
{
return quantityProperty().get();
}
public final void setPosition(String pPosition)
{
positionProperty().set(pPosition);
}
public final void setQuantity(int pQuantity)
{
quantityProperty().set(pQuantity);
}
}