From 068d3d8fb2abc085a776cf67ef789f1ea08a6aaf Mon Sep 17 00:00:00 2001 From: "d.breimaier" Date: Mon, 28 Nov 2022 11:46:30 +0100 Subject: [PATCH 01/10] Essensbestellungen --- Aviso/Aviso.vbproj | 9 ++ Aviso/frmEssensbestellungen.Designer.vb | 80 ++++++++++++++++ Aviso/frmEssensbestellungen.resx | 120 ++++++++++++++++++++++++ Aviso/frmEssensbestellungen.vb | 8 ++ Aviso/frmLogin.vb | 6 ++ 5 files changed, 223 insertions(+) create mode 100644 Aviso/frmEssensbestellungen.Designer.vb create mode 100644 Aviso/frmEssensbestellungen.resx create mode 100644 Aviso/frmEssensbestellungen.vb diff --git a/Aviso/Aviso.vbproj b/Aviso/Aviso.vbproj index f2bf7b4..477be57 100644 --- a/Aviso/Aviso.vbproj +++ b/Aviso/Aviso.vbproj @@ -537,6 +537,12 @@ Form + + frmEssensbestellungen.vb + + + Form + frmFrachtkostenBerechnen.vb @@ -1089,6 +1095,9 @@ frmAvisoBenachrichtigungReminderBestaetigen.vb + + frmEssensbestellungen.vb + frmFrachtkostenBerechnen.vb diff --git a/Aviso/frmEssensbestellungen.Designer.vb b/Aviso/frmEssensbestellungen.Designer.vb new file mode 100644 index 0000000..553e7b4 --- /dev/null +++ b/Aviso/frmEssensbestellungen.Designer.vb @@ -0,0 +1,80 @@ + _ +Partial Class frmEssensbestellungen + Inherits System.Windows.Forms.Form + + 'Das Formular überschreibt den Löschvorgang, um die Komponentenliste zu bereinigen. + _ + Protected Overrides Sub Dispose(ByVal disposing As Boolean) + Try + If disposing AndAlso components IsNot Nothing Then + components.Dispose() + End If + Finally + MyBase.Dispose(disposing) + End Try + End Sub + + 'Wird vom Windows Form-Designer benötigt. + Private components As System.ComponentModel.IContainer + + 'Hinweis: Die folgende Prozedur ist für den Windows Form-Designer erforderlich. + 'Das Bearbeiten ist mit dem Windows Form-Designer möglich. + 'Das Bearbeiten mit dem Code-Editor ist nicht möglich. + _ + Private Sub InitializeComponent() + Me.components = New System.ComponentModel.Container() + Me.MyComboBox1 = New VERAG_PROG_ALLGEMEIN.MyComboBox() + Me.lblWochenkarte = New System.Windows.Forms.Label() + Me.MyDatagridview1 = New VERAG_PROG_ALLGEMEIN.MyDatagridview(Me.components) + CType(Me.MyDatagridview1, System.ComponentModel.ISupportInitialize).BeginInit() + Me.SuspendLayout() + ' + 'MyComboBox1 + ' + Me.MyComboBox1._allowedValuesFreiText = Nothing + Me.MyComboBox1._allowFreiText = False + Me.MyComboBox1._value = "" + Me.MyComboBox1.FormattingEnabled = True + Me.MyComboBox1.Location = New System.Drawing.Point(15, 60) + Me.MyComboBox1.Name = "MyComboBox1" + Me.MyComboBox1.Size = New System.Drawing.Size(95, 21) + Me.MyComboBox1.TabIndex = 0 + ' + 'lblWochenkarte + ' + Me.lblWochenkarte.AutoSize = True + Me.lblWochenkarte.Location = New System.Drawing.Point(12, 34) + Me.lblWochenkarte.Name = "lblWochenkarte" + Me.lblWochenkarte.Size = New System.Drawing.Size(39, 13) + Me.lblWochenkarte.TabIndex = 1 + Me.lblWochenkarte.Text = "Label1" + ' + 'MyDatagridview1 + ' + Me.MyDatagridview1.AKTUALISIERUNGS_INTERVALL = -1 + Me.MyDatagridview1.ColumnHeadersHeightSizeMode = System.Windows.Forms.DataGridViewColumnHeadersHeightSizeMode.AutoSize + Me.MyDatagridview1.Location = New System.Drawing.Point(252, 31) + Me.MyDatagridview1.Name = "MyDatagridview1" + Me.MyDatagridview1.Size = New System.Drawing.Size(485, 150) + Me.MyDatagridview1.TabIndex = 2 + ' + 'frmEssensbestellungen + ' + Me.AutoScaleDimensions = New System.Drawing.SizeF(6.0!, 13.0!) + Me.AutoScaleMode = System.Windows.Forms.AutoScaleMode.Font + Me.ClientSize = New System.Drawing.Size(800, 450) + Me.Controls.Add(Me.MyDatagridview1) + Me.Controls.Add(Me.lblWochenkarte) + Me.Controls.Add(Me.MyComboBox1) + Me.Name = "frmEssensbestellungen" + Me.Text = "frmEssensbestellungen" + CType(Me.MyDatagridview1, System.ComponentModel.ISupportInitialize).EndInit() + Me.ResumeLayout(False) + Me.PerformLayout() + + End Sub + + Friend WithEvents MyComboBox1 As VERAG_PROG_ALLGEMEIN.MyComboBox + Friend WithEvents lblWochenkarte As Label + Friend WithEvents MyDatagridview1 As VERAG_PROG_ALLGEMEIN.MyDatagridview +End Class diff --git a/Aviso/frmEssensbestellungen.resx b/Aviso/frmEssensbestellungen.resx new file mode 100644 index 0000000..1af7de1 --- /dev/null +++ b/Aviso/frmEssensbestellungen.resx @@ -0,0 +1,120 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + text/microsoft-resx + + + 2.0 + + + System.Resources.ResXResourceReader, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + + System.Resources.ResXResourceWriter, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + \ No newline at end of file diff --git a/Aviso/frmEssensbestellungen.vb b/Aviso/frmEssensbestellungen.vb new file mode 100644 index 0000000..ba8b925 --- /dev/null +++ b/Aviso/frmEssensbestellungen.vb @@ -0,0 +1,8 @@ +Public Class frmEssensbestellungen + Private Sub frmEssensbestellungen_Load(sender As Object, e As EventArgs) Handles MyBase.Load + 'MyComboBox1.fillWithSQL("Select [MenuTitel] from [GMenu]") + + MyComboBox1.fillWithSQL("Select [MenuTitel] from [GMenu]",, "Gastro", True) + + End Sub +End Class \ No newline at end of file diff --git a/Aviso/frmLogin.vb b/Aviso/frmLogin.vb index 5ddacdb..a809378 100644 --- a/Aviso/frmLogin.vb +++ b/Aviso/frmLogin.vb @@ -4,6 +4,7 @@ Imports VERAG_PROG_ALLGEMEIN Imports System.Reflection Imports System.DirectoryServices +Imports Therefore.API Public Class frmLogin @@ -484,6 +485,11 @@ Public Class frmLogin ' If MsgBox("AUTO-LOGIN?", vbYesNoCancel) = vbYes Then btnOK.PerformClick() End If + If Environment.MachineName = "H6CCWP3" Then + txtSachbear.Text = "daniel" + txtKennwort.Text = "debug" + End If + ' Spire.License.LicenseProvider.SetLicenseKey("PFIX3V0pG5DaAQCBLK1gLRCjwhu+wX1JsEcX0hyXZty9sbe8Zm5XIrWr214umg/g22Jy0+5BJQ6QgRhLl0eUqVMyCAHswvrA+jVz8s20VTNEOTWhzwpLBqoRG6IFh3EGNawUS7a+fW5OVPLApUd3Y+IcKYZihow7+5lKPN6+seKWy5uFjwRFNSBOTAjUGsfEw9sukXvtcnLh2Vo5ttKbPSLb1EeCdgaNd8nWa+RKQk0Rlg4R/7M9BBTURZXCVAoA4kfbNyPnksggPvYPbpVqPqtT9LbjycBLSB/Uwf16fZlVDuDrCJCij2ZI3ebSwM1sumBtXj4WhXk+Mwxj7acdb9saqmOsmyAcd11MZ2NfRAhv2L8S7RLSGr4OYR9/9Fnk9aN9q7T8D51jUfJgV82ZIZMvCpI2RTtsRaOyMandpfpFE96k1kjlVRuWm8JGKUHZV0bETyaBTqpiwn4ShoqdlYlyvIjfjWX/TbWCuy2uSugCC9BLW0P0ND/G2z2kbHQCEiQCRn92TrlvTpQg9veACDn1Lb3savBYyW3VQMuHgybLpq3x9LIV5nrTli87kzqvTuZmUZanhgx0M4BFi2CsWlf28yRpQo2l1HDLjScgzxvXOk3/N9wOlS2gbfeN74iHU0vb1heHfa5ahmRwtgg7C6iYu0WD1u5p/hO3Ja5tkNBxicJO5TJXq3W5U65lCsQDOQbiZCeTJzjYP0SGypIo701hqqVG9hW/Sd2siqb4w/W1H9xKTxDCL+EwCHduLZuNze1gyyxKR5nGCsIhaXBaRCaQ8Z1OHlU25h+yeHwFF1yMKzdbX6VKG+5GjZ3yvSjwqGgFfDPLVr2QxJpLqpAwcdmG7w6xwVoOP81C8Sv60U2UaDLw7I0U1GfMhkqOr0tRtFQRa2iDgPnrZWhiNPPjDYtPyHt5ZwdIoAKaNRpI1f+u6rDJRmyAr4jizBRxHIlsSM86MXRbEvBLkDEyDQPLC3ntaPi5kRn7vObrlDGR7aZEKy+8PkU8qrVw7wgqxQtbc+isO8x6yoe/yTydhFiY1HlUbjPlAM9s+SSV4D2L9oHmYCtO1wdo3Gl0Dj6Mp3hioi9Cyd4+bp/A28ukhQXjtNUhUhNgzcyfP/Fg1at6lj0NPYWvOibJr0I/Fi38AeBM+kXNnuMblXnlawtTjnjGvi/fA9tHz6EI44ChhIrd8a3Kjx2bGcFlVENXe3YDu1W5ZbDOcoERW8qxZLBKqYIMiwQ61ZAq69PXKSZZk+1mi8oyCNS9xpBZndWLKTKG6XqM1FkZew1bTD4GLZRdC4x72iqSmVIu3ZU8rSk7rxGQUNWKIi7gIJhXEnmeWt322KDCxBWDZcrxKKGc8ZIDRL3EmW13/7ow4WowlCUW+lvhlkbwsXDPwqtO+IQJ3UisJFnF2jnFqaLoKELNJx6hfg2iyYR2+gJgiKWLKOzS56Id7o3iY4ou1TZauqSK9A836t36UxXtjYWSk9aoDDhZwlqRbwXok9pds5dC") From 926580e58fedbe48234dc3f957feaaf786a41baf Mon Sep 17 00:00:00 2001 From: "d.breimaier" Date: Mon, 28 Nov 2022 16:50:52 +0100 Subject: [PATCH 02/10] Essensbestellung --- Aviso/frmEssensbestellungen.Designer.vb | 515 +++++++++++++++++++++++- Aviso/frmEssensbestellungen.resx | 15 + Aviso/frmEssensbestellungen.vb | 43 +- Aviso/frmHauptfenster.Designer.vb | 24 +- Aviso/frmHauptfenster.vb | 5 + 5 files changed, 569 insertions(+), 33 deletions(-) diff --git a/Aviso/frmEssensbestellungen.Designer.vb b/Aviso/frmEssensbestellungen.Designer.vb index 553e7b4..b41ab1c 100644 --- a/Aviso/frmEssensbestellungen.Designer.vb +++ b/Aviso/frmEssensbestellungen.Designer.vb @@ -1,9 +1,9 @@ - _ + Partial Class frmEssensbestellungen Inherits System.Windows.Forms.Form 'Das Formular überschreibt den Löschvorgang, um die Komponentenliste zu bereinigen. - _ + Protected Overrides Sub Dispose(ByVal disposing As Boolean) Try If disposing AndAlso components IsNot Nothing Then @@ -20,13 +20,52 @@ Partial Class frmEssensbestellungen 'Hinweis: Die folgende Prozedur ist für den Windows Form-Designer erforderlich. 'Das Bearbeiten ist mit dem Windows Form-Designer möglich. 'Das Bearbeiten mit dem Code-Editor ist nicht möglich. - _ + Private Sub InitializeComponent() Me.components = New System.ComponentModel.Container() + Dim DataGridViewCellStyle4 As System.Windows.Forms.DataGridViewCellStyle = New System.Windows.Forms.DataGridViewCellStyle() + Dim DataGridViewCellStyle5 As System.Windows.Forms.DataGridViewCellStyle = New System.Windows.Forms.DataGridViewCellStyle() + Dim DataGridViewCellStyle6 As System.Windows.Forms.DataGridViewCellStyle = New System.Windows.Forms.DataGridViewCellStyle() Me.MyComboBox1 = New VERAG_PROG_ALLGEMEIN.MyComboBox() Me.lblWochenkarte = New System.Windows.Forms.Label() - Me.MyDatagridview1 = New VERAG_PROG_ALLGEMEIN.MyDatagridview(Me.components) - CType(Me.MyDatagridview1, System.ComponentModel.ISupportInitialize).BeginInit() + Me.dgvBestellungen = New VERAG_PROG_ALLGEMEIN.MyDatagridview(Me.components) + Me.btnSave = New System.Windows.Forms.Button() + Me.lblDatum = New System.Windows.Forms.Label() + Me.GroupBox1 = New System.Windows.Forms.GroupBox() + Me.rbMenuMo = New VERAG_PROG_ALLGEMEIN.MyRadioButton(Me.components) + Me.rbMenoAltMo = New VERAG_PROG_ALLGEMEIN.MyRadioButton(Me.components) + Me.txtAltMo = New VERAG_PROG_ALLGEMEIN.MyTextBox() + Me.GroupBox2 = New System.Windows.Forms.GroupBox() + Me.txtAltDi = New VERAG_PROG_ALLGEMEIN.MyTextBox() + Me.rbMenuAltDi = New VERAG_PROG_ALLGEMEIN.MyRadioButton(Me.components) + Me.rbMenuDi = New VERAG_PROG_ALLGEMEIN.MyRadioButton(Me.components) + Me.GroupBox3 = New System.Windows.Forms.GroupBox() + Me.txtAltMi = New VERAG_PROG_ALLGEMEIN.MyTextBox() + Me.rbMenuAltMi = New VERAG_PROG_ALLGEMEIN.MyRadioButton(Me.components) + Me.rbMenuMi = New VERAG_PROG_ALLGEMEIN.MyRadioButton(Me.components) + Me.GroupBox4 = New System.Windows.Forms.GroupBox() + Me.txtAltDo = New VERAG_PROG_ALLGEMEIN.MyTextBox() + Me.rbMenuAltDo = New VERAG_PROG_ALLGEMEIN.MyRadioButton(Me.components) + Me.rbMenuDo = New VERAG_PROG_ALLGEMEIN.MyRadioButton(Me.components) + Me.GroupBox5 = New System.Windows.Forms.GroupBox() + Me.txtAltFr = New VERAG_PROG_ALLGEMEIN.MyTextBox() + Me.rbMenuFrAlt = New VERAG_PROG_ALLGEMEIN.MyRadioButton(Me.components) + Me.rbMenuFr = New VERAG_PROG_ALLGEMEIN.MyRadioButton(Me.components) + Me.lbl1 = New System.Windows.Forms.Label() + Me.lbl2 = New System.Windows.Forms.Label() + Me.txtAnzahlMenu = New System.Windows.Forms.Label() + Me.txtAnzahlLaCart = New System.Windows.Forms.Label() + Me.ToolTipInfoMo = New System.Windows.Forms.ToolTip(Me.components) + Me.ToolTipInfoDi = New System.Windows.Forms.ToolTip(Me.components) + Me.ToolTipInfoMi = New System.Windows.Forms.ToolTip(Me.components) + Me.ToolTipInfoDo = New System.Windows.Forms.ToolTip(Me.components) + Me.ToolTipInfoFr = New System.Windows.Forms.ToolTip(Me.components) + CType(Me.dgvBestellungen, System.ComponentModel.ISupportInitialize).BeginInit() + Me.GroupBox1.SuspendLayout() + Me.GroupBox2.SuspendLayout() + Me.GroupBox3.SuspendLayout() + Me.GroupBox4.SuspendLayout() + Me.GroupBox5.SuspendLayout() Me.SuspendLayout() ' 'MyComboBox1 @@ -35,7 +74,7 @@ Partial Class frmEssensbestellungen Me.MyComboBox1._allowFreiText = False Me.MyComboBox1._value = "" Me.MyComboBox1.FormattingEnabled = True - Me.MyComboBox1.Location = New System.Drawing.Point(15, 60) + Me.MyComboBox1.Location = New System.Drawing.Point(12, 30) Me.MyComboBox1.Name = "MyComboBox1" Me.MyComboBox1.Size = New System.Drawing.Size(95, 21) Me.MyComboBox1.TabIndex = 0 @@ -43,32 +82,435 @@ Partial Class frmEssensbestellungen 'lblWochenkarte ' Me.lblWochenkarte.AutoSize = True - Me.lblWochenkarte.Location = New System.Drawing.Point(12, 34) + Me.lblWochenkarte.Location = New System.Drawing.Point(12, 14) Me.lblWochenkarte.Name = "lblWochenkarte" - Me.lblWochenkarte.Size = New System.Drawing.Size(39, 13) + Me.lblWochenkarte.Size = New System.Drawing.Size(34, 13) Me.lblWochenkarte.TabIndex = 1 - Me.lblWochenkarte.Text = "Label1" + Me.lblWochenkarte.Text = "Menü" ' - 'MyDatagridview1 + 'dgvBestellungen ' - Me.MyDatagridview1.AKTUALISIERUNGS_INTERVALL = -1 - Me.MyDatagridview1.ColumnHeadersHeightSizeMode = System.Windows.Forms.DataGridViewColumnHeadersHeightSizeMode.AutoSize - Me.MyDatagridview1.Location = New System.Drawing.Point(252, 31) - Me.MyDatagridview1.Name = "MyDatagridview1" - Me.MyDatagridview1.Size = New System.Drawing.Size(485, 150) - Me.MyDatagridview1.TabIndex = 2 + Me.dgvBestellungen.AKTUALISIERUNGS_INTERVALL = -1 + Me.dgvBestellungen.AllowUserToAddRows = False + Me.dgvBestellungen.AllowUserToDeleteRows = False + Me.dgvBestellungen.AllowUserToOrderColumns = True + Me.dgvBestellungen.BackgroundColor = System.Drawing.Color.White + DataGridViewCellStyle4.Alignment = System.Windows.Forms.DataGridViewContentAlignment.MiddleLeft + DataGridViewCellStyle4.BackColor = System.Drawing.SystemColors.Control + DataGridViewCellStyle4.Font = New System.Drawing.Font("Microsoft Sans Serif", 8.25!, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, CType(0, Byte)) + DataGridViewCellStyle4.ForeColor = System.Drawing.SystemColors.WindowText + DataGridViewCellStyle4.SelectionBackColor = System.Drawing.SystemColors.Highlight + DataGridViewCellStyle4.SelectionForeColor = System.Drawing.SystemColors.HighlightText + DataGridViewCellStyle4.WrapMode = System.Windows.Forms.DataGridViewTriState.[True] + Me.dgvBestellungen.ColumnHeadersDefaultCellStyle = DataGridViewCellStyle4 + Me.dgvBestellungen.ColumnHeadersHeightSizeMode = System.Windows.Forms.DataGridViewColumnHeadersHeightSizeMode.AutoSize + DataGridViewCellStyle5.Alignment = System.Windows.Forms.DataGridViewContentAlignment.MiddleLeft + DataGridViewCellStyle5.BackColor = System.Drawing.SystemColors.Window + DataGridViewCellStyle5.Font = New System.Drawing.Font("Microsoft Sans Serif", 8.25!, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, CType(0, Byte)) + DataGridViewCellStyle5.ForeColor = System.Drawing.SystemColors.ControlText + DataGridViewCellStyle5.SelectionBackColor = System.Drawing.SystemColors.Highlight + DataGridViewCellStyle5.SelectionForeColor = System.Drawing.SystemColors.HighlightText + DataGridViewCellStyle5.WrapMode = System.Windows.Forms.DataGridViewTriState.[False] + Me.dgvBestellungen.DefaultCellStyle = DataGridViewCellStyle5 + Me.dgvBestellungen.Location = New System.Drawing.Point(12, 298) + Me.dgvBestellungen.Name = "dgvBestellungen" + DataGridViewCellStyle6.Alignment = System.Windows.Forms.DataGridViewContentAlignment.MiddleLeft + DataGridViewCellStyle6.BackColor = System.Drawing.SystemColors.Control + DataGridViewCellStyle6.Font = New System.Drawing.Font("Microsoft Sans Serif", 8.25!, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, CType(0, Byte)) + DataGridViewCellStyle6.ForeColor = System.Drawing.SystemColors.WindowText + DataGridViewCellStyle6.SelectionBackColor = System.Drawing.SystemColors.Highlight + DataGridViewCellStyle6.SelectionForeColor = System.Drawing.SystemColors.HighlightText + DataGridViewCellStyle6.WrapMode = System.Windows.Forms.DataGridViewTriState.[True] + Me.dgvBestellungen.RowHeadersDefaultCellStyle = DataGridViewCellStyle6 + Me.dgvBestellungen.Size = New System.Drawing.Size(528, 150) + Me.dgvBestellungen.TabIndex = 2 + ' + 'btnSave + ' + Me.btnSave.Location = New System.Drawing.Point(565, 249) + Me.btnSave.Name = "btnSave" + Me.btnSave.Size = New System.Drawing.Size(75, 23) + Me.btnSave.TabIndex = 10 + Me.btnSave.Text = "OK" + Me.btnSave.UseVisualStyleBackColor = True + ' + 'lblDatum + ' + Me.lblDatum.AutoSize = True + Me.lblDatum.Location = New System.Drawing.Point(167, 14) + Me.lblDatum.Name = "lblDatum" + Me.lblDatum.Size = New System.Drawing.Size(41, 13) + Me.lblDatum.TabIndex = 11 + Me.lblDatum.Text = "Datum:" + ' + 'GroupBox1 + ' + Me.GroupBox1.Controls.Add(Me.txtAltMo) + Me.GroupBox1.Controls.Add(Me.rbMenoAltMo) + Me.GroupBox1.Controls.Add(Me.rbMenuMo) + Me.GroupBox1.Location = New System.Drawing.Point(15, 67) + 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" + ' + 'rbMenuMo + ' + Me.rbMenuMo.AutoSize = True + Me.rbMenuMo.GroupName = Nothing + Me.rbMenuMo.Location = New System.Drawing.Point(3, 19) + Me.rbMenuMo.Name = "rbMenuMo" + Me.rbMenuMo.Size = New System.Drawing.Size(52, 17) + Me.rbMenuMo.TabIndex = 0 + Me.rbMenuMo.TabStop = True + Me.rbMenuMo.Text = "Menü" + Me.rbMenuMo.UseVisualStyleBackColor = True + ' + 'rbMenoAltMo + ' + Me.rbMenoAltMo.AutoSize = True + Me.rbMenoAltMo.GroupName = Nothing + Me.rbMenoAltMo.Location = New System.Drawing.Point(3, 42) + Me.rbMenoAltMo.Name = "rbMenoAltMo" + Me.rbMenoAltMo.Size = New System.Drawing.Size(70, 17) + Me.rbMenoAltMo.TabIndex = 1 + Me.rbMenoAltMo.TabStop = True + Me.rbMenoAltMo.Text = "A la carte" + Me.rbMenoAltMo.UseVisualStyleBackColor = True + ' + 'txtAltMo + ' + Me.txtAltMo._DateTimeOnly = False + Me.txtAltMo._numbersOnly = False + Me.txtAltMo._numbersOnlyKommastellen = "" + Me.txtAltMo._numbersOnlyTrennzeichen = True + Me.txtAltMo._Prozent = False + Me.txtAltMo._ShortDateNew = False + Me.txtAltMo._ShortDateOnly = False + Me.txtAltMo._TimeOnly = False + Me.txtAltMo._TimeOnly_Seconds = False + Me.txtAltMo._value = "" + 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.MaxLineLength = -1 + Me.txtAltMo.MaxLines_Warning = "" + Me.txtAltMo.MaxLines_Warning_Label = Nothing + Me.txtAltMo.Name = "txtAltMo" + Me.txtAltMo.Size = New System.Drawing.Size(177, 20) + Me.txtAltMo.TabIndex = 2 + Me.txtAltMo.Visible = False + ' + 'GroupBox2 + ' + Me.GroupBox2.Controls.Add(Me.txtAltDi) + Me.GroupBox2.Controls.Add(Me.rbMenuAltDi) + Me.GroupBox2.Controls.Add(Me.rbMenuDi) + Me.GroupBox2.Location = New System.Drawing.Point(234, 67) + Me.GroupBox2.Name = "GroupBox2" + Me.GroupBox2.Size = New System.Drawing.Size(200, 95) + Me.GroupBox2.TabIndex = 13 + Me.GroupBox2.TabStop = False + Me.GroupBox2.Text = "Dienstag" + ' + 'txtAltDi + ' + Me.txtAltDi._DateTimeOnly = False + Me.txtAltDi._numbersOnly = False + Me.txtAltDi._numbersOnlyKommastellen = "" + Me.txtAltDi._numbersOnlyTrennzeichen = True + Me.txtAltDi._Prozent = False + Me.txtAltDi._ShortDateNew = False + Me.txtAltDi._ShortDateOnly = False + Me.txtAltDi._TimeOnly = False + Me.txtAltDi._TimeOnly_Seconds = False + Me.txtAltDi._value = "" + 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.MaxLineLength = -1 + Me.txtAltDi.MaxLines_Warning = "" + Me.txtAltDi.MaxLines_Warning_Label = Nothing + Me.txtAltDi.Name = "txtAltDi" + Me.txtAltDi.Size = New System.Drawing.Size(177, 20) + Me.txtAltDi.TabIndex = 2 + Me.txtAltDi.Visible = False + ' + 'rbMenuAltDi + ' + Me.rbMenuAltDi.AutoSize = True + Me.rbMenuAltDi.GroupName = Nothing + Me.rbMenuAltDi.Location = New System.Drawing.Point(3, 42) + Me.rbMenuAltDi.Name = "rbMenuAltDi" + Me.rbMenuAltDi.Size = New System.Drawing.Size(70, 17) + Me.rbMenuAltDi.TabIndex = 1 + Me.rbMenuAltDi.TabStop = True + Me.rbMenuAltDi.Text = "A la carte" + Me.rbMenuAltDi.UseVisualStyleBackColor = True + ' + 'rbMenuDi + ' + Me.rbMenuDi.AutoSize = True + Me.rbMenuDi.GroupName = Nothing + Me.rbMenuDi.Location = New System.Drawing.Point(3, 19) + Me.rbMenuDi.Name = "rbMenuDi" + Me.rbMenuDi.Size = New System.Drawing.Size(52, 17) + Me.rbMenuDi.TabIndex = 0 + Me.rbMenuDi.TabStop = True + Me.rbMenuDi.Text = "Menü" + Me.rbMenuDi.UseVisualStyleBackColor = True + ' + 'GroupBox3 + ' + Me.GroupBox3.Controls.Add(Me.txtAltMi) + Me.GroupBox3.Controls.Add(Me.rbMenuAltMi) + Me.GroupBox3.Controls.Add(Me.rbMenuMi) + Me.GroupBox3.Location = New System.Drawing.Point(440, 67) + Me.GroupBox3.Name = "GroupBox3" + Me.GroupBox3.Size = New System.Drawing.Size(200, 95) + Me.GroupBox3.TabIndex = 13 + Me.GroupBox3.TabStop = False + Me.GroupBox3.Text = "Mittwoch" + ' + 'txtAltMi + ' + Me.txtAltMi._DateTimeOnly = False + Me.txtAltMi._numbersOnly = False + Me.txtAltMi._numbersOnlyKommastellen = "" + Me.txtAltMi._numbersOnlyTrennzeichen = True + Me.txtAltMi._Prozent = False + Me.txtAltMi._ShortDateNew = False + Me.txtAltMi._ShortDateOnly = False + Me.txtAltMi._TimeOnly = False + Me.txtAltMi._TimeOnly_Seconds = False + Me.txtAltMi._value = "" + 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.MaxLineLength = -1 + Me.txtAltMi.MaxLines_Warning = "" + Me.txtAltMi.MaxLines_Warning_Label = Nothing + Me.txtAltMi.Name = "txtAltMi" + Me.txtAltMi.Size = New System.Drawing.Size(177, 20) + Me.txtAltMi.TabIndex = 2 + Me.txtAltMi.Visible = False + ' + 'rbMenuAltMi + ' + Me.rbMenuAltMi.AutoSize = True + Me.rbMenuAltMi.GroupName = Nothing + Me.rbMenuAltMi.Location = New System.Drawing.Point(3, 42) + Me.rbMenuAltMi.Name = "rbMenuAltMi" + Me.rbMenuAltMi.Size = New System.Drawing.Size(70, 17) + Me.rbMenuAltMi.TabIndex = 1 + Me.rbMenuAltMi.TabStop = True + Me.rbMenuAltMi.Text = "A la carte" + Me.rbMenuAltMi.UseVisualStyleBackColor = True + ' + 'rbMenuMi + ' + Me.rbMenuMi.AutoSize = True + Me.rbMenuMi.GroupName = Nothing + Me.rbMenuMi.Location = New System.Drawing.Point(3, 19) + Me.rbMenuMi.Name = "rbMenuMi" + Me.rbMenuMi.Size = New System.Drawing.Size(52, 17) + Me.rbMenuMi.TabIndex = 0 + Me.rbMenuMi.TabStop = True + Me.rbMenuMi.Text = "Menü" + Me.rbMenuMi.UseVisualStyleBackColor = True + ' + 'GroupBox4 + ' + Me.GroupBox4.Controls.Add(Me.txtAltDo) + Me.GroupBox4.Controls.Add(Me.rbMenuAltDo) + Me.GroupBox4.Controls.Add(Me.rbMenuDo) + Me.GroupBox4.Location = New System.Drawing.Point(12, 168) + 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" + ' + 'txtAltDo + ' + Me.txtAltDo._DateTimeOnly = False + Me.txtAltDo._numbersOnly = False + Me.txtAltDo._numbersOnlyKommastellen = "" + Me.txtAltDo._numbersOnlyTrennzeichen = True + Me.txtAltDo._Prozent = False + Me.txtAltDo._ShortDateNew = False + Me.txtAltDo._ShortDateOnly = False + Me.txtAltDo._TimeOnly = False + Me.txtAltDo._TimeOnly_Seconds = False + Me.txtAltDo._value = "" + 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.MaxLineLength = -1 + Me.txtAltDo.MaxLines_Warning = "" + Me.txtAltDo.MaxLines_Warning_Label = Nothing + Me.txtAltDo.Name = "txtAltDo" + Me.txtAltDo.Size = New System.Drawing.Size(177, 20) + Me.txtAltDo.TabIndex = 2 + Me.txtAltDo.Visible = False + ' + 'rbMenuAltDo + ' + Me.rbMenuAltDo.AutoSize = True + Me.rbMenuAltDo.GroupName = Nothing + Me.rbMenuAltDo.Location = New System.Drawing.Point(3, 42) + Me.rbMenuAltDo.Name = "rbMenuAltDo" + Me.rbMenuAltDo.Size = New System.Drawing.Size(70, 17) + Me.rbMenuAltDo.TabIndex = 1 + Me.rbMenuAltDo.TabStop = True + Me.rbMenuAltDo.Text = "A la carte" + Me.rbMenuAltDo.UseVisualStyleBackColor = True + ' + 'rbMenuDo + ' + Me.rbMenuDo.AutoSize = True + Me.rbMenuDo.GroupName = Nothing + Me.rbMenuDo.Location = New System.Drawing.Point(3, 19) + Me.rbMenuDo.Name = "rbMenuDo" + Me.rbMenuDo.Size = New System.Drawing.Size(52, 17) + Me.rbMenuDo.TabIndex = 0 + Me.rbMenuDo.TabStop = True + Me.rbMenuDo.Text = "Menü" + Me.rbMenuDo.UseVisualStyleBackColor = True + ' + 'GroupBox5 + ' + Me.GroupBox5.Controls.Add(Me.txtAltFr) + Me.GroupBox5.Controls.Add(Me.rbMenuFrAlt) + Me.GroupBox5.Controls.Add(Me.rbMenuFr) + Me.GroupBox5.Location = New System.Drawing.Point(234, 168) + 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" + ' + 'txtAltFr + ' + Me.txtAltFr._DateTimeOnly = False + Me.txtAltFr._numbersOnly = False + Me.txtAltFr._numbersOnlyKommastellen = "" + Me.txtAltFr._numbersOnlyTrennzeichen = True + Me.txtAltFr._Prozent = False + Me.txtAltFr._ShortDateNew = False + Me.txtAltFr._ShortDateOnly = False + Me.txtAltFr._TimeOnly = False + Me.txtAltFr._TimeOnly_Seconds = False + Me.txtAltFr._value = "" + 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.MaxLineLength = -1 + Me.txtAltFr.MaxLines_Warning = "" + Me.txtAltFr.MaxLines_Warning_Label = Nothing + Me.txtAltFr.Name = "txtAltFr" + Me.txtAltFr.Size = New System.Drawing.Size(177, 20) + Me.txtAltFr.TabIndex = 2 + Me.txtAltFr.Visible = False + ' + 'rbMenuFrAlt + ' + Me.rbMenuFrAlt.AutoSize = True + Me.rbMenuFrAlt.GroupName = Nothing + Me.rbMenuFrAlt.Location = New System.Drawing.Point(3, 42) + Me.rbMenuFrAlt.Name = "rbMenuFrAlt" + Me.rbMenuFrAlt.Size = New System.Drawing.Size(70, 17) + Me.rbMenuFrAlt.TabIndex = 1 + Me.rbMenuFrAlt.TabStop = True + Me.rbMenuFrAlt.Text = "A la carte" + Me.rbMenuFrAlt.UseVisualStyleBackColor = True + ' + 'rbMenuFr + ' + Me.rbMenuFr.AutoSize = True + Me.rbMenuFr.GroupName = Nothing + Me.rbMenuFr.Location = New System.Drawing.Point(3, 19) + Me.rbMenuFr.Name = "rbMenuFr" + Me.rbMenuFr.Size = New System.Drawing.Size(52, 17) + Me.rbMenuFr.TabIndex = 0 + Me.rbMenuFr.TabStop = True + Me.rbMenuFr.Text = "Menü" + Me.rbMenuFr.UseVisualStyleBackColor = True + ' + 'lbl1 + ' + Me.lbl1.AutoSize = True + Me.lbl1.Location = New System.Drawing.Point(472, 187) + Me.lbl1.Name = "lbl1" + Me.lbl1.Size = New System.Drawing.Size(72, 13) + Me.lbl1.TabIndex = 14 + Me.lbl1.Text = "Anzahl Menü:" + ' + 'lbl2 + ' + Me.lbl2.AutoSize = True + Me.lbl2.Location = New System.Drawing.Point(472, 214) + Me.lbl2.Name = "lbl2" + Me.lbl2.Size = New System.Drawing.Size(90, 13) + Me.lbl2.TabIndex = 15 + Me.lbl2.Text = "Anzahl a la Carte:" + ' + 'txtAnzahlMenu + ' + Me.txtAnzahlMenu.AutoSize = True + Me.txtAnzahlMenu.Location = New System.Drawing.Point(562, 189) + Me.txtAnzahlMenu.Name = "txtAnzahlMenu" + Me.txtAnzahlMenu.Size = New System.Drawing.Size(13, 13) + Me.txtAnzahlMenu.TabIndex = 16 + Me.txtAnzahlMenu.Text = "0" + ' + 'txtAnzahlLaCart + ' + Me.txtAnzahlLaCart.AutoSize = True + Me.txtAnzahlLaCart.Location = New System.Drawing.Point(562, 214) + Me.txtAnzahlLaCart.Name = "txtAnzahlLaCart" + Me.txtAnzahlLaCart.Size = New System.Drawing.Size(13, 13) + Me.txtAnzahlLaCart.TabIndex = 17 + Me.txtAnzahlLaCart.Text = "0" ' 'frmEssensbestellungen ' Me.AutoScaleDimensions = New System.Drawing.SizeF(6.0!, 13.0!) Me.AutoScaleMode = System.Windows.Forms.AutoScaleMode.Font - Me.ClientSize = New System.Drawing.Size(800, 450) - Me.Controls.Add(Me.MyDatagridview1) + Me.ClientSize = New System.Drawing.Size(680, 476) + Me.Controls.Add(Me.txtAnzahlLaCart) + Me.Controls.Add(Me.txtAnzahlMenu) + Me.Controls.Add(Me.lbl2) + Me.Controls.Add(Me.lbl1) + Me.Controls.Add(Me.GroupBox5) + Me.Controls.Add(Me.GroupBox4) + Me.Controls.Add(Me.GroupBox3) + Me.Controls.Add(Me.GroupBox2) + Me.Controls.Add(Me.GroupBox1) + Me.Controls.Add(Me.lblDatum) + Me.Controls.Add(Me.btnSave) + Me.Controls.Add(Me.dgvBestellungen) Me.Controls.Add(Me.lblWochenkarte) Me.Controls.Add(Me.MyComboBox1) Me.Name = "frmEssensbestellungen" - Me.Text = "frmEssensbestellungen" - CType(Me.MyDatagridview1, System.ComponentModel.ISupportInitialize).EndInit() + Me.Text = "Essensbestellung" + CType(Me.dgvBestellungen, System.ComponentModel.ISupportInitialize).EndInit() + Me.GroupBox1.ResumeLayout(False) + Me.GroupBox1.PerformLayout() + Me.GroupBox2.ResumeLayout(False) + Me.GroupBox2.PerformLayout() + Me.GroupBox3.ResumeLayout(False) + Me.GroupBox3.PerformLayout() + Me.GroupBox4.ResumeLayout(False) + Me.GroupBox4.PerformLayout() + Me.GroupBox5.ResumeLayout(False) + Me.GroupBox5.PerformLayout() Me.ResumeLayout(False) Me.PerformLayout() @@ -76,5 +518,36 @@ Partial Class frmEssensbestellungen Friend WithEvents MyComboBox1 As VERAG_PROG_ALLGEMEIN.MyComboBox Friend WithEvents lblWochenkarte As Label - Friend WithEvents MyDatagridview1 As VERAG_PROG_ALLGEMEIN.MyDatagridview + 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 txtAltMo As VERAG_PROG_ALLGEMEIN.MyTextBox + Friend WithEvents rbMenoAltMo As VERAG_PROG_ALLGEMEIN.MyRadioButton + Friend WithEvents rbMenuMo As VERAG_PROG_ALLGEMEIN.MyRadioButton + Friend WithEvents GroupBox2 As GroupBox + Friend WithEvents txtAltDi As VERAG_PROG_ALLGEMEIN.MyTextBox + Friend WithEvents rbMenuAltDi As VERAG_PROG_ALLGEMEIN.MyRadioButton + Friend WithEvents rbMenuDi As VERAG_PROG_ALLGEMEIN.MyRadioButton + Friend WithEvents GroupBox3 As GroupBox + Friend WithEvents txtAltMi As VERAG_PROG_ALLGEMEIN.MyTextBox + Friend WithEvents rbMenuAltMi As VERAG_PROG_ALLGEMEIN.MyRadioButton + Friend WithEvents rbMenuMi As VERAG_PROG_ALLGEMEIN.MyRadioButton + Friend WithEvents GroupBox4 As GroupBox + Friend WithEvents txtAltDo As VERAG_PROG_ALLGEMEIN.MyTextBox + Friend WithEvents rbMenuAltDo As VERAG_PROG_ALLGEMEIN.MyRadioButton + Friend WithEvents rbMenuDo As VERAG_PROG_ALLGEMEIN.MyRadioButton + Friend WithEvents GroupBox5 As GroupBox + Friend WithEvents txtAltFr As VERAG_PROG_ALLGEMEIN.MyTextBox + Friend WithEvents rbMenuFrAlt As VERAG_PROG_ALLGEMEIN.MyRadioButton + Friend WithEvents rbMenuFr As VERAG_PROG_ALLGEMEIN.MyRadioButton + Friend WithEvents lbl1 As Label + Friend WithEvents lbl2 As Label + Friend WithEvents txtAnzahlMenu As Label + Friend WithEvents txtAnzahlLaCart As Label + Friend WithEvents ToolTipInfoMo As ToolTip + Friend WithEvents ToolTipInfoDi As ToolTip + Friend WithEvents ToolTipInfoMi As ToolTip + Friend WithEvents ToolTipInfoDo As ToolTip + Friend WithEvents ToolTipInfoFr As ToolTip End Class diff --git a/Aviso/frmEssensbestellungen.resx b/Aviso/frmEssensbestellungen.resx index 1af7de1..56b734e 100644 --- a/Aviso/frmEssensbestellungen.resx +++ b/Aviso/frmEssensbestellungen.resx @@ -117,4 +117,19 @@ System.Resources.ResXResourceWriter, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + 17, 17 + + + 116, 17 + + + 215, 17 + + + 314, 17 + + + 413, 17 + \ No newline at end of file diff --git a/Aviso/frmEssensbestellungen.vb b/Aviso/frmEssensbestellungen.vb index ba8b925..93e0055 100644 --- a/Aviso/frmEssensbestellungen.vb +++ b/Aviso/frmEssensbestellungen.vb @@ -1,8 +1,43 @@ -Public Class frmEssensbestellungen - Private Sub frmEssensbestellungen_Load(sender As Object, e As EventArgs) Handles MyBase.Load - 'MyComboBox1.fillWithSQL("Select [MenuTitel] from [GMenu]") + + +Imports GrapeCity.ActiveReports.ReportsCore.Tools +Imports Spire.Pdf.General.Paper +Imports VERAG_PROG_ALLGEMEIN + +Public Class frmEssensbestellungen + + Dim SQL As New VERAG_PROG_ALLGEMEIN.SQL + + + + Private Sub frmEssensbestellungen_Load(sender As Object, e As EventArgs) Handles MyBase.Load - MyComboBox1.fillWithSQL("Select [MenuTitel] from [GMenu]",, "Gastro", True) End Sub + + Private Sub btnSave_Click(sender As Object, e As EventArgs) Handles btnSave.Click + + End Sub + + + Private Sub MyComboBox1_SelectedValueChanged(sender As Object, e As EventArgs) Handles MyComboBox1.SelectedValueChanged + + Dim dt As New DataTable + dt = SQL.loadDgvBySql("SELECT * FROM tblEBMenu where [MenuTitel] = '" & MyComboBox1._value & "'", "AVISO", 100, True) + + If dt.Rows.Count > 0 Then + + btnSave.Enabled = True + Else + btnSave.Enabled = False + End If + + + End Sub + + Private Sub rbMenoAltMo_CheckedChanged(sender As Object, e As EventArgs) Handles rbMenoAltMo.CheckedChanged + IIf(rbMenoAltMo.Checked, txtAltMo.Visible = True, txtAltMo.Visible = False) + End Sub + + End Class \ No newline at end of file diff --git a/Aviso/frmHauptfenster.Designer.vb b/Aviso/frmHauptfenster.Designer.vb index 2382b31..912b0c0 100644 --- a/Aviso/frmHauptfenster.Designer.vb +++ b/Aviso/frmHauptfenster.Designer.vb @@ -92,11 +92,11 @@ Partial Class frmHauptfenster Me.SpracheWechselnToolStripMenuItem = New System.Windows.Forms.ToolStripMenuItem() Me.DeutschToolStripMenuItem = New System.Windows.Forms.ToolStripMenuItem() Me.TürkischToolStripMenuItem = New System.Windows.Forms.ToolStripMenuItem() + Me.StandarddruckerWechselnToolStripMenuItem = New System.Windows.Forms.ToolStripMenuItem() Me.NacherfassungToolStripMenuItem = New System.Windows.Forms.ToolStripMenuItem() Me.VollständigesUpdateToolStripMenuItem = New System.Windows.Forms.ToolStripMenuItem() Me.UpdateToolStripMenuItem = New System.Windows.Forms.ToolStripMenuItem() Me.LogoutToolStripMenuItem = New System.Windows.Forms.ToolStripMenuItem() - Me.StandarddruckerWechselnToolStripMenuItem = New System.Windows.Forms.ToolStripMenuItem() Me.FunktionenToolStripMenuItem = New System.Windows.Forms.ToolStripMenuItem() Me.GenerelleGestellungenDurchsuchenToolStripMenuItem = New System.Windows.Forms.ToolStripMenuItem() Me.KundenVonFremdenSpeditionenToolStripMenuItem = New System.Windows.Forms.ToolStripMenuItem() @@ -363,6 +363,7 @@ Partial Class frmHauptfenster Me.ToolStripMenuItem19 = New System.Windows.Forms.ToolStripMenuItem() Me.ToolStripMenuItem20 = New System.Windows.Forms.ToolStripMenuItem() Me.ToolStripMenuItem21 = New System.Windows.Forms.ToolStripMenuItem() + Me.EssensbestellungenToolStripMenuItem = New System.Windows.Forms.ToolStripMenuItem() Me.conMenuAviso.SuspendLayout() Me.MenuStrip1.SuspendLayout() Me.Top.SuspendLayout() @@ -774,6 +775,12 @@ Partial Class frmHauptfenster Me.TürkischToolStripMenuItem.Size = New System.Drawing.Size(118, 22) Me.TürkischToolStripMenuItem.Text = "Türkisch" ' + 'StandarddruckerWechselnToolStripMenuItem + ' + Me.StandarddruckerWechselnToolStripMenuItem.Name = "StandarddruckerWechselnToolStripMenuItem" + Me.StandarddruckerWechselnToolStripMenuItem.Size = New System.Drawing.Size(213, 22) + Me.StandarddruckerWechselnToolStripMenuItem.Text = "Standarddrucker wechseln" + ' 'NacherfassungToolStripMenuItem ' Me.NacherfassungToolStripMenuItem.Name = "NacherfassungToolStripMenuItem" @@ -800,15 +807,9 @@ Partial Class frmHauptfenster Me.LogoutToolStripMenuItem.Text = "Logout" Me.LogoutToolStripMenuItem.Visible = False ' - 'StandarddruckerWechselnToolStripMenuItem - ' - Me.StandarddruckerWechselnToolStripMenuItem.Name = "StandarddruckerWechselnToolStripMenuItem" - Me.StandarddruckerWechselnToolStripMenuItem.Size = New System.Drawing.Size(213, 22) - Me.StandarddruckerWechselnToolStripMenuItem.Text = "Standarddrucker wechseln" - ' 'FunktionenToolStripMenuItem ' - Me.FunktionenToolStripMenuItem.DropDownItems.AddRange(New System.Windows.Forms.ToolStripItem() {Me.GenerelleGestellungenDurchsuchenToolStripMenuItem, Me.KundenVonFremdenSpeditionenToolStripMenuItem, Me.KundenverwaltungToolStripMenuItem, Me.MDMParkplatzkartenToolStripMenuItem, Me.SMSSendenToolStripMenuItem, Me.ZollprogrammeNachEORIDurchsuchenToolStripMenuItem, Me.MRNBarcodedruckToolStripMenuItem, Me.ToolStripSeparator12, Me.ToolStripMenuItem3, Me.ToolStripMenuItem4, Me.ToolStripMenuItem5, Me.BürgschaftenExcelToolStripMenuItem, Me.ToolStripMenuItem6, Me.ToolStripMenuItem10, Me.TICKETWaidhausToolStripMenuItem, Me.ToolStripSeparator10, Me.DAKOSYToolStripMenuItem, Me.ToolStripSeparator11, Me.SDLAbholaufträgeToolStripMenuItem, Me.ToolStripMenuItem13, Me.VorauskassenToolStripMenuItem, Me.DEGesamtsicherheitVeragGmbHToolStripMenuItem, Me.ATGesamtsicherheitVeragAGToolStripMenuItem, Me.ATGesamtsicherheitIMEXCSGmbHToolStripMenuItem, Me.ATGesamtsicherheitVeragCSToolStripMenuItem}) + Me.FunktionenToolStripMenuItem.DropDownItems.AddRange(New System.Windows.Forms.ToolStripItem() {Me.GenerelleGestellungenDurchsuchenToolStripMenuItem, Me.KundenVonFremdenSpeditionenToolStripMenuItem, Me.KundenverwaltungToolStripMenuItem, Me.MDMParkplatzkartenToolStripMenuItem, Me.SMSSendenToolStripMenuItem, Me.ZollprogrammeNachEORIDurchsuchenToolStripMenuItem, Me.MRNBarcodedruckToolStripMenuItem, Me.ToolStripSeparator12, Me.ToolStripMenuItem3, Me.ToolStripMenuItem4, Me.ToolStripMenuItem5, Me.BürgschaftenExcelToolStripMenuItem, Me.ToolStripMenuItem6, Me.ToolStripMenuItem10, Me.TICKETWaidhausToolStripMenuItem, Me.ToolStripSeparator10, Me.DAKOSYToolStripMenuItem, Me.ToolStripSeparator11, Me.SDLAbholaufträgeToolStripMenuItem, Me.ToolStripMenuItem13, Me.VorauskassenToolStripMenuItem, Me.DEGesamtsicherheitVeragGmbHToolStripMenuItem, Me.ATGesamtsicherheitVeragAGToolStripMenuItem, Me.ATGesamtsicherheitIMEXCSGmbHToolStripMenuItem, Me.ATGesamtsicherheitVeragCSToolStripMenuItem, Me.EssensbestellungenToolStripMenuItem}) Me.FunktionenToolStripMenuItem.Name = "FunktionenToolStripMenuItem" Me.FunktionenToolStripMenuItem.Size = New System.Drawing.Size(79, 20) Me.FunktionenToolStripMenuItem.Text = "Funktionen" @@ -3464,6 +3465,12 @@ Partial Class frmHauptfenster Me.ToolStripMenuItem21.Size = New System.Drawing.Size(121, 22) Me.ToolStripMenuItem21.Text = "GELB" ' + 'EssensbestellungenToolStripMenuItem + ' + Me.EssensbestellungenToolStripMenuItem.Name = "EssensbestellungenToolStripMenuItem" + Me.EssensbestellungenToolStripMenuItem.Size = New System.Drawing.Size(383, 22) + Me.EssensbestellungenToolStripMenuItem.Text = "Essensbestellungen" + ' 'frmHauptfenster ' Me.AutoScaleDimensions = New System.Drawing.SizeF(6.0!, 13.0!) @@ -3866,4 +3873,5 @@ Partial Class frmHauptfenster Friend WithEvents ALLEToolStripMenuItem As ToolStripMenuItem Friend WithEvents RoutenverwaltungToolStripMenuItem As ToolStripMenuItem Friend WithEvents StandarddruckerWechselnToolStripMenuItem As ToolStripMenuItem + Friend WithEvents EssensbestellungenToolStripMenuItem As ToolStripMenuItem End Class diff --git a/Aviso/frmHauptfenster.vb b/Aviso/frmHauptfenster.vb index d666848..8545bc6 100644 --- a/Aviso/frmHauptfenster.vb +++ b/Aviso/frmHauptfenster.vb @@ -4210,6 +4210,11 @@ Public Class frmHauptfenster Dim f As New frmWechselStandarddrucker() f.ShowDialog(Me) End Sub + + Private Sub EssensbestellungenToolStripMenuItem_Click(sender As Object, e As EventArgs) Handles EssensbestellungenToolStripMenuItem.Click + Dim f As New frmEssensbestellungen() + f.ShowDialog(Me) + End Sub End Class Public Class AvisoStatusFunctions From 4882bdfa18ea403548f481dc0d4dc9bcf9f18e5f Mon Sep 17 00:00:00 2001 From: "d.breimaier" Date: Mon, 28 Nov 2022 17:37:49 +0100 Subject: [PATCH 03/10] Essensbestellungen --- Aviso/frmEssensbestellungen.Designer.vb | 241 ++++++++++++++++-------- Aviso/frmEssensbestellungen.vb | 89 ++++++++- 2 files changed, 252 insertions(+), 78 deletions(-) diff --git a/Aviso/frmEssensbestellungen.Designer.vb b/Aviso/frmEssensbestellungen.Designer.vb index b41ab1c..43b1b1e 100644 --- a/Aviso/frmEssensbestellungen.Designer.vb +++ b/Aviso/frmEssensbestellungen.Designer.vb @@ -26,28 +26,31 @@ Partial Class frmEssensbestellungen Dim DataGridViewCellStyle4 As System.Windows.Forms.DataGridViewCellStyle = New System.Windows.Forms.DataGridViewCellStyle() Dim DataGridViewCellStyle5 As System.Windows.Forms.DataGridViewCellStyle = New System.Windows.Forms.DataGridViewCellStyle() Dim DataGridViewCellStyle6 As System.Windows.Forms.DataGridViewCellStyle = New System.Windows.Forms.DataGridViewCellStyle() - Me.MyComboBox1 = New VERAG_PROG_ALLGEMEIN.MyComboBox() Me.lblWochenkarte = New System.Windows.Forms.Label() - Me.dgvBestellungen = New VERAG_PROG_ALLGEMEIN.MyDatagridview(Me.components) Me.btnSave = New System.Windows.Forms.Button() Me.lblDatum = New System.Windows.Forms.Label() Me.GroupBox1 = New System.Windows.Forms.GroupBox() - Me.rbMenuMo = New VERAG_PROG_ALLGEMEIN.MyRadioButton(Me.components) - Me.rbMenoAltMo = New VERAG_PROG_ALLGEMEIN.MyRadioButton(Me.components) + Me.cbMontag = New System.Windows.Forms.CheckBox() Me.txtAltMo = New VERAG_PROG_ALLGEMEIN.MyTextBox() + Me.rbMenoAltMo = New VERAG_PROG_ALLGEMEIN.MyRadioButton(Me.components) + Me.rbMenuMo = New VERAG_PROG_ALLGEMEIN.MyRadioButton(Me.components) Me.GroupBox2 = New System.Windows.Forms.GroupBox() + Me.cbDienstag = New System.Windows.Forms.CheckBox() Me.txtAltDi = New VERAG_PROG_ALLGEMEIN.MyTextBox() Me.rbMenuAltDi = New VERAG_PROG_ALLGEMEIN.MyRadioButton(Me.components) Me.rbMenuDi = New VERAG_PROG_ALLGEMEIN.MyRadioButton(Me.components) Me.GroupBox3 = New System.Windows.Forms.GroupBox() + Me.cbMittwoch = New System.Windows.Forms.CheckBox() Me.txtAltMi = New VERAG_PROG_ALLGEMEIN.MyTextBox() Me.rbMenuAltMi = New VERAG_PROG_ALLGEMEIN.MyRadioButton(Me.components) Me.rbMenuMi = New VERAG_PROG_ALLGEMEIN.MyRadioButton(Me.components) Me.GroupBox4 = New System.Windows.Forms.GroupBox() + Me.cbDonnerstag = New System.Windows.Forms.CheckBox() Me.txtAltDo = New VERAG_PROG_ALLGEMEIN.MyTextBox() Me.rbMenuAltDo = New VERAG_PROG_ALLGEMEIN.MyRadioButton(Me.components) Me.rbMenuDo = New VERAG_PROG_ALLGEMEIN.MyRadioButton(Me.components) Me.GroupBox5 = New System.Windows.Forms.GroupBox() + Me.cbFreitag = New System.Windows.Forms.CheckBox() Me.txtAltFr = New VERAG_PROG_ALLGEMEIN.MyTextBox() Me.rbMenuFrAlt = New VERAG_PROG_ALLGEMEIN.MyRadioButton(Me.components) Me.rbMenuFr = New VERAG_PROG_ALLGEMEIN.MyRadioButton(Me.components) @@ -60,25 +63,18 @@ Partial Class frmEssensbestellungen Me.ToolTipInfoMi = New System.Windows.Forms.ToolTip(Me.components) Me.ToolTipInfoDo = New System.Windows.Forms.ToolTip(Me.components) Me.ToolTipInfoFr = New System.Windows.Forms.ToolTip(Me.components) - CType(Me.dgvBestellungen, System.ComponentModel.ISupportInitialize).BeginInit() + Me.dgvBestellungen = New VERAG_PROG_ALLGEMEIN.MyDatagridview(Me.components) + Me.MyComboBox1 = New VERAG_PROG_ALLGEMEIN.MyComboBox() + Me.lblAbteilung = New System.Windows.Forms.Label() + Me.lblGebaeude = New System.Windows.Forms.Label() Me.GroupBox1.SuspendLayout() Me.GroupBox2.SuspendLayout() Me.GroupBox3.SuspendLayout() Me.GroupBox4.SuspendLayout() Me.GroupBox5.SuspendLayout() + CType(Me.dgvBestellungen, System.ComponentModel.ISupportInitialize).BeginInit() Me.SuspendLayout() ' - 'MyComboBox1 - ' - Me.MyComboBox1._allowedValuesFreiText = Nothing - Me.MyComboBox1._allowFreiText = False - Me.MyComboBox1._value = "" - Me.MyComboBox1.FormattingEnabled = True - Me.MyComboBox1.Location = New System.Drawing.Point(12, 30) - Me.MyComboBox1.Name = "MyComboBox1" - Me.MyComboBox1.Size = New System.Drawing.Size(95, 21) - Me.MyComboBox1.TabIndex = 0 - ' 'lblWochenkarte ' Me.lblWochenkarte.AutoSize = True @@ -88,43 +84,6 @@ Partial Class frmEssensbestellungen Me.lblWochenkarte.TabIndex = 1 Me.lblWochenkarte.Text = "Menü" ' - 'dgvBestellungen - ' - Me.dgvBestellungen.AKTUALISIERUNGS_INTERVALL = -1 - Me.dgvBestellungen.AllowUserToAddRows = False - Me.dgvBestellungen.AllowUserToDeleteRows = False - Me.dgvBestellungen.AllowUserToOrderColumns = True - Me.dgvBestellungen.BackgroundColor = System.Drawing.Color.White - DataGridViewCellStyle4.Alignment = System.Windows.Forms.DataGridViewContentAlignment.MiddleLeft - DataGridViewCellStyle4.BackColor = System.Drawing.SystemColors.Control - DataGridViewCellStyle4.Font = New System.Drawing.Font("Microsoft Sans Serif", 8.25!, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, CType(0, Byte)) - DataGridViewCellStyle4.ForeColor = System.Drawing.SystemColors.WindowText - DataGridViewCellStyle4.SelectionBackColor = System.Drawing.SystemColors.Highlight - DataGridViewCellStyle4.SelectionForeColor = System.Drawing.SystemColors.HighlightText - DataGridViewCellStyle4.WrapMode = System.Windows.Forms.DataGridViewTriState.[True] - Me.dgvBestellungen.ColumnHeadersDefaultCellStyle = DataGridViewCellStyle4 - Me.dgvBestellungen.ColumnHeadersHeightSizeMode = System.Windows.Forms.DataGridViewColumnHeadersHeightSizeMode.AutoSize - DataGridViewCellStyle5.Alignment = System.Windows.Forms.DataGridViewContentAlignment.MiddleLeft - DataGridViewCellStyle5.BackColor = System.Drawing.SystemColors.Window - DataGridViewCellStyle5.Font = New System.Drawing.Font("Microsoft Sans Serif", 8.25!, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, CType(0, Byte)) - DataGridViewCellStyle5.ForeColor = System.Drawing.SystemColors.ControlText - DataGridViewCellStyle5.SelectionBackColor = System.Drawing.SystemColors.Highlight - DataGridViewCellStyle5.SelectionForeColor = System.Drawing.SystemColors.HighlightText - DataGridViewCellStyle5.WrapMode = System.Windows.Forms.DataGridViewTriState.[False] - Me.dgvBestellungen.DefaultCellStyle = DataGridViewCellStyle5 - Me.dgvBestellungen.Location = New System.Drawing.Point(12, 298) - Me.dgvBestellungen.Name = "dgvBestellungen" - DataGridViewCellStyle6.Alignment = System.Windows.Forms.DataGridViewContentAlignment.MiddleLeft - DataGridViewCellStyle6.BackColor = System.Drawing.SystemColors.Control - DataGridViewCellStyle6.Font = New System.Drawing.Font("Microsoft Sans Serif", 8.25!, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, CType(0, Byte)) - DataGridViewCellStyle6.ForeColor = System.Drawing.SystemColors.WindowText - DataGridViewCellStyle6.SelectionBackColor = System.Drawing.SystemColors.Highlight - DataGridViewCellStyle6.SelectionForeColor = System.Drawing.SystemColors.HighlightText - DataGridViewCellStyle6.WrapMode = System.Windows.Forms.DataGridViewTriState.[True] - Me.dgvBestellungen.RowHeadersDefaultCellStyle = DataGridViewCellStyle6 - Me.dgvBestellungen.Size = New System.Drawing.Size(528, 150) - Me.dgvBestellungen.TabIndex = 2 - ' 'btnSave ' Me.btnSave.Location = New System.Drawing.Point(565, 249) @@ -145,6 +104,7 @@ Partial Class frmEssensbestellungen ' 'GroupBox1 ' + Me.GroupBox1.Controls.Add(Me.cbMontag) Me.GroupBox1.Controls.Add(Me.txtAltMo) Me.GroupBox1.Controls.Add(Me.rbMenoAltMo) Me.GroupBox1.Controls.Add(Me.rbMenuMo) @@ -155,29 +115,15 @@ Partial Class frmEssensbestellungen Me.GroupBox1.TabStop = False Me.GroupBox1.Text = "Montag" ' - 'rbMenuMo + 'cbMontag ' - Me.rbMenuMo.AutoSize = True - Me.rbMenuMo.GroupName = Nothing - Me.rbMenuMo.Location = New System.Drawing.Point(3, 19) - Me.rbMenuMo.Name = "rbMenuMo" - Me.rbMenuMo.Size = New System.Drawing.Size(52, 17) - Me.rbMenuMo.TabIndex = 0 - Me.rbMenuMo.TabStop = True - Me.rbMenuMo.Text = "Menü" - Me.rbMenuMo.UseVisualStyleBackColor = True - ' - 'rbMenoAltMo - ' - Me.rbMenoAltMo.AutoSize = True - Me.rbMenoAltMo.GroupName = Nothing - Me.rbMenoAltMo.Location = New System.Drawing.Point(3, 42) - Me.rbMenoAltMo.Name = "rbMenoAltMo" - Me.rbMenoAltMo.Size = New System.Drawing.Size(70, 17) - Me.rbMenoAltMo.TabIndex = 1 - Me.rbMenoAltMo.TabStop = True - Me.rbMenoAltMo.Text = "A la carte" - Me.rbMenoAltMo.UseVisualStyleBackColor = True + Me.cbMontag.AutoSize = True + Me.cbMontag.Location = New System.Drawing.Point(3, 0) + Me.cbMontag.Name = "cbMontag" + Me.cbMontag.Size = New System.Drawing.Size(62, 17) + Me.cbMontag.TabIndex = 3 + Me.cbMontag.Text = "Montag" + Me.cbMontag.UseVisualStyleBackColor = True ' 'txtAltMo ' @@ -203,8 +149,33 @@ Partial Class frmEssensbestellungen Me.txtAltMo.TabIndex = 2 Me.txtAltMo.Visible = False ' + 'rbMenoAltMo + ' + Me.rbMenoAltMo.AutoSize = True + Me.rbMenoAltMo.GroupName = "GroupBox1" + Me.rbMenoAltMo.Location = New System.Drawing.Point(3, 42) + Me.rbMenoAltMo.Name = "rbMenoAltMo" + Me.rbMenoAltMo.Size = New System.Drawing.Size(70, 17) + Me.rbMenoAltMo.TabIndex = 1 + Me.rbMenoAltMo.TabStop = True + Me.rbMenoAltMo.Text = "A la carte" + Me.rbMenoAltMo.UseVisualStyleBackColor = True + ' + 'rbMenuMo + ' + Me.rbMenuMo.AutoSize = True + Me.rbMenuMo.GroupName = "GroupBox1" + Me.rbMenuMo.Location = New System.Drawing.Point(3, 19) + Me.rbMenuMo.Name = "rbMenuMo" + Me.rbMenuMo.Size = New System.Drawing.Size(52, 17) + Me.rbMenuMo.TabIndex = 0 + Me.rbMenuMo.TabStop = True + Me.rbMenuMo.Text = "Menü" + Me.rbMenuMo.UseVisualStyleBackColor = True + ' 'GroupBox2 ' + Me.GroupBox2.Controls.Add(Me.cbDienstag) Me.GroupBox2.Controls.Add(Me.txtAltDi) Me.GroupBox2.Controls.Add(Me.rbMenuAltDi) Me.GroupBox2.Controls.Add(Me.rbMenuDi) @@ -215,6 +186,16 @@ Partial Class frmEssensbestellungen Me.GroupBox2.TabStop = False Me.GroupBox2.Text = "Dienstag" ' + 'cbDienstag + ' + Me.cbDienstag.AutoSize = True + Me.cbDienstag.Location = New System.Drawing.Point(0, 0) + Me.cbDienstag.Name = "cbDienstag" + Me.cbDienstag.Size = New System.Drawing.Size(68, 17) + Me.cbDienstag.TabIndex = 4 + Me.cbDienstag.Text = "Dienstag" + Me.cbDienstag.UseVisualStyleBackColor = True + ' 'txtAltDi ' Me.txtAltDi._DateTimeOnly = False @@ -265,6 +246,7 @@ Partial Class frmEssensbestellungen ' 'GroupBox3 ' + Me.GroupBox3.Controls.Add(Me.cbMittwoch) Me.GroupBox3.Controls.Add(Me.txtAltMi) Me.GroupBox3.Controls.Add(Me.rbMenuAltMi) Me.GroupBox3.Controls.Add(Me.rbMenuMi) @@ -275,6 +257,16 @@ Partial Class frmEssensbestellungen Me.GroupBox3.TabStop = False Me.GroupBox3.Text = "Mittwoch" ' + 'cbMittwoch + ' + Me.cbMittwoch.AutoSize = True + Me.cbMittwoch.Location = New System.Drawing.Point(0, 0) + Me.cbMittwoch.Name = "cbMittwoch" + Me.cbMittwoch.Size = New System.Drawing.Size(69, 17) + Me.cbMittwoch.TabIndex = 5 + Me.cbMittwoch.Text = "Mittwoch" + Me.cbMittwoch.UseVisualStyleBackColor = True + ' 'txtAltMi ' Me.txtAltMi._DateTimeOnly = False @@ -325,6 +317,7 @@ Partial Class frmEssensbestellungen ' 'GroupBox4 ' + Me.GroupBox4.Controls.Add(Me.cbDonnerstag) Me.GroupBox4.Controls.Add(Me.txtAltDo) Me.GroupBox4.Controls.Add(Me.rbMenuAltDo) Me.GroupBox4.Controls.Add(Me.rbMenuDo) @@ -335,6 +328,16 @@ Partial Class frmEssensbestellungen Me.GroupBox4.TabStop = False Me.GroupBox4.Text = "Donnerstag" ' + 'cbDonnerstag + ' + Me.cbDonnerstag.AutoSize = True + Me.cbDonnerstag.Location = New System.Drawing.Point(3, 0) + Me.cbDonnerstag.Name = "cbDonnerstag" + Me.cbDonnerstag.Size = New System.Drawing.Size(81, 17) + Me.cbDonnerstag.TabIndex = 7 + Me.cbDonnerstag.Text = "Donnerstag" + Me.cbDonnerstag.UseVisualStyleBackColor = True + ' 'txtAltDo ' Me.txtAltDo._DateTimeOnly = False @@ -385,6 +388,7 @@ Partial Class frmEssensbestellungen ' 'GroupBox5 ' + Me.GroupBox5.Controls.Add(Me.cbFreitag) Me.GroupBox5.Controls.Add(Me.txtAltFr) Me.GroupBox5.Controls.Add(Me.rbMenuFrAlt) Me.GroupBox5.Controls.Add(Me.rbMenuFr) @@ -395,6 +399,16 @@ Partial Class frmEssensbestellungen Me.GroupBox5.TabStop = False Me.GroupBox5.Text = "Freitag" ' + 'cbFreitag + ' + Me.cbFreitag.AutoSize = True + Me.cbFreitag.Location = New System.Drawing.Point(3, 0) + Me.cbFreitag.Name = "cbFreitag" + Me.cbFreitag.Size = New System.Drawing.Size(58, 17) + Me.cbFreitag.TabIndex = 6 + Me.cbFreitag.Text = "Freitag" + Me.cbFreitag.UseVisualStyleBackColor = True + ' 'txtAltFr ' Me.txtAltFr._DateTimeOnly = False @@ -479,11 +493,79 @@ Partial Class frmEssensbestellungen Me.txtAnzahlLaCart.TabIndex = 17 Me.txtAnzahlLaCart.Text = "0" ' + 'dgvBestellungen + ' + Me.dgvBestellungen.AKTUALISIERUNGS_INTERVALL = -1 + Me.dgvBestellungen.AllowUserToAddRows = False + Me.dgvBestellungen.AllowUserToDeleteRows = False + Me.dgvBestellungen.AllowUserToOrderColumns = True + Me.dgvBestellungen.BackgroundColor = System.Drawing.Color.White + DataGridViewCellStyle4.Alignment = System.Windows.Forms.DataGridViewContentAlignment.MiddleLeft + DataGridViewCellStyle4.BackColor = System.Drawing.SystemColors.Control + DataGridViewCellStyle4.Font = New System.Drawing.Font("Microsoft Sans Serif", 8.25!, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, CType(0, Byte)) + DataGridViewCellStyle4.ForeColor = System.Drawing.SystemColors.WindowText + DataGridViewCellStyle4.SelectionBackColor = System.Drawing.SystemColors.Highlight + DataGridViewCellStyle4.SelectionForeColor = System.Drawing.SystemColors.HighlightText + DataGridViewCellStyle4.WrapMode = System.Windows.Forms.DataGridViewTriState.[True] + Me.dgvBestellungen.ColumnHeadersDefaultCellStyle = DataGridViewCellStyle4 + Me.dgvBestellungen.ColumnHeadersHeightSizeMode = System.Windows.Forms.DataGridViewColumnHeadersHeightSizeMode.AutoSize + DataGridViewCellStyle5.Alignment = System.Windows.Forms.DataGridViewContentAlignment.MiddleLeft + DataGridViewCellStyle5.BackColor = System.Drawing.SystemColors.Window + DataGridViewCellStyle5.Font = New System.Drawing.Font("Microsoft Sans Serif", 8.25!, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, CType(0, Byte)) + DataGridViewCellStyle5.ForeColor = System.Drawing.SystemColors.ControlText + DataGridViewCellStyle5.SelectionBackColor = System.Drawing.SystemColors.Highlight + DataGridViewCellStyle5.SelectionForeColor = System.Drawing.SystemColors.HighlightText + DataGridViewCellStyle5.WrapMode = System.Windows.Forms.DataGridViewTriState.[False] + Me.dgvBestellungen.DefaultCellStyle = DataGridViewCellStyle5 + Me.dgvBestellungen.Location = New System.Drawing.Point(12, 298) + Me.dgvBestellungen.Name = "dgvBestellungen" + DataGridViewCellStyle6.Alignment = System.Windows.Forms.DataGridViewContentAlignment.MiddleLeft + DataGridViewCellStyle6.BackColor = System.Drawing.SystemColors.Control + DataGridViewCellStyle6.Font = New System.Drawing.Font("Microsoft Sans Serif", 8.25!, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, CType(0, Byte)) + DataGridViewCellStyle6.ForeColor = System.Drawing.SystemColors.WindowText + DataGridViewCellStyle6.SelectionBackColor = System.Drawing.SystemColors.Highlight + DataGridViewCellStyle6.SelectionForeColor = System.Drawing.SystemColors.HighlightText + DataGridViewCellStyle6.WrapMode = System.Windows.Forms.DataGridViewTriState.[True] + Me.dgvBestellungen.RowHeadersDefaultCellStyle = DataGridViewCellStyle6 + Me.dgvBestellungen.Size = New System.Drawing.Size(528, 150) + Me.dgvBestellungen.TabIndex = 2 + ' + 'MyComboBox1 + ' + Me.MyComboBox1._allowedValuesFreiText = Nothing + Me.MyComboBox1._allowFreiText = False + Me.MyComboBox1._value = "" + Me.MyComboBox1.FormattingEnabled = True + Me.MyComboBox1.Location = New System.Drawing.Point(12, 30) + Me.MyComboBox1.Name = "MyComboBox1" + Me.MyComboBox1.Size = New System.Drawing.Size(95, 21) + Me.MyComboBox1.TabIndex = 0 + ' + 'lblAbteilung + ' + Me.lblAbteilung.AutoSize = True + Me.lblAbteilung.Location = New System.Drawing.Point(472, 9) + Me.lblAbteilung.Name = "lblAbteilung" + Me.lblAbteilung.Size = New System.Drawing.Size(54, 13) + Me.lblAbteilung.TabIndex = 18 + Me.lblAbteilung.Text = "Abteilung:" + ' + 'lblGebaeude + ' + Me.lblGebaeude.AutoSize = True + Me.lblGebaeude.Location = New System.Drawing.Point(472, 30) + Me.lblGebaeude.Name = "lblGebaeude" + Me.lblGebaeude.Size = New System.Drawing.Size(54, 13) + Me.lblGebaeude.TabIndex = 19 + Me.lblGebaeude.Text = "Gebäude:" + ' 'frmEssensbestellungen ' Me.AutoScaleDimensions = New System.Drawing.SizeF(6.0!, 13.0!) Me.AutoScaleMode = System.Windows.Forms.AutoScaleMode.Font Me.ClientSize = New System.Drawing.Size(680, 476) + Me.Controls.Add(Me.lblGebaeude) + Me.Controls.Add(Me.lblAbteilung) Me.Controls.Add(Me.txtAnzahlLaCart) Me.Controls.Add(Me.txtAnzahlMenu) Me.Controls.Add(Me.lbl2) @@ -500,7 +582,6 @@ Partial Class frmEssensbestellungen Me.Controls.Add(Me.MyComboBox1) Me.Name = "frmEssensbestellungen" Me.Text = "Essensbestellung" - CType(Me.dgvBestellungen, System.ComponentModel.ISupportInitialize).EndInit() Me.GroupBox1.ResumeLayout(False) Me.GroupBox1.PerformLayout() Me.GroupBox2.ResumeLayout(False) @@ -511,6 +592,7 @@ Partial Class frmEssensbestellungen Me.GroupBox4.PerformLayout() Me.GroupBox5.ResumeLayout(False) Me.GroupBox5.PerformLayout() + CType(Me.dgvBestellungen, System.ComponentModel.ISupportInitialize).EndInit() Me.ResumeLayout(False) Me.PerformLayout() @@ -550,4 +632,11 @@ Partial Class frmEssensbestellungen Friend WithEvents ToolTipInfoMi As ToolTip Friend WithEvents ToolTipInfoDo As ToolTip Friend WithEvents ToolTipInfoFr As ToolTip + Friend WithEvents cbMontag As CheckBox + Friend WithEvents cbDienstag As CheckBox + Friend WithEvents cbMittwoch As CheckBox + Friend WithEvents cbDonnerstag As CheckBox + Friend WithEvents cbFreitag As CheckBox + Friend WithEvents lblAbteilung As Label + Friend WithEvents lblGebaeude As Label End Class diff --git a/Aviso/frmEssensbestellungen.vb b/Aviso/frmEssensbestellungen.vb index 93e0055..4f6dfa6 100644 --- a/Aviso/frmEssensbestellungen.vb +++ b/Aviso/frmEssensbestellungen.vb @@ -1,5 +1,6 @@  +Imports System.Web.UI.WebControls Imports GrapeCity.ActiveReports.ReportsCore.Tools Imports Spire.Pdf.General.Paper Imports VERAG_PROG_ALLGEMEIN @@ -7,21 +8,62 @@ Imports VERAG_PROG_ALLGEMEIN Public Class frmEssensbestellungen Dim SQL As New VERAG_PROG_ALLGEMEIN.SQL - + Dim essen As New cEssensbestellung() Private Sub frmEssensbestellungen_Load(sender As Object, e As EventArgs) Handles MyBase.Load + MyComboBox1.fillWithSQL("SELECT MenuTitel from tblEBMenu", False, "AVISO", True) + + lblGebaeude.Text = VERAG_PROG_ALLGEMEIN.cAllgemein.BÜRO + lblAbteilung.Text = VERAG_PROG_ALLGEMEIN.cAllgemein.ABTEILUNG + + End Sub Private Sub btnSave_Click(sender As Object, e As EventArgs) Handles btnSave.Click + If cbMontag.Checked Then + IIf(rbMenuMo.Checked, essen.eb_montag = "Menu", essen.eb_montag = txtAltMo.ToString) + Else + essen.eb_montag = Nothing + End If + + If cbDienstag.Checked Then + IIf(rbMenuDi.Checked, essen.eb_dienstag = "Menu", essen.eb_dienstag = txtAltMo.ToString) + Else + essen.eb_dienstag = Nothing + End If + + If cbMittwoch.Checked Then + IIf(rbMenuMi.Checked, essen.eb_mittwoch = "Menu", essen.eb_mittwoch = txtAltMo.ToString) + Else + essen.eb_mittwoch = Nothing + End If + + + If cbDonnerstag.Checked Then + IIf(rbMenuDo.Checked, essen.eb_donnerstag = "Menu", essen.eb_donnerstag = txtAltMo.ToString) + Else + essen.eb_donnerstag = Nothing + End If + + If cbFreitag.Checked Then + IIf(rbMenuFr.Checked, essen.eb_freitag = "Menu", essen.eb_freitag = txtAltMo.ToString) + Else + essen.eb_freitag = Nothing + End If + + essen.SAVE() + End Sub Private Sub MyComboBox1_SelectedValueChanged(sender As Object, e As EventArgs) Handles MyComboBox1.SelectedValueChanged + essen = New cEssensbestellung(MyComboBox1._value, VERAG_PROG_ALLGEMEIN.cAllgemein.USRID, VERAG_PROG_ALLGEMEIN.cAllgemein.BÜRO, VERAG_PROG_ALLGEMEIN.cAllgemein.ABTEILUNG) + Dim dt As New DataTable dt = SQL.loadDgvBySql("SELECT * FROM tblEBMenu where [MenuTitel] = '" & MyComboBox1._value & "'", "AVISO", 100, True) @@ -36,8 +78,51 @@ Public Class frmEssensbestellungen End Sub Private Sub rbMenoAltMo_CheckedChanged(sender As Object, e As EventArgs) Handles rbMenoAltMo.CheckedChanged - IIf(rbMenoAltMo.Checked, txtAltMo.Visible = True, txtAltMo.Visible = False) + End Sub + 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 + rbMenoAltMo.Enabled = True + rbMenuMo.Enabled = True + Else + rbMenoAltMo.Enabled = False + rbMenoAltMo.Enabled = False + End If + If cbDienstag.Checked Then + rbMenuAltDi.Enabled = True + rbMenuDi.Enabled = True + Else + rbMenuDi.Enabled = False + rbMenuAltDi.Enabled = False + End If + + If cbMittwoch.Checked Then + rbMenuAltMi.Enabled = True + rbMenuMi.Enabled = True + Else + rbMenuMi.Enabled = False + rbMenuAltMi.Enabled = False + End If + + + If cbDonnerstag.Checked Then + rbMenuAltDo.Enabled = True + rbMenuDo.Enabled = True + Else + rbMenuDo.Enabled = False + rbMenuAltDo.Enabled = False + End If + + If cbFreitag.Checked Then + rbMenuFrAlt.Enabled = True + rbMenuFr.Enabled = True + Else + rbMenuFr.Enabled = False + rbMenuFrAlt.Enabled = False + End If + + + End Sub End Class \ No newline at end of file From e5909bd403962ecd0a09343d704fb38a4262fa02 Mon Sep 17 00:00:00 2001 From: "d.breimaier" Date: Tue, 29 Nov 2022 15:15:05 +0100 Subject: [PATCH 04/10] Essensbestellungen --- Aviso/frmEssensbestellungen.Designer.vb | 539 +++++++++++++++--------- Aviso/frmEssensbestellungen.vb | 384 +++++++++++++++-- 2 files changed, 690 insertions(+), 233 deletions(-) diff --git a/Aviso/frmEssensbestellungen.Designer.vb b/Aviso/frmEssensbestellungen.Designer.vb index 43b1b1e..cf1a3fa 100644 --- a/Aviso/frmEssensbestellungen.Designer.vb +++ b/Aviso/frmEssensbestellungen.Designer.vb @@ -30,30 +30,35 @@ Partial Class frmEssensbestellungen Me.btnSave = New System.Windows.Forms.Button() Me.lblDatum = New System.Windows.Forms.Label() Me.GroupBox1 = New System.Windows.Forms.GroupBox() + Me.pbMontag = New System.Windows.Forms.PictureBox() Me.cbMontag = New System.Windows.Forms.CheckBox() Me.txtAltMo = New VERAG_PROG_ALLGEMEIN.MyTextBox() - Me.rbMenoAltMo = New VERAG_PROG_ALLGEMEIN.MyRadioButton(Me.components) - Me.rbMenuMo = New VERAG_PROG_ALLGEMEIN.MyRadioButton(Me.components) - Me.GroupBox2 = New System.Windows.Forms.GroupBox() + Me.rbMenoAlt_Mo = New VERAG_PROG_ALLGEMEIN.MyRadioButton(Me.components) + Me.rbMenu_Mo = New VERAG_PROG_ALLGEMEIN.MyRadioButton(Me.components) + Me.Dienstag = New System.Windows.Forms.GroupBox() + Me.pbDienstag = New System.Windows.Forms.PictureBox() Me.cbDienstag = New System.Windows.Forms.CheckBox() Me.txtAltDi = New VERAG_PROG_ALLGEMEIN.MyTextBox() - Me.rbMenuAltDi = New VERAG_PROG_ALLGEMEIN.MyRadioButton(Me.components) - Me.rbMenuDi = New VERAG_PROG_ALLGEMEIN.MyRadioButton(Me.components) - Me.GroupBox3 = New System.Windows.Forms.GroupBox() + Me.rbMenuAlt_Di = New VERAG_PROG_ALLGEMEIN.MyRadioButton(Me.components) + Me.rbMenu_Di = New VERAG_PROG_ALLGEMEIN.MyRadioButton(Me.components) + Me.Mittwoch = New System.Windows.Forms.GroupBox() + Me.pbMittwoch = New System.Windows.Forms.PictureBox() Me.cbMittwoch = New System.Windows.Forms.CheckBox() Me.txtAltMi = New VERAG_PROG_ALLGEMEIN.MyTextBox() - Me.rbMenuAltMi = New VERAG_PROG_ALLGEMEIN.MyRadioButton(Me.components) - Me.rbMenuMi = New VERAG_PROG_ALLGEMEIN.MyRadioButton(Me.components) + 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.pbDonnerstag = New System.Windows.Forms.PictureBox() Me.cbDonnerstag = New System.Windows.Forms.CheckBox() Me.txtAltDo = New VERAG_PROG_ALLGEMEIN.MyTextBox() - Me.rbMenuAltDo = New VERAG_PROG_ALLGEMEIN.MyRadioButton(Me.components) - Me.rbMenuDo = New VERAG_PROG_ALLGEMEIN.MyRadioButton(Me.components) + Me.rbMenuAlt_Do = New VERAG_PROG_ALLGEMEIN.MyRadioButton(Me.components) + Me.rbMenu_Do = New VERAG_PROG_ALLGEMEIN.MyRadioButton(Me.components) Me.GroupBox5 = New System.Windows.Forms.GroupBox() + Me.pbFreitag = New System.Windows.Forms.PictureBox() Me.cbFreitag = New System.Windows.Forms.CheckBox() Me.txtAltFr = New VERAG_PROG_ALLGEMEIN.MyTextBox() - Me.rbMenuFrAlt = New VERAG_PROG_ALLGEMEIN.MyRadioButton(Me.components) - Me.rbMenuFr = New VERAG_PROG_ALLGEMEIN.MyRadioButton(Me.components) + Me.rbMenuAlt_Fr = New VERAG_PROG_ALLGEMEIN.MyRadioButton(Me.components) + Me.rbMenu_Fr = New VERAG_PROG_ALLGEMEIN.MyRadioButton(Me.components) Me.lbl1 = New System.Windows.Forms.Label() Me.lbl2 = New System.Windows.Forms.Label() Me.txtAnzahlMenu = New System.Windows.Forms.Label() @@ -64,15 +69,27 @@ Partial Class frmEssensbestellungen Me.ToolTipInfoDo = New System.Windows.Forms.ToolTip(Me.components) Me.ToolTipInfoFr = New System.Windows.Forms.ToolTip(Me.components) Me.dgvBestellungen = New VERAG_PROG_ALLGEMEIN.MyDatagridview(Me.components) - Me.MyComboBox1 = New VERAG_PROG_ALLGEMEIN.MyComboBox() + Me.cbxMenu = New VERAG_PROG_ALLGEMEIN.MyComboBox() Me.lblAbteilung = New System.Windows.Forms.Label() Me.lblGebaeude = New System.Windows.Forms.Label() + Me.MyPanel1 = New VERAG_PROG_ALLGEMEIN.MyPanel(Me.components) + Me.lblBestellungen = New System.Windows.Forms.Label() + Me.txtPreis = New System.Windows.Forms.Label() + Me.Label2 = New System.Windows.Forms.Label() + Me.cbxGebauede = New VERAG_PROG_ALLGEMEIN.MyComboBox() + Me.lblBestellungBis = New System.Windows.Forms.Label() Me.GroupBox1.SuspendLayout() - Me.GroupBox2.SuspendLayout() - Me.GroupBox3.SuspendLayout() + CType(Me.pbMontag, System.ComponentModel.ISupportInitialize).BeginInit() + Me.Dienstag.SuspendLayout() + CType(Me.pbDienstag, System.ComponentModel.ISupportInitialize).BeginInit() + Me.Mittwoch.SuspendLayout() + CType(Me.pbMittwoch, System.ComponentModel.ISupportInitialize).BeginInit() Me.GroupBox4.SuspendLayout() + CType(Me.pbDonnerstag, System.ComponentModel.ISupportInitialize).BeginInit() Me.GroupBox5.SuspendLayout() + CType(Me.pbFreitag, System.ComponentModel.ISupportInitialize).BeginInit() CType(Me.dgvBestellungen, System.ComponentModel.ISupportInitialize).BeginInit() + Me.MyPanel1.SuspendLayout() Me.SuspendLayout() ' 'lblWochenkarte @@ -86,7 +103,7 @@ Partial Class frmEssensbestellungen ' 'btnSave ' - Me.btnSave.Location = New System.Drawing.Point(565, 249) + Me.btnSave.Location = New System.Drawing.Point(305, 484) Me.btnSave.Name = "btnSave" Me.btnSave.Size = New System.Drawing.Size(75, 23) Me.btnSave.TabIndex = 10 @@ -104,17 +121,28 @@ Partial Class frmEssensbestellungen ' 'GroupBox1 ' + Me.GroupBox1.Controls.Add(Me.pbMontag) Me.GroupBox1.Controls.Add(Me.cbMontag) Me.GroupBox1.Controls.Add(Me.txtAltMo) - Me.GroupBox1.Controls.Add(Me.rbMenoAltMo) - Me.GroupBox1.Controls.Add(Me.rbMenuMo) - Me.GroupBox1.Location = New System.Drawing.Point(15, 67) + 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" ' + 'pbMontag + ' + Me.pbMontag.Image = Global.AVISO.My.Resources.Resources.documents + Me.pbMontag.Location = New System.Drawing.Point(61, 23) + Me.pbMontag.Name = "pbMontag" + Me.pbMontag.Size = New System.Drawing.Size(17, 13) + Me.pbMontag.SizeMode = System.Windows.Forms.PictureBoxSizeMode.StretchImage + Me.pbMontag.TabIndex = 4 + Me.pbMontag.TabStop = False + ' 'cbMontag ' Me.cbMontag.AutoSize = True @@ -149,42 +177,53 @@ Partial Class frmEssensbestellungen Me.txtAltMo.TabIndex = 2 Me.txtAltMo.Visible = False ' - 'rbMenoAltMo + 'rbMenoAlt_Mo ' - Me.rbMenoAltMo.AutoSize = True - Me.rbMenoAltMo.GroupName = "GroupBox1" - Me.rbMenoAltMo.Location = New System.Drawing.Point(3, 42) - Me.rbMenoAltMo.Name = "rbMenoAltMo" - Me.rbMenoAltMo.Size = New System.Drawing.Size(70, 17) - Me.rbMenoAltMo.TabIndex = 1 - Me.rbMenoAltMo.TabStop = True - Me.rbMenoAltMo.Text = "A la carte" - Me.rbMenoAltMo.UseVisualStyleBackColor = True + 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 ' - 'rbMenuMo + 'rbMenu_Mo ' - Me.rbMenuMo.AutoSize = True - Me.rbMenuMo.GroupName = "GroupBox1" - Me.rbMenuMo.Location = New System.Drawing.Point(3, 19) - Me.rbMenuMo.Name = "rbMenuMo" - Me.rbMenuMo.Size = New System.Drawing.Size(52, 17) - Me.rbMenuMo.TabIndex = 0 - Me.rbMenuMo.TabStop = True - Me.rbMenuMo.Text = "Menü" - Me.rbMenuMo.UseVisualStyleBackColor = True + Me.rbMenu_Mo.AutoSize = True + Me.rbMenu_Mo.GroupName = "GroupBox1" + Me.rbMenu_Mo.Location = New System.Drawing.Point(3, 19) + Me.rbMenu_Mo.Name = "rbMenu_Mo" + Me.rbMenu_Mo.Size = New System.Drawing.Size(52, 17) + Me.rbMenu_Mo.TabIndex = 0 + Me.rbMenu_Mo.TabStop = True + Me.rbMenu_Mo.Text = "Menü" + Me.rbMenu_Mo.UseVisualStyleBackColor = True ' - 'GroupBox2 + 'Dienstag ' - Me.GroupBox2.Controls.Add(Me.cbDienstag) - Me.GroupBox2.Controls.Add(Me.txtAltDi) - Me.GroupBox2.Controls.Add(Me.rbMenuAltDi) - Me.GroupBox2.Controls.Add(Me.rbMenuDi) - Me.GroupBox2.Location = New System.Drawing.Point(234, 67) - Me.GroupBox2.Name = "GroupBox2" - Me.GroupBox2.Size = New System.Drawing.Size(200, 95) - Me.GroupBox2.TabIndex = 13 - Me.GroupBox2.TabStop = False - Me.GroupBox2.Text = "Dienstag" + 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" + ' + 'pbDienstag + ' + Me.pbDienstag.Image = Global.AVISO.My.Resources.Resources.documents + Me.pbDienstag.Location = New System.Drawing.Point(61, 23) + Me.pbDienstag.Name = "pbDienstag" + Me.pbDienstag.Size = New System.Drawing.Size(17, 13) + Me.pbDienstag.SizeMode = System.Windows.Forms.PictureBoxSizeMode.StretchImage + Me.pbDienstag.TabIndex = 5 + Me.pbDienstag.TabStop = False ' 'cbDienstag ' @@ -220,42 +259,53 @@ Partial Class frmEssensbestellungen Me.txtAltDi.TabIndex = 2 Me.txtAltDi.Visible = False ' - 'rbMenuAltDi + 'rbMenuAlt_Di ' - Me.rbMenuAltDi.AutoSize = True - Me.rbMenuAltDi.GroupName = Nothing - Me.rbMenuAltDi.Location = New System.Drawing.Point(3, 42) - Me.rbMenuAltDi.Name = "rbMenuAltDi" - Me.rbMenuAltDi.Size = New System.Drawing.Size(70, 17) - Me.rbMenuAltDi.TabIndex = 1 - Me.rbMenuAltDi.TabStop = True - Me.rbMenuAltDi.Text = "A la carte" - Me.rbMenuAltDi.UseVisualStyleBackColor = True + Me.rbMenuAlt_Di.AutoSize = True + Me.rbMenuAlt_Di.GroupName = "Dienstag" + Me.rbMenuAlt_Di.Location = New System.Drawing.Point(3, 42) + Me.rbMenuAlt_Di.Name = "rbMenuAlt_Di" + Me.rbMenuAlt_Di.Size = New System.Drawing.Size(70, 17) + Me.rbMenuAlt_Di.TabIndex = 1 + Me.rbMenuAlt_Di.TabStop = True + Me.rbMenuAlt_Di.Text = "A la carte" + Me.rbMenuAlt_Di.UseVisualStyleBackColor = True ' - 'rbMenuDi + 'rbMenu_Di ' - Me.rbMenuDi.AutoSize = True - Me.rbMenuDi.GroupName = Nothing - Me.rbMenuDi.Location = New System.Drawing.Point(3, 19) - Me.rbMenuDi.Name = "rbMenuDi" - Me.rbMenuDi.Size = New System.Drawing.Size(52, 17) - Me.rbMenuDi.TabIndex = 0 - Me.rbMenuDi.TabStop = True - Me.rbMenuDi.Text = "Menü" - Me.rbMenuDi.UseVisualStyleBackColor = True + Me.rbMenu_Di.AutoSize = True + Me.rbMenu_Di.GroupName = "Dienstag" + Me.rbMenu_Di.Location = New System.Drawing.Point(3, 19) + Me.rbMenu_Di.Name = "rbMenu_Di" + Me.rbMenu_Di.Size = New System.Drawing.Size(52, 17) + Me.rbMenu_Di.TabIndex = 0 + Me.rbMenu_Di.TabStop = True + Me.rbMenu_Di.Text = "Menü" + Me.rbMenu_Di.UseVisualStyleBackColor = True ' - 'GroupBox3 + 'Mittwoch ' - Me.GroupBox3.Controls.Add(Me.cbMittwoch) - Me.GroupBox3.Controls.Add(Me.txtAltMi) - Me.GroupBox3.Controls.Add(Me.rbMenuAltMi) - Me.GroupBox3.Controls.Add(Me.rbMenuMi) - Me.GroupBox3.Location = New System.Drawing.Point(440, 67) - Me.GroupBox3.Name = "GroupBox3" - Me.GroupBox3.Size = New System.Drawing.Size(200, 95) - Me.GroupBox3.TabIndex = 13 - Me.GroupBox3.TabStop = False - Me.GroupBox3.Text = "Mittwoch" + Me.Mittwoch.Controls.Add(Me.pbMittwoch) + Me.Mittwoch.Controls.Add(Me.cbMittwoch) + Me.Mittwoch.Controls.Add(Me.txtAltMi) + Me.Mittwoch.Controls.Add(Me.rbMenuAlt_Mi) + 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.TabIndex = 13 + Me.Mittwoch.TabStop = False + Me.Mittwoch.Text = "Mittwoch" + ' + 'pbMittwoch + ' + Me.pbMittwoch.Image = Global.AVISO.My.Resources.Resources.documents + Me.pbMittwoch.Location = New System.Drawing.Point(56, 23) + Me.pbMittwoch.Name = "pbMittwoch" + Me.pbMittwoch.Size = New System.Drawing.Size(17, 13) + Me.pbMittwoch.SizeMode = System.Windows.Forms.PictureBoxSizeMode.StretchImage + Me.pbMittwoch.TabIndex = 6 + Me.pbMittwoch.TabStop = False ' 'cbMittwoch ' @@ -291,43 +341,54 @@ Partial Class frmEssensbestellungen Me.txtAltMi.TabIndex = 2 Me.txtAltMi.Visible = False ' - 'rbMenuAltMi + 'rbMenuAlt_Mi ' - Me.rbMenuAltMi.AutoSize = True - Me.rbMenuAltMi.GroupName = Nothing - Me.rbMenuAltMi.Location = New System.Drawing.Point(3, 42) - Me.rbMenuAltMi.Name = "rbMenuAltMi" - Me.rbMenuAltMi.Size = New System.Drawing.Size(70, 17) - Me.rbMenuAltMi.TabIndex = 1 - Me.rbMenuAltMi.TabStop = True - Me.rbMenuAltMi.Text = "A la carte" - Me.rbMenuAltMi.UseVisualStyleBackColor = True + Me.rbMenuAlt_Mi.AutoSize = True + Me.rbMenuAlt_Mi.GroupName = "Mittwoch" + Me.rbMenuAlt_Mi.Location = New System.Drawing.Point(3, 42) + Me.rbMenuAlt_Mi.Name = "rbMenuAlt_Mi" + Me.rbMenuAlt_Mi.Size = New System.Drawing.Size(70, 17) + Me.rbMenuAlt_Mi.TabIndex = 1 + Me.rbMenuAlt_Mi.TabStop = True + Me.rbMenuAlt_Mi.Text = "A la carte" + Me.rbMenuAlt_Mi.UseVisualStyleBackColor = True ' - 'rbMenuMi + 'rbMenu_Mi ' - Me.rbMenuMi.AutoSize = True - Me.rbMenuMi.GroupName = Nothing - Me.rbMenuMi.Location = New System.Drawing.Point(3, 19) - Me.rbMenuMi.Name = "rbMenuMi" - Me.rbMenuMi.Size = New System.Drawing.Size(52, 17) - Me.rbMenuMi.TabIndex = 0 - Me.rbMenuMi.TabStop = True - Me.rbMenuMi.Text = "Menü" - Me.rbMenuMi.UseVisualStyleBackColor = True + Me.rbMenu_Mi.AutoSize = True + Me.rbMenu_Mi.GroupName = "Mittwoch" + Me.rbMenu_Mi.Location = New System.Drawing.Point(3, 19) + Me.rbMenu_Mi.Name = "rbMenu_Mi" + Me.rbMenu_Mi.Size = New System.Drawing.Size(52, 17) + Me.rbMenu_Mi.TabIndex = 0 + Me.rbMenu_Mi.TabStop = True + Me.rbMenu_Mi.Text = "Menü" + Me.rbMenu_Mi.UseVisualStyleBackColor = True ' 'GroupBox4 ' + Me.GroupBox4.Controls.Add(Me.pbDonnerstag) Me.GroupBox4.Controls.Add(Me.cbDonnerstag) Me.GroupBox4.Controls.Add(Me.txtAltDo) - Me.GroupBox4.Controls.Add(Me.rbMenuAltDo) - Me.GroupBox4.Controls.Add(Me.rbMenuDo) - Me.GroupBox4.Location = New System.Drawing.Point(12, 168) + 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" ' + 'pbDonnerstag + ' + Me.pbDonnerstag.Image = Global.AVISO.My.Resources.Resources.documents + Me.pbDonnerstag.Location = New System.Drawing.Point(56, 21) + Me.pbDonnerstag.Name = "pbDonnerstag" + Me.pbDonnerstag.Size = New System.Drawing.Size(17, 13) + Me.pbDonnerstag.SizeMode = System.Windows.Forms.PictureBoxSizeMode.StretchImage + Me.pbDonnerstag.TabIndex = 7 + Me.pbDonnerstag.TabStop = False + ' 'cbDonnerstag ' Me.cbDonnerstag.AutoSize = True @@ -362,43 +423,54 @@ Partial Class frmEssensbestellungen Me.txtAltDo.TabIndex = 2 Me.txtAltDo.Visible = False ' - 'rbMenuAltDo + 'rbMenuAlt_Do ' - Me.rbMenuAltDo.AutoSize = True - Me.rbMenuAltDo.GroupName = Nothing - Me.rbMenuAltDo.Location = New System.Drawing.Point(3, 42) - Me.rbMenuAltDo.Name = "rbMenuAltDo" - Me.rbMenuAltDo.Size = New System.Drawing.Size(70, 17) - Me.rbMenuAltDo.TabIndex = 1 - Me.rbMenuAltDo.TabStop = True - Me.rbMenuAltDo.Text = "A la carte" - Me.rbMenuAltDo.UseVisualStyleBackColor = True + Me.rbMenuAlt_Do.AutoSize = True + Me.rbMenuAlt_Do.GroupName = "Donnerstag" + Me.rbMenuAlt_Do.Location = New System.Drawing.Point(3, 42) + Me.rbMenuAlt_Do.Name = "rbMenuAlt_Do" + Me.rbMenuAlt_Do.Size = New System.Drawing.Size(70, 17) + Me.rbMenuAlt_Do.TabIndex = 1 + Me.rbMenuAlt_Do.TabStop = True + Me.rbMenuAlt_Do.Text = "A la carte" + Me.rbMenuAlt_Do.UseVisualStyleBackColor = True ' - 'rbMenuDo + 'rbMenu_Do ' - Me.rbMenuDo.AutoSize = True - Me.rbMenuDo.GroupName = Nothing - Me.rbMenuDo.Location = New System.Drawing.Point(3, 19) - Me.rbMenuDo.Name = "rbMenuDo" - Me.rbMenuDo.Size = New System.Drawing.Size(52, 17) - Me.rbMenuDo.TabIndex = 0 - Me.rbMenuDo.TabStop = True - Me.rbMenuDo.Text = "Menü" - Me.rbMenuDo.UseVisualStyleBackColor = True + Me.rbMenu_Do.AutoSize = True + Me.rbMenu_Do.GroupName = "Donnerstag" + Me.rbMenu_Do.Location = New System.Drawing.Point(3, 19) + Me.rbMenu_Do.Name = "rbMenu_Do" + Me.rbMenu_Do.Size = New System.Drawing.Size(52, 17) + Me.rbMenu_Do.TabIndex = 0 + Me.rbMenu_Do.TabStop = True + Me.rbMenu_Do.Text = "Menü" + Me.rbMenu_Do.UseVisualStyleBackColor = True ' 'GroupBox5 ' + Me.GroupBox5.Controls.Add(Me.pbFreitag) Me.GroupBox5.Controls.Add(Me.cbFreitag) Me.GroupBox5.Controls.Add(Me.txtAltFr) - Me.GroupBox5.Controls.Add(Me.rbMenuFrAlt) - Me.GroupBox5.Controls.Add(Me.rbMenuFr) - Me.GroupBox5.Location = New System.Drawing.Point(234, 168) + 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" ' + 'pbFreitag + ' + Me.pbFreitag.Image = Global.AVISO.My.Resources.Resources.documents + Me.pbFreitag.Location = New System.Drawing.Point(61, 23) + Me.pbFreitag.Name = "pbFreitag" + Me.pbFreitag.Size = New System.Drawing.Size(17, 13) + Me.pbFreitag.SizeMode = System.Windows.Forms.PictureBoxSizeMode.StretchImage + Me.pbFreitag.TabIndex = 8 + Me.pbFreitag.TabStop = False + ' 'cbFreitag ' Me.cbFreitag.AutoSize = True @@ -433,34 +505,34 @@ Partial Class frmEssensbestellungen Me.txtAltFr.TabIndex = 2 Me.txtAltFr.Visible = False ' - 'rbMenuFrAlt + 'rbMenuAlt_Fr ' - Me.rbMenuFrAlt.AutoSize = True - Me.rbMenuFrAlt.GroupName = Nothing - Me.rbMenuFrAlt.Location = New System.Drawing.Point(3, 42) - Me.rbMenuFrAlt.Name = "rbMenuFrAlt" - Me.rbMenuFrAlt.Size = New System.Drawing.Size(70, 17) - Me.rbMenuFrAlt.TabIndex = 1 - Me.rbMenuFrAlt.TabStop = True - Me.rbMenuFrAlt.Text = "A la carte" - Me.rbMenuFrAlt.UseVisualStyleBackColor = True + Me.rbMenuAlt_Fr.AutoSize = True + Me.rbMenuAlt_Fr.GroupName = "Freitag" + Me.rbMenuAlt_Fr.Location = New System.Drawing.Point(3, 42) + Me.rbMenuAlt_Fr.Name = "rbMenuAlt_Fr" + Me.rbMenuAlt_Fr.Size = New System.Drawing.Size(70, 17) + Me.rbMenuAlt_Fr.TabIndex = 1 + Me.rbMenuAlt_Fr.TabStop = True + Me.rbMenuAlt_Fr.Text = "A la carte" + Me.rbMenuAlt_Fr.UseVisualStyleBackColor = True ' - 'rbMenuFr + 'rbMenu_Fr ' - Me.rbMenuFr.AutoSize = True - Me.rbMenuFr.GroupName = Nothing - Me.rbMenuFr.Location = New System.Drawing.Point(3, 19) - Me.rbMenuFr.Name = "rbMenuFr" - Me.rbMenuFr.Size = New System.Drawing.Size(52, 17) - Me.rbMenuFr.TabIndex = 0 - Me.rbMenuFr.TabStop = True - Me.rbMenuFr.Text = "Menü" - Me.rbMenuFr.UseVisualStyleBackColor = True + Me.rbMenu_Fr.AutoSize = True + Me.rbMenu_Fr.GroupName = "Freitag" + Me.rbMenu_Fr.Location = New System.Drawing.Point(3, 19) + Me.rbMenu_Fr.Name = "rbMenu_Fr" + Me.rbMenu_Fr.Size = New System.Drawing.Size(52, 17) + Me.rbMenu_Fr.TabIndex = 0 + Me.rbMenu_Fr.TabStop = True + Me.rbMenu_Fr.Text = "Menü" + Me.rbMenu_Fr.UseVisualStyleBackColor = True ' 'lbl1 ' Me.lbl1.AutoSize = True - Me.lbl1.Location = New System.Drawing.Point(472, 187) + Me.lbl1.Location = New System.Drawing.Point(463, 128) Me.lbl1.Name = "lbl1" Me.lbl1.Size = New System.Drawing.Size(72, 13) Me.lbl1.TabIndex = 14 @@ -469,7 +541,7 @@ Partial Class frmEssensbestellungen 'lbl2 ' Me.lbl2.AutoSize = True - Me.lbl2.Location = New System.Drawing.Point(472, 214) + Me.lbl2.Location = New System.Drawing.Point(463, 155) Me.lbl2.Name = "lbl2" Me.lbl2.Size = New System.Drawing.Size(90, 13) Me.lbl2.TabIndex = 15 @@ -478,7 +550,7 @@ Partial Class frmEssensbestellungen 'txtAnzahlMenu ' Me.txtAnzahlMenu.AutoSize = True - Me.txtAnzahlMenu.Location = New System.Drawing.Point(562, 189) + Me.txtAnzahlMenu.Location = New System.Drawing.Point(553, 130) Me.txtAnzahlMenu.Name = "txtAnzahlMenu" Me.txtAnzahlMenu.Size = New System.Drawing.Size(13, 13) Me.txtAnzahlMenu.TabIndex = 16 @@ -487,7 +559,7 @@ Partial Class frmEssensbestellungen 'txtAnzahlLaCart ' Me.txtAnzahlLaCart.AutoSize = True - Me.txtAnzahlLaCart.Location = New System.Drawing.Point(562, 214) + Me.txtAnzahlLaCart.Location = New System.Drawing.Point(553, 155) Me.txtAnzahlLaCart.Name = "txtAnzahlLaCart" Me.txtAnzahlLaCart.Size = New System.Drawing.Size(13, 13) Me.txtAnzahlLaCart.TabIndex = 17 @@ -517,8 +589,9 @@ Partial Class frmEssensbestellungen DataGridViewCellStyle5.SelectionForeColor = System.Drawing.SystemColors.HighlightText DataGridViewCellStyle5.WrapMode = System.Windows.Forms.DataGridViewTriState.[False] Me.dgvBestellungen.DefaultCellStyle = DataGridViewCellStyle5 - Me.dgvBestellungen.Location = New System.Drawing.Point(12, 298) + Me.dgvBestellungen.Location = New System.Drawing.Point(12, 351) Me.dgvBestellungen.Name = "dgvBestellungen" + Me.dgvBestellungen.ReadOnly = True DataGridViewCellStyle6.Alignment = System.Windows.Forms.DataGridViewContentAlignment.MiddleLeft DataGridViewCellStyle6.BackColor = System.Drawing.SystemColors.Control DataGridViewCellStyle6.Font = New System.Drawing.Font("Microsoft Sans Serif", 8.25!, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, CType(0, Byte)) @@ -527,24 +600,26 @@ Partial Class frmEssensbestellungen DataGridViewCellStyle6.SelectionForeColor = System.Drawing.SystemColors.HighlightText DataGridViewCellStyle6.WrapMode = System.Windows.Forms.DataGridViewTriState.[True] Me.dgvBestellungen.RowHeadersDefaultCellStyle = DataGridViewCellStyle6 - Me.dgvBestellungen.Size = New System.Drawing.Size(528, 150) + Me.dgvBestellungen.SelectionMode = System.Windows.Forms.DataGridViewSelectionMode.FullRowSelect + Me.dgvBestellungen.ShowEditingIcon = False + Me.dgvBestellungen.Size = New System.Drawing.Size(663, 127) Me.dgvBestellungen.TabIndex = 2 ' - 'MyComboBox1 + 'cbxMenu ' - Me.MyComboBox1._allowedValuesFreiText = Nothing - Me.MyComboBox1._allowFreiText = False - Me.MyComboBox1._value = "" - Me.MyComboBox1.FormattingEnabled = True - Me.MyComboBox1.Location = New System.Drawing.Point(12, 30) - Me.MyComboBox1.Name = "MyComboBox1" - Me.MyComboBox1.Size = New System.Drawing.Size(95, 21) - Me.MyComboBox1.TabIndex = 0 + Me.cbxMenu._allowedValuesFreiText = Nothing + Me.cbxMenu._allowFreiText = False + Me.cbxMenu._value = "" + Me.cbxMenu.FormattingEnabled = True + Me.cbxMenu.Location = New System.Drawing.Point(12, 30) + Me.cbxMenu.Name = "cbxMenu" + Me.cbxMenu.Size = New System.Drawing.Size(95, 21) + Me.cbxMenu.TabIndex = 0 ' 'lblAbteilung ' Me.lblAbteilung.AutoSize = True - Me.lblAbteilung.Location = New System.Drawing.Point(472, 9) + Me.lblAbteilung.Location = New System.Drawing.Point(511, 9) Me.lblAbteilung.Name = "lblAbteilung" Me.lblAbteilung.Size = New System.Drawing.Size(54, 13) Me.lblAbteilung.TabIndex = 18 @@ -553,76 +628,143 @@ Partial Class frmEssensbestellungen 'lblGebaeude ' Me.lblGebaeude.AutoSize = True - Me.lblGebaeude.Location = New System.Drawing.Point(472, 30) + Me.lblGebaeude.Location = New System.Drawing.Point(511, 27) Me.lblGebaeude.Name = "lblGebaeude" Me.lblGebaeude.Size = New System.Drawing.Size(54, 13) Me.lblGebaeude.TabIndex = 19 Me.lblGebaeude.Text = "Gebäude:" ' + 'MyPanel1 + ' + Me.MyPanel1.Controls.Add(Me.txtPreis) + Me.MyPanel1.Controls.Add(Me.Label2) + Me.MyPanel1.Controls.Add(Me.Dienstag) + Me.MyPanel1.Controls.Add(Me.lbl1) + Me.MyPanel1.Controls.Add(Me.GroupBox1) + Me.MyPanel1.Controls.Add(Me.GroupBox5) + 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.txtAnzahlMenu) + Me.MyPanel1.Location = New System.Drawing.Point(12, 67) + Me.MyPanel1.Name = "MyPanel1" + Me.MyPanel1.Size = New System.Drawing.Size(667, 240) + Me.MyPanel1.TabIndex = 18 + ' + 'lblBestellungen + ' + Me.lblBestellungen.AutoSize = True + Me.lblBestellungen.Location = New System.Drawing.Point(9, 335) + Me.lblBestellungen.Name = "lblBestellungen" + Me.lblBestellungen.Size = New System.Drawing.Size(100, 13) + Me.lblBestellungen.TabIndex = 20 + Me.lblBestellungen.Text = "Meine Bestellungen" + ' + 'txtPreis + ' + Me.txtPreis.AutoSize = True + Me.txtPreis.Location = New System.Drawing.Point(553, 181) + Me.txtPreis.Name = "txtPreis" + Me.txtPreis.Size = New System.Drawing.Size(13, 13) + Me.txtPreis.TabIndex = 19 + Me.txtPreis.Text = "0" + ' + 'Label2 + ' + Me.Label2.AutoSize = True + Me.Label2.Location = New System.Drawing.Point(463, 181) + Me.Label2.Name = "Label2" + Me.Label2.Size = New System.Drawing.Size(68, 13) + Me.Label2.TabIndex = 18 + Me.Label2.Text = "Gesamtpreis:" + ' + 'cbxGebauede + ' + Me.cbxGebauede._allowedValuesFreiText = Nothing + Me.cbxGebauede._allowFreiText = False + Me.cbxGebauede._value = "" + Me.cbxGebauede.FormattingEnabled = True + Me.cbxGebauede.Location = New System.Drawing.Point(580, 24) + Me.cbxGebauede.Name = "cbxGebauede" + Me.cbxGebauede.Size = New System.Drawing.Size(95, 21) + Me.cbxGebauede.TabIndex = 21 + ' + 'lblBestellungBis + ' + Me.lblBestellungBis.AutoSize = True + Me.lblBestellungBis.Location = New System.Drawing.Point(167, 38) + Me.lblBestellungBis.Name = "lblBestellungBis" + Me.lblBestellungBis.Size = New System.Drawing.Size(114, 13) + Me.lblBestellungBis.TabIndex = 22 + Me.lblBestellungBis.Text = "Bestellung möglich bis:" + ' 'frmEssensbestellungen ' Me.AutoScaleDimensions = New System.Drawing.SizeF(6.0!, 13.0!) Me.AutoScaleMode = System.Windows.Forms.AutoScaleMode.Font - Me.ClientSize = New System.Drawing.Size(680, 476) + Me.ClientSize = New System.Drawing.Size(687, 518) + Me.Controls.Add(Me.lblBestellungBis) + Me.Controls.Add(Me.cbxGebauede) + Me.Controls.Add(Me.lblBestellungen) + Me.Controls.Add(Me.MyPanel1) + Me.Controls.Add(Me.btnSave) Me.Controls.Add(Me.lblGebaeude) Me.Controls.Add(Me.lblAbteilung) - Me.Controls.Add(Me.txtAnzahlLaCart) - Me.Controls.Add(Me.txtAnzahlMenu) - Me.Controls.Add(Me.lbl2) - Me.Controls.Add(Me.lbl1) - Me.Controls.Add(Me.GroupBox5) - Me.Controls.Add(Me.GroupBox4) - Me.Controls.Add(Me.GroupBox3) - Me.Controls.Add(Me.GroupBox2) - Me.Controls.Add(Me.GroupBox1) Me.Controls.Add(Me.lblDatum) - Me.Controls.Add(Me.btnSave) Me.Controls.Add(Me.dgvBestellungen) Me.Controls.Add(Me.lblWochenkarte) - Me.Controls.Add(Me.MyComboBox1) + Me.Controls.Add(Me.cbxMenu) Me.Name = "frmEssensbestellungen" Me.Text = "Essensbestellung" Me.GroupBox1.ResumeLayout(False) Me.GroupBox1.PerformLayout() - Me.GroupBox2.ResumeLayout(False) - Me.GroupBox2.PerformLayout() - Me.GroupBox3.ResumeLayout(False) - Me.GroupBox3.PerformLayout() + CType(Me.pbMontag, System.ComponentModel.ISupportInitialize).EndInit() + Me.Dienstag.ResumeLayout(False) + Me.Dienstag.PerformLayout() + CType(Me.pbDienstag, 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() + CType(Me.pbDonnerstag, System.ComponentModel.ISupportInitialize).EndInit() Me.GroupBox5.ResumeLayout(False) Me.GroupBox5.PerformLayout() + CType(Me.pbFreitag, System.ComponentModel.ISupportInitialize).EndInit() CType(Me.dgvBestellungen, System.ComponentModel.ISupportInitialize).EndInit() + Me.MyPanel1.ResumeLayout(False) + Me.MyPanel1.PerformLayout() Me.ResumeLayout(False) Me.PerformLayout() End Sub - Friend WithEvents MyComboBox1 As VERAG_PROG_ALLGEMEIN.MyComboBox + Friend WithEvents cbxMenu As VERAG_PROG_ALLGEMEIN.MyComboBox Friend WithEvents lblWochenkarte As Label 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 txtAltMo As VERAG_PROG_ALLGEMEIN.MyTextBox - Friend WithEvents rbMenoAltMo As VERAG_PROG_ALLGEMEIN.MyRadioButton - Friend WithEvents rbMenuMo As VERAG_PROG_ALLGEMEIN.MyRadioButton - Friend WithEvents GroupBox2 As GroupBox + Friend WithEvents rbMenoAlt_Mo As VERAG_PROG_ALLGEMEIN.MyRadioButton + Friend WithEvents rbMenu_Mo As VERAG_PROG_ALLGEMEIN.MyRadioButton + Friend WithEvents Dienstag As GroupBox Friend WithEvents txtAltDi As VERAG_PROG_ALLGEMEIN.MyTextBox - Friend WithEvents rbMenuAltDi As VERAG_PROG_ALLGEMEIN.MyRadioButton - Friend WithEvents rbMenuDi As VERAG_PROG_ALLGEMEIN.MyRadioButton - Friend WithEvents GroupBox3 As GroupBox + Friend WithEvents rbMenuAlt_Di As VERAG_PROG_ALLGEMEIN.MyRadioButton + Friend WithEvents rbMenu_Di As VERAG_PROG_ALLGEMEIN.MyRadioButton + Friend WithEvents Mittwoch As GroupBox Friend WithEvents txtAltMi As VERAG_PROG_ALLGEMEIN.MyTextBox - Friend WithEvents rbMenuAltMi As VERAG_PROG_ALLGEMEIN.MyRadioButton - Friend WithEvents rbMenuMi As VERAG_PROG_ALLGEMEIN.MyRadioButton + 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 txtAltDo As VERAG_PROG_ALLGEMEIN.MyTextBox - Friend WithEvents rbMenuAltDo As VERAG_PROG_ALLGEMEIN.MyRadioButton - Friend WithEvents rbMenuDo As VERAG_PROG_ALLGEMEIN.MyRadioButton + 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 txtAltFr As VERAG_PROG_ALLGEMEIN.MyTextBox - Friend WithEvents rbMenuFrAlt As VERAG_PROG_ALLGEMEIN.MyRadioButton - Friend WithEvents rbMenuFr As VERAG_PROG_ALLGEMEIN.MyRadioButton + Friend WithEvents rbMenuAlt_Fr As VERAG_PROG_ALLGEMEIN.MyRadioButton + Friend WithEvents rbMenu_Fr As VERAG_PROG_ALLGEMEIN.MyRadioButton Friend WithEvents lbl1 As Label Friend WithEvents lbl2 As Label Friend WithEvents txtAnzahlMenu As Label @@ -639,4 +781,15 @@ Partial Class frmEssensbestellungen Friend WithEvents cbFreitag As CheckBox Friend WithEvents lblAbteilung As Label Friend WithEvents lblGebaeude As Label + Friend WithEvents MyPanel1 As VERAG_PROG_ALLGEMEIN.MyPanel + Friend WithEvents lblBestellungen As Label + Friend WithEvents pbMontag As PictureBox + Friend WithEvents pbDienstag As PictureBox + Friend WithEvents pbMittwoch As PictureBox + Friend WithEvents pbDonnerstag As PictureBox + Friend WithEvents pbFreitag As PictureBox + Friend WithEvents txtPreis As Label + Friend WithEvents Label2 As Label + Friend WithEvents cbxGebauede As VERAG_PROG_ALLGEMEIN.MyComboBox + Friend WithEvents lblBestellungBis As Label End Class diff --git a/Aviso/frmEssensbestellungen.vb b/Aviso/frmEssensbestellungen.vb index 4f6dfa6..3f8c1a8 100644 --- a/Aviso/frmEssensbestellungen.vb +++ b/Aviso/frmEssensbestellungen.vb @@ -1,128 +1,432 @@ - - -Imports System.Web.UI.WebControls -Imports GrapeCity.ActiveReports.ReportsCore.Tools -Imports Spire.Pdf.General.Paper +Imports Org.BouncyCastle.Asn1.Cms Imports VERAG_PROG_ALLGEMEIN Public Class frmEssensbestellungen Dim SQL As New VERAG_PROG_ALLGEMEIN.SQL Dim essen As New cEssensbestellung() + Dim dt As New DataTable + Private Sub frmEssensbestellungen_Load(sender As Object, e As EventArgs) Handles MyBase.Load - MyComboBox1.fillWithSQL("SELECT MenuTitel from tblEBMenu", False, "AVISO", True) - - lblGebaeude.Text = VERAG_PROG_ALLGEMEIN.cAllgemein.BÜRO - lblAbteilung.Text = VERAG_PROG_ALLGEMEIN.cAllgemein.ABTEILUNG + cbxMenu.fillWithSQL("SELECT MenuTitel from tblEBMenu", False, "AVISO", True) + lblGebaeude.Text = "Gebäude: " + lblAbteilung.Text = "Abteilung: " & VERAG_PROG_ALLGEMEIN.cAllgemein.ABTEILUNG + loadDGVBestellungen() + cbxGebauede.Items.Add(New VERAG_PROG_ALLGEMEIN.MyListItem("Frontoffice", "Frontoffice")) + cbxGebauede.Items.Add(New VERAG_PROG_ALLGEMEIN.MyListItem("Asfinag", "Asfinag")) + cbxGebauede.Items.Add(New VERAG_PROG_ALLGEMEIN.MyListItem("Verag Verrechnung", "Verag Verrechnung")) + cbxGebauede.Items.Add(New VERAG_PROG_ALLGEMEIN.MyListItem("Maut", "Maut")) End Sub Private Sub btnSave_Click(sender As Object, e As EventArgs) Handles btnSave.Click + essen = New cEssensbestellung(cbxMenu._value, cAllgemein.USRID, "Test", cAllgemein.ABTEILUNG) If cbMontag.Checked Then - IIf(rbMenuMo.Checked, essen.eb_montag = "Menu", essen.eb_montag = txtAltMo.ToString) + If rbMenu_Mo.Checked Then + essen.eb_montag = "Menu" + Else + essen.eb_montag = txtAltMo.Text.ToString + End If + Else essen.eb_montag = Nothing End If + If cbDienstag.Checked Then - IIf(rbMenuDi.Checked, essen.eb_dienstag = "Menu", essen.eb_dienstag = txtAltMo.ToString) + If rbMenu_Di.Checked Then + essen.eb_dienstag = "Menu" + Else + essen.eb_dienstag = txtAltDi.Text.ToString + End If + Else essen.eb_dienstag = Nothing End If If cbMittwoch.Checked Then - IIf(rbMenuMi.Checked, essen.eb_mittwoch = "Menu", essen.eb_mittwoch = txtAltMo.ToString) + If rbMenu_Mi.Checked Then + essen.eb_mittwoch = "Menu" + Else + essen.eb_mittwoch = txtAltMi.Text.ToString + End If + Else essen.eb_mittwoch = Nothing End If - If cbDonnerstag.Checked Then - IIf(rbMenuDo.Checked, essen.eb_donnerstag = "Menu", essen.eb_donnerstag = txtAltMo.ToString) + If rbMenu_Do.Checked Then + essen.eb_donnerstag = "Menu" + Else + essen.eb_donnerstag = txtAltDo.Text.ToString + End If + Else essen.eb_donnerstag = Nothing End If If cbFreitag.Checked Then - IIf(rbMenuFr.Checked, essen.eb_freitag = "Menu", essen.eb_freitag = txtAltMo.ToString) + If rbMenu_Fr.Checked Then + essen.eb_freitag = "Menu" + Else + essen.eb_freitag = txtAltFr.Text.ToString + End If + Else essen.eb_freitag = Nothing End If + If txtPreis.Text IsNot "" Then + essen.eb_preis = CDbl(txtPreis.Text) + End If essen.SAVE() + loadDGVBestellungen() End Sub - Private Sub MyComboBox1_SelectedValueChanged(sender As Object, e As EventArgs) Handles MyComboBox1.SelectedValueChanged + Private Sub cbxMenu_SelectedValueChanged(sender As Object, e As EventArgs) Handles cbxMenu.SelectedValueChanged - essen = New cEssensbestellung(MyComboBox1._value, VERAG_PROG_ALLGEMEIN.cAllgemein.USRID, VERAG_PROG_ALLGEMEIN.cAllgemein.BÜRO, VERAG_PROG_ALLGEMEIN.cAllgemein.ABTEILUNG) - Dim dt As New DataTable - dt = SQL.loadDgvBySql("SELECT * FROM tblEBMenu where [MenuTitel] = '" & MyComboBox1._value & "'", "AVISO", 100, True) + dt.Clear() + dt = SQL.loadDgvBySql("SELECT * FROM tblEBMenu where [MenuTitel] = '" & cbxMenu._value & "'", "AVISO", 100, True) If dt.Rows.Count > 0 Then + If checkIfOrderIsPossible() Then + MyPanel1.Enabled = True + Else + MyPanel1.Enabled = True + End If + lblDatum.Text = "Datum: " & CDate(dt.Rows(0).Item("MenuDateVon")).ToString("dd.MM.yyyy") & " - " & CDate(dt.Rows(0).Item("MenuDateBis")).ToString("dd.MM.yyyy") + loadMenuInfo(dt) btnSave.Enabled = True Else btnSave.Enabled = False End If + uncheckGroupBoxes(sender, e) + loadDGVBestellungen() End Sub - Private Sub rbMenoAltMo_CheckedChanged(sender As Object, e As EventArgs) Handles rbMenoAltMo.CheckedChanged + 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 + If rbMenoAlt_Mo.Checked Then + txtAltMo.Visible = True + Else + txtAltMo.Visible = False + End If + + If rbMenuAlt_Di.Checked Then + txtAltDi.Visible = True + Else + + txtAltDi.Visible = False + End If + + If rbMenuAlt_Mi.Checked Then + txtAltMi.Visible = True + Else + txtAltMi.Visible = False + End If + + + If rbMenuAlt_Do.Checked Then + txtAltDo.Visible = True + Else + txtAltDo.Visible = False + End If + + If rbMenuAlt_Fr.Checked Then + txtAltFr.Visible = True + Else + txtAltFr.Visible = False + End If + countChecks() End Sub 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 - rbMenoAltMo.Enabled = True - rbMenuMo.Enabled = True + rbMenoAlt_Mo.Enabled = True + rbMenu_Mo.Enabled = True Else - rbMenoAltMo.Enabled = False - rbMenoAltMo.Enabled = False + rbMenoAlt_Mo.Enabled = False + rbMenu_Mo.Enabled = False + txtAltMo.Text = "" End If If cbDienstag.Checked Then - rbMenuAltDi.Enabled = True - rbMenuDi.Enabled = True + rbMenuAlt_Di.Enabled = True + rbMenu_Di.Enabled = True Else - rbMenuDi.Enabled = False - rbMenuAltDi.Enabled = False + rbMenu_Di.Enabled = False + rbMenuAlt_Di.Enabled = False + txtAltDi.Text = "" End If If cbMittwoch.Checked Then - rbMenuAltMi.Enabled = True - rbMenuMi.Enabled = True + rbMenuAlt_Mi.Enabled = True + rbMenu_Mi.Enabled = True Else - rbMenuMi.Enabled = False - rbMenuAltMi.Enabled = False + rbMenu_Mi.Enabled = False + rbMenuAlt_Mi.Enabled = False + txtAltMi.Text = "" End If If cbDonnerstag.Checked Then - rbMenuAltDo.Enabled = True - rbMenuDo.Enabled = True + rbMenuAlt_Do.Enabled = True + rbMenu_Do.Enabled = True Else - rbMenuDo.Enabled = False - rbMenuAltDo.Enabled = False + rbMenu_Do.Enabled = False + rbMenuAlt_Do.Enabled = False + txtAltDo.Text = "" End If If cbFreitag.Checked Then - rbMenuFrAlt.Enabled = True - rbMenuFr.Enabled = True + rbMenuAlt_Fr.Enabled = True + rbMenu_Fr.Enabled = True Else - rbMenuFr.Enabled = False - rbMenuFrAlt.Enabled = False + rbMenu_Fr.Enabled = False + rbMenuAlt_Fr.Enabled = False + txtAltFr.Text = "" + End If + countChecks() + End Sub + + + Private Sub loadDGVBestellungen() + + Dim SQLWhere As String = "" + If cbxMenu._value IsNot "" Then SQLWhere = " AND [eb_kw] = '" & cbxMenu._value.ToString & "'" + + Dim SQLString As String = "SELECT [eb_kw], [eb_mitid] , [eb_gebaeude],[eb_abteilung],[eb_montag],[eb_dienstag],[eb_mittwoch],[eb_donnerstag] ,[eb_freitag],[eb_preis] FROM [tblEssensbestellungen] where [eb_mitid] = '" & VERAG_PROG_ALLGEMEIN.cAllgemein.USRID & "'" & SQLWhere & " order by [eb_kw]" + + dgvBestellungen.SET_SQL(SQLString, "AVISO", ,) + dgvBestellungen.LOAD() + + + If dgvBestellungen.Columns.Count < 1 Then Exit Sub + + With dgvBestellungen + .RowHeadersWidth = 10 + .Columns("eb_kw").AutoSizeMode = DataGridViewAutoSizeColumnMode.Fill + .Columns("eb_kw").HeaderText = "KW" + .Columns("eb_mitid").Visible = False + .Columns("eb_gebaeude").Visible = False + .Columns("eb_abteilung").Visible = False + .Columns("eb_montag").Width = 100 + .Columns("eb_montag").HeaderText = "Montag" + .Columns("eb_montag").Width = 100 + .Columns("eb_dienstag").HeaderText = "Dienstag" + .Columns("eb_dienstag").Width = 100 + .Columns("eb_mittwoch").HeaderText = "Mittwoch" + .Columns("eb_mittwoch").Width = 100 + .Columns("eb_donnerstag").HeaderText = "Donnerstag" + .Columns("eb_donnerstag").Width = 100 + .Columns("eb_freitag").HeaderText = "Freitag" + .Columns("eb_freitag").Width = 100 + .Columns("eb_preis").HeaderText = "Preis" + .Columns("eb_preis").Width = 40 + End With + + End Sub + + Private Sub uncheckGroupBoxes(sender, e) + For Each gb As Control In MyPanel1.Controls + If TypeOf gb Is GroupBox Then + For Each c As Control In gb.Controls + If TypeOf c Is CheckBox Then + Dim checkbox As CheckBox = c + checkbox.Checked = False + End If + Next + End If + Next + cbFields_CheckedChanged(sender, e) + End Sub + + Private Sub countChecks() + + Dim countMenus As Integer + Dim countlaCarte As Integer + countMenus = 0 + countlaCarte = 0 + For Each gb As Control In MyPanel1.Controls + If TypeOf gb Is GroupBox Then + For Each c As Control In gb.Controls + + If c.Text.ToLower.StartsWith("menü") AndAlso TypeOf c Is VERAG_PROG_ALLGEMEIN.MyRadioButton AndAlso c.Enabled = True Then + Dim rb As VERAG_PROG_ALLGEMEIN.MyRadioButton = c + If rb.Checked Then countMenus = countMenus + 1 + End If + + If c.Text.ToLower.StartsWith("a la carte") AndAlso TypeOf c Is VERAG_PROG_ALLGEMEIN.MyRadioButton AndAlso c.Enabled = True Then + Dim rb As VERAG_PROG_ALLGEMEIN.MyRadioButton = c + If rb.Checked Then countlaCarte = countlaCarte + 1 + End If + Next + End If + Next + + txtAnzahlMenu.Text = countMenus.ToString() + txtAnzahlLaCart.Text = countlaCarte.ToString + txtPreis.Text = (CDbl(countlaCarte) + CDbl(countMenus)) * 3 + + + End Sub + + Private Sub loadMenuInfo(dt As DataTable) + + If dt.Rows(0).Item("MenuEssenMo") IsNot Nothing Then + pbMontag.Visible = True + Dim ttMontag As New ToolTip() + ttMontag.SetToolTip(pbMontag, dt.Rows(0).Item("MenuEssenMo").ToString) + Else + pbMontag.Visible = False + End If + + + If dt.Rows(0).Item("MenuEssenDi") IsNot Nothing Then + pbDienstag.Visible = True + Dim ttDienstag As New ToolTip() + ttDienstag.SetToolTip(pbDienstag, dt.Rows(0).Item("MenuEssenDi").ToString) + Else + pbDienstag.Visible = False + End If + + + If dt.Rows(0).Item("MenuEssenMi") IsNot Nothing Then + pbMittwoch.Visible = True + Dim ttMittwoch As New ToolTip() + 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 + Dim ttDonnerstag As New ToolTip() + 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 + Dim ttFreitag As New ToolTip() + ttFreitag.SetToolTip(pbFreitag, dt.Rows(0).Item("MenuEssenFr").ToString) + Else + pbFreitag.Visible = False + End If + + End Sub + + Private Sub dgvBestellungen_Click(sender As Object, e As EventArgs) Handles dgvBestellungen.Click + + If dgvBestellungen.Rows.Count = 0 Then Exit Sub + + 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) + + 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 + If currentEssen.eb_montag IsNot Nothing Then txtAltMo.Text = currentEssen.eb_montag.ToString + End If + Else + cbMontag.Checked = False + End If + + If currentEssen.eb_dienstag IsNot Nothing Then + cbDienstag.Checked = True + If currentEssen.eb_dienstag.ToString = "Menu" Then + rbMenu_Di.Checked = True + Else + rbMenuAlt_Di.Checked = True + If currentEssen.eb_dienstag IsNot Nothing Then txtAltDi.Text = currentEssen.eb_dienstag.ToString + End If + Else + cbDienstag.Checked = False + End If + + + If currentEssen.eb_mittwoch IsNot Nothing Then + cbMittwoch.Checked = True + If currentEssen.eb_mittwoch.ToString = "Menu" Then + rbMenu_Mi.Checked = True + Else + rbMenuAlt_Mi.Checked = True + If currentEssen.eb_mittwoch IsNot Nothing Then txtAltMi.Text = currentEssen.eb_mittwoch.ToString + End If + Else + cbMittwoch.Checked = False + End If + + If currentEssen.eb_donnerstag IsNot Nothing Then + cbDonnerstag.Checked = True + If currentEssen.eb_donnerstag.ToString = "Menu" Then + rbMenu_Do.Checked = True + Else + rbMenuAlt_Do.Checked = True + If currentEssen.eb_donnerstag IsNot Nothing Then txtAltDo.Text = currentEssen.eb_donnerstag.ToString + End If + Else + cbMittwoch.Checked = False + End If + + + If currentEssen.eb_freitag IsNot Nothing Then + cbFreitag.Checked = True + If currentEssen.eb_freitag.ToString = "Menu" Then + rbMenu_Fr.Checked = True + Else + rbMenuAlt_Fr.Checked = True + If currentEssen.eb_freitag IsNot Nothing Then txtAltDo.Text = currentEssen.eb_freitag.ToString + End If + Else + cbFreitag.Checked = False End If End Sub + + Private Function checkIfOrderIsPossible() As Boolean + + Dim isPossible As Boolean = False + + If dt.Rows.Count = 0 Then Return False + + Try + Dim startMenu = Date.Parse(dt.Rows(0).Item("MenuDateVon")) + + + Dim newTime As New TimeSpan(14, 30, 0) + Dim timeToOrderLimit = startMenu.AddDays(-5) + newTime + lblBestellungBis.Text = "Bestellung möglich bis: " & timeToOrderLimit.ToShortDateString & " - " & timeToOrderLimit.ToShortTimeString + + If Now >= timeToOrderLimit Then + lblBestellungBis.ForeColor = Color.Red + Return True + Else + lblBestellungBis.ForeColor = Color.Black + Return True + End If + Catch ex As Exception + MessageBox.Show(ex.Message) + End Try + + + End Function + End Class \ No newline at end of file From 340fdc57c03e8efd7362ea8b62dfbc20e6fe6bee Mon Sep 17 00:00:00 2001 From: "d.breimaier" Date: Tue, 29 Nov 2022 15:19:34 +0100 Subject: [PATCH 05/10] Essensbestellung --- Aviso/frmEssensbestellungen.vb | 16 ++++++++++++---- 1 file changed, 12 insertions(+), 4 deletions(-) diff --git a/Aviso/frmEssensbestellungen.vb b/Aviso/frmEssensbestellungen.vb index 3f8c1a8..6e2d325 100644 --- a/Aviso/frmEssensbestellungen.vb +++ b/Aviso/frmEssensbestellungen.vb @@ -1,4 +1,4 @@ -Imports Org.BouncyCastle.Asn1.Cms + Imports VERAG_PROG_ALLGEMEIN Public Class frmEssensbestellungen @@ -21,11 +21,19 @@ Public Class frmEssensbestellungen cbxGebauede.Items.Add(New VERAG_PROG_ALLGEMEIN.MyListItem("Asfinag", "Asfinag")) cbxGebauede.Items.Add(New VERAG_PROG_ALLGEMEIN.MyListItem("Verag Verrechnung", "Verag Verrechnung")) cbxGebauede.Items.Add(New VERAG_PROG_ALLGEMEIN.MyListItem("Maut", "Maut")) + cbxGebauede.Items.Add(New VERAG_PROG_ALLGEMEIN.MyListItem("", "")) + cbxGebauede.changeItem("") End Sub Private Sub btnSave_Click(sender As Object, e As EventArgs) Handles btnSave.Click - essen = New cEssensbestellung(cbxMenu._value, cAllgemein.USRID, "Test", cAllgemein.ABTEILUNG) + + If cbxGebauede._value = "" Then + MsgBox("Bitte Gebäude für die Essensbestellung angeben!") + Exit Sub + End If + + essen = New cEssensbestellung(cbxMenu._value, cAllgemein.USRID, cbxGebauede._value, cAllgemein.ABTEILUNG) If cbMontag.Checked Then If rbMenu_Mo.Checked Then @@ -102,7 +110,7 @@ Public Class frmEssensbestellungen If checkIfOrderIsPossible() Then MyPanel1.Enabled = True Else - MyPanel1.Enabled = True + MyPanel1.Enabled = False End If lblDatum.Text = "Datum: " & CDate(dt.Rows(0).Item("MenuDateVon")).ToString("dd.MM.yyyy") & " - " & CDate(dt.Rows(0).Item("MenuDateBis")).ToString("dd.MM.yyyy") loadMenuInfo(dt) @@ -417,7 +425,7 @@ Public Class frmEssensbestellungen If Now >= timeToOrderLimit Then lblBestellungBis.ForeColor = Color.Red - Return True + Return True 'zu testzwecken -> muss dann wieder auf false gesetzt werden!!!! Else lblBestellungBis.ForeColor = Color.Black Return True From d0f4c450fb1c00bc4291cfeef73069e4745c9773 Mon Sep 17 00:00:00 2001 From: "d.breimaier" Date: Tue, 29 Nov 2022 17:25:00 +0100 Subject: [PATCH 06/10] Essensbestellungen --- Aviso/frmEssensbestellungen.Designer.vb | 660 ++++++++++++------------ Aviso/frmEssensbestellungen.vb | 6 + 2 files changed, 336 insertions(+), 330 deletions(-) diff --git a/Aviso/frmEssensbestellungen.Designer.vb b/Aviso/frmEssensbestellungen.Designer.vb index cf1a3fa..38051c0 100644 --- a/Aviso/frmEssensbestellungen.Designer.vb +++ b/Aviso/frmEssensbestellungen.Designer.vb @@ -23,24 +23,46 @@ Partial Class frmEssensbestellungen Private Sub InitializeComponent() Me.components = New System.ComponentModel.Container() - Dim DataGridViewCellStyle4 As System.Windows.Forms.DataGridViewCellStyle = New System.Windows.Forms.DataGridViewCellStyle() - Dim DataGridViewCellStyle5 As System.Windows.Forms.DataGridViewCellStyle = New System.Windows.Forms.DataGridViewCellStyle() - Dim DataGridViewCellStyle6 As System.Windows.Forms.DataGridViewCellStyle = New System.Windows.Forms.DataGridViewCellStyle() + Dim DataGridViewCellStyle1 As System.Windows.Forms.DataGridViewCellStyle = New System.Windows.Forms.DataGridViewCellStyle() + Dim DataGridViewCellStyle2 As System.Windows.Forms.DataGridViewCellStyle = New System.Windows.Forms.DataGridViewCellStyle() + Dim DataGridViewCellStyle3 As System.Windows.Forms.DataGridViewCellStyle = New System.Windows.Forms.DataGridViewCellStyle() Me.lblWochenkarte = New System.Windows.Forms.Label() Me.btnSave = New System.Windows.Forms.Button() Me.lblDatum = New System.Windows.Forms.Label() - Me.GroupBox1 = New System.Windows.Forms.GroupBox() - 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.rbMenu_Mo = New VERAG_PROG_ALLGEMEIN.MyRadioButton(Me.components) + Me.ToolTipInfoMo = New System.Windows.Forms.ToolTip(Me.components) + Me.ToolTipInfoDi = New System.Windows.Forms.ToolTip(Me.components) + Me.ToolTipInfoMi = New System.Windows.Forms.ToolTip(Me.components) + Me.ToolTipInfoDo = New System.Windows.Forms.ToolTip(Me.components) + Me.ToolTipInfoFr = New System.Windows.Forms.ToolTip(Me.components) + Me.lblAbteilung = New System.Windows.Forms.Label() + Me.lblGebaeude = New System.Windows.Forms.Label() + Me.lblBestellungen = New System.Windows.Forms.Label() + Me.lblBestellungBis = New System.Windows.Forms.Label() + Me.cbxGebauede = New VERAG_PROG_ALLGEMEIN.MyComboBox() + 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.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.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.rbMenu_Mo = New VERAG_PROG_ALLGEMEIN.MyRadioButton(Me.components) + Me.GroupBox5 = New System.Windows.Forms.GroupBox() + Me.pbFreitag = New System.Windows.Forms.PictureBox() + Me.cbFreitag = New System.Windows.Forms.CheckBox() + Me.txtAltFr = New VERAG_PROG_ALLGEMEIN.MyTextBox() + Me.rbMenuAlt_Fr = New VERAG_PROG_ALLGEMEIN.MyRadioButton(Me.components) + Me.rbMenu_Fr = New VERAG_PROG_ALLGEMEIN.MyRadioButton(Me.components) + Me.txtAnzahlLaCart = New System.Windows.Forms.Label() + Me.lbl2 = New System.Windows.Forms.Label() Me.Mittwoch = New System.Windows.Forms.GroupBox() Me.pbMittwoch = New System.Windows.Forms.PictureBox() Me.cbMittwoch = New System.Windows.Forms.CheckBox() @@ -53,43 +75,21 @@ Partial Class frmEssensbestellungen 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.GroupBox5 = New System.Windows.Forms.GroupBox() - Me.pbFreitag = New System.Windows.Forms.PictureBox() - Me.cbFreitag = New System.Windows.Forms.CheckBox() - Me.txtAltFr = New VERAG_PROG_ALLGEMEIN.MyTextBox() - Me.rbMenuAlt_Fr = New VERAG_PROG_ALLGEMEIN.MyRadioButton(Me.components) - Me.rbMenu_Fr = New VERAG_PROG_ALLGEMEIN.MyRadioButton(Me.components) - Me.lbl1 = New System.Windows.Forms.Label() - Me.lbl2 = New System.Windows.Forms.Label() Me.txtAnzahlMenu = New System.Windows.Forms.Label() - Me.txtAnzahlLaCart = New System.Windows.Forms.Label() - Me.ToolTipInfoMo = New System.Windows.Forms.ToolTip(Me.components) - Me.ToolTipInfoDi = New System.Windows.Forms.ToolTip(Me.components) - Me.ToolTipInfoMi = New System.Windows.Forms.ToolTip(Me.components) - Me.ToolTipInfoDo = New System.Windows.Forms.ToolTip(Me.components) - Me.ToolTipInfoFr = New System.Windows.Forms.ToolTip(Me.components) Me.dgvBestellungen = New VERAG_PROG_ALLGEMEIN.MyDatagridview(Me.components) Me.cbxMenu = New VERAG_PROG_ALLGEMEIN.MyComboBox() - Me.lblAbteilung = New System.Windows.Forms.Label() - Me.lblGebaeude = New System.Windows.Forms.Label() - Me.MyPanel1 = New VERAG_PROG_ALLGEMEIN.MyPanel(Me.components) - Me.lblBestellungen = New System.Windows.Forms.Label() - Me.txtPreis = New System.Windows.Forms.Label() - Me.Label2 = New System.Windows.Forms.Label() - Me.cbxGebauede = New VERAG_PROG_ALLGEMEIN.MyComboBox() - Me.lblBestellungBis = New System.Windows.Forms.Label() - Me.GroupBox1.SuspendLayout() - CType(Me.pbMontag, System.ComponentModel.ISupportInitialize).BeginInit() + Me.MyPanel1.SuspendLayout() Me.Dienstag.SuspendLayout() CType(Me.pbDienstag, System.ComponentModel.ISupportInitialize).BeginInit() + Me.GroupBox1.SuspendLayout() + CType(Me.pbMontag, System.ComponentModel.ISupportInitialize).BeginInit() + Me.GroupBox5.SuspendLayout() + CType(Me.pbFreitag, System.ComponentModel.ISupportInitialize).BeginInit() Me.Mittwoch.SuspendLayout() CType(Me.pbMittwoch, System.ComponentModel.ISupportInitialize).BeginInit() Me.GroupBox4.SuspendLayout() CType(Me.pbDonnerstag, System.ComponentModel.ISupportInitialize).BeginInit() - Me.GroupBox5.SuspendLayout() - CType(Me.pbFreitag, System.ComponentModel.ISupportInitialize).BeginInit() CType(Me.dgvBestellungen, System.ComponentModel.ISupportInitialize).BeginInit() - Me.MyPanel1.SuspendLayout() Me.SuspendLayout() ' 'lblWochenkarte @@ -119,6 +119,180 @@ Partial Class frmEssensbestellungen Me.lblDatum.TabIndex = 11 Me.lblDatum.Text = "Datum:" ' + 'lblAbteilung + ' + Me.lblAbteilung.AutoSize = True + Me.lblAbteilung.Location = New System.Drawing.Point(511, 9) + Me.lblAbteilung.Name = "lblAbteilung" + Me.lblAbteilung.Size = New System.Drawing.Size(54, 13) + Me.lblAbteilung.TabIndex = 18 + Me.lblAbteilung.Text = "Abteilung:" + ' + 'lblGebaeude + ' + Me.lblGebaeude.AutoSize = True + Me.lblGebaeude.Location = New System.Drawing.Point(511, 27) + Me.lblGebaeude.Name = "lblGebaeude" + Me.lblGebaeude.Size = New System.Drawing.Size(54, 13) + Me.lblGebaeude.TabIndex = 19 + Me.lblGebaeude.Text = "Gebäude:" + ' + 'lblBestellungen + ' + Me.lblBestellungen.AutoSize = True + Me.lblBestellungen.Location = New System.Drawing.Point(9, 335) + Me.lblBestellungen.Name = "lblBestellungen" + Me.lblBestellungen.Size = New System.Drawing.Size(100, 13) + Me.lblBestellungen.TabIndex = 20 + Me.lblBestellungen.Text = "Meine Bestellungen" + ' + 'lblBestellungBis + ' + Me.lblBestellungBis.AutoSize = True + Me.lblBestellungBis.Location = New System.Drawing.Point(167, 38) + Me.lblBestellungBis.Name = "lblBestellungBis" + Me.lblBestellungBis.Size = New System.Drawing.Size(114, 13) + Me.lblBestellungBis.TabIndex = 22 + Me.lblBestellungBis.Text = "Bestellung möglich bis:" + ' + 'cbxGebauede + ' + Me.cbxGebauede._allowedValuesFreiText = Nothing + Me.cbxGebauede._allowFreiText = False + Me.cbxGebauede._value = "" + Me.cbxGebauede.FormattingEnabled = True + Me.cbxGebauede.Location = New System.Drawing.Point(580, 24) + Me.cbxGebauede.Name = "cbxGebauede" + Me.cbxGebauede.Size = New System.Drawing.Size(95, 21) + Me.cbxGebauede.TabIndex = 21 + ' + 'MyPanel1 + ' + Me.MyPanel1.Controls.Add(Me.txtPreis) + Me.MyPanel1.Controls.Add(Me.Label2) + Me.MyPanel1.Controls.Add(Me.Dienstag) + Me.MyPanel1.Controls.Add(Me.lbl1) + Me.MyPanel1.Controls.Add(Me.GroupBox1) + Me.MyPanel1.Controls.Add(Me.GroupBox5) + 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.txtAnzahlMenu) + Me.MyPanel1.Location = New System.Drawing.Point(12, 67) + Me.MyPanel1.Name = "MyPanel1" + Me.MyPanel1.Size = New System.Drawing.Size(667, 240) + Me.MyPanel1.TabIndex = 18 + ' + 'txtPreis + ' + Me.txtPreis.AutoSize = True + Me.txtPreis.Location = New System.Drawing.Point(553, 181) + Me.txtPreis.Name = "txtPreis" + Me.txtPreis.Size = New System.Drawing.Size(13, 13) + Me.txtPreis.TabIndex = 19 + Me.txtPreis.Text = "0" + ' + 'Label2 + ' + Me.Label2.AutoSize = True + Me.Label2.Location = New System.Drawing.Point(463, 181) + Me.Label2.Name = "Label2" + Me.Label2.Size = New System.Drawing.Size(68, 13) + Me.Label2.TabIndex = 18 + Me.Label2.Text = "Gesamtpreis:" + ' + 'Dienstag + ' + 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" + ' + 'pbDienstag + ' + Me.pbDienstag.Image = Global.AVISO.My.Resources.Resources.documents + Me.pbDienstag.Location = New System.Drawing.Point(61, 23) + Me.pbDienstag.Name = "pbDienstag" + Me.pbDienstag.Size = New System.Drawing.Size(17, 13) + Me.pbDienstag.SizeMode = System.Windows.Forms.PictureBoxSizeMode.StretchImage + Me.pbDienstag.TabIndex = 5 + Me.pbDienstag.TabStop = False + ' + 'cbDienstag + ' + Me.cbDienstag.AutoSize = True + Me.cbDienstag.Location = New System.Drawing.Point(0, 0) + Me.cbDienstag.Name = "cbDienstag" + Me.cbDienstag.Size = New System.Drawing.Size(68, 17) + Me.cbDienstag.TabIndex = 4 + Me.cbDienstag.Text = "Dienstag" + Me.cbDienstag.UseVisualStyleBackColor = True + ' + 'txtAltDi + ' + Me.txtAltDi._DateTimeOnly = False + Me.txtAltDi._numbersOnly = False + Me.txtAltDi._numbersOnlyKommastellen = "" + Me.txtAltDi._numbersOnlyTrennzeichen = True + Me.txtAltDi._Prozent = False + Me.txtAltDi._ShortDateNew = False + Me.txtAltDi._ShortDateOnly = False + Me.txtAltDi._TimeOnly = False + Me.txtAltDi._TimeOnly_Seconds = False + Me.txtAltDi._value = "" + 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.MaxLineLength = -1 + Me.txtAltDi.MaxLines_Warning = "" + Me.txtAltDi.MaxLines_Warning_Label = Nothing + Me.txtAltDi.Name = "txtAltDi" + Me.txtAltDi.Size = New System.Drawing.Size(177, 20) + Me.txtAltDi.TabIndex = 2 + Me.txtAltDi.Visible = False + ' + 'rbMenuAlt_Di + ' + Me.rbMenuAlt_Di.AutoSize = True + Me.rbMenuAlt_Di.GroupName = "Dienstag" + Me.rbMenuAlt_Di.Location = New System.Drawing.Point(3, 42) + Me.rbMenuAlt_Di.Name = "rbMenuAlt_Di" + Me.rbMenuAlt_Di.Size = New System.Drawing.Size(70, 17) + Me.rbMenuAlt_Di.TabIndex = 1 + Me.rbMenuAlt_Di.TabStop = True + Me.rbMenuAlt_Di.Text = "A la carte" + Me.rbMenuAlt_Di.UseVisualStyleBackColor = True + ' + 'rbMenu_Di + ' + Me.rbMenu_Di.AutoSize = True + Me.rbMenu_Di.GroupName = "Dienstag" + Me.rbMenu_Di.Location = New System.Drawing.Point(3, 19) + Me.rbMenu_Di.Name = "rbMenu_Di" + Me.rbMenu_Di.Size = New System.Drawing.Size(52, 17) + Me.rbMenu_Di.TabIndex = 0 + Me.rbMenu_Di.TabStop = True + Me.rbMenu_Di.Text = "Menü" + Me.rbMenu_Di.UseVisualStyleBackColor = True + ' + 'lbl1 + ' + Me.lbl1.AutoSize = True + Me.lbl1.Location = New System.Drawing.Point(463, 128) + Me.lbl1.Name = "lbl1" + Me.lbl1.Size = New System.Drawing.Size(72, 13) + Me.lbl1.TabIndex = 14 + Me.lbl1.Text = "Anzahl Menü:" + ' 'GroupBox1 ' Me.GroupBox1.Controls.Add(Me.pbMontag) @@ -201,87 +375,105 @@ Partial Class frmEssensbestellungen Me.rbMenu_Mo.Text = "Menü" Me.rbMenu_Mo.UseVisualStyleBackColor = True ' - 'Dienstag + 'GroupBox5 ' - 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.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" ' - 'pbDienstag + 'pbFreitag ' - Me.pbDienstag.Image = Global.AVISO.My.Resources.Resources.documents - Me.pbDienstag.Location = New System.Drawing.Point(61, 23) - Me.pbDienstag.Name = "pbDienstag" - Me.pbDienstag.Size = New System.Drawing.Size(17, 13) - Me.pbDienstag.SizeMode = System.Windows.Forms.PictureBoxSizeMode.StretchImage - Me.pbDienstag.TabIndex = 5 - Me.pbDienstag.TabStop = False + Me.pbFreitag.Image = Global.AVISO.My.Resources.Resources.documents + Me.pbFreitag.Location = New System.Drawing.Point(61, 23) + Me.pbFreitag.Name = "pbFreitag" + Me.pbFreitag.Size = New System.Drawing.Size(17, 13) + Me.pbFreitag.SizeMode = System.Windows.Forms.PictureBoxSizeMode.StretchImage + Me.pbFreitag.TabIndex = 8 + Me.pbFreitag.TabStop = False ' - 'cbDienstag + 'cbFreitag ' - Me.cbDienstag.AutoSize = True - Me.cbDienstag.Location = New System.Drawing.Point(0, 0) - Me.cbDienstag.Name = "cbDienstag" - Me.cbDienstag.Size = New System.Drawing.Size(68, 17) - Me.cbDienstag.TabIndex = 4 - Me.cbDienstag.Text = "Dienstag" - Me.cbDienstag.UseVisualStyleBackColor = True + Me.cbFreitag.AutoSize = True + Me.cbFreitag.Location = New System.Drawing.Point(3, 0) + Me.cbFreitag.Name = "cbFreitag" + Me.cbFreitag.Size = New System.Drawing.Size(58, 17) + Me.cbFreitag.TabIndex = 6 + Me.cbFreitag.Text = "Freitag" + Me.cbFreitag.UseVisualStyleBackColor = True ' - 'txtAltDi + 'txtAltFr ' - Me.txtAltDi._DateTimeOnly = False - Me.txtAltDi._numbersOnly = False - Me.txtAltDi._numbersOnlyKommastellen = "" - Me.txtAltDi._numbersOnlyTrennzeichen = True - Me.txtAltDi._Prozent = False - Me.txtAltDi._ShortDateNew = False - Me.txtAltDi._ShortDateOnly = False - Me.txtAltDi._TimeOnly = False - Me.txtAltDi._TimeOnly_Seconds = False - Me.txtAltDi._value = "" - 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.MaxLineLength = -1 - Me.txtAltDi.MaxLines_Warning = "" - Me.txtAltDi.MaxLines_Warning_Label = Nothing - Me.txtAltDi.Name = "txtAltDi" - Me.txtAltDi.Size = New System.Drawing.Size(177, 20) - Me.txtAltDi.TabIndex = 2 - Me.txtAltDi.Visible = False + Me.txtAltFr._DateTimeOnly = False + Me.txtAltFr._numbersOnly = False + Me.txtAltFr._numbersOnlyKommastellen = "" + Me.txtAltFr._numbersOnlyTrennzeichen = True + Me.txtAltFr._Prozent = False + Me.txtAltFr._ShortDateNew = False + Me.txtAltFr._ShortDateOnly = False + Me.txtAltFr._TimeOnly = False + Me.txtAltFr._TimeOnly_Seconds = False + Me.txtAltFr._value = "" + 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.MaxLineLength = -1 + Me.txtAltFr.MaxLines_Warning = "" + Me.txtAltFr.MaxLines_Warning_Label = Nothing + Me.txtAltFr.Name = "txtAltFr" + Me.txtAltFr.Size = New System.Drawing.Size(177, 20) + Me.txtAltFr.TabIndex = 2 + Me.txtAltFr.Visible = False ' - 'rbMenuAlt_Di + 'rbMenuAlt_Fr ' - Me.rbMenuAlt_Di.AutoSize = True - Me.rbMenuAlt_Di.GroupName = "Dienstag" - Me.rbMenuAlt_Di.Location = New System.Drawing.Point(3, 42) - Me.rbMenuAlt_Di.Name = "rbMenuAlt_Di" - Me.rbMenuAlt_Di.Size = New System.Drawing.Size(70, 17) - Me.rbMenuAlt_Di.TabIndex = 1 - Me.rbMenuAlt_Di.TabStop = True - Me.rbMenuAlt_Di.Text = "A la carte" - Me.rbMenuAlt_Di.UseVisualStyleBackColor = True + Me.rbMenuAlt_Fr.AutoSize = True + Me.rbMenuAlt_Fr.GroupName = "Freitag" + Me.rbMenuAlt_Fr.Location = New System.Drawing.Point(3, 42) + Me.rbMenuAlt_Fr.Name = "rbMenuAlt_Fr" + Me.rbMenuAlt_Fr.Size = New System.Drawing.Size(70, 17) + Me.rbMenuAlt_Fr.TabIndex = 1 + Me.rbMenuAlt_Fr.TabStop = True + Me.rbMenuAlt_Fr.Text = "A la carte" + Me.rbMenuAlt_Fr.UseVisualStyleBackColor = True ' - 'rbMenu_Di + 'rbMenu_Fr ' - Me.rbMenu_Di.AutoSize = True - Me.rbMenu_Di.GroupName = "Dienstag" - Me.rbMenu_Di.Location = New System.Drawing.Point(3, 19) - Me.rbMenu_Di.Name = "rbMenu_Di" - Me.rbMenu_Di.Size = New System.Drawing.Size(52, 17) - Me.rbMenu_Di.TabIndex = 0 - Me.rbMenu_Di.TabStop = True - Me.rbMenu_Di.Text = "Menü" - Me.rbMenu_Di.UseVisualStyleBackColor = True + Me.rbMenu_Fr.AutoSize = True + Me.rbMenu_Fr.GroupName = "Freitag" + Me.rbMenu_Fr.Location = New System.Drawing.Point(3, 19) + Me.rbMenu_Fr.Name = "rbMenu_Fr" + Me.rbMenu_Fr.Size = New System.Drawing.Size(52, 17) + Me.rbMenu_Fr.TabIndex = 0 + Me.rbMenu_Fr.TabStop = True + Me.rbMenu_Fr.Text = "Menü" + Me.rbMenu_Fr.UseVisualStyleBackColor = True + ' + 'txtAnzahlLaCart + ' + Me.txtAnzahlLaCart.AutoSize = True + Me.txtAnzahlLaCart.Location = New System.Drawing.Point(553, 155) + Me.txtAnzahlLaCart.Name = "txtAnzahlLaCart" + Me.txtAnzahlLaCart.Size = New System.Drawing.Size(13, 13) + Me.txtAnzahlLaCart.TabIndex = 17 + Me.txtAnzahlLaCart.Text = "0" + ' + 'lbl2 + ' + Me.lbl2.AutoSize = True + Me.lbl2.Location = New System.Drawing.Point(463, 155) + Me.lbl2.Name = "lbl2" + Me.lbl2.Size = New System.Drawing.Size(90, 13) + Me.lbl2.TabIndex = 15 + Me.lbl2.Text = "Anzahl a la Carte:" ' 'Mittwoch ' @@ -447,106 +639,6 @@ Partial Class frmEssensbestellungen Me.rbMenu_Do.Text = "Menü" Me.rbMenu_Do.UseVisualStyleBackColor = True ' - 'GroupBox5 - ' - 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" - ' - 'pbFreitag - ' - Me.pbFreitag.Image = Global.AVISO.My.Resources.Resources.documents - Me.pbFreitag.Location = New System.Drawing.Point(61, 23) - Me.pbFreitag.Name = "pbFreitag" - Me.pbFreitag.Size = New System.Drawing.Size(17, 13) - Me.pbFreitag.SizeMode = System.Windows.Forms.PictureBoxSizeMode.StretchImage - Me.pbFreitag.TabIndex = 8 - Me.pbFreitag.TabStop = False - ' - 'cbFreitag - ' - Me.cbFreitag.AutoSize = True - Me.cbFreitag.Location = New System.Drawing.Point(3, 0) - Me.cbFreitag.Name = "cbFreitag" - Me.cbFreitag.Size = New System.Drawing.Size(58, 17) - Me.cbFreitag.TabIndex = 6 - Me.cbFreitag.Text = "Freitag" - Me.cbFreitag.UseVisualStyleBackColor = True - ' - 'txtAltFr - ' - Me.txtAltFr._DateTimeOnly = False - Me.txtAltFr._numbersOnly = False - Me.txtAltFr._numbersOnlyKommastellen = "" - Me.txtAltFr._numbersOnlyTrennzeichen = True - Me.txtAltFr._Prozent = False - Me.txtAltFr._ShortDateNew = False - Me.txtAltFr._ShortDateOnly = False - Me.txtAltFr._TimeOnly = False - Me.txtAltFr._TimeOnly_Seconds = False - Me.txtAltFr._value = "" - 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.MaxLineLength = -1 - Me.txtAltFr.MaxLines_Warning = "" - Me.txtAltFr.MaxLines_Warning_Label = Nothing - Me.txtAltFr.Name = "txtAltFr" - Me.txtAltFr.Size = New System.Drawing.Size(177, 20) - Me.txtAltFr.TabIndex = 2 - Me.txtAltFr.Visible = False - ' - 'rbMenuAlt_Fr - ' - Me.rbMenuAlt_Fr.AutoSize = True - Me.rbMenuAlt_Fr.GroupName = "Freitag" - Me.rbMenuAlt_Fr.Location = New System.Drawing.Point(3, 42) - Me.rbMenuAlt_Fr.Name = "rbMenuAlt_Fr" - Me.rbMenuAlt_Fr.Size = New System.Drawing.Size(70, 17) - Me.rbMenuAlt_Fr.TabIndex = 1 - Me.rbMenuAlt_Fr.TabStop = True - Me.rbMenuAlt_Fr.Text = "A la carte" - Me.rbMenuAlt_Fr.UseVisualStyleBackColor = True - ' - 'rbMenu_Fr - ' - Me.rbMenu_Fr.AutoSize = True - Me.rbMenu_Fr.GroupName = "Freitag" - Me.rbMenu_Fr.Location = New System.Drawing.Point(3, 19) - Me.rbMenu_Fr.Name = "rbMenu_Fr" - Me.rbMenu_Fr.Size = New System.Drawing.Size(52, 17) - Me.rbMenu_Fr.TabIndex = 0 - Me.rbMenu_Fr.TabStop = True - Me.rbMenu_Fr.Text = "Menü" - Me.rbMenu_Fr.UseVisualStyleBackColor = True - ' - 'lbl1 - ' - Me.lbl1.AutoSize = True - Me.lbl1.Location = New System.Drawing.Point(463, 128) - Me.lbl1.Name = "lbl1" - Me.lbl1.Size = New System.Drawing.Size(72, 13) - Me.lbl1.TabIndex = 14 - Me.lbl1.Text = "Anzahl Menü:" - ' - 'lbl2 - ' - Me.lbl2.AutoSize = True - Me.lbl2.Location = New System.Drawing.Point(463, 155) - Me.lbl2.Name = "lbl2" - Me.lbl2.Size = New System.Drawing.Size(90, 13) - Me.lbl2.TabIndex = 15 - Me.lbl2.Text = "Anzahl a la Carte:" - ' 'txtAnzahlMenu ' Me.txtAnzahlMenu.AutoSize = True @@ -556,15 +648,6 @@ Partial Class frmEssensbestellungen Me.txtAnzahlMenu.TabIndex = 16 Me.txtAnzahlMenu.Text = "0" ' - 'txtAnzahlLaCart - ' - Me.txtAnzahlLaCart.AutoSize = True - Me.txtAnzahlLaCart.Location = New System.Drawing.Point(553, 155) - Me.txtAnzahlLaCart.Name = "txtAnzahlLaCart" - Me.txtAnzahlLaCart.Size = New System.Drawing.Size(13, 13) - Me.txtAnzahlLaCart.TabIndex = 17 - Me.txtAnzahlLaCart.Text = "0" - ' 'dgvBestellungen ' Me.dgvBestellungen.AKTUALISIERUNGS_INTERVALL = -1 @@ -572,34 +655,34 @@ Partial Class frmEssensbestellungen Me.dgvBestellungen.AllowUserToDeleteRows = False Me.dgvBestellungen.AllowUserToOrderColumns = True Me.dgvBestellungen.BackgroundColor = System.Drawing.Color.White - DataGridViewCellStyle4.Alignment = System.Windows.Forms.DataGridViewContentAlignment.MiddleLeft - DataGridViewCellStyle4.BackColor = System.Drawing.SystemColors.Control - DataGridViewCellStyle4.Font = New System.Drawing.Font("Microsoft Sans Serif", 8.25!, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, CType(0, Byte)) - DataGridViewCellStyle4.ForeColor = System.Drawing.SystemColors.WindowText - DataGridViewCellStyle4.SelectionBackColor = System.Drawing.SystemColors.Highlight - DataGridViewCellStyle4.SelectionForeColor = System.Drawing.SystemColors.HighlightText - DataGridViewCellStyle4.WrapMode = System.Windows.Forms.DataGridViewTriState.[True] - Me.dgvBestellungen.ColumnHeadersDefaultCellStyle = DataGridViewCellStyle4 + DataGridViewCellStyle1.Alignment = System.Windows.Forms.DataGridViewContentAlignment.MiddleLeft + DataGridViewCellStyle1.BackColor = System.Drawing.SystemColors.Control + DataGridViewCellStyle1.Font = New System.Drawing.Font("Microsoft Sans Serif", 8.25!, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, CType(0, Byte)) + DataGridViewCellStyle1.ForeColor = System.Drawing.SystemColors.WindowText + DataGridViewCellStyle1.SelectionBackColor = System.Drawing.SystemColors.Highlight + DataGridViewCellStyle1.SelectionForeColor = System.Drawing.SystemColors.HighlightText + DataGridViewCellStyle1.WrapMode = System.Windows.Forms.DataGridViewTriState.[True] + Me.dgvBestellungen.ColumnHeadersDefaultCellStyle = DataGridViewCellStyle1 Me.dgvBestellungen.ColumnHeadersHeightSizeMode = System.Windows.Forms.DataGridViewColumnHeadersHeightSizeMode.AutoSize - DataGridViewCellStyle5.Alignment = System.Windows.Forms.DataGridViewContentAlignment.MiddleLeft - DataGridViewCellStyle5.BackColor = System.Drawing.SystemColors.Window - DataGridViewCellStyle5.Font = New System.Drawing.Font("Microsoft Sans Serif", 8.25!, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, CType(0, Byte)) - DataGridViewCellStyle5.ForeColor = System.Drawing.SystemColors.ControlText - DataGridViewCellStyle5.SelectionBackColor = System.Drawing.SystemColors.Highlight - DataGridViewCellStyle5.SelectionForeColor = System.Drawing.SystemColors.HighlightText - DataGridViewCellStyle5.WrapMode = System.Windows.Forms.DataGridViewTriState.[False] - Me.dgvBestellungen.DefaultCellStyle = DataGridViewCellStyle5 + DataGridViewCellStyle2.Alignment = System.Windows.Forms.DataGridViewContentAlignment.MiddleLeft + DataGridViewCellStyle2.BackColor = System.Drawing.SystemColors.Window + DataGridViewCellStyle2.Font = New System.Drawing.Font("Microsoft Sans Serif", 8.25!, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, CType(0, Byte)) + DataGridViewCellStyle2.ForeColor = System.Drawing.SystemColors.ControlText + DataGridViewCellStyle2.SelectionBackColor = System.Drawing.SystemColors.Highlight + DataGridViewCellStyle2.SelectionForeColor = System.Drawing.SystemColors.HighlightText + DataGridViewCellStyle2.WrapMode = System.Windows.Forms.DataGridViewTriState.[False] + Me.dgvBestellungen.DefaultCellStyle = DataGridViewCellStyle2 Me.dgvBestellungen.Location = New System.Drawing.Point(12, 351) Me.dgvBestellungen.Name = "dgvBestellungen" Me.dgvBestellungen.ReadOnly = True - DataGridViewCellStyle6.Alignment = System.Windows.Forms.DataGridViewContentAlignment.MiddleLeft - DataGridViewCellStyle6.BackColor = System.Drawing.SystemColors.Control - DataGridViewCellStyle6.Font = New System.Drawing.Font("Microsoft Sans Serif", 8.25!, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, CType(0, Byte)) - DataGridViewCellStyle6.ForeColor = System.Drawing.SystemColors.WindowText - DataGridViewCellStyle6.SelectionBackColor = System.Drawing.SystemColors.Highlight - DataGridViewCellStyle6.SelectionForeColor = System.Drawing.SystemColors.HighlightText - DataGridViewCellStyle6.WrapMode = System.Windows.Forms.DataGridViewTriState.[True] - Me.dgvBestellungen.RowHeadersDefaultCellStyle = DataGridViewCellStyle6 + DataGridViewCellStyle3.Alignment = System.Windows.Forms.DataGridViewContentAlignment.MiddleLeft + DataGridViewCellStyle3.BackColor = System.Drawing.SystemColors.Control + DataGridViewCellStyle3.Font = New System.Drawing.Font("Microsoft Sans Serif", 8.25!, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, CType(0, Byte)) + DataGridViewCellStyle3.ForeColor = System.Drawing.SystemColors.WindowText + DataGridViewCellStyle3.SelectionBackColor = System.Drawing.SystemColors.Highlight + DataGridViewCellStyle3.SelectionForeColor = System.Drawing.SystemColors.HighlightText + DataGridViewCellStyle3.WrapMode = System.Windows.Forms.DataGridViewTriState.[True] + Me.dgvBestellungen.RowHeadersDefaultCellStyle = DataGridViewCellStyle3 Me.dgvBestellungen.SelectionMode = System.Windows.Forms.DataGridViewSelectionMode.FullRowSelect Me.dgvBestellungen.ShowEditingIcon = False Me.dgvBestellungen.Size = New System.Drawing.Size(663, 127) @@ -616,89 +699,6 @@ Partial Class frmEssensbestellungen Me.cbxMenu.Size = New System.Drawing.Size(95, 21) Me.cbxMenu.TabIndex = 0 ' - 'lblAbteilung - ' - Me.lblAbteilung.AutoSize = True - Me.lblAbteilung.Location = New System.Drawing.Point(511, 9) - Me.lblAbteilung.Name = "lblAbteilung" - Me.lblAbteilung.Size = New System.Drawing.Size(54, 13) - Me.lblAbteilung.TabIndex = 18 - Me.lblAbteilung.Text = "Abteilung:" - ' - 'lblGebaeude - ' - Me.lblGebaeude.AutoSize = True - Me.lblGebaeude.Location = New System.Drawing.Point(511, 27) - Me.lblGebaeude.Name = "lblGebaeude" - Me.lblGebaeude.Size = New System.Drawing.Size(54, 13) - Me.lblGebaeude.TabIndex = 19 - Me.lblGebaeude.Text = "Gebäude:" - ' - 'MyPanel1 - ' - Me.MyPanel1.Controls.Add(Me.txtPreis) - Me.MyPanel1.Controls.Add(Me.Label2) - Me.MyPanel1.Controls.Add(Me.Dienstag) - Me.MyPanel1.Controls.Add(Me.lbl1) - Me.MyPanel1.Controls.Add(Me.GroupBox1) - Me.MyPanel1.Controls.Add(Me.GroupBox5) - 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.txtAnzahlMenu) - Me.MyPanel1.Location = New System.Drawing.Point(12, 67) - Me.MyPanel1.Name = "MyPanel1" - Me.MyPanel1.Size = New System.Drawing.Size(667, 240) - Me.MyPanel1.TabIndex = 18 - ' - 'lblBestellungen - ' - Me.lblBestellungen.AutoSize = True - Me.lblBestellungen.Location = New System.Drawing.Point(9, 335) - Me.lblBestellungen.Name = "lblBestellungen" - Me.lblBestellungen.Size = New System.Drawing.Size(100, 13) - Me.lblBestellungen.TabIndex = 20 - Me.lblBestellungen.Text = "Meine Bestellungen" - ' - 'txtPreis - ' - Me.txtPreis.AutoSize = True - Me.txtPreis.Location = New System.Drawing.Point(553, 181) - Me.txtPreis.Name = "txtPreis" - Me.txtPreis.Size = New System.Drawing.Size(13, 13) - Me.txtPreis.TabIndex = 19 - Me.txtPreis.Text = "0" - ' - 'Label2 - ' - Me.Label2.AutoSize = True - Me.Label2.Location = New System.Drawing.Point(463, 181) - Me.Label2.Name = "Label2" - Me.Label2.Size = New System.Drawing.Size(68, 13) - Me.Label2.TabIndex = 18 - Me.Label2.Text = "Gesamtpreis:" - ' - 'cbxGebauede - ' - Me.cbxGebauede._allowedValuesFreiText = Nothing - Me.cbxGebauede._allowFreiText = False - Me.cbxGebauede._value = "" - Me.cbxGebauede.FormattingEnabled = True - Me.cbxGebauede.Location = New System.Drawing.Point(580, 24) - Me.cbxGebauede.Name = "cbxGebauede" - Me.cbxGebauede.Size = New System.Drawing.Size(95, 21) - Me.cbxGebauede.TabIndex = 21 - ' - 'lblBestellungBis - ' - Me.lblBestellungBis.AutoSize = True - Me.lblBestellungBis.Location = New System.Drawing.Point(167, 38) - Me.lblBestellungBis.Name = "lblBestellungBis" - Me.lblBestellungBis.Size = New System.Drawing.Size(114, 13) - Me.lblBestellungBis.TabIndex = 22 - Me.lblBestellungBis.Text = "Bestellung möglich bis:" - ' 'frmEssensbestellungen ' Me.AutoScaleDimensions = New System.Drawing.SizeF(6.0!, 13.0!) @@ -717,24 +717,24 @@ Partial Class frmEssensbestellungen Me.Controls.Add(Me.cbxMenu) Me.Name = "frmEssensbestellungen" Me.Text = "Essensbestellung" - Me.GroupBox1.ResumeLayout(False) - Me.GroupBox1.PerformLayout() - CType(Me.pbMontag, System.ComponentModel.ISupportInitialize).EndInit() + Me.MyPanel1.ResumeLayout(False) + Me.MyPanel1.PerformLayout() Me.Dienstag.ResumeLayout(False) Me.Dienstag.PerformLayout() CType(Me.pbDienstag, System.ComponentModel.ISupportInitialize).EndInit() + Me.GroupBox1.ResumeLayout(False) + Me.GroupBox1.PerformLayout() + CType(Me.pbMontag, System.ComponentModel.ISupportInitialize).EndInit() + Me.GroupBox5.ResumeLayout(False) + Me.GroupBox5.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() CType(Me.pbDonnerstag, System.ComponentModel.ISupportInitialize).EndInit() - Me.GroupBox5.ResumeLayout(False) - Me.GroupBox5.PerformLayout() - CType(Me.pbFreitag, System.ComponentModel.ISupportInitialize).EndInit() CType(Me.dgvBestellungen, System.ComponentModel.ISupportInitialize).EndInit() - Me.MyPanel1.ResumeLayout(False) - Me.MyPanel1.PerformLayout() Me.ResumeLayout(False) Me.PerformLayout() diff --git a/Aviso/frmEssensbestellungen.vb b/Aviso/frmEssensbestellungen.vb index 6e2d325..fbe3edb 100644 --- a/Aviso/frmEssensbestellungen.vb +++ b/Aviso/frmEssensbestellungen.vb @@ -94,6 +94,9 @@ Public Class frmEssensbestellungen If txtPreis.Text IsNot "" Then essen.eb_preis = CDbl(txtPreis.Text) End If + + essen.eb_datum = CDate(dt.Rows(0).Item("MenuDateVon")) + essen.SAVE() loadDGVBestellungen() @@ -437,4 +440,7 @@ Public Class frmEssensbestellungen End Function + Private Sub rbMenu_Mo_Click(sender As Object, e As EventArgs) Handles rbMenu_Mo.Click, rbMenu_Di.Click, rbMenu_Mi.Click, rbMenu_Do.Click, rbMenu_Fr.Click + countChecks() + End Sub End Class \ No newline at end of file From b73bb673491e040706246fc4b68053a5eeb5b8c7 Mon Sep 17 00:00:00 2001 From: "d.breimaier" Date: Wed, 30 Nov 2022 10:24:58 +0100 Subject: [PATCH 07/10] Essensbestellungen --- Aviso/frmEssensbestellungen.Designer.vb | 4 +++- Aviso/frmEssensbestellungen.vb | 4 ++-- 2 files changed, 5 insertions(+), 3 deletions(-) diff --git a/Aviso/frmEssensbestellungen.Designer.vb b/Aviso/frmEssensbestellungen.Designer.vb index 38051c0..62c873a 100644 --- a/Aviso/frmEssensbestellungen.Designer.vb +++ b/Aviso/frmEssensbestellungen.Designer.vb @@ -158,8 +158,9 @@ Partial Class frmEssensbestellungen 'cbxGebauede ' Me.cbxGebauede._allowedValuesFreiText = Nothing - Me.cbxGebauede._allowFreiText = False + Me.cbxGebauede._allowFreiText = True Me.cbxGebauede._value = "" + Me.cbxGebauede.DropDownWidth = 150 Me.cbxGebauede.FormattingEnabled = True Me.cbxGebauede.Location = New System.Drawing.Point(580, 24) Me.cbxGebauede.Name = "cbxGebauede" @@ -693,6 +694,7 @@ Partial Class frmEssensbestellungen Me.cbxMenu._allowedValuesFreiText = Nothing Me.cbxMenu._allowFreiText = False Me.cbxMenu._value = "" + Me.cbxMenu.DropDownWidth = 200 Me.cbxMenu.FormattingEnabled = True Me.cbxMenu.Location = New System.Drawing.Point(12, 30) Me.cbxMenu.Name = "cbxMenu" diff --git a/Aviso/frmEssensbestellungen.vb b/Aviso/frmEssensbestellungen.vb index fbe3edb..3419059 100644 --- a/Aviso/frmEssensbestellungen.vb +++ b/Aviso/frmEssensbestellungen.vb @@ -11,7 +11,7 @@ Public Class frmEssensbestellungen Private Sub frmEssensbestellungen_Load(sender As Object, e As EventArgs) Handles MyBase.Load - cbxMenu.fillWithSQL("SELECT MenuTitel from tblEBMenu", False, "AVISO", True) + cbxMenu.fillWithSQL("SELECT Distinct (MenuDateVon), MenuTitel from tblEBMenu where MenuDateVon >= GETDATE() order by MenuDateVon desc", True, "AVISO", True) lblGebaeude.Text = "Gebäude: " lblAbteilung.Text = "Abteilung: " & VERAG_PROG_ALLGEMEIN.cAllgemein.ABTEILUNG @@ -107,7 +107,7 @@ Public Class frmEssensbestellungen dt.Clear() - dt = SQL.loadDgvBySql("SELECT * FROM tblEBMenu where [MenuTitel] = '" & cbxMenu._value & "'", "AVISO", 100, True) + dt = SQL.loadDgvBySql("SELECT * FROM tblEBMenu where [MenuDateVon] = '" & cbxMenu._value & "'", "AVISO", 100, True) If dt.Rows.Count > 0 Then If checkIfOrderIsPossible() Then From 72693343d89f51b162c383a1037e6408d308fb37 Mon Sep 17 00:00:00 2001 From: "d.breimaier" Date: Wed, 30 Nov 2022 14:10:00 +0100 Subject: [PATCH 08/10] Gesamtsicherheiten und Essensbestellungen --- Aviso/frmEssensbestellungen.Designer.vb | 94 ++++++++++++------- Aviso/frmEssensbestellungen.vb | 37 ++++++-- .../frmGesamtsicherheitenMenuNEU.Designer.vb | 24 ++--- Aviso/frmGesamtsicherheitenMenuNEU.vb | 6 +- Aviso/frmGesamtsicherheitenNEU.Designer.vb | 20 ++-- Aviso/frmGesamtsicherheitenNEU.vb | 32 ++++--- 6 files changed, 134 insertions(+), 79 deletions(-) diff --git a/Aviso/frmEssensbestellungen.Designer.vb b/Aviso/frmEssensbestellungen.Designer.vb index 62c873a..b347d06 100644 --- a/Aviso/frmEssensbestellungen.Designer.vb +++ b/Aviso/frmEssensbestellungen.Designer.vb @@ -23,9 +23,9 @@ Partial Class frmEssensbestellungen Private Sub InitializeComponent() Me.components = New System.ComponentModel.Container() - Dim DataGridViewCellStyle1 As System.Windows.Forms.DataGridViewCellStyle = New System.Windows.Forms.DataGridViewCellStyle() - Dim DataGridViewCellStyle2 As System.Windows.Forms.DataGridViewCellStyle = New System.Windows.Forms.DataGridViewCellStyle() - Dim DataGridViewCellStyle3 As System.Windows.Forms.DataGridViewCellStyle = New System.Windows.Forms.DataGridViewCellStyle() + Dim DataGridViewCellStyle10 As System.Windows.Forms.DataGridViewCellStyle = New System.Windows.Forms.DataGridViewCellStyle() + Dim DataGridViewCellStyle11 As System.Windows.Forms.DataGridViewCellStyle = New System.Windows.Forms.DataGridViewCellStyle() + Dim DataGridViewCellStyle12 As System.Windows.Forms.DataGridViewCellStyle = New System.Windows.Forms.DataGridViewCellStyle() Me.lblWochenkarte = New System.Windows.Forms.Label() Me.btnSave = New System.Windows.Forms.Button() Me.lblDatum = New System.Windows.Forms.Label() @@ -78,6 +78,8 @@ Partial Class frmEssensbestellungen Me.txtAnzahlMenu = New System.Windows.Forms.Label() Me.dgvBestellungen = New VERAG_PROG_ALLGEMEIN.MyDatagridview(Me.components) Me.cbxMenu = New VERAG_PROG_ALLGEMEIN.MyComboBox() + Me.Button1 = New System.Windows.Forms.Button() + Me.txtAbteilung = New System.Windows.Forms.Label() Me.MyPanel1.SuspendLayout() Me.Dienstag.SuspendLayout() CType(Me.pbDienstag, System.ComponentModel.ISupportInitialize).BeginInit() @@ -95,7 +97,7 @@ Partial Class frmEssensbestellungen 'lblWochenkarte ' Me.lblWochenkarte.AutoSize = True - Me.lblWochenkarte.Location = New System.Drawing.Point(12, 14) + Me.lblWochenkarte.Location = New System.Drawing.Point(18, 14) Me.lblWochenkarte.Name = "lblWochenkarte" Me.lblWochenkarte.Size = New System.Drawing.Size(34, 13) Me.lblWochenkarte.TabIndex = 1 @@ -103,6 +105,7 @@ Partial Class frmEssensbestellungen ' 'btnSave ' + Me.btnSave.Anchor = System.Windows.Forms.AnchorStyles.Bottom Me.btnSave.Location = New System.Drawing.Point(305, 484) Me.btnSave.Name = "btnSave" Me.btnSave.Size = New System.Drawing.Size(75, 23) @@ -140,7 +143,7 @@ Partial Class frmEssensbestellungen 'lblBestellungen ' Me.lblBestellungen.AutoSize = True - Me.lblBestellungen.Location = New System.Drawing.Point(9, 335) + Me.lblBestellungen.Location = New System.Drawing.Point(15, 335) Me.lblBestellungen.Name = "lblBestellungen" Me.lblBestellungen.Size = New System.Drawing.Size(100, 13) Me.lblBestellungen.TabIndex = 20 @@ -162,13 +165,14 @@ Partial Class frmEssensbestellungen Me.cbxGebauede._value = "" Me.cbxGebauede.DropDownWidth = 150 Me.cbxGebauede.FormattingEnabled = True - Me.cbxGebauede.Location = New System.Drawing.Point(580, 24) + Me.cbxGebauede.Location = New System.Drawing.Point(584, 24) Me.cbxGebauede.Name = "cbxGebauede" Me.cbxGebauede.Size = New System.Drawing.Size(95, 21) Me.cbxGebauede.TabIndex = 21 ' 'MyPanel1 ' + Me.MyPanel1.Controls.Add(Me.Button1) Me.MyPanel1.Controls.Add(Me.txtPreis) Me.MyPanel1.Controls.Add(Me.Label2) Me.MyPanel1.Controls.Add(Me.Dienstag) @@ -655,35 +659,37 @@ Partial Class frmEssensbestellungen Me.dgvBestellungen.AllowUserToAddRows = False Me.dgvBestellungen.AllowUserToDeleteRows = False Me.dgvBestellungen.AllowUserToOrderColumns = True + Me.dgvBestellungen.Anchor = CType(((System.Windows.Forms.AnchorStyles.Bottom Or System.Windows.Forms.AnchorStyles.Left) _ + Or System.Windows.Forms.AnchorStyles.Right), System.Windows.Forms.AnchorStyles) Me.dgvBestellungen.BackgroundColor = System.Drawing.Color.White - DataGridViewCellStyle1.Alignment = System.Windows.Forms.DataGridViewContentAlignment.MiddleLeft - DataGridViewCellStyle1.BackColor = System.Drawing.SystemColors.Control - DataGridViewCellStyle1.Font = New System.Drawing.Font("Microsoft Sans Serif", 8.25!, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, CType(0, Byte)) - DataGridViewCellStyle1.ForeColor = System.Drawing.SystemColors.WindowText - DataGridViewCellStyle1.SelectionBackColor = System.Drawing.SystemColors.Highlight - DataGridViewCellStyle1.SelectionForeColor = System.Drawing.SystemColors.HighlightText - DataGridViewCellStyle1.WrapMode = System.Windows.Forms.DataGridViewTriState.[True] - Me.dgvBestellungen.ColumnHeadersDefaultCellStyle = DataGridViewCellStyle1 + DataGridViewCellStyle10.Alignment = System.Windows.Forms.DataGridViewContentAlignment.MiddleLeft + DataGridViewCellStyle10.BackColor = System.Drawing.SystemColors.Control + DataGridViewCellStyle10.Font = New System.Drawing.Font("Microsoft Sans Serif", 8.25!, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, CType(0, Byte)) + DataGridViewCellStyle10.ForeColor = System.Drawing.SystemColors.WindowText + DataGridViewCellStyle10.SelectionBackColor = System.Drawing.SystemColors.Highlight + DataGridViewCellStyle10.SelectionForeColor = System.Drawing.SystemColors.HighlightText + DataGridViewCellStyle10.WrapMode = System.Windows.Forms.DataGridViewTriState.[True] + Me.dgvBestellungen.ColumnHeadersDefaultCellStyle = DataGridViewCellStyle10 Me.dgvBestellungen.ColumnHeadersHeightSizeMode = System.Windows.Forms.DataGridViewColumnHeadersHeightSizeMode.AutoSize - DataGridViewCellStyle2.Alignment = System.Windows.Forms.DataGridViewContentAlignment.MiddleLeft - DataGridViewCellStyle2.BackColor = System.Drawing.SystemColors.Window - DataGridViewCellStyle2.Font = New System.Drawing.Font("Microsoft Sans Serif", 8.25!, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, CType(0, Byte)) - DataGridViewCellStyle2.ForeColor = System.Drawing.SystemColors.ControlText - DataGridViewCellStyle2.SelectionBackColor = System.Drawing.SystemColors.Highlight - DataGridViewCellStyle2.SelectionForeColor = System.Drawing.SystemColors.HighlightText - DataGridViewCellStyle2.WrapMode = System.Windows.Forms.DataGridViewTriState.[False] - Me.dgvBestellungen.DefaultCellStyle = DataGridViewCellStyle2 - Me.dgvBestellungen.Location = New System.Drawing.Point(12, 351) + DataGridViewCellStyle11.Alignment = System.Windows.Forms.DataGridViewContentAlignment.MiddleLeft + DataGridViewCellStyle11.BackColor = System.Drawing.SystemColors.Window + DataGridViewCellStyle11.Font = New System.Drawing.Font("Microsoft Sans Serif", 8.25!, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, CType(0, Byte)) + DataGridViewCellStyle11.ForeColor = System.Drawing.SystemColors.ControlText + DataGridViewCellStyle11.SelectionBackColor = System.Drawing.SystemColors.Highlight + DataGridViewCellStyle11.SelectionForeColor = System.Drawing.SystemColors.HighlightText + DataGridViewCellStyle11.WrapMode = System.Windows.Forms.DataGridViewTriState.[False] + Me.dgvBestellungen.DefaultCellStyle = DataGridViewCellStyle11 + Me.dgvBestellungen.Location = New System.Drawing.Point(16, 351) Me.dgvBestellungen.Name = "dgvBestellungen" Me.dgvBestellungen.ReadOnly = True - DataGridViewCellStyle3.Alignment = System.Windows.Forms.DataGridViewContentAlignment.MiddleLeft - DataGridViewCellStyle3.BackColor = System.Drawing.SystemColors.Control - DataGridViewCellStyle3.Font = New System.Drawing.Font("Microsoft Sans Serif", 8.25!, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, CType(0, Byte)) - DataGridViewCellStyle3.ForeColor = System.Drawing.SystemColors.WindowText - DataGridViewCellStyle3.SelectionBackColor = System.Drawing.SystemColors.Highlight - DataGridViewCellStyle3.SelectionForeColor = System.Drawing.SystemColors.HighlightText - DataGridViewCellStyle3.WrapMode = System.Windows.Forms.DataGridViewTriState.[True] - Me.dgvBestellungen.RowHeadersDefaultCellStyle = DataGridViewCellStyle3 + DataGridViewCellStyle12.Alignment = System.Windows.Forms.DataGridViewContentAlignment.MiddleLeft + DataGridViewCellStyle12.BackColor = System.Drawing.SystemColors.Control + DataGridViewCellStyle12.Font = New System.Drawing.Font("Microsoft Sans Serif", 8.25!, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, CType(0, Byte)) + DataGridViewCellStyle12.ForeColor = System.Drawing.SystemColors.WindowText + DataGridViewCellStyle12.SelectionBackColor = System.Drawing.SystemColors.Highlight + DataGridViewCellStyle12.SelectionForeColor = System.Drawing.SystemColors.HighlightText + DataGridViewCellStyle12.WrapMode = System.Windows.Forms.DataGridViewTriState.[True] + Me.dgvBestellungen.RowHeadersDefaultCellStyle = DataGridViewCellStyle12 Me.dgvBestellungen.SelectionMode = System.Windows.Forms.DataGridViewSelectionMode.FullRowSelect Me.dgvBestellungen.ShowEditingIcon = False Me.dgvBestellungen.Size = New System.Drawing.Size(663, 127) @@ -696,16 +702,36 @@ Partial Class frmEssensbestellungen Me.cbxMenu._value = "" Me.cbxMenu.DropDownWidth = 200 Me.cbxMenu.FormattingEnabled = True - Me.cbxMenu.Location = New System.Drawing.Point(12, 30) + Me.cbxMenu.Location = New System.Drawing.Point(15, 30) Me.cbxMenu.Name = "cbxMenu" - Me.cbxMenu.Size = New System.Drawing.Size(95, 21) + Me.cbxMenu.Size = New System.Drawing.Size(136, 21) Me.cbxMenu.TabIndex = 0 ' + 'Button1 + ' + Me.Button1.Image = Global.AVISO.My.Resources.Resources.pdf1 + Me.Button1.Location = New System.Drawing.Point(590, 147) + Me.Button1.Name = "Button1" + Me.Button1.Size = New System.Drawing.Size(61, 57) + Me.Button1.TabIndex = 20 + Me.Button1.UseVisualStyleBackColor = True + Me.Button1.Visible = False + ' + 'txtAbteilung + ' + Me.txtAbteilung.AutoSize = True + Me.txtAbteilung.Location = New System.Drawing.Point(581, 9) + Me.txtAbteilung.Name = "txtAbteilung" + Me.txtAbteilung.Size = New System.Drawing.Size(29, 13) + Me.txtAbteilung.TabIndex = 23 + Me.txtAbteilung.Text = "EDV" + ' '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.Controls.Add(Me.txtAbteilung) Me.Controls.Add(Me.lblBestellungBis) Me.Controls.Add(Me.cbxGebauede) Me.Controls.Add(Me.lblBestellungen) @@ -794,4 +820,6 @@ Partial Class frmEssensbestellungen Friend WithEvents Label2 As Label Friend WithEvents cbxGebauede As VERAG_PROG_ALLGEMEIN.MyComboBox Friend WithEvents lblBestellungBis As Label + Friend WithEvents Button1 As Button + Friend WithEvents txtAbteilung As Label End Class diff --git a/Aviso/frmEssensbestellungen.vb b/Aviso/frmEssensbestellungen.vb index 3419059..a0101ef 100644 --- a/Aviso/frmEssensbestellungen.vb +++ b/Aviso/frmEssensbestellungen.vb @@ -1,4 +1,5 @@  +Imports Therefore.API Imports VERAG_PROG_ALLGEMEIN Public Class frmEssensbestellungen @@ -11,10 +12,9 @@ Public Class frmEssensbestellungen Private Sub frmEssensbestellungen_Load(sender As Object, e As EventArgs) Handles MyBase.Load - cbxMenu.fillWithSQL("SELECT Distinct (MenuDateVon), MenuTitel from tblEBMenu where MenuDateVon >= GETDATE() order by MenuDateVon desc", True, "AVISO", True) + cbxMenu.fillWithSQL("SELECT Distinct Top 10 (MenuTitel), MenuDateVon from tblEBMenu order by MenuDateVon desc", True, "AVISO", True) '/ where MenuDateVon >= GETDATE() - lblGebaeude.Text = "Gebäude: " - lblAbteilung.Text = "Abteilung: " & VERAG_PROG_ALLGEMEIN.cAllgemein.ABTEILUNG + txtAbteilung.Text = VERAG_PROG_ALLGEMEIN.cAllgemein.ABTEILUNG loadDGVBestellungen() cbxGebauede.Items.Add(New VERAG_PROG_ALLGEMEIN.MyListItem("Frontoffice", "Frontoffice")) @@ -23,6 +23,7 @@ Public Class frmEssensbestellungen cbxGebauede.Items.Add(New VERAG_PROG_ALLGEMEIN.MyListItem("Maut", "Maut")) cbxGebauede.Items.Add(New VERAG_PROG_ALLGEMEIN.MyListItem("", "")) cbxGebauede.changeItem("") + btnSave.Enabled = False End Sub @@ -105,9 +106,17 @@ Public Class frmEssensbestellungen Private Sub cbxMenu_SelectedValueChanged(sender As Object, e As EventArgs) Handles cbxMenu.SelectedValueChanged + If cbxMenu._value Is Nothing Or cbxMenu._value = "" Then + Button1.Visible = False + loadDGVBestellungen() + btnSave.Enabled = False + Exit Sub + End If + btnSave.Enabled = True + 'Button1.Visible = True dt.Clear() - dt = SQL.loadDgvBySql("SELECT * FROM tblEBMenu where [MenuDateVon] = '" & cbxMenu._value & "'", "AVISO", 100, True) + dt = SQL.loadDgvBySql("SELECT Top 1 * FROM tblEBMenu where [MenuTitel] = '" & cbxMenu._value & "' order by MenuDateVon desc", "AVISO", 100, True) If dt.Rows.Count > 0 Then If checkIfOrderIsPossible() Then @@ -234,19 +243,20 @@ Public Class frmEssensbestellungen .Columns("eb_mitid").Visible = False .Columns("eb_gebaeude").Visible = False .Columns("eb_abteilung").Visible = False - .Columns("eb_montag").Width = 100 + .Columns("eb_montag").Width = 80 .Columns("eb_montag").HeaderText = "Montag" - .Columns("eb_montag").Width = 100 + .Columns("eb_montag").Width = 80 .Columns("eb_dienstag").HeaderText = "Dienstag" - .Columns("eb_dienstag").Width = 100 + .Columns("eb_dienstag").Width = 80 .Columns("eb_mittwoch").HeaderText = "Mittwoch" - .Columns("eb_mittwoch").Width = 100 + .Columns("eb_mittwoch").Width = 80 .Columns("eb_donnerstag").HeaderText = "Donnerstag" - .Columns("eb_donnerstag").Width = 100 + .Columns("eb_donnerstag").Width = 80 .Columns("eb_freitag").HeaderText = "Freitag" - .Columns("eb_freitag").Width = 100 + .Columns("eb_freitag").Width = 80 .Columns("eb_preis").HeaderText = "Preis" .Columns("eb_preis").Width = 40 + .Columns("eb_preis").DefaultCellStyle.Format = "N" End With End Sub @@ -410,6 +420,9 @@ Public Class frmEssensbestellungen End If + cbxGebauede._value = currentEssen.eb_gebaeude + + End Sub Private Function checkIfOrderIsPossible() As Boolean @@ -443,4 +456,8 @@ Public Class frmEssensbestellungen Private Sub rbMenu_Mo_Click(sender As Object, e As EventArgs) Handles rbMenu_Mo.Click, rbMenu_Di.Click, rbMenu_Mi.Click, rbMenu_Do.Click, rbMenu_Fr.Click countChecks() End Sub + + Private Sub Button1_Click(sender As Object, e As EventArgs) Handles Button1.Click + 'Process.Start("\\YM5T001348\Gastro\FTPUpload\Menues\" & cbxMenu._value & ".pdf") + End Sub End Class \ No newline at end of file diff --git a/Aviso/frmGesamtsicherheitenMenuNEU.Designer.vb b/Aviso/frmGesamtsicherheitenMenuNEU.Designer.vb index 6dc595f..4a61bd6 100644 --- a/Aviso/frmGesamtsicherheitenMenuNEU.Designer.vb +++ b/Aviso/frmGesamtsicherheitenMenuNEU.Designer.vb @@ -81,7 +81,7 @@ Partial Class frmGesamtsicherheitenMenuNEU Me.dgvListe.Location = New System.Drawing.Point(-3, 288) Me.dgvListe.Name = "dgvListe" Me.dgvListe.ReadOnly = True - Me.dgvListe.Size = New System.Drawing.Size(606, 427) + Me.dgvListe.Size = New System.Drawing.Size(658, 427) Me.dgvListe.TabIndex = 1 ' 'ContextMenuStrip1 @@ -143,7 +143,7 @@ Partial Class frmGesamtsicherheitenMenuNEU Me.Panel1.Dock = System.Windows.Forms.DockStyle.Top Me.Panel1.Location = New System.Drawing.Point(0, 0) Me.Panel1.Name = "Panel1" - Me.Panel1.Size = New System.Drawing.Size(606, 288) + Me.Panel1.Size = New System.Drawing.Size(658, 288) Me.Panel1.TabIndex = 0 ' 'btnOpenOver85Days @@ -458,7 +458,7 @@ Partial Class frmGesamtsicherheitenMenuNEU Me.FlatButton2.FlatAppearance.BorderSize = 0 Me.FlatButton2.FlatStyle = System.Windows.Forms.FlatStyle.Flat Me.FlatButton2.ForeColor = System.Drawing.Color.Black - Me.FlatButton2.Location = New System.Drawing.Point(513, 220) + Me.FlatButton2.Location = New System.Drawing.Point(565, 220) Me.FlatButton2.Name = "FlatButton2" Me.FlatButton2.Size = New System.Drawing.Size(81, 20) Me.FlatButton2.TabIndex = 30 @@ -496,7 +496,7 @@ Partial Class frmGesamtsicherheitenMenuNEU Me.txtbis._WaehrungZeichen = True Me.txtbis.Anchor = System.Windows.Forms.AnchorStyles.Right Me.txtbis.ForeColor = System.Drawing.Color.Black - Me.txtbis.Location = New System.Drawing.Point(513, 196) + Me.txtbis.Location = New System.Drawing.Point(565, 196) Me.txtbis.MaxLineLength = -1 Me.txtbis.MaxLines_Warning = "" Me.txtbis.MaxLines_Warning_Label = Nothing @@ -522,7 +522,7 @@ Partial Class frmGesamtsicherheitenMenuNEU Me.txtVon._WaehrungZeichen = True Me.txtVon.Anchor = System.Windows.Forms.AnchorStyles.Right Me.txtVon.ForeColor = System.Drawing.Color.Black - Me.txtVon.Location = New System.Drawing.Point(510, 153) + Me.txtVon.Location = New System.Drawing.Point(562, 153) Me.txtVon.MaxLineLength = -1 Me.txtVon.MaxLines_Warning = "" Me.txtVon.MaxLines_Warning_Label = Nothing @@ -538,7 +538,7 @@ Partial Class frmGesamtsicherheitenMenuNEU Me.Label3.AutoSize = True Me.Label3.Font = New System.Drawing.Font("Microsoft Sans Serif", 9.0!) Me.Label3.ForeColor = System.Drawing.Color.Honeydew - Me.Label3.Location = New System.Drawing.Point(510, 177) + Me.Label3.Location = New System.Drawing.Point(562, 177) Me.Label3.Name = "Label3" Me.Label3.Size = New System.Drawing.Size(24, 15) Me.Label3.TabIndex = 22 @@ -551,7 +551,7 @@ Partial Class frmGesamtsicherheitenMenuNEU Me.Label2.AutoSize = True Me.Label2.Font = New System.Drawing.Font("Microsoft Sans Serif", 9.0!) Me.Label2.ForeColor = System.Drawing.Color.Honeydew - Me.Label2.Location = New System.Drawing.Point(510, 134) + Me.Label2.Location = New System.Drawing.Point(562, 134) Me.Label2.Name = "Label2" Me.Label2.Size = New System.Drawing.Size(28, 15) Me.Label2.TabIndex = 10 @@ -611,7 +611,7 @@ Partial Class frmGesamtsicherheitenMenuNEU Me.btnNeu.FlatAppearance.BorderSize = 0 Me.btnNeu.FlatStyle = System.Windows.Forms.FlatStyle.Flat Me.btnNeu.ForeColor = System.Drawing.Color.Black - Me.btnNeu.Location = New System.Drawing.Point(519, 253) + Me.btnNeu.Location = New System.Drawing.Point(571, 253) Me.btnNeu.Name = "btnNeu" Me.btnNeu.Size = New System.Drawing.Size(75, 23) Me.btnNeu.TabIndex = 34 @@ -624,7 +624,7 @@ Partial Class frmGesamtsicherheitenMenuNEU Me.lblSaldo.AutoSize = True Me.lblSaldo.Font = New System.Drawing.Font("Microsoft Sans Serif", 14.25!, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, CType(0, Byte)) Me.lblSaldo.ForeColor = System.Drawing.Color.Red - Me.lblSaldo.Location = New System.Drawing.Point(398, 11) + Me.lblSaldo.Location = New System.Drawing.Point(450, 11) Me.lblSaldo.Name = "lblSaldo" Me.lblSaldo.Size = New System.Drawing.Size(82, 24) Me.lblSaldo.TabIndex = 1 @@ -636,7 +636,7 @@ Partial Class frmGesamtsicherheitenMenuNEU Me.lblZollsatz.AutoSize = True Me.lblZollsatz.Font = New System.Drawing.Font("Microsoft Sans Serif", 9.75!, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, CType(0, Byte)) Me.lblZollsatz.ForeColor = System.Drawing.Color.Honeydew - Me.lblZollsatz.Location = New System.Drawing.Point(399, 116) + Me.lblZollsatz.Location = New System.Drawing.Point(451, 116) Me.lblZollsatz.Name = "lblZollsatz" Me.lblZollsatz.Size = New System.Drawing.Size(63, 16) Me.lblZollsatz.TabIndex = 9 @@ -648,7 +648,7 @@ Partial Class frmGesamtsicherheitenMenuNEU Me.lblReferenzwert.AutoSize = True Me.lblReferenzwert.Font = New System.Drawing.Font("Microsoft Sans Serif", 9.75!, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, CType(0, Byte)) Me.lblReferenzwert.ForeColor = System.Drawing.Color.Honeydew - Me.lblReferenzwert.Location = New System.Drawing.Point(399, 89) + Me.lblReferenzwert.Location = New System.Drawing.Point(451, 89) Me.lblReferenzwert.Name = "lblReferenzwert" Me.lblReferenzwert.Size = New System.Drawing.Size(95, 16) Me.lblReferenzwert.TabIndex = 6 @@ -658,7 +658,7 @@ Partial Class frmGesamtsicherheitenMenuNEU ' Me.AutoScaleDimensions = New System.Drawing.SizeF(6.0!, 13.0!) Me.AutoScaleMode = System.Windows.Forms.AutoScaleMode.Font - Me.ClientSize = New System.Drawing.Size(606, 721) + Me.ClientSize = New System.Drawing.Size(658, 721) Me.Controls.Add(Me.dgvListe) Me.Controls.Add(Me.Panel1) Me.Icon = CType(resources.GetObject("$this.Icon"), System.Drawing.Icon) diff --git a/Aviso/frmGesamtsicherheitenMenuNEU.vb b/Aviso/frmGesamtsicherheitenMenuNEU.vb index a48b344..878fd20 100644 --- a/Aviso/frmGesamtsicherheitenMenuNEU.vb +++ b/Aviso/frmGesamtsicherheitenMenuNEU.vb @@ -53,7 +53,7 @@ Public Class frmGesamtsicherheitenMenuNEU If cbxWarenort._value <> "" Then sqladdon &= " AND gs_warenort = '" & cbxWarenort._value.ToString & "'" Dim sqlstring As String = - " select * from (Select gs_gsnr as gs_gsnr, MIN(gs_standort) as gs_standort, MIN(gs_warenort) as gs_warenort, MIN(gs_filialenNr) as gs_filialenNr, min(gs_abfertigungsNr) as gs_abfertigungsNr, + " select * from (Select gs_gsnr as gs_gsnr, MIN(gs_standort) as gs_standort, MIN(gs_warenort) as gs_warenort, MIN(gs_filialenNr) as gs_filialenNr, min(gs_abfertigungsNr) as gs_abfertigungsNr, MIN(gs_avisoId) as gs_avisoId, max(gs_LKWKZ) as gs_LKWKZ, min (gs_datum) as gs_datum, FORMAT( (Select SUM( Case when gs_art = 'Open' then (gs_sicherheitsbetrag * -1) @@ -70,6 +70,7 @@ Public Class frmGesamtsicherheitenMenuNEU From (select * from (select gs_gsnr as ding from [tblGesamtsicherheit] where gs_freitext like '%" & txtSuchbegriff.Text & "%' OR gs_abfertigungsNr like '%" & txtSuchbegriff.Text & "%' OR + gs_avisoId like '%" & txtSuchbegriff.Text & "%' OR gs_ATBNr like '%" & txtSuchbegriff.Text & "%' OR gs_LKWKZ like '%" & txtSuchbegriff.Text & "%' OR gs_warenort like '%" & txtSuchbegriff.Text & "%' @@ -97,6 +98,8 @@ Public Class frmGesamtsicherheitenMenuNEU .Columns("gs_SicherheitsSaldo").HeaderText = "Sicherheitssaldo" .Columns("gs_Warenort").Width = 96 .Columns("gs_Warenort").HeaderText = "Warenort" + .Columns("gs_avisoId").Width = 96 + .Columns("gs_avisoId").HeaderText = "LKW-ID" .Columns("gs_LKWKZ").HeaderText = "LKW-KZ" End With @@ -163,6 +166,7 @@ Public Class frmGesamtsicherheitenMenuNEU .FilialNummer = dgvListe.CurrentRow.Cells("gs_filialenNr").Value .Abfertigungsnummer = dgvListe.CurrentRow.Cells("gs_abfertigungsNr").Value .warenortID = dgvListe.CurrentRow.Cells("gs_warenort").Value + .avisoID = dgvListe.CurrentRow.Cells("gs_avisoId").Value .dataTable = Me.dataTable End With diff --git a/Aviso/frmGesamtsicherheitenNEU.Designer.vb b/Aviso/frmGesamtsicherheitenNEU.Designer.vb index 0f5aac4..67e6ec5 100644 --- a/Aviso/frmGesamtsicherheitenNEU.Designer.vb +++ b/Aviso/frmGesamtsicherheitenNEU.Designer.vb @@ -51,7 +51,7 @@ Partial Class frmGesamtsicherheitenNEU Me.lblWarenort = New System.Windows.Forms.Label() Me.cboFiliale = New VERAG_PROG_ALLGEMEIN.MyComboBox() Me.btnSave = New VERAG_PROG_ALLGEMEIN.FlatButton() - Me.txtLKWID = New System.Windows.Forms.TextBox() + Me.txtLKWKZ = New System.Windows.Forms.TextBox() Me.txtAbfertNum = New System.Windows.Forms.TextBox() Me.Label18 = New System.Windows.Forms.Label() Me.Label17 = New System.Windows.Forms.Label() @@ -327,7 +327,7 @@ Partial Class frmGesamtsicherheitenNEU Me.panOverlay.Controls.Add(Me.lblWarenort) Me.panOverlay.Controls.Add(Me.cboFiliale) Me.panOverlay.Controls.Add(Me.btnSave) - Me.panOverlay.Controls.Add(Me.txtLKWID) + Me.panOverlay.Controls.Add(Me.txtLKWKZ) Me.panOverlay.Controls.Add(Me.txtAbfertNum) Me.panOverlay.Controls.Add(Me.Label18) Me.panOverlay.Controls.Add(Me.Label17) @@ -426,14 +426,14 @@ Partial Class frmGesamtsicherheitenNEU Me.btnSave.Text = "Speichern" Me.btnSave.UseVisualStyleBackColor = False ' - 'txtLKWID + 'txtLKWKZ ' - Me.txtLKWID.Font = New System.Drawing.Font("Microsoft Sans Serif", 11.25!, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, CType(0, Byte)) - Me.txtLKWID.Location = New System.Drawing.Point(279, 216) - Me.txtLKWID.Margin = New System.Windows.Forms.Padding(0) - Me.txtLKWID.Name = "txtLKWID" - Me.txtLKWID.Size = New System.Drawing.Size(186, 24) - Me.txtLKWID.TabIndex = 8 + Me.txtLKWKZ.Font = New System.Drawing.Font("Microsoft Sans Serif", 11.25!, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, CType(0, Byte)) + Me.txtLKWKZ.Location = New System.Drawing.Point(279, 216) + Me.txtLKWKZ.Margin = New System.Windows.Forms.Padding(0) + Me.txtLKWKZ.Name = "txtLKWKZ" + Me.txtLKWKZ.Size = New System.Drawing.Size(186, 24) + Me.txtLKWKZ.TabIndex = 8 ' 'txtAbfertNum ' @@ -1554,7 +1554,7 @@ Partial Class frmGesamtsicherheitenNEU Friend WithEvents txtAnzahlPos As TextBox Friend WithEvents panOverlay As Panel Friend WithEvents btnSave As VERAG_PROG_ALLGEMEIN.FlatButton - Friend WithEvents txtLKWID As TextBox + Friend WithEvents txtLKWKZ As TextBox Friend WithEvents txtAbfertNum As TextBox Friend WithEvents Label18 As Label Friend WithEvents Label17 As Label diff --git a/Aviso/frmGesamtsicherheitenNEU.vb b/Aviso/frmGesamtsicherheitenNEU.vb index cc90253..e6c066c 100644 --- a/Aviso/frmGesamtsicherheitenNEU.vb +++ b/Aviso/frmGesamtsicherheitenNEU.vb @@ -320,8 +320,8 @@ Public Class frmGesamtsicherheitenNEU Me.warenortID = setNullToZero(dt.Rows(0).Item("gs_warenort")) End If - If Me.avisoID.ToString.Length > 0 Then lblGestellungNr.Text &= "Aviso-ID: " & Me.avisoID & " " - If Me.LKWKZ.ToString.Length > 0 Then lblGestellungNr.Text &= "LKW-ID: " & Me.LKWKZ & " " + If Me.avisoID.ToString.Length > 0 Then lblGestellungNr.Text &= "LKW-ID: " & Me.avisoID & " " + If Me.LKWKZ.ToString.Length > 0 Then lblGestellungNr.Text &= "LKW-KZ: " & Me.LKWKZ & " " If Me.FilialNummer.ToString.Length > 0 Then lblGestellungNr.Text &= "FilialNr: " & Me.FilialNummer & " " If Me.Abfertigungsnummer.Length > 0 Then lblGestellungNr.Text &= "AbfNr: " & Me.Abfertigungsnummer & " " If Me.warenortID.Length > 0 Then lblGestellungNr.Text &= "Warenort: " & Me.warenortID & " " @@ -505,8 +505,7 @@ Public Class frmGesamtsicherheitenNEU .gsp_filialenNr = OPEN.gs_filialenNr .gsp_art = "OPEN" .gsp_abfertigungsNr = OPEN.gs_abfertigungsnr - .gsp_erstellungsdatum = Me.datum - .gsp_avisoId = "" + .gsp_erstellungsdatum = DateTimeString2DateTimeKonvertinator(txtSicherheitDate.Text, txtSicherheitTime.Text) .gsp_ust = "" .gsp_avisoId = Me.avisoID '.gsp_ATCNr = "" @@ -671,10 +670,14 @@ Public Class frmGesamtsicherheitenNEU End Try Me.Abfertigungsnummer = txtAbfertNum.Text - Me.LKWKZ = txtLKWID.Text + Me.LKWKZ = txtLKWKZ.Text + If txtlkwIdSearch.Text IsNot "" Then + Me.avisoID = CInt(txtlkwIdSearch.Text) + End If + If setNullToZero(Me.gessicherheitID) > 0 Then - Dim sqlstring = "Update [tblGesamtsicherheit] set [gs_filialenNr] = '" & Me.FilialNummer & "', [gs_abfertigungsNr] = '" & Me.Abfertigungsnummer & "', [gs_LKWKZ] = '" & Me.LKWKZ & "', [gs_warenort] = '" & Me.warenortID & "' WHERE [gs_gsNr] = '" & Me.gessicherheitID & "' " + Dim sqlstring = "Update [tblGesamtsicherheit] set [gs_filialenNr] = '" & Me.FilialNummer & "', [gs_abfertigungsNr] = '" & Me.Abfertigungsnummer & "', [gs_avisoId] = '" & Me.avisoID & "',[gs_LKWKZ] = '" & Me.LKWKZ & "', [gs_warenort] = '" & Me.warenortID & "' WHERE [gs_gsNr] = '" & Me.gessicherheitID & "' " SQL.doSQL(sqlstring, "AVISO") btnAddPos.Visible = True LoadDGVSicherheiten() @@ -721,8 +724,8 @@ Public Class frmGesamtsicherheitenNEU txtSicherheitWarenwert.Text = Sicherh.gs_warenwert txtSicherheitFreitext.Text = Sicherh.gs_freitext cboSicherheitATR.SelectedItem = Sicherh.gs_atr - txtSicherheitDate.Text = Sicherh.gs_erstellungsdatum.ToString("dd.MM.yyyy") - txtSicherheitTime.Text = Sicherh.gs_erstellungsdatum.ToString("HH:mm") + txtSicherheitDate.Text = Sicherh.gs_datum.ToString("dd.MM.yyyy") + txtSicherheitTime.Text = Sicherh.gs_datum.ToString("HH:mm") currentSicherheit = Sicherh txtAnzahlPos.Enabled = False @@ -772,6 +775,7 @@ Public Class frmGesamtsicherheitenNEU .gsp_sicherheitsbetrag = Double.Parse(txtPosSicherheitsbetrag.Text) .gsp_warenwert = Double.Parse(txtPosWarenwert.Text) .gsp_ATCNr = If(txtPositionenCRN.Text <> "", txtPositionenCRN.Text, Nothing) + .gsp_erstellungsdatum = DateTimeString2DateTimeKonvertinator(txtPosDate.Text, txtPosTime.Text) End With If checkSicherheitsbetrag() = False Then Exit Sub @@ -837,8 +841,10 @@ Public Class frmGesamtsicherheitenNEU cboFiliale.SelectedIndex = cboFiliale.FindString(Me.FilialNummer) cboWarenort.fillWithSQL("SELECT [wo_warenort],CONCAT([wo_knnr],' - ' ,[wo_bezeichnung]) FROM [tblWarenorte] WHERE [wo_aktiv] ='1' ORDER BY [wo_reihenfolge] ", True, "AVISO", True) cboWarenort.SelectedIndex = cbx_Suche_Warenort.FindString(Me.warenortID) + txtlkwIdSearch.initSearchBox(Me.FindForm, " LKW_Nr, AvisoID, CAST(Datum as Date) as Datum FROM [Aviso]", {"LKW_Nr", "AvisoID", "Datum"}, "", "Datum desc", "LKW_Nr", "AvisoID", "AVISO",, 250, 200) + txtlkwIdSearch.Text = Me.avisoID txtAbfertNum.Text = Me.Abfertigungsnummer - txtLKWID.Text = Me.LKWKZ + txtLKWKZ.Text = Me.LKWKZ panOben.Enabled = False End Sub @@ -1287,11 +1293,11 @@ Public Class frmGesamtsicherheitenNEU Private Sub txtlkwIdSearch_VALUE_CHANGED() Handles txtlkwIdSearch.VALUE_CHANGED If (txtlkwIdSearch._value <> "") Then - txtLKWID.Text = txtlkwIdSearch._value - txtLKWID.ReadOnly = True + txtLKWKZ.Text = txtlkwIdSearch._value + txtLKWKZ.ReadOnly = True Else - txtLKWID.Clear() - txtLKWID.ReadOnly = False + txtLKWKZ.Clear() + txtLKWKZ.ReadOnly = False End If End Sub From 67601f4ee38b3e05b16c9f1fe395bb6566a747ad Mon Sep 17 00:00:00 2001 From: "d.breimaier" Date: Wed, 30 Nov 2022 14:34:57 +0100 Subject: [PATCH 09/10] Essensbestellungen GUIVerbesserungen --- Aviso/frmEssensbestellungen.Designer.vb | 88 ++++++++++++++----------- Aviso/frmEssensbestellungen.vb | 11 +++- 2 files changed, 60 insertions(+), 39 deletions(-) diff --git a/Aviso/frmEssensbestellungen.Designer.vb b/Aviso/frmEssensbestellungen.Designer.vb index b347d06..8bc8a00 100644 --- a/Aviso/frmEssensbestellungen.Designer.vb +++ b/Aviso/frmEssensbestellungen.Designer.vb @@ -23,9 +23,9 @@ Partial Class frmEssensbestellungen Private Sub InitializeComponent() Me.components = New System.ComponentModel.Container() - Dim DataGridViewCellStyle10 As System.Windows.Forms.DataGridViewCellStyle = New System.Windows.Forms.DataGridViewCellStyle() - Dim DataGridViewCellStyle11 As System.Windows.Forms.DataGridViewCellStyle = New System.Windows.Forms.DataGridViewCellStyle() - Dim DataGridViewCellStyle12 As System.Windows.Forms.DataGridViewCellStyle = New System.Windows.Forms.DataGridViewCellStyle() + Dim DataGridViewCellStyle1 As System.Windows.Forms.DataGridViewCellStyle = New System.Windows.Forms.DataGridViewCellStyle() + Dim DataGridViewCellStyle2 As System.Windows.Forms.DataGridViewCellStyle = New System.Windows.Forms.DataGridViewCellStyle() + Dim DataGridViewCellStyle3 As System.Windows.Forms.DataGridViewCellStyle = New System.Windows.Forms.DataGridViewCellStyle() Me.lblWochenkarte = New System.Windows.Forms.Label() Me.btnSave = New System.Windows.Forms.Button() Me.lblDatum = New System.Windows.Forms.Label() @@ -40,6 +40,7 @@ Partial Class frmEssensbestellungen Me.lblBestellungBis = New System.Windows.Forms.Label() Me.cbxGebauede = New VERAG_PROG_ALLGEMEIN.MyComboBox() Me.MyPanel1 = New VERAG_PROG_ALLGEMEIN.MyPanel(Me.components) + Me.Button1 = New System.Windows.Forms.Button() Me.txtPreis = New System.Windows.Forms.Label() Me.Label2 = New System.Windows.Forms.Label() Me.Dienstag = New System.Windows.Forms.GroupBox() @@ -78,8 +79,8 @@ Partial Class frmEssensbestellungen Me.txtAnzahlMenu = New System.Windows.Forms.Label() Me.dgvBestellungen = New VERAG_PROG_ALLGEMEIN.MyDatagridview(Me.components) Me.cbxMenu = New VERAG_PROG_ALLGEMEIN.MyComboBox() - Me.Button1 = New System.Windows.Forms.Button() Me.txtAbteilung = New System.Windows.Forms.Label() + Me.Button2 = New System.Windows.Forms.Button() Me.MyPanel1.SuspendLayout() Me.Dienstag.SuspendLayout() CType(Me.pbDienstag, System.ComponentModel.ISupportInitialize).BeginInit() @@ -189,6 +190,16 @@ Partial Class frmEssensbestellungen Me.MyPanel1.Size = New System.Drawing.Size(667, 240) Me.MyPanel1.TabIndex = 18 ' + 'Button1 + ' + Me.Button1.Image = Global.AVISO.My.Resources.Resources.pdf1 + Me.Button1.Location = New System.Drawing.Point(590, 147) + Me.Button1.Name = "Button1" + Me.Button1.Size = New System.Drawing.Size(61, 57) + Me.Button1.TabIndex = 20 + Me.Button1.UseVisualStyleBackColor = True + Me.Button1.Visible = False + ' 'txtPreis ' Me.txtPreis.AutoSize = True @@ -662,34 +673,34 @@ Partial Class frmEssensbestellungen Me.dgvBestellungen.Anchor = CType(((System.Windows.Forms.AnchorStyles.Bottom Or System.Windows.Forms.AnchorStyles.Left) _ Or System.Windows.Forms.AnchorStyles.Right), System.Windows.Forms.AnchorStyles) Me.dgvBestellungen.BackgroundColor = System.Drawing.Color.White - DataGridViewCellStyle10.Alignment = System.Windows.Forms.DataGridViewContentAlignment.MiddleLeft - DataGridViewCellStyle10.BackColor = System.Drawing.SystemColors.Control - DataGridViewCellStyle10.Font = New System.Drawing.Font("Microsoft Sans Serif", 8.25!, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, CType(0, Byte)) - DataGridViewCellStyle10.ForeColor = System.Drawing.SystemColors.WindowText - DataGridViewCellStyle10.SelectionBackColor = System.Drawing.SystemColors.Highlight - DataGridViewCellStyle10.SelectionForeColor = System.Drawing.SystemColors.HighlightText - DataGridViewCellStyle10.WrapMode = System.Windows.Forms.DataGridViewTriState.[True] - Me.dgvBestellungen.ColumnHeadersDefaultCellStyle = DataGridViewCellStyle10 + DataGridViewCellStyle1.Alignment = System.Windows.Forms.DataGridViewContentAlignment.MiddleLeft + DataGridViewCellStyle1.BackColor = System.Drawing.SystemColors.Control + DataGridViewCellStyle1.Font = New System.Drawing.Font("Microsoft Sans Serif", 8.25!, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, CType(0, Byte)) + DataGridViewCellStyle1.ForeColor = System.Drawing.SystemColors.WindowText + DataGridViewCellStyle1.SelectionBackColor = System.Drawing.SystemColors.Highlight + DataGridViewCellStyle1.SelectionForeColor = System.Drawing.SystemColors.HighlightText + DataGridViewCellStyle1.WrapMode = System.Windows.Forms.DataGridViewTriState.[True] + Me.dgvBestellungen.ColumnHeadersDefaultCellStyle = DataGridViewCellStyle1 Me.dgvBestellungen.ColumnHeadersHeightSizeMode = System.Windows.Forms.DataGridViewColumnHeadersHeightSizeMode.AutoSize - DataGridViewCellStyle11.Alignment = System.Windows.Forms.DataGridViewContentAlignment.MiddleLeft - DataGridViewCellStyle11.BackColor = System.Drawing.SystemColors.Window - DataGridViewCellStyle11.Font = New System.Drawing.Font("Microsoft Sans Serif", 8.25!, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, CType(0, Byte)) - DataGridViewCellStyle11.ForeColor = System.Drawing.SystemColors.ControlText - DataGridViewCellStyle11.SelectionBackColor = System.Drawing.SystemColors.Highlight - DataGridViewCellStyle11.SelectionForeColor = System.Drawing.SystemColors.HighlightText - DataGridViewCellStyle11.WrapMode = System.Windows.Forms.DataGridViewTriState.[False] - Me.dgvBestellungen.DefaultCellStyle = DataGridViewCellStyle11 + DataGridViewCellStyle2.Alignment = System.Windows.Forms.DataGridViewContentAlignment.MiddleLeft + DataGridViewCellStyle2.BackColor = System.Drawing.SystemColors.Window + DataGridViewCellStyle2.Font = New System.Drawing.Font("Microsoft Sans Serif", 8.25!, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, CType(0, Byte)) + DataGridViewCellStyle2.ForeColor = System.Drawing.SystemColors.ControlText + DataGridViewCellStyle2.SelectionBackColor = System.Drawing.SystemColors.Highlight + 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, 351) Me.dgvBestellungen.Name = "dgvBestellungen" Me.dgvBestellungen.ReadOnly = True - DataGridViewCellStyle12.Alignment = System.Windows.Forms.DataGridViewContentAlignment.MiddleLeft - DataGridViewCellStyle12.BackColor = System.Drawing.SystemColors.Control - DataGridViewCellStyle12.Font = New System.Drawing.Font("Microsoft Sans Serif", 8.25!, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, CType(0, Byte)) - DataGridViewCellStyle12.ForeColor = System.Drawing.SystemColors.WindowText - DataGridViewCellStyle12.SelectionBackColor = System.Drawing.SystemColors.Highlight - DataGridViewCellStyle12.SelectionForeColor = System.Drawing.SystemColors.HighlightText - DataGridViewCellStyle12.WrapMode = System.Windows.Forms.DataGridViewTriState.[True] - Me.dgvBestellungen.RowHeadersDefaultCellStyle = DataGridViewCellStyle12 + DataGridViewCellStyle3.Alignment = System.Windows.Forms.DataGridViewContentAlignment.MiddleLeft + DataGridViewCellStyle3.BackColor = System.Drawing.SystemColors.Control + DataGridViewCellStyle3.Font = New System.Drawing.Font("Microsoft Sans Serif", 8.25!, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, CType(0, Byte)) + DataGridViewCellStyle3.ForeColor = System.Drawing.SystemColors.WindowText + DataGridViewCellStyle3.SelectionBackColor = System.Drawing.SystemColors.Highlight + DataGridViewCellStyle3.SelectionForeColor = System.Drawing.SystemColors.HighlightText + DataGridViewCellStyle3.WrapMode = System.Windows.Forms.DataGridViewTriState.[True] + Me.dgvBestellungen.RowHeadersDefaultCellStyle = DataGridViewCellStyle3 Me.dgvBestellungen.SelectionMode = System.Windows.Forms.DataGridViewSelectionMode.FullRowSelect Me.dgvBestellungen.ShowEditingIcon = False Me.dgvBestellungen.Size = New System.Drawing.Size(663, 127) @@ -707,16 +718,6 @@ Partial Class frmEssensbestellungen Me.cbxMenu.Size = New System.Drawing.Size(136, 21) Me.cbxMenu.TabIndex = 0 ' - 'Button1 - ' - Me.Button1.Image = Global.AVISO.My.Resources.Resources.pdf1 - Me.Button1.Location = New System.Drawing.Point(590, 147) - Me.Button1.Name = "Button1" - Me.Button1.Size = New System.Drawing.Size(61, 57) - Me.Button1.TabIndex = 20 - Me.Button1.UseVisualStyleBackColor = True - Me.Button1.Visible = False - ' 'txtAbteilung ' Me.txtAbteilung.AutoSize = True @@ -726,11 +727,21 @@ Partial Class frmEssensbestellungen Me.txtAbteilung.TabIndex = 23 Me.txtAbteilung.Text = "EDV" ' + 'Button2 + ' + Me.Button2.Location = New System.Drawing.Point(499, 324) + Me.Button2.Name = "Button2" + Me.Button2.Size = New System.Drawing.Size(180, 21) + Me.Button2.TabIndex = 25 + Me.Button2.Text = "alle Bestellungen anzeigen" + Me.Button2.UseVisualStyleBackColor = True + ' '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.Controls.Add(Me.Button2) Me.Controls.Add(Me.txtAbteilung) Me.Controls.Add(Me.lblBestellungBis) Me.Controls.Add(Me.cbxGebauede) @@ -822,4 +833,5 @@ Partial Class frmEssensbestellungen Friend WithEvents lblBestellungBis As Label Friend WithEvents Button1 As Button Friend WithEvents txtAbteilung As Label + Friend WithEvents Button2 As Button End Class diff --git a/Aviso/frmEssensbestellungen.vb b/Aviso/frmEssensbestellungen.vb index a0101ef..04026cc 100644 --- a/Aviso/frmEssensbestellungen.vb +++ b/Aviso/frmEssensbestellungen.vb @@ -108,6 +108,8 @@ Public Class frmEssensbestellungen If cbxMenu._value Is Nothing Or cbxMenu._value = "" Then Button1.Visible = False + lblDatum.Text = "Datum: " + lblBestellungBis.Text = "" loadDGVBestellungen() btnSave.Enabled = False Exit Sub @@ -241,7 +243,7 @@ Public Class frmEssensbestellungen .Columns("eb_kw").AutoSizeMode = DataGridViewAutoSizeColumnMode.Fill .Columns("eb_kw").HeaderText = "KW" .Columns("eb_mitid").Visible = False - .Columns("eb_gebaeude").Visible = False + .Columns("eb_abteilung").Visible = False .Columns("eb_montag").Width = 80 .Columns("eb_montag").HeaderText = "Montag" @@ -254,6 +256,8 @@ Public Class frmEssensbestellungen .Columns("eb_donnerstag").Width = 80 .Columns("eb_freitag").HeaderText = "Freitag" .Columns("eb_freitag").Width = 80 + .Columns("eb_gebaeude").HeaderText = "Gebäude" + .Columns("eb_gebaeude").Width = 80 .Columns("eb_preis").HeaderText = "Preis" .Columns("eb_preis").Width = 40 .Columns("eb_preis").DefaultCellStyle.Format = "N" @@ -460,4 +464,9 @@ Public Class frmEssensbestellungen Private Sub Button1_Click(sender As Object, e As EventArgs) Handles Button1.Click 'Process.Start("\\YM5T001348\Gastro\FTPUpload\Menues\" & cbxMenu._value & ".pdf") End Sub + + + Private Sub Button2_Click(sender As Object, e As EventArgs) Handles Button2.Click + cbxMenu.changeItem("") + End Sub End Class \ No newline at end of file From 914da90d60a32b5ec000c5b3e1b1702eab5036ef Mon Sep 17 00:00:00 2001 From: "d.breimaier" Date: Wed, 30 Nov 2022 16:09:47 +0100 Subject: [PATCH 10/10] =?UTF-8?q?Berechtigung=20f=C3=BCr=20Essensbestellun?= =?UTF-8?q?g?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- Aviso/frmHauptfenster.Designer.vb | 15 ++++++++------- Aviso/frmHauptfenster.vb | 7 +++++++ 2 files changed, 15 insertions(+), 7 deletions(-) diff --git a/Aviso/frmHauptfenster.Designer.vb b/Aviso/frmHauptfenster.Designer.vb index 912b0c0..4fa17e3 100644 --- a/Aviso/frmHauptfenster.Designer.vb +++ b/Aviso/frmHauptfenster.Designer.vb @@ -126,6 +126,7 @@ Partial Class frmHauptfenster Me.ATGesamtsicherheitVeragAGToolStripMenuItem = New System.Windows.Forms.ToolStripMenuItem() Me.ATGesamtsicherheitIMEXCSGmbHToolStripMenuItem = New System.Windows.Forms.ToolStripMenuItem() Me.ATGesamtsicherheitVeragCSToolStripMenuItem = New System.Windows.Forms.ToolStripMenuItem() + Me.EssensbestellungenToolStripMenuItem = New System.Windows.Forms.ToolStripMenuItem() Me.StatistikToolStripMenuItem = New System.Windows.Forms.ToolStripMenuItem() Me.LKWBerichtToolStripMenuItem = New System.Windows.Forms.ToolStripMenuItem() Me.StatistikADMINToolStripMenuItem = New System.Windows.Forms.ToolStripMenuItem() @@ -363,7 +364,6 @@ Partial Class frmHauptfenster Me.ToolStripMenuItem19 = New System.Windows.Forms.ToolStripMenuItem() Me.ToolStripMenuItem20 = New System.Windows.Forms.ToolStripMenuItem() Me.ToolStripMenuItem21 = New System.Windows.Forms.ToolStripMenuItem() - Me.EssensbestellungenToolStripMenuItem = New System.Windows.Forms.ToolStripMenuItem() Me.conMenuAviso.SuspendLayout() Me.MenuStrip1.SuspendLayout() Me.Top.SuspendLayout() @@ -990,6 +990,13 @@ Partial Class frmHauptfenster Me.ATGesamtsicherheitVeragCSToolStripMenuItem.Text = "AT | Gesamtsicherheit Verag CS" Me.ATGesamtsicherheitVeragCSToolStripMenuItem.Visible = False ' + 'EssensbestellungenToolStripMenuItem + ' + Me.EssensbestellungenToolStripMenuItem.Name = "EssensbestellungenToolStripMenuItem" + Me.EssensbestellungenToolStripMenuItem.Size = New System.Drawing.Size(383, 22) + Me.EssensbestellungenToolStripMenuItem.Text = "Essensbestellungen" + Me.EssensbestellungenToolStripMenuItem.Visible = False + ' 'StatistikToolStripMenuItem ' Me.StatistikToolStripMenuItem.DropDownItems.AddRange(New System.Windows.Forms.ToolStripItem() {Me.LKWBerichtToolStripMenuItem, Me.StatistikADMINToolStripMenuItem, Me.ToolStripSeparator8, Me.BürgschafrtsbuchungenFremdToolStripMenuItem, Me.LKWEingetroffenNachToolStripMenuItem, Me.ToolStripSeparator7, Me.SDLAuswertungenToolStripMenuItem, Me.SDLAuswertungenToolStripMenuItem1}) @@ -3465,12 +3472,6 @@ Partial Class frmHauptfenster Me.ToolStripMenuItem21.Size = New System.Drawing.Size(121, 22) Me.ToolStripMenuItem21.Text = "GELB" ' - 'EssensbestellungenToolStripMenuItem - ' - Me.EssensbestellungenToolStripMenuItem.Name = "EssensbestellungenToolStripMenuItem" - Me.EssensbestellungenToolStripMenuItem.Size = New System.Drawing.Size(383, 22) - Me.EssensbestellungenToolStripMenuItem.Text = "Essensbestellungen" - ' 'frmHauptfenster ' Me.AutoScaleDimensions = New System.Drawing.SizeF(6.0!, 13.0!) diff --git a/Aviso/frmHauptfenster.vb b/Aviso/frmHauptfenster.vb index 8545bc6..dc5cc5d 100644 --- a/Aviso/frmHauptfenster.vb +++ b/Aviso/frmHauptfenster.vb @@ -536,6 +536,13 @@ Public Class frmHauptfenster btnKassenbuch.Visible = True End If + If VERAG_PROG_ALLGEMEIN.cBerechtignunen.CHECK_BERECHTIGUNG_bool("ESSENSBESTELLUNGEN", "AVISO") Then + Select Case VERAG_PROG_ALLGEMEIN.cAllgemein.FIRMA + Case "FRONTOFFICE", "VERAG", "IMEX" + EssensbestellungenToolStripMenuItem.Visible = True + End Select + End If + Panel1.Height -= pnlSearch.Height End Sub