Essensbestellungen

This commit is contained in:
2022-12-23 08:24:35 +01:00
parent 552dd3b02c
commit bb723948b8
3 changed files with 271 additions and 142 deletions

View File

@@ -31,5 +31,5 @@ Imports System.Runtime.InteropServices
' übernehmen, indem Sie "*" eingeben:
' <Assembly: AssemblyVersion("1.0.*")>
<Assembly: AssemblyVersion("3.8.4.0")>
<Assembly: AssemblyFileVersion("3.8.4.0")>
<Assembly: AssemblyVersion("3.8.4.1")>
<Assembly: AssemblyFileVersion("3.8.4.1")>

View File

@@ -43,20 +43,24 @@ Partial Class frmEssensbestellungen
Me.MyPanel1 = New VERAG_PROG_ALLGEMEIN.MyPanel(Me.components)
Me.txtPreis = New System.Windows.Forms.Label()
Me.Label2 = New System.Windows.Forms.Label()
Me.Dienstag = New System.Windows.Forms.GroupBox()
Me.GroupBoxDienstag = New System.Windows.Forms.GroupBox()
Me.txtMenuDi = New System.Windows.Forms.Label()
Me.pbDienstag = New System.Windows.Forms.PictureBox()
Me.cbDienstag = New System.Windows.Forms.CheckBox()
Me.txtAltDi = New VERAG_PROG_ALLGEMEIN.MyTextBox()
Me.rbMenuAlt_Di = New VERAG_PROG_ALLGEMEIN.MyRadioButton(Me.components)
Me.rbMenu_Di = New VERAG_PROG_ALLGEMEIN.MyRadioButton(Me.components)
Me.lbl1 = New System.Windows.Forms.Label()
Me.GroupBox1 = New System.Windows.Forms.GroupBox()
Me.Button1 = New System.Windows.Forms.Button()
Me.GroupBoxMontag = New System.Windows.Forms.GroupBox()
Me.txtMenuMo = New System.Windows.Forms.Label()
Me.pbMontag = New System.Windows.Forms.PictureBox()
Me.cbMontag = New System.Windows.Forms.CheckBox()
Me.txtAltMo = New VERAG_PROG_ALLGEMEIN.MyTextBox()
Me.rbMenoAlt_Mo = New VERAG_PROG_ALLGEMEIN.MyRadioButton(Me.components)
Me.rbMenuAlt_Mo = New VERAG_PROG_ALLGEMEIN.MyRadioButton(Me.components)
Me.rbMenu_Mo = New VERAG_PROG_ALLGEMEIN.MyRadioButton(Me.components)
Me.GroupBox5 = New System.Windows.Forms.GroupBox()
Me.GroupBoxFreitag = New System.Windows.Forms.GroupBox()
Me.txtMenuFr = New System.Windows.Forms.Label()
Me.pbFreitag = New System.Windows.Forms.PictureBox()
Me.cbFreitag = New System.Windows.Forms.CheckBox()
Me.txtAltFr = New VERAG_PROG_ALLGEMEIN.MyTextBox()
@@ -65,19 +69,20 @@ Partial Class frmEssensbestellungen
Me.txtAnzahlLaCart = New System.Windows.Forms.Label()
Me.lbl2 = New System.Windows.Forms.Label()
Me.Mittwoch = New System.Windows.Forms.GroupBox()
Me.txtMenuMi = New System.Windows.Forms.Label()
Me.pbMittwoch = New System.Windows.Forms.PictureBox()
Me.cbMittwoch = New System.Windows.Forms.CheckBox()
Me.txtAltMi = New VERAG_PROG_ALLGEMEIN.MyTextBox()
Me.rbMenuAlt_Mi = New VERAG_PROG_ALLGEMEIN.MyRadioButton(Me.components)
Me.rbMenu_Mi = New VERAG_PROG_ALLGEMEIN.MyRadioButton(Me.components)
Me.GroupBox4 = New System.Windows.Forms.GroupBox()
Me.GroupBoxDonnerstag = New System.Windows.Forms.GroupBox()
Me.txtMenuDo = New System.Windows.Forms.Label()
Me.pbDonnerstag = New System.Windows.Forms.PictureBox()
Me.cbDonnerstag = New System.Windows.Forms.CheckBox()
Me.txtAltDo = New VERAG_PROG_ALLGEMEIN.MyTextBox()
Me.rbMenuAlt_Do = New VERAG_PROG_ALLGEMEIN.MyRadioButton(Me.components)
Me.rbMenu_Do = New VERAG_PROG_ALLGEMEIN.MyRadioButton(Me.components)
Me.txtAnzahlMenu = New System.Windows.Forms.Label()
Me.Button1 = New System.Windows.Forms.Button()
Me.dgvBestellungen = New VERAG_PROG_ALLGEMEIN.MyDatagridview(Me.components)
Me.cbxMenu = New VERAG_PROG_ALLGEMEIN.MyComboBox()
Me.txtAbteilung = New System.Windows.Forms.Label()
@@ -86,16 +91,17 @@ Partial Class frmEssensbestellungen
Me.Label3 = New System.Windows.Forms.Label()
Me.PictureBox1 = New System.Windows.Forms.PictureBox()
Me.Label1 = New System.Windows.Forms.Label()
Me.lblTest = New System.Windows.Forms.Label()
Me.MyPanel1.SuspendLayout()
Me.Dienstag.SuspendLayout()
Me.GroupBoxDienstag.SuspendLayout()
CType(Me.pbDienstag, System.ComponentModel.ISupportInitialize).BeginInit()
Me.GroupBox1.SuspendLayout()
Me.GroupBoxMontag.SuspendLayout()
CType(Me.pbMontag, System.ComponentModel.ISupportInitialize).BeginInit()
Me.GroupBox5.SuspendLayout()
Me.GroupBoxFreitag.SuspendLayout()
CType(Me.pbFreitag, System.ComponentModel.ISupportInitialize).BeginInit()
Me.Mittwoch.SuspendLayout()
CType(Me.pbMittwoch, System.ComponentModel.ISupportInitialize).BeginInit()
Me.GroupBox4.SuspendLayout()
Me.GroupBoxDonnerstag.SuspendLayout()
CType(Me.pbDonnerstag, System.ComponentModel.ISupportInitialize).BeginInit()
CType(Me.dgvBestellungen, System.ComponentModel.ISupportInitialize).BeginInit()
CType(Me.PictureBox1, System.ComponentModel.ISupportInitialize).BeginInit()
@@ -113,7 +119,7 @@ Partial Class frmEssensbestellungen
'btnSave
'
Me.btnSave.Anchor = System.Windows.Forms.AnchorStyles.Bottom
Me.btnSave.Location = New System.Drawing.Point(305, 484)
Me.btnSave.Location = New System.Drawing.Point(305, 531)
Me.btnSave.Name = "btnSave"
Me.btnSave.Size = New System.Drawing.Size(75, 23)
Me.btnSave.TabIndex = 10
@@ -166,7 +172,7 @@ Partial Class frmEssensbestellungen
'lblBestellungen
'
Me.lblBestellungen.AutoSize = True
Me.lblBestellungen.Location = New System.Drawing.Point(15, 297)
Me.lblBestellungen.Location = New System.Drawing.Point(15, 334)
Me.lblBestellungen.Name = "lblBestellungen"
Me.lblBestellungen.Size = New System.Drawing.Size(100, 13)
Me.lblBestellungen.TabIndex = 20
@@ -197,25 +203,25 @@ Partial Class frmEssensbestellungen
'
Me.MyPanel1.Controls.Add(Me.txtPreis)
Me.MyPanel1.Controls.Add(Me.Label2)
Me.MyPanel1.Controls.Add(Me.Dienstag)
Me.MyPanel1.Controls.Add(Me.GroupBoxDienstag)
Me.MyPanel1.Controls.Add(Me.lbl1)
Me.MyPanel1.Controls.Add(Me.Button1)
Me.MyPanel1.Controls.Add(Me.GroupBox1)
Me.MyPanel1.Controls.Add(Me.GroupBox5)
Me.MyPanel1.Controls.Add(Me.GroupBoxMontag)
Me.MyPanel1.Controls.Add(Me.GroupBoxFreitag)
Me.MyPanel1.Controls.Add(Me.txtAnzahlLaCart)
Me.MyPanel1.Controls.Add(Me.lbl2)
Me.MyPanel1.Controls.Add(Me.Mittwoch)
Me.MyPanel1.Controls.Add(Me.GroupBox4)
Me.MyPanel1.Controls.Add(Me.GroupBoxDonnerstag)
Me.MyPanel1.Controls.Add(Me.txtAnzahlMenu)
Me.MyPanel1.Location = New System.Drawing.Point(12, 67)
Me.MyPanel1.Location = New System.Drawing.Point(12, 65)
Me.MyPanel1.Name = "MyPanel1"
Me.MyPanel1.Size = New System.Drawing.Size(667, 210)
Me.MyPanel1.Size = New System.Drawing.Size(667, 259)
Me.MyPanel1.TabIndex = 18
'
'txtPreis
'
Me.txtPreis.AutoSize = True
Me.txtPreis.Location = New System.Drawing.Point(553, 181)
Me.txtPreis.Location = New System.Drawing.Point(553, 188)
Me.txtPreis.Name = "txtPreis"
Me.txtPreis.Size = New System.Drawing.Size(13, 13)
Me.txtPreis.TabIndex = 19
@@ -224,35 +230,45 @@ Partial Class frmEssensbestellungen
'Label2
'
Me.Label2.AutoSize = True
Me.Label2.Location = New System.Drawing.Point(463, 181)
Me.Label2.Location = New System.Drawing.Point(463, 188)
Me.Label2.Name = "Label2"
Me.Label2.Size = New System.Drawing.Size(68, 13)
Me.Label2.TabIndex = 18
Me.Label2.Text = "Gesamtpreis:"
'
'Dienstag
'GroupBoxDienstag
'
Me.Dienstag.Controls.Add(Me.pbDienstag)
Me.Dienstag.Controls.Add(Me.cbDienstag)
Me.Dienstag.Controls.Add(Me.txtAltDi)
Me.Dienstag.Controls.Add(Me.rbMenuAlt_Di)
Me.Dienstag.Controls.Add(Me.rbMenu_Di)
Me.Dienstag.Location = New System.Drawing.Point(225, 8)
Me.Dienstag.Name = "Dienstag"
Me.Dienstag.Size = New System.Drawing.Size(200, 95)
Me.Dienstag.TabIndex = 13
Me.Dienstag.TabStop = False
Me.Dienstag.Text = "Dienstag"
Me.GroupBoxDienstag.Controls.Add(Me.txtMenuDi)
Me.GroupBoxDienstag.Controls.Add(Me.pbDienstag)
Me.GroupBoxDienstag.Controls.Add(Me.cbDienstag)
Me.GroupBoxDienstag.Controls.Add(Me.txtAltDi)
Me.GroupBoxDienstag.Controls.Add(Me.rbMenuAlt_Di)
Me.GroupBoxDienstag.Controls.Add(Me.rbMenu_Di)
Me.GroupBoxDienstag.Location = New System.Drawing.Point(225, 8)
Me.GroupBoxDienstag.Name = "GroupBoxDienstag"
Me.GroupBoxDienstag.Size = New System.Drawing.Size(200, 121)
Me.GroupBoxDienstag.TabIndex = 13
Me.GroupBoxDienstag.TabStop = False
Me.GroupBoxDienstag.Text = "Dienstag"
'
'txtMenuDi
'
Me.txtMenuDi.Location = New System.Drawing.Point(0, 39)
Me.txtMenuDi.Name = "txtMenuDi"
Me.txtMenuDi.Size = New System.Drawing.Size(188, 32)
Me.txtMenuDi.TabIndex = 30
Me.txtMenuDi.Text = "Menutext"
'
'pbDienstag
'
Me.pbDienstag.Image = Global.AVISO.My.Resources.Resources.documents
Me.pbDienstag.Location = New System.Drawing.Point(61, 19)
Me.pbDienstag.Location = New System.Drawing.Point(168, 19)
Me.pbDienstag.Name = "pbDienstag"
Me.pbDienstag.Size = New System.Drawing.Size(26, 26)
Me.pbDienstag.SizeMode = System.Windows.Forms.PictureBoxSizeMode.StretchImage
Me.pbDienstag.TabIndex = 5
Me.pbDienstag.TabStop = False
Me.pbDienstag.Visible = False
'
'cbDienstag
'
@@ -279,7 +295,7 @@ Partial Class frmEssensbestellungen
Me.txtAltDi._Waehrung = False
Me.txtAltDi._WaehrungZeichen = True
Me.txtAltDi.ForeColor = System.Drawing.Color.Black
Me.txtAltDi.Location = New System.Drawing.Point(0, 65)
Me.txtAltDi.Location = New System.Drawing.Point(0, 93)
Me.txtAltDi.MaxLineLength = -1
Me.txtAltDi.MaxLines_Warning = ""
Me.txtAltDi.MaxLines_Warning_Label = Nothing
@@ -292,7 +308,7 @@ Partial Class frmEssensbestellungen
'
Me.rbMenuAlt_Di.AutoSize = True
Me.rbMenuAlt_Di.GroupName = "Dienstag"
Me.rbMenuAlt_Di.Location = New System.Drawing.Point(3, 42)
Me.rbMenuAlt_Di.Location = New System.Drawing.Point(3, 74)
Me.rbMenuAlt_Di.Name = "rbMenuAlt_Di"
Me.rbMenuAlt_Di.Size = New System.Drawing.Size(70, 17)
Me.rbMenuAlt_Di.TabIndex = 1
@@ -315,35 +331,55 @@ Partial Class frmEssensbestellungen
'lbl1
'
Me.lbl1.AutoSize = True
Me.lbl1.Location = New System.Drawing.Point(463, 128)
Me.lbl1.Location = New System.Drawing.Point(463, 135)
Me.lbl1.Name = "lbl1"
Me.lbl1.Size = New System.Drawing.Size(72, 13)
Me.lbl1.TabIndex = 14
Me.lbl1.Text = "Anzahl Menü:"
'
'GroupBox1
'Button1
'
Me.GroupBox1.Controls.Add(Me.pbMontag)
Me.GroupBox1.Controls.Add(Me.cbMontag)
Me.GroupBox1.Controls.Add(Me.txtAltMo)
Me.GroupBox1.Controls.Add(Me.rbMenoAlt_Mo)
Me.GroupBox1.Controls.Add(Me.rbMenu_Mo)
Me.GroupBox1.Location = New System.Drawing.Point(6, 8)
Me.GroupBox1.Name = "GroupBox1"
Me.GroupBox1.Size = New System.Drawing.Size(200, 95)
Me.GroupBox1.TabIndex = 12
Me.GroupBox1.TabStop = False
Me.GroupBox1.Text = "Montag"
Me.Button1.Image = Global.AVISO.My.Resources.Resources.pdf
Me.Button1.Location = New System.Drawing.Point(599, 140)
Me.Button1.Name = "Button1"
Me.Button1.Size = New System.Drawing.Size(54, 57)
Me.Button1.TabIndex = 20
Me.Button1.UseVisualStyleBackColor = True
Me.Button1.Visible = False
'
'GroupBoxMontag
'
Me.GroupBoxMontag.Controls.Add(Me.txtMenuMo)
Me.GroupBoxMontag.Controls.Add(Me.pbMontag)
Me.GroupBoxMontag.Controls.Add(Me.cbMontag)
Me.GroupBoxMontag.Controls.Add(Me.txtAltMo)
Me.GroupBoxMontag.Controls.Add(Me.rbMenuAlt_Mo)
Me.GroupBoxMontag.Controls.Add(Me.rbMenu_Mo)
Me.GroupBoxMontag.Location = New System.Drawing.Point(6, 8)
Me.GroupBoxMontag.Name = "GroupBoxMontag"
Me.GroupBoxMontag.Size = New System.Drawing.Size(200, 121)
Me.GroupBoxMontag.TabIndex = 12
Me.GroupBoxMontag.TabStop = False
Me.GroupBoxMontag.Text = "Montag"
'
'txtMenuMo
'
Me.txtMenuMo.Location = New System.Drawing.Point(6, 39)
Me.txtMenuMo.Name = "txtMenuMo"
Me.txtMenuMo.Size = New System.Drawing.Size(188, 32)
Me.txtMenuMo.TabIndex = 29
Me.txtMenuMo.Text = "Menutext"
'
'pbMontag
'
Me.pbMontag.Image = Global.AVISO.My.Resources.Resources.documents
Me.pbMontag.Location = New System.Drawing.Point(61, 19)
Me.pbMontag.Location = New System.Drawing.Point(168, 19)
Me.pbMontag.Name = "pbMontag"
Me.pbMontag.Size = New System.Drawing.Size(26, 26)
Me.pbMontag.SizeMode = System.Windows.Forms.PictureBoxSizeMode.StretchImage
Me.pbMontag.TabIndex = 4
Me.pbMontag.TabStop = False
Me.pbMontag.Visible = False
'
'cbMontag
'
@@ -370,7 +406,7 @@ Partial Class frmEssensbestellungen
Me.txtAltMo._Waehrung = False
Me.txtAltMo._WaehrungZeichen = True
Me.txtAltMo.ForeColor = System.Drawing.Color.Black
Me.txtAltMo.Location = New System.Drawing.Point(0, 65)
Me.txtAltMo.Location = New System.Drawing.Point(3, 92)
Me.txtAltMo.MaxLineLength = -1
Me.txtAltMo.MaxLines_Warning = ""
Me.txtAltMo.MaxLines_Warning_Label = Nothing
@@ -379,17 +415,17 @@ Partial Class frmEssensbestellungen
Me.txtAltMo.TabIndex = 2
Me.txtAltMo.Visible = False
'
'rbMenoAlt_Mo
'rbMenuAlt_Mo
'
Me.rbMenoAlt_Mo.AutoSize = True
Me.rbMenoAlt_Mo.GroupName = "GroupBox1"
Me.rbMenoAlt_Mo.Location = New System.Drawing.Point(3, 42)
Me.rbMenoAlt_Mo.Name = "rbMenoAlt_Mo"
Me.rbMenoAlt_Mo.Size = New System.Drawing.Size(70, 17)
Me.rbMenoAlt_Mo.TabIndex = 1
Me.rbMenoAlt_Mo.TabStop = True
Me.rbMenoAlt_Mo.Text = "A la carte"
Me.rbMenoAlt_Mo.UseVisualStyleBackColor = True
Me.rbMenuAlt_Mo.AutoSize = True
Me.rbMenuAlt_Mo.GroupName = "GroupBox1"
Me.rbMenuAlt_Mo.Location = New System.Drawing.Point(6, 74)
Me.rbMenuAlt_Mo.Name = "rbMenuAlt_Mo"
Me.rbMenuAlt_Mo.Size = New System.Drawing.Size(70, 17)
Me.rbMenuAlt_Mo.TabIndex = 1
Me.rbMenuAlt_Mo.TabStop = True
Me.rbMenuAlt_Mo.Text = "A la carte"
Me.rbMenuAlt_Mo.UseVisualStyleBackColor = True
'
'rbMenu_Mo
'
@@ -403,29 +439,39 @@ Partial Class frmEssensbestellungen
Me.rbMenu_Mo.Text = "Menü"
Me.rbMenu_Mo.UseVisualStyleBackColor = True
'
'GroupBox5
'GroupBoxFreitag
'
Me.GroupBox5.Controls.Add(Me.pbFreitag)
Me.GroupBox5.Controls.Add(Me.cbFreitag)
Me.GroupBox5.Controls.Add(Me.txtAltFr)
Me.GroupBox5.Controls.Add(Me.rbMenuAlt_Fr)
Me.GroupBox5.Controls.Add(Me.rbMenu_Fr)
Me.GroupBox5.Location = New System.Drawing.Point(225, 109)
Me.GroupBox5.Name = "GroupBox5"
Me.GroupBox5.Size = New System.Drawing.Size(200, 95)
Me.GroupBox5.TabIndex = 13
Me.GroupBox5.TabStop = False
Me.GroupBox5.Text = "Freitag"
Me.GroupBoxFreitag.Controls.Add(Me.txtMenuFr)
Me.GroupBoxFreitag.Controls.Add(Me.pbFreitag)
Me.GroupBoxFreitag.Controls.Add(Me.cbFreitag)
Me.GroupBoxFreitag.Controls.Add(Me.txtAltFr)
Me.GroupBoxFreitag.Controls.Add(Me.rbMenuAlt_Fr)
Me.GroupBoxFreitag.Controls.Add(Me.rbMenu_Fr)
Me.GroupBoxFreitag.Location = New System.Drawing.Point(219, 135)
Me.GroupBoxFreitag.Name = "GroupBoxFreitag"
Me.GroupBoxFreitag.Size = New System.Drawing.Size(200, 121)
Me.GroupBoxFreitag.TabIndex = 13
Me.GroupBoxFreitag.TabStop = False
Me.GroupBoxFreitag.Text = "Freitag"
'
'txtMenuFr
'
Me.txtMenuFr.Location = New System.Drawing.Point(3, 39)
Me.txtMenuFr.Name = "txtMenuFr"
Me.txtMenuFr.Size = New System.Drawing.Size(188, 32)
Me.txtMenuFr.TabIndex = 32
Me.txtMenuFr.Text = "Menutext"
'
'pbFreitag
'
Me.pbFreitag.Image = Global.AVISO.My.Resources.Resources.documents
Me.pbFreitag.Location = New System.Drawing.Point(67, 19)
Me.pbFreitag.Location = New System.Drawing.Point(168, 19)
Me.pbFreitag.Name = "pbFreitag"
Me.pbFreitag.Size = New System.Drawing.Size(26, 26)
Me.pbFreitag.SizeMode = System.Windows.Forms.PictureBoxSizeMode.StretchImage
Me.pbFreitag.TabIndex = 8
Me.pbFreitag.TabStop = False
Me.pbFreitag.Visible = False
'
'cbFreitag
'
@@ -452,7 +498,7 @@ Partial Class frmEssensbestellungen
Me.txtAltFr._Waehrung = False
Me.txtAltFr._WaehrungZeichen = True
Me.txtAltFr.ForeColor = System.Drawing.Color.Black
Me.txtAltFr.Location = New System.Drawing.Point(0, 65)
Me.txtAltFr.Location = New System.Drawing.Point(-3, 97)
Me.txtAltFr.MaxLineLength = -1
Me.txtAltFr.MaxLines_Warning = ""
Me.txtAltFr.MaxLines_Warning_Label = Nothing
@@ -465,7 +511,7 @@ Partial Class frmEssensbestellungen
'
Me.rbMenuAlt_Fr.AutoSize = True
Me.rbMenuAlt_Fr.GroupName = "Freitag"
Me.rbMenuAlt_Fr.Location = New System.Drawing.Point(3, 42)
Me.rbMenuAlt_Fr.Location = New System.Drawing.Point(0, 78)
Me.rbMenuAlt_Fr.Name = "rbMenuAlt_Fr"
Me.rbMenuAlt_Fr.Size = New System.Drawing.Size(70, 17)
Me.rbMenuAlt_Fr.TabIndex = 1
@@ -488,7 +534,7 @@ Partial Class frmEssensbestellungen
'txtAnzahlLaCart
'
Me.txtAnzahlLaCart.AutoSize = True
Me.txtAnzahlLaCart.Location = New System.Drawing.Point(553, 155)
Me.txtAnzahlLaCart.Location = New System.Drawing.Point(553, 162)
Me.txtAnzahlLaCart.Name = "txtAnzahlLaCart"
Me.txtAnzahlLaCart.Size = New System.Drawing.Size(13, 13)
Me.txtAnzahlLaCart.TabIndex = 17
@@ -497,7 +543,7 @@ Partial Class frmEssensbestellungen
'lbl2
'
Me.lbl2.AutoSize = True
Me.lbl2.Location = New System.Drawing.Point(463, 155)
Me.lbl2.Location = New System.Drawing.Point(463, 162)
Me.lbl2.Name = "lbl2"
Me.lbl2.Size = New System.Drawing.Size(90, 13)
Me.lbl2.TabIndex = 15
@@ -505,6 +551,7 @@ Partial Class frmEssensbestellungen
'
'Mittwoch
'
Me.Mittwoch.Controls.Add(Me.txtMenuMi)
Me.Mittwoch.Controls.Add(Me.pbMittwoch)
Me.Mittwoch.Controls.Add(Me.cbMittwoch)
Me.Mittwoch.Controls.Add(Me.txtAltMi)
@@ -512,20 +559,29 @@ Partial Class frmEssensbestellungen
Me.Mittwoch.Controls.Add(Me.rbMenu_Mi)
Me.Mittwoch.Location = New System.Drawing.Point(431, 8)
Me.Mittwoch.Name = "Mittwoch"
Me.Mittwoch.Size = New System.Drawing.Size(200, 95)
Me.Mittwoch.Size = New System.Drawing.Size(200, 121)
Me.Mittwoch.TabIndex = 13
Me.Mittwoch.TabStop = False
Me.Mittwoch.Text = "Mittwoch"
'
'txtMenuMi
'
Me.txtMenuMi.Location = New System.Drawing.Point(0, 39)
Me.txtMenuMi.Name = "txtMenuMi"
Me.txtMenuMi.Size = New System.Drawing.Size(188, 32)
Me.txtMenuMi.TabIndex = 31
Me.txtMenuMi.Text = "Menutext"
'
'pbMittwoch
'
Me.pbMittwoch.Image = Global.AVISO.My.Resources.Resources.documents
Me.pbMittwoch.Location = New System.Drawing.Point(61, 19)
Me.pbMittwoch.Location = New System.Drawing.Point(168, 19)
Me.pbMittwoch.Name = "pbMittwoch"
Me.pbMittwoch.Size = New System.Drawing.Size(26, 26)
Me.pbMittwoch.SizeMode = System.Windows.Forms.PictureBoxSizeMode.StretchImage
Me.pbMittwoch.TabIndex = 6
Me.pbMittwoch.TabStop = False
Me.pbMittwoch.Visible = False
'
'cbMittwoch
'
@@ -552,7 +608,7 @@ Partial Class frmEssensbestellungen
Me.txtAltMi._Waehrung = False
Me.txtAltMi._WaehrungZeichen = True
Me.txtAltMi.ForeColor = System.Drawing.Color.Black
Me.txtAltMi.Location = New System.Drawing.Point(0, 65)
Me.txtAltMi.Location = New System.Drawing.Point(0, 93)
Me.txtAltMi.MaxLineLength = -1
Me.txtAltMi.MaxLines_Warning = ""
Me.txtAltMi.MaxLines_Warning_Label = Nothing
@@ -565,7 +621,7 @@ Partial Class frmEssensbestellungen
'
Me.rbMenuAlt_Mi.AutoSize = True
Me.rbMenuAlt_Mi.GroupName = "Mittwoch"
Me.rbMenuAlt_Mi.Location = New System.Drawing.Point(3, 42)
Me.rbMenuAlt_Mi.Location = New System.Drawing.Point(3, 74)
Me.rbMenuAlt_Mi.Name = "rbMenuAlt_Mi"
Me.rbMenuAlt_Mi.Size = New System.Drawing.Size(70, 17)
Me.rbMenuAlt_Mi.TabIndex = 1
@@ -585,29 +641,39 @@ Partial Class frmEssensbestellungen
Me.rbMenu_Mi.Text = "Menü"
Me.rbMenu_Mi.UseVisualStyleBackColor = True
'
'GroupBox4
'GroupBoxDonnerstag
'
Me.GroupBox4.Controls.Add(Me.pbDonnerstag)
Me.GroupBox4.Controls.Add(Me.cbDonnerstag)
Me.GroupBox4.Controls.Add(Me.txtAltDo)
Me.GroupBox4.Controls.Add(Me.rbMenuAlt_Do)
Me.GroupBox4.Controls.Add(Me.rbMenu_Do)
Me.GroupBox4.Location = New System.Drawing.Point(3, 109)
Me.GroupBox4.Name = "GroupBox4"
Me.GroupBox4.Size = New System.Drawing.Size(200, 95)
Me.GroupBox4.TabIndex = 13
Me.GroupBox4.TabStop = False
Me.GroupBox4.Text = "Donnerstag"
Me.GroupBoxDonnerstag.Controls.Add(Me.txtMenuDo)
Me.GroupBoxDonnerstag.Controls.Add(Me.pbDonnerstag)
Me.GroupBoxDonnerstag.Controls.Add(Me.cbDonnerstag)
Me.GroupBoxDonnerstag.Controls.Add(Me.txtAltDo)
Me.GroupBoxDonnerstag.Controls.Add(Me.rbMenuAlt_Do)
Me.GroupBoxDonnerstag.Controls.Add(Me.rbMenu_Do)
Me.GroupBoxDonnerstag.Location = New System.Drawing.Point(3, 135)
Me.GroupBoxDonnerstag.Name = "GroupBoxDonnerstag"
Me.GroupBoxDonnerstag.Size = New System.Drawing.Size(200, 121)
Me.GroupBoxDonnerstag.TabIndex = 13
Me.GroupBoxDonnerstag.TabStop = False
Me.GroupBoxDonnerstag.Text = "Donnerstag"
'
'txtMenuDo
'
Me.txtMenuDo.Location = New System.Drawing.Point(3, 39)
Me.txtMenuDo.Name = "txtMenuDo"
Me.txtMenuDo.Size = New System.Drawing.Size(188, 32)
Me.txtMenuDo.TabIndex = 33
Me.txtMenuDo.Text = "Menutext"
'
'pbDonnerstag
'
Me.pbDonnerstag.Image = Global.AVISO.My.Resources.Resources.documents
Me.pbDonnerstag.Location = New System.Drawing.Point(56, 19)
Me.pbDonnerstag.Location = New System.Drawing.Point(171, 19)
Me.pbDonnerstag.Name = "pbDonnerstag"
Me.pbDonnerstag.Size = New System.Drawing.Size(26, 26)
Me.pbDonnerstag.SizeMode = System.Windows.Forms.PictureBoxSizeMode.StretchImage
Me.pbDonnerstag.TabIndex = 7
Me.pbDonnerstag.TabStop = False
Me.pbDonnerstag.Visible = False
'
'cbDonnerstag
'
@@ -634,7 +700,7 @@ Partial Class frmEssensbestellungen
Me.txtAltDo._Waehrung = False
Me.txtAltDo._WaehrungZeichen = True
Me.txtAltDo.ForeColor = System.Drawing.Color.Black
Me.txtAltDo.Location = New System.Drawing.Point(0, 65)
Me.txtAltDo.Location = New System.Drawing.Point(1, 97)
Me.txtAltDo.MaxLineLength = -1
Me.txtAltDo.MaxLines_Warning = ""
Me.txtAltDo.MaxLines_Warning_Label = Nothing
@@ -647,7 +713,7 @@ Partial Class frmEssensbestellungen
'
Me.rbMenuAlt_Do.AutoSize = True
Me.rbMenuAlt_Do.GroupName = "Donnerstag"
Me.rbMenuAlt_Do.Location = New System.Drawing.Point(3, 42)
Me.rbMenuAlt_Do.Location = New System.Drawing.Point(4, 78)
Me.rbMenuAlt_Do.Name = "rbMenuAlt_Do"
Me.rbMenuAlt_Do.Size = New System.Drawing.Size(70, 17)
Me.rbMenuAlt_Do.TabIndex = 1
@@ -670,22 +736,12 @@ Partial Class frmEssensbestellungen
'txtAnzahlMenu
'
Me.txtAnzahlMenu.AutoSize = True
Me.txtAnzahlMenu.Location = New System.Drawing.Point(553, 130)
Me.txtAnzahlMenu.Location = New System.Drawing.Point(553, 137)
Me.txtAnzahlMenu.Name = "txtAnzahlMenu"
Me.txtAnzahlMenu.Size = New System.Drawing.Size(13, 13)
Me.txtAnzahlMenu.TabIndex = 16
Me.txtAnzahlMenu.Text = "0"
'
'Button1
'
Me.Button1.Image = Global.AVISO.My.Resources.Resources.pdf
Me.Button1.Location = New System.Drawing.Point(599, 133)
Me.Button1.Name = "Button1"
Me.Button1.Size = New System.Drawing.Size(54, 57)
Me.Button1.TabIndex = 20
Me.Button1.UseVisualStyleBackColor = True
Me.Button1.Visible = False
'
'dgvBestellungen
'
Me.dgvBestellungen.AKTUALISIERUNGS_INTERVALL = -1
@@ -712,7 +768,7 @@ Partial Class frmEssensbestellungen
DataGridViewCellStyle2.SelectionForeColor = System.Drawing.SystemColors.HighlightText
DataGridViewCellStyle2.WrapMode = System.Windows.Forms.DataGridViewTriState.[False]
Me.dgvBestellungen.DefaultCellStyle = DataGridViewCellStyle2
Me.dgvBestellungen.Location = New System.Drawing.Point(16, 313)
Me.dgvBestellungen.Location = New System.Drawing.Point(16, 360)
Me.dgvBestellungen.Name = "dgvBestellungen"
Me.dgvBestellungen.ReadOnly = True
DataGridViewCellStyle3.Alignment = System.Windows.Forms.DataGridViewContentAlignment.MiddleLeft
@@ -751,7 +807,7 @@ Partial Class frmEssensbestellungen
'
'Button2
'
Me.Button2.Location = New System.Drawing.Point(499, 286)
Me.Button2.Location = New System.Drawing.Point(499, 323)
Me.Button2.Name = "Button2"
Me.Button2.Size = New System.Drawing.Size(180, 21)
Me.Button2.TabIndex = 25
@@ -794,11 +850,21 @@ Partial Class frmEssensbestellungen
Me.Label1.TabIndex = 28
Me.Label1.Text = "Menü"
'
'lblTest
'
Me.lblTest.AutoSize = True
Me.lblTest.ForeColor = System.Drawing.Color.Red
Me.lblTest.Location = New System.Drawing.Point(16, 1)
Me.lblTest.Name = "lblTest"
Me.lblTest.Size = New System.Drawing.Size(0, 13)
Me.lblTest.TabIndex = 29
'
'frmEssensbestellungen
'
Me.AutoScaleDimensions = New System.Drawing.SizeF(6.0!, 13.0!)
Me.AutoScaleMode = System.Windows.Forms.AutoScaleMode.Font
Me.ClientSize = New System.Drawing.Size(687, 518)
Me.ClientSize = New System.Drawing.Size(687, 565)
Me.Controls.Add(Me.lblTest)
Me.Controls.Add(Me.Label1)
Me.Controls.Add(Me.PictureBox1)
Me.Controls.Add(Me.txtMA)
@@ -822,20 +888,20 @@ Partial Class frmEssensbestellungen
Me.Text = "Essensbestellung"
Me.MyPanel1.ResumeLayout(False)
Me.MyPanel1.PerformLayout()
Me.Dienstag.ResumeLayout(False)
Me.Dienstag.PerformLayout()
Me.GroupBoxDienstag.ResumeLayout(False)
Me.GroupBoxDienstag.PerformLayout()
CType(Me.pbDienstag, System.ComponentModel.ISupportInitialize).EndInit()
Me.GroupBox1.ResumeLayout(False)
Me.GroupBox1.PerformLayout()
Me.GroupBoxMontag.ResumeLayout(False)
Me.GroupBoxMontag.PerformLayout()
CType(Me.pbMontag, System.ComponentModel.ISupportInitialize).EndInit()
Me.GroupBox5.ResumeLayout(False)
Me.GroupBox5.PerformLayout()
Me.GroupBoxFreitag.ResumeLayout(False)
Me.GroupBoxFreitag.PerformLayout()
CType(Me.pbFreitag, System.ComponentModel.ISupportInitialize).EndInit()
Me.Mittwoch.ResumeLayout(False)
Me.Mittwoch.PerformLayout()
CType(Me.pbMittwoch, System.ComponentModel.ISupportInitialize).EndInit()
Me.GroupBox4.ResumeLayout(False)
Me.GroupBox4.PerformLayout()
Me.GroupBoxDonnerstag.ResumeLayout(False)
Me.GroupBoxDonnerstag.PerformLayout()
CType(Me.pbDonnerstag, System.ComponentModel.ISupportInitialize).EndInit()
CType(Me.dgvBestellungen, System.ComponentModel.ISupportInitialize).EndInit()
CType(Me.PictureBox1, System.ComponentModel.ISupportInitialize).EndInit()
@@ -849,11 +915,11 @@ Partial Class frmEssensbestellungen
Friend WithEvents dgvBestellungen As VERAG_PROG_ALLGEMEIN.MyDatagridview
Friend WithEvents btnSave As Button
Friend WithEvents lblDatum As Label
Friend WithEvents GroupBox1 As GroupBox
Friend WithEvents GroupBoxMontag As GroupBox
Friend WithEvents txtAltMo As VERAG_PROG_ALLGEMEIN.MyTextBox
Friend WithEvents rbMenoAlt_Mo As VERAG_PROG_ALLGEMEIN.MyRadioButton
Friend WithEvents rbMenuAlt_Mo As VERAG_PROG_ALLGEMEIN.MyRadioButton
Friend WithEvents rbMenu_Mo As VERAG_PROG_ALLGEMEIN.MyRadioButton
Friend WithEvents Dienstag As GroupBox
Friend WithEvents GroupBoxDienstag As GroupBox
Friend WithEvents txtAltDi As VERAG_PROG_ALLGEMEIN.MyTextBox
Friend WithEvents rbMenuAlt_Di As VERAG_PROG_ALLGEMEIN.MyRadioButton
Friend WithEvents rbMenu_Di As VERAG_PROG_ALLGEMEIN.MyRadioButton
@@ -861,11 +927,11 @@ Partial Class frmEssensbestellungen
Friend WithEvents txtAltMi As VERAG_PROG_ALLGEMEIN.MyTextBox
Friend WithEvents rbMenuAlt_Mi As VERAG_PROG_ALLGEMEIN.MyRadioButton
Friend WithEvents rbMenu_Mi As VERAG_PROG_ALLGEMEIN.MyRadioButton
Friend WithEvents GroupBox4 As GroupBox
Friend WithEvents GroupBoxDonnerstag As GroupBox
Friend WithEvents txtAltDo As VERAG_PROG_ALLGEMEIN.MyTextBox
Friend WithEvents rbMenuAlt_Do As VERAG_PROG_ALLGEMEIN.MyRadioButton
Friend WithEvents rbMenu_Do As VERAG_PROG_ALLGEMEIN.MyRadioButton
Friend WithEvents GroupBox5 As GroupBox
Friend WithEvents GroupBoxFreitag As GroupBox
Friend WithEvents txtAltFr As VERAG_PROG_ALLGEMEIN.MyTextBox
Friend WithEvents rbMenuAlt_Fr As VERAG_PROG_ALLGEMEIN.MyRadioButton
Friend WithEvents rbMenu_Fr As VERAG_PROG_ALLGEMEIN.MyRadioButton
@@ -903,4 +969,10 @@ Partial Class frmEssensbestellungen
Friend WithEvents Label3 As Label
Friend WithEvents PictureBox1 As PictureBox
Friend WithEvents Label1 As Label
Friend WithEvents txtMenuDi As Label
Friend WithEvents txtMenuMo As Label
Friend WithEvents txtMenuFr As Label
Friend WithEvents txtMenuMi As Label
Friend WithEvents txtMenuDo As Label
Friend WithEvents lblTest As Label
End Class

View File

@@ -8,7 +8,8 @@ Public Class frmEssensbestellungen
Dim dt As New DataTable
Dim ttMontag, ttDienstag, ttMittwoch, ttDonnerstag, ttFreitag As New ToolTip()
Private ToolTipFont As New Font("Courier New", 12)
Dim essenMontag As String = ""
Dim preisProMahlzeit As Double = 3
Dim menu As String = "Menü:"
@@ -100,7 +101,7 @@ Public Class frmEssensbestellungen
End If
essen.eb_datum = CDate(dt.Rows(0).Item("MenuDateVon"))
essen.eb_gebaeude = cbxGebauede._value
essen.SAVE()
loadDGVBestellungen()
@@ -145,14 +146,14 @@ Public Class frmEssensbestellungen
btnSave.Enabled = False
End If
uncheckGroupBoxes(sender, e)
uncheckGroupBoxesAndRadioButtons(sender, e)
loadDGVBestellungen()
End Sub
Private Sub rbaLaCarte_CheckedChanged(sender As Object, e As EventArgs) Handles rbMenoAlt_Mo.CheckedChanged, rbMenuAlt_Di.CheckedChanged, rbMenuAlt_Do.CheckedChanged, rbMenuAlt_Mi.CheckedChanged, rbMenuAlt_Fr.CheckedChanged
Private Sub rbaLaCarte_CheckedChanged(sender As Object, e As EventArgs) Handles rbMenuAlt_Mo.CheckedChanged, rbMenuAlt_Di.CheckedChanged, rbMenuAlt_Do.CheckedChanged, rbMenuAlt_Mi.CheckedChanged, rbMenuAlt_Fr.CheckedChanged
If rbMenoAlt_Mo.Checked Then
If rbMenuAlt_Mo.Checked Then
txtAltMo.Visible = True
Else
txtAltMo.Visible = False
@@ -188,10 +189,13 @@ Public Class frmEssensbestellungen
Private Sub cbFields_CheckedChanged(sender As Object, e As EventArgs) Handles cbMontag.CheckedChanged, cbDienstag.CheckedChanged, cbMittwoch.CheckedChanged, cbDonnerstag.CheckedChanged, cbFreitag.CheckedChanged
If cbMontag.Checked Then
rbMenoAlt_Mo.Enabled = True
rbMenuAlt_Mo.Enabled = True
rbMenu_Mo.Enabled = True
If checkIfGroupBoxIsSetFirstTime(GroupBoxMontag) Then
rbMenu_Mo.Checked = True
End If
Else
rbMenoAlt_Mo.Enabled = False
rbMenuAlt_Mo.Enabled = False
rbMenu_Mo.Enabled = False
txtAltMo.Text = ""
End If
@@ -199,6 +203,9 @@ Public Class frmEssensbestellungen
If cbDienstag.Checked Then
rbMenuAlt_Di.Enabled = True
rbMenu_Di.Enabled = True
If checkIfGroupBoxIsSetFirstTime(GroupBoxDienstag) Then
rbMenu_Di.Checked = True
End If
Else
rbMenu_Di.Enabled = False
rbMenuAlt_Di.Enabled = False
@@ -208,6 +215,9 @@ Public Class frmEssensbestellungen
If cbMittwoch.Checked Then
rbMenuAlt_Mi.Enabled = True
rbMenu_Mi.Enabled = True
If checkIfGroupBoxIsSetFirstTime(Mittwoch) Then
rbMenu_Mi.Checked = True
End If
Else
rbMenu_Mi.Enabled = False
rbMenuAlt_Mi.Enabled = False
@@ -218,6 +228,9 @@ Public Class frmEssensbestellungen
If cbDonnerstag.Checked Then
rbMenuAlt_Do.Enabled = True
rbMenu_Do.Enabled = True
If checkIfGroupBoxIsSetFirstTime(GroupBoxDonnerstag) Then
rbMenu_Do.Checked = True
End If
Else
rbMenu_Do.Enabled = False
rbMenuAlt_Do.Enabled = False
@@ -227,6 +240,9 @@ Public Class frmEssensbestellungen
If cbFreitag.Checked Then
rbMenuAlt_Fr.Enabled = True
rbMenu_Fr.Enabled = True
If checkIfGroupBoxIsSetFirstTime(GroupBoxFreitag) Then
rbMenu_Fr.Checked = True
End If
Else
rbMenu_Fr.Enabled = False
rbMenuAlt_Fr.Enabled = False
@@ -276,7 +292,7 @@ Public Class frmEssensbestellungen
End Sub
Private Sub uncheckGroupBoxes(sender, e)
Private Sub uncheckGroupBoxesAndRadioButtons(sender, e)
For Each gb As Control In MyPanel1.Controls
If TypeOf gb Is GroupBox Then
For Each c As Control In gb.Controls
@@ -284,6 +300,11 @@ Public Class frmEssensbestellungen
Dim checkbox As CheckBox = c
checkbox.Checked = False
End If
If TypeOf c Is RadioButton Then
Dim radiobutton As RadioButton = c
radiobutton.Checked = False
End If
Next
End If
Next
@@ -315,7 +336,7 @@ Public Class frmEssensbestellungen
txtAnzahlMenu.Text = countMenus.ToString()
txtAnzahlLaCart.Text = countlaCarte.ToString
txtPreis.Text = (CDbl(countlaCarte) + CDbl(countMenus)) * 3
txtPreis.Text = (CDbl(countlaCarte) + CDbl(countMenus)) * preisProMahlzeit
End Sub
@@ -323,15 +344,21 @@ Public Class frmEssensbestellungen
Private Sub loadMenuInfo(dt As DataTable)
If dt.Rows(0).Item("MenuEssenMo") IsNot Nothing Then
pbMontag.Visible = True
'pbMontag.Visible = True
rbMenu_Mo.Text = menu
txtMenuMo.Text = dt.Rows(0).Item("MenuEssenMo").ToString
ttMontag.SetToolTip(pbMontag, dt.Rows(0).Item("MenuEssenMo").ToString)
Else
pbMontag.Visible = False
txtMenuMo.Text = ""
End If
If dt.Rows(0).Item("MenuEssenDi") IsNot Nothing Then
pbDienstag.Visible = True
'pbDienstag.Visible = True
rbMenu_Di.Text = menu
txtMenuDi.Text = dt.Rows(0).Item("MenuEssenDi").ToString()
ttDienstag.SetToolTip(pbDienstag, dt.Rows(0).Item("MenuEssenDi").ToString)
Else
@@ -340,21 +367,27 @@ Public Class frmEssensbestellungen
If dt.Rows(0).Item("MenuEssenMi") IsNot Nothing Then
pbMittwoch.Visible = True
'pbMittwoch.Visible = True
rbMenu_Mi.Text = menu
txtMenuMi.Text = dt.Rows(0).Item("MenuEssenMi").ToString()
ttMittwoch.SetToolTip(pbMittwoch, dt.Rows(0).Item("MenuEssenMi").ToString)
Else
pbMittwoch.Visible = False
End If
If dt.Rows(0).Item("MenuEssenDo") IsNot Nothing Then
pbDonnerstag.Visible = True
'pbDonnerstag.Visible = True
rbMenu_Do.Text = menu
txtMenuDo.Text = dt.Rows(0).Item("MenuEssenDo").ToString()
ttDonnerstag.SetToolTip(pbDonnerstag, dt.Rows(0).Item("MenuEssenDo").ToString)
Else
pbDonnerstag.Visible = False
End If
If dt.Rows(0).Item("MenuEssenFr") IsNot Nothing Then
pbFreitag.Visible = True
'pbFreitag.Visible = True
rbMenu_Fr.Text = menu
txtMenuFr.Text = dt.Rows(0).Item("MenuEssenFr").ToString()
ttFreitag.SetToolTip(pbFreitag, dt.Rows(0).Item("MenuEssenFr").ToString)
Else
pbFreitag.Visible = False
@@ -368,12 +401,14 @@ Public Class frmEssensbestellungen
Dim currentEssen As New cEssensbestellung(dgvBestellungen.CurrentRow.Cells("eb_kw").Value, dgvBestellungen.CurrentRow.Cells("eb_mitid").Value, dgvBestellungen.CurrentRow.Cells("eb_gebaeude").Value, dgvBestellungen.CurrentRow.Cells("eb_abteilung").Value)
cbxMenu.changeItem(currentEssen.eb_kw)
If currentEssen.eb_montag IsNot Nothing Then
cbMontag.Checked = True
If currentEssen.eb_montag.ToString = "Menu" Then
rbMenu_Mo.Checked = True
Else
rbMenoAlt_Mo.Checked = True
rbMenuAlt_Mo.Checked = True
If currentEssen.eb_montag IsNot Nothing Then txtAltMo.Text = currentEssen.eb_montag.ToString
End If
Else
@@ -431,7 +466,7 @@ Public Class frmEssensbestellungen
End If
cbxGebauede._value = currentEssen.eb_gebaeude
cbxGebauede._value = currentEssen.eb_gebaeude.ToString
End Sub
@@ -466,9 +501,16 @@ Public Class frmEssensbestellungen
Try
Dim startMenu = Date.Parse(dt.Rows(0).Item("MenuDateVon"))
Dim tageBisBestellende = 20 '-5
If tageBisBestellende > 0 Then
lblTest.Text = "Zu Testzwecken darf aktuell " & tageBisBestellende & " Tage im Nachhinein bestellt werden!"
Else
lblTest.Text = ""
End If
Dim newTime As New TimeSpan(14, 30, 0)
Dim timeToOrderLimit = startMenu.AddDays(20) + newTime '-5
Dim timeToOrderLimit = startMenu.AddDays(tageBisBestellende) + newTime
lblBestellungBis.Text = "Bestellung möglich bis: " & timeToOrderLimit.ToShortDateString & " - " & timeToOrderLimit.ToShortTimeString
If Now >= timeToOrderLimit Then
@@ -499,4 +541,19 @@ Public Class frmEssensbestellungen
Private Sub Button2_Click(sender As Object, e As EventArgs) Handles Button2.Click
cbxMenu.changeItem("")
End Sub
Private Function checkIfGroupBoxIsSetFirstTime(gb As GroupBox)
For Each c As Control In gb.Controls
If TypeOf c Is RadioButton Then
Dim radioButton As RadioButton = c
If radioButton.Checked = True Then
Return False
End If
End If
Next
Return True
End Function
End Class