diff --git a/Enigma/Enigma.csproj b/Enigma/Enigma.csproj
index e116304..2212980 100644
--- a/Enigma/Enigma.csproj
+++ b/Enigma/Enigma.csproj
@@ -62,12 +62,6 @@
-
- Form
-
-
- AddParty.cs
-
Form
@@ -80,6 +74,12 @@
TableAssign.cs
+
+ Form
+
+
+ tableOrder.cs
+
Form
@@ -115,15 +115,15 @@
-
- AddParty.cs
-
resAdd.cs
TableAssign.cs
+
+ tableOrder.cs
+
waitListAdd.cs
diff --git a/Enigma/Popups/AddParty.Designer.cs b/Enigma/Popups/AddParty.Designer.cs
deleted file mode 100644
index 8b5f579..0000000
--- a/Enigma/Popups/AddParty.Designer.cs
+++ /dev/null
@@ -1,165 +0,0 @@
-namespace Enigma.Popups
-{
- partial class AddParty
- {
- ///
- /// Required designer variable.
- ///
- private System.ComponentModel.IContainer components = null;
-
- ///
- /// Clean up any resources being used.
- ///
- /// true if managed resources should be disposed; otherwise, false.
- protected override void Dispose(bool disposing)
- {
- if (disposing && (components != null))
- {
- components.Dispose();
- }
- base.Dispose(disposing);
- }
-
- #region Windows Form Designer generated code
-
- ///
- /// Required method for Designer support - do not modify
- /// the contents of this method with the code editor.
- ///
- private void InitializeComponent()
- {
- this.partyName = new MetroFramework.Controls.MetroTextBox();
- this.metroLabel1 = new MetroFramework.Controls.MetroLabel();
- this.addPartyButton = new MetroFramework.Controls.MetroButton();
- this.metroLabel2 = new MetroFramework.Controls.MetroLabel();
- this.countBox = new System.Windows.Forms.NumericUpDown();
- this.metroLabel3 = new MetroFramework.Controls.MetroLabel();
- this.tableSelectionBox = new MetroFramework.Controls.MetroComboBox();
- ((System.ComponentModel.ISupportInitialize)(this.countBox)).BeginInit();
- this.SuspendLayout();
- //
- // partyName
- //
- //
- //
- //
- this.partyName.CustomButton.Image = null;
- this.partyName.CustomButton.Location = new System.Drawing.Point(668, 1);
- this.partyName.CustomButton.Name = "";
- this.partyName.CustomButton.Size = new System.Drawing.Size(21, 21);
- this.partyName.CustomButton.Style = MetroFramework.MetroColorStyle.Blue;
- this.partyName.CustomButton.TabIndex = 1;
- this.partyName.CustomButton.Theme = MetroFramework.MetroThemeStyle.Light;
- this.partyName.CustomButton.UseSelectable = true;
- this.partyName.CustomButton.Visible = false;
- this.partyName.Lines = new string[] {
- "Name of Party"};
- this.partyName.Location = new System.Drawing.Point(81, 60);
- this.partyName.MaxLength = 32767;
- this.partyName.Name = "partyName";
- this.partyName.PasswordChar = '\0';
- this.partyName.ScrollBars = System.Windows.Forms.ScrollBars.None;
- this.partyName.SelectedText = "";
- this.partyName.SelectionLength = 0;
- this.partyName.SelectionStart = 0;
- this.partyName.ShortcutsEnabled = true;
- this.partyName.Size = new System.Drawing.Size(690, 23);
- this.partyName.TabIndex = 0;
- this.partyName.Text = "Name of Party";
- this.partyName.UseSelectable = true;
- this.partyName.WaterMarkColor = System.Drawing.Color.FromArgb(((int)(((byte)(109)))), ((int)(((byte)(109)))), ((int)(((byte)(109)))));
- this.partyName.WaterMarkFont = new System.Drawing.Font("Segoe UI", 12F, System.Drawing.FontStyle.Italic, System.Drawing.GraphicsUnit.Pixel);
- //
- // metroLabel1
- //
- this.metroLabel1.AutoSize = true;
- this.metroLabel1.Location = new System.Drawing.Point(23, 60);
- this.metroLabel1.Name = "metroLabel1";
- this.metroLabel1.Size = new System.Drawing.Size(52, 19);
- this.metroLabel1.TabIndex = 1;
- this.metroLabel1.Text = "Name: ";
- //
- // addPartyButton
- //
- this.addPartyButton.Location = new System.Drawing.Point(777, 60);
- this.addPartyButton.Name = "addPartyButton";
- this.addPartyButton.Size = new System.Drawing.Size(178, 90);
- this.addPartyButton.TabIndex = 4;
- this.addPartyButton.Text = "Add Party";
- this.addPartyButton.UseSelectable = true;
- this.addPartyButton.Click += new System.EventHandler(this.addPartyButton_Click);
- //
- // metroLabel2
- //
- this.metroLabel2.AutoSize = true;
- this.metroLabel2.Location = new System.Drawing.Point(23, 89);
- this.metroLabel2.Name = "metroLabel2";
- this.metroLabel2.Size = new System.Drawing.Size(47, 19);
- this.metroLabel2.TabIndex = 3;
- this.metroLabel2.Text = "Count:";
- //
- // countBox
- //
- this.countBox.Location = new System.Drawing.Point(81, 89);
- this.countBox.Name = "countBox";
- this.countBox.Size = new System.Drawing.Size(180, 26);
- this.countBox.TabIndex = 5;
- this.countBox.Value = new decimal(new int[] {
- 1,
- 0,
- 0,
- 0});
- //
- // metroLabel3
- //
- this.metroLabel3.AutoSize = true;
- this.metroLabel3.Location = new System.Drawing.Point(23, 122);
- this.metroLabel3.Name = "metroLabel3";
- this.metroLabel3.Size = new System.Drawing.Size(42, 19);
- this.metroLabel3.TabIndex = 6;
- this.metroLabel3.Text = "Table:";
- //
- // tableSelectionBox
- //
- this.tableSelectionBox.FormattingEnabled = true;
- this.tableSelectionBox.ItemHeight = 23;
- this.tableSelectionBox.Items.AddRange(new object[] {
- "None"});
- this.tableSelectionBox.Location = new System.Drawing.Point(81, 121);
- this.tableSelectionBox.Name = "tableSelectionBox";
- this.tableSelectionBox.Size = new System.Drawing.Size(323, 29);
- this.tableSelectionBox.TabIndex = 7;
- this.tableSelectionBox.UseSelectable = true;
- //
- // AddParty
- //
- this.AutoScaleDimensions = new System.Drawing.SizeF(9F, 20F);
- this.AutoScaleMode = System.Windows.Forms.AutoScaleMode.Font;
- this.ClientSize = new System.Drawing.Size(978, 172);
- this.Controls.Add(this.tableSelectionBox);
- this.Controls.Add(this.metroLabel3);
- this.Controls.Add(this.countBox);
- this.Controls.Add(this.addPartyButton);
- this.Controls.Add(this.metroLabel2);
- this.Controls.Add(this.metroLabel1);
- this.Controls.Add(this.partyName);
- this.Name = "AddParty";
- this.Text = "Add Party";
- this.Load += new System.EventHandler(this.AddPatron_Load);
- ((System.ComponentModel.ISupportInitialize)(this.countBox)).EndInit();
- this.ResumeLayout(false);
- this.PerformLayout();
-
- }
-
- #endregion
-
- private MetroFramework.Controls.MetroTextBox partyName;
- private MetroFramework.Controls.MetroLabel metroLabel1;
- private MetroFramework.Controls.MetroButton addPartyButton;
- private MetroFramework.Controls.MetroLabel metroLabel2;
- private System.Windows.Forms.NumericUpDown countBox;
- private MetroFramework.Controls.MetroLabel metroLabel3;
- private MetroFramework.Controls.MetroComboBox tableSelectionBox;
- }
-}
\ No newline at end of file
diff --git a/Enigma/Popups/AddParty.cs b/Enigma/Popups/AddParty.cs
deleted file mode 100644
index e4d2934..0000000
--- a/Enigma/Popups/AddParty.cs
+++ /dev/null
@@ -1,50 +0,0 @@
-using EnigmaX.Classes;
-using MetroFramework.Forms;
-using System;
-using System.Collections.Generic;
-using System.ComponentModel;
-using System.Data;
-using System.Drawing;
-using System.Linq;
-using System.Text;
-using System.Threading.Tasks;
-using System.Windows.Forms;
-
-namespace Enigma.Popups
-{
- public partial class AddParty : MetroForm
- {
-
- List tables;
- public AddParty()
- {
- InitializeComponent();
-
- }
- public AddParty(List _tables)
- {
- InitializeComponent();
- tables = _tables;
- }
-
- private void AddPatron_Load(object sender, EventArgs e)
- {
- foreach (Table table in tables) {
- tableSelectionBox.Items.Add("Table " + table.tableId() + " " + table._count + " / " + table._capacity);
- }
- }
-
- private void addPartyButton_Click(object sender, EventArgs e)
- {
- Party party = new Party(partyName.Text, (int)countBox.Value);
- if (tableSelectionBox.SelectedIndex > 0) {
- // index 0 is always "none"
- Table selected = tables[tableSelectionBox.SelectedIndex - 1];
- if (selected.remaining >= (int)countBox.Value) {
- selected.addPatron(party);
- party.setTable(selected);
- }
- }
- }
- }
-}
diff --git a/Enigma/Popups/tableOrder.Designer.cs b/Enigma/Popups/tableOrder.Designer.cs
new file mode 100644
index 0000000..3964d31
--- /dev/null
+++ b/Enigma/Popups/tableOrder.Designer.cs
@@ -0,0 +1,121 @@
+namespace Enigma.Popups
+{
+ partial class tableOrder
+ {
+ ///
+ /// Required designer variable.
+ ///
+ private System.ComponentModel.IContainer components = null;
+
+ ///
+ /// Clean up any resources being used.
+ ///
+ /// true if managed resources should be disposed; otherwise, false.
+ protected override void Dispose(bool disposing)
+ {
+ if (disposing && (components != null))
+ {
+ components.Dispose();
+ }
+ base.Dispose(disposing);
+ }
+
+ #region Windows Form Designer generated code
+
+ ///
+ /// Required method for Designer support - do not modify
+ /// the contents of this method with the code editor.
+ ///
+ private void InitializeComponent()
+ {
+ this.metroComboBox1 = new MetroFramework.Controls.MetroComboBox();
+ this.dataGridView1 = new System.Windows.Forms.DataGridView();
+ this.dataGridView2 = new System.Windows.Forms.DataGridView();
+ this.Menu = new MetroFramework.Controls.MetroLabel();
+ this.order = new MetroFramework.Controls.MetroLabel();
+ ((System.ComponentModel.ISupportInitialize)(this.dataGridView1)).BeginInit();
+ ((System.ComponentModel.ISupportInitialize)(this.dataGridView2)).BeginInit();
+ this.SuspendLayout();
+ //
+ // metroComboBox1
+ //
+ this.metroComboBox1.FormattingEnabled = true;
+ this.metroComboBox1.ItemHeight = 24;
+ this.metroComboBox1.Location = new System.Drawing.Point(34, 108);
+ this.metroComboBox1.Name = "metroComboBox1";
+ this.metroComboBox1.Size = new System.Drawing.Size(121, 30);
+ this.metroComboBox1.TabIndex = 0;
+ this.metroComboBox1.UseSelectable = true;
+ //
+ // dataGridView1
+ //
+ this.dataGridView1.AllowUserToAddRows = false;
+ this.dataGridView1.AllowUserToDeleteRows = false;
+ this.dataGridView1.ColumnHeadersHeightSizeMode = System.Windows.Forms.DataGridViewColumnHeadersHeightSizeMode.AutoSize;
+ this.dataGridView1.Location = new System.Drawing.Point(34, 166);
+ this.dataGridView1.Name = "dataGridView1";
+ this.dataGridView1.ReadOnly = true;
+ this.dataGridView1.RowTemplate.Height = 24;
+ this.dataGridView1.Size = new System.Drawing.Size(531, 605);
+ this.dataGridView1.TabIndex = 1;
+ //
+ // dataGridView2
+ //
+ this.dataGridView2.AllowUserToAddRows = false;
+ this.dataGridView2.AllowUserToDeleteRows = false;
+ this.dataGridView2.ColumnHeadersHeightSizeMode = System.Windows.Forms.DataGridViewColumnHeadersHeightSizeMode.AutoSize;
+ this.dataGridView2.Location = new System.Drawing.Point(769, 166);
+ this.dataGridView2.Name = "dataGridView2";
+ this.dataGridView2.ReadOnly = true;
+ this.dataGridView2.RowTemplate.Height = 24;
+ this.dataGridView2.Size = new System.Drawing.Size(531, 605);
+ this.dataGridView2.TabIndex = 2;
+ //
+ // Menu
+ //
+ this.Menu.AutoSize = true;
+ this.Menu.Location = new System.Drawing.Point(34, 71);
+ this.Menu.Name = "Menu";
+ this.Menu.Size = new System.Drawing.Size(45, 20);
+ this.Menu.TabIndex = 3;
+ this.Menu.Text = "Menu";
+ //
+ // order
+ //
+ this.order.AutoSize = true;
+ this.order.Location = new System.Drawing.Point(769, 108);
+ this.order.Name = "order";
+ this.order.Size = new System.Drawing.Size(46, 20);
+ this.order.TabIndex = 4;
+ this.order.Text = "Order";
+ //
+ // tableOrder
+ //
+ this.AutoScaleDimensions = new System.Drawing.SizeF(8F, 16F);
+ this.AutoScaleMode = System.Windows.Forms.AutoScaleMode.Font;
+ this.ClientSize = new System.Drawing.Size(1386, 810);
+ this.Controls.Add(this.order);
+ this.Controls.Add(this.Menu);
+ this.Controls.Add(this.dataGridView2);
+ this.Controls.Add(this.dataGridView1);
+ this.Controls.Add(this.metroComboBox1);
+ this.Name = "tableOrder";
+ this.Style = MetroFramework.MetroColorStyle.Orange;
+ this.Text = "tableOrder";
+ this.Load += new System.EventHandler(this.tableOrder_Load);
+ ((System.ComponentModel.ISupportInitialize)(this.dataGridView1)).EndInit();
+ ((System.ComponentModel.ISupportInitialize)(this.dataGridView2)).EndInit();
+ this.ResumeLayout(false);
+ this.PerformLayout();
+
+ }
+
+ #endregion
+
+ private MetroFramework.Controls.MetroComboBox metroComboBox1;
+ private System.Windows.Forms.DataGridView dataGridView1;
+ private System.Windows.Forms.DataGridView dataGridView2;
+ private MetroFramework.Controls.MetroLabel Menu;
+ private MetroFramework.Controls.MetroLabel order;
+ }
+}
\ No newline at end of file
diff --git a/Enigma/Popups/tableOrder.cs b/Enigma/Popups/tableOrder.cs
new file mode 100644
index 0000000..f5dc938
--- /dev/null
+++ b/Enigma/Popups/tableOrder.cs
@@ -0,0 +1,26 @@
+using System;
+using System.Collections.Generic;
+using System.ComponentModel;
+using System.Data;
+using System.Drawing;
+using System.Linq;
+using System.Text;
+using System.Threading.Tasks;
+using System.Windows.Forms;
+using MetroFramework.Forms;
+
+namespace Enigma.Popups
+{
+ public partial class tableOrder : MetroForm
+ {
+ public tableOrder()
+ {
+ InitializeComponent();
+ }
+
+ private void tableOrder_Load(object sender, EventArgs e)
+ {
+
+ }
+ }
+}
diff --git a/Enigma/Popups/AddParty.resx b/Enigma/Popups/tableOrder.resx
similarity index 100%
rename from Enigma/Popups/AddParty.resx
rename to Enigma/Popups/tableOrder.resx
diff --git a/Enigma/StationsGUI/HostStationView.Designer.cs b/Enigma/StationsGUI/HostStationView.Designer.cs
index 2b94ef4..7f5b974 100644
--- a/Enigma/StationsGUI/HostStationView.Designer.cs
+++ b/Enigma/StationsGUI/HostStationView.Designer.cs
@@ -33,7 +33,6 @@ private void InitializeComponent()
this.dataGridView1 = new System.Windows.Forms.DataGridView();
this.addToWaitlist = new MetroFramework.Controls.MetroButton();
this.waitListRefresh = new System.Windows.Forms.Timer(this.components);
- this.label1 = new System.Windows.Forms.Label();
this.tableAssign = new MetroFramework.Controls.MetroButton();
this.viewRefresh = new System.Windows.Forms.Timer(this.components);
this.resAdd = new MetroFramework.Controls.MetroButton();
@@ -82,15 +81,6 @@ private void InitializeComponent()
this.waitListRefresh.Interval = 5000;
this.waitListRefresh.Tick += new System.EventHandler(this.waitListRefresh_Tick);
//
- // label1
- //
- this.label1.AutoSize = true;
- this.label1.Location = new System.Drawing.Point(883, 404);
- this.label1.Name = "label1";
- this.label1.Size = new System.Drawing.Size(46, 17);
- this.label1.TabIndex = 3;
- this.label1.Text = "label1";
- //
// tableAssign
//
this.tableAssign.Location = new System.Drawing.Point(886, 170);
@@ -123,7 +113,6 @@ private void InitializeComponent()
this.ClientSize = new System.Drawing.Size(1111, 747);
this.Controls.Add(this.resAdd);
this.Controls.Add(this.tableAssign);
- this.Controls.Add(this.label1);
this.Controls.Add(this.addToWaitlist);
this.Controls.Add(this.dataGridView1);
this.Controls.Add(this.comboBox1);
@@ -136,7 +125,6 @@ private void InitializeComponent()
this.Load += new System.EventHandler(this.HostStationView_Load);
((System.ComponentModel.ISupportInitialize)(this.dataGridView1)).EndInit();
this.ResumeLayout(false);
- this.PerformLayout();
}
@@ -146,7 +134,6 @@ private void InitializeComponent()
private System.Windows.Forms.DataGridView dataGridView1;
private MetroFramework.Controls.MetroButton addToWaitlist;
private System.Windows.Forms.Timer waitListRefresh;
- private System.Windows.Forms.Label label1;
private MetroFramework.Controls.MetroButton tableAssign;
private System.Windows.Forms.Timer viewRefresh;
private MetroFramework.Controls.MetroButton resAdd;
diff --git a/Enigma/StationsGUI/HostStationView.cs b/Enigma/StationsGUI/HostStationView.cs
index aa4f2bb..fe0f977 100644
--- a/Enigma/StationsGUI/HostStationView.cs
+++ b/Enigma/StationsGUI/HostStationView.cs
@@ -144,8 +144,6 @@ private void waitListRefresh_Tick(object sender, EventArgs e) //actions when the
{
try
{
- label1.Text = waitList.Count().ToString(); //FOR TESTING
- label1.Refresh();//FOR TESTING
for (int i = 0; i < waitList.Count(); i++)//interate through all objects in the waitlist
{
diff --git a/Enigma/StationsGUI/WaiterStationView.Designer.cs b/Enigma/StationsGUI/WaiterStationView.Designer.cs
index ac5151b..a478952 100644
--- a/Enigma/StationsGUI/WaiterStationView.Designer.cs
+++ b/Enigma/StationsGUI/WaiterStationView.Designer.cs
@@ -28,20 +28,107 @@ protected override void Dispose(bool disposing)
///
private void InitializeComponent()
{
+ this.tableNumber = new MetroFramework.Controls.MetroLabel();
+ this.tableNumInput = new MetroFramework.Controls.MetroTextBox();
+ this.orderSelect = new MetroFramework.Controls.MetroButton();
+ this.checkoutTable = new MetroFramework.Controls.MetroButton();
+ this.printCheque = new MetroFramework.Controls.MetroButton();
this.SuspendLayout();
//
+ // tableNumber
+ //
+ this.tableNumber.AutoSize = true;
+ this.tableNumber.Location = new System.Drawing.Point(22, 74);
+ this.tableNumber.Name = "tableNumber";
+ this.tableNumber.Size = new System.Drawing.Size(101, 20);
+ this.tableNumber.TabIndex = 0;
+ this.tableNumber.Text = "Table Number:";
+ //
+ // tableNumInput
+ //
+ //
+ //
+ //
+ this.tableNumInput.CustomButton.Image = null;
+ this.tableNumInput.CustomButton.Location = new System.Drawing.Point(67, 1);
+ this.tableNumInput.CustomButton.Name = "";
+ this.tableNumInput.CustomButton.Size = new System.Drawing.Size(21, 21);
+ this.tableNumInput.CustomButton.Style = MetroFramework.MetroColorStyle.Blue;
+ this.tableNumInput.CustomButton.TabIndex = 1;
+ this.tableNumInput.CustomButton.Theme = MetroFramework.MetroThemeStyle.Light;
+ this.tableNumInput.CustomButton.UseSelectable = true;
+ this.tableNumInput.CustomButton.Visible = false;
+ this.tableNumInput.Lines = new string[] {
+ "metroTextBox1"};
+ this.tableNumInput.Location = new System.Drawing.Point(130, 74);
+ this.tableNumInput.MaxLength = 32767;
+ this.tableNumInput.Name = "tableNumInput";
+ this.tableNumInput.PasswordChar = '\0';
+ this.tableNumInput.ScrollBars = System.Windows.Forms.ScrollBars.None;
+ this.tableNumInput.SelectedText = "";
+ this.tableNumInput.SelectionLength = 0;
+ this.tableNumInput.SelectionStart = 0;
+ this.tableNumInput.ShortcutsEnabled = true;
+ this.tableNumInput.Size = new System.Drawing.Size(89, 23);
+ this.tableNumInput.TabIndex = 1;
+ this.tableNumInput.Text = "metroTextBox1";
+ this.tableNumInput.UseSelectable = true;
+ this.tableNumInput.WaterMarkColor = System.Drawing.Color.FromArgb(((int)(((byte)(109)))), ((int)(((byte)(109)))), ((int)(((byte)(109)))));
+ this.tableNumInput.WaterMarkFont = new System.Drawing.Font("Segoe UI", 12F, System.Drawing.FontStyle.Italic, System.Drawing.GraphicsUnit.Pixel);
+ //
+ // orderSelect
+ //
+ this.orderSelect.Location = new System.Drawing.Point(22, 117);
+ this.orderSelect.Name = "orderSelect";
+ this.orderSelect.Size = new System.Drawing.Size(197, 65);
+ this.orderSelect.TabIndex = 2;
+ this.orderSelect.Text = "Enter Table Order";
+ this.orderSelect.UseSelectable = true;
+ //
+ // checkoutTable
+ //
+ this.checkoutTable.Location = new System.Drawing.Point(21, 282);
+ this.checkoutTable.Name = "checkoutTable";
+ this.checkoutTable.Size = new System.Drawing.Size(197, 65);
+ this.checkoutTable.TabIndex = 3;
+ this.checkoutTable.Text = "Checkout Table";
+ this.checkoutTable.UseSelectable = true;
+ //
+ // printCheque
+ //
+ this.printCheque.Location = new System.Drawing.Point(22, 198);
+ this.printCheque.Name = "printCheque";
+ this.printCheque.Size = new System.Drawing.Size(197, 65);
+ this.printCheque.TabIndex = 4;
+ this.printCheque.Text = "Print Cheque";
+ this.printCheque.UseSelectable = true;
+ //
// WaiterStationView
//
- this.AutoScaleDimensions = new System.Drawing.SizeF(9F, 20F);
+ this.AutoScaleDimensions = new System.Drawing.SizeF(8F, 16F);
this.AutoScaleMode = System.Windows.Forms.AutoScaleMode.Font;
- this.ClientSize = new System.Drawing.Size(1334, 1020);
+ this.ClientSize = new System.Drawing.Size(248, 380);
+ this.Controls.Add(this.printCheque);
+ this.Controls.Add(this.checkoutTable);
+ this.Controls.Add(this.orderSelect);
+ this.Controls.Add(this.tableNumInput);
+ this.Controls.Add(this.tableNumber);
+ this.Margin = new System.Windows.Forms.Padding(3, 2, 3, 2);
this.Name = "WaiterStationView";
+ this.Padding = new System.Windows.Forms.Padding(18, 60, 18, 16);
this.Text = "Waiter Station";
this.Load += new System.EventHandler(this.WaiterStationView_Load);
this.ResumeLayout(false);
+ this.PerformLayout();
}
#endregion
+
+ private MetroFramework.Controls.MetroLabel tableNumber;
+ private MetroFramework.Controls.MetroTextBox tableNumInput;
+ private MetroFramework.Controls.MetroButton orderSelect;
+ private MetroFramework.Controls.MetroButton checkoutTable;
+ private MetroFramework.Controls.MetroButton printCheque;
}
}
\ No newline at end of file